Author |
Message |
Doulos
Life Cycles Becoming CPU Cycles
![](modules/Forums/images/avatars/181553f049aa2a5924cda.jpg)
Joined: Jun 06, 2005
Posts: 732
|
Posted:
Sat Nov 09, 2019 4:40 am |
|
Got it. I doubt if I'll remember it, but for now I got it.
Thanks. |
|
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
Doulos
![](modules/Forums/images/avatars/gallery/blank.gif)
|
Posted:
Thu Dec 12, 2019 12:17 pm |
|
Getting this in error log:Code:[12-Dec-2019 06:45:44 America/Chicago] PHP Notice: Undefined variable: sid in /home/meme
| /public_html/modules/News/friend.php on line 26 |
|
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
neralex
Site Admin
![](modules/Forums/images/avatars/201442295664a46e4575d46.jpg)
Joined: Aug 22, 2007
Posts: 1775
|
Posted:
Thu Dec 12, 2019 1:35 pm |
|
Thanks for the report.
This is not a real issue. This is the result, when you request this file outside of the functinality. If you are logged in as user and your are using the "Send to a Friend" link from a story of the News module, you will get a form, where you can enter "Your Friend's Name" and "Your Friend's E-mail". If you are not logged in, then you get a redirect to the full article-view of the story. Only if you doesn't pass the variable into this function, then you get this warning. This behavoir is outside of the logic of the functionality but it is not a bad idea to prevent this usage.
Example: Only registered users can see links on this board! Get registered or login!
If you want prevent this warning, you could add an header-redirect to the index before the variable: $sid is used in this file.
Find:
php Code:$pagetitle = '- ' . _RECOMMEND;
|
Add after:
php Code:if (empty($sid)) {Header('Location: index.php');}
|
Note: added to the github repo: https://github.com/neralex/RavenNuke/commit/6fbc168acbae25d07104365b25c3fe5836335f62
![Wink](modules/Forums/images/smiles/icon_wink.gif) |
_________________ Only registered users can see links on this board! Get registered or login! |
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
Doulos
![](modules/Forums/images/avatars/gallery/blank.gif)
|
Posted:
Sun Dec 15, 2019 4:41 pm |
|
Getting a bunch of these is log:
Code:PHP Warning: preg_match(): Unknown modifier 't' in /home/meme/public_html/includes/nukesentinel.php on line 479
|
|
|
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
neralex
![](modules/Forums/images/avatars/gallery/blank.gif)
|
Posted:
Mon Dec 16, 2019 10:15 am |
|
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
Doulos
![](modules/Forums/images/avatars/gallery/blank.gif)
|
Posted:
Mon Dec 16, 2019 12:27 pm |
|
Yes, same result. The logs show several instances of what I posted, and several with other "modifiers". Sorry, I didn't want to post the whole thing - and I've deleted it now. I don't understand it good enough to even tell you what the modifier is in that line - but I think it is / . I saw another post here where someone suggested trying to replace / with # to see if that worked. I assumed it meant something like this:
Code:if (isset($name) && !preg_match('^name=' . $name . '/i', $pg) && stristr($nsnst_const['script_name'], 'modules.php')) { $mod_check = 1; }
|
I thought I'd check here to see if you agreed before I changed it to Code:if (isset($name) && !preg_match('#^name=' . $name . '#i', $pg) && stristr($nsnst_const['script_name'], 'modules.php')) { $mod_check = 1; }
|
|
|
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
neralex
![](modules/Forums/images/avatars/gallery/blank.gif)
|
Posted:
Tue Dec 17, 2019 12:45 am |
|
I don't get these warnings. Which PHP-version you are using and which settings you have enabled in Sentinel? Can you please post the link to the thread, which you mean?
On all my local installations and also here on RPS with PHP 7.3.12 I don't get these warnings with enabled IP tracking and full PHP error-reporting. |
|
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
kd8hho
Worker
![Worker Worker](modules/Forums/images/ranks/3stars.gif)
![](modules/Forums/images/avatars/62dea0774a2ec5e8975fc.png)
Joined: Mar 30, 2009
Posts: 132
|
Posted:
Tue Dec 17, 2019 12:31 pm |
|
I just made a new site, (i got bored and its been awhile lol) anyway using the latest RN (php7) everything seems to work fine outside of nukespam. it does not give me a way to put in my SFS and PHpot api keys, any ideas how to fix? I was thinking maybe sql didn't install correctly and was missing something but I found the lines in the db and attempted to manually enter the key via phpmyadmin but the key gets wiped out. |
_________________ Linux Register User #481509 | Ubuntu Register User #25492 |
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
Doulos
![](modules/Forums/images/avatars/gallery/blank.gif)
|
Posted:
Tue Dec 17, 2019 12:41 pm |
|
neralex wrote: | I don't get these warnings. Which PHP-version you are using and which settings you have enabled in Sentinel? Can you please post the link to the thread, which you mean?
On all my local installations and also here on RPS with PHP 7.3.12 I don't get these warnings with enabled IP tracking and full PHP error-reporting. |
Actually, I just noticed that is is not a post about preg_match() but here is where I got the idea from https://www.ravenphpscripts.com/ftopict-21325-preg_match.html%28%29%3A+Unknown+modifier
PHP 7.3.12, IP tracking enabled. This is a cPanel account and I am looking at logs in /home/meme/logs/meme_com.php.error.log. No errors are showing up in /public_html
i have no idea what is happening to cause the errors. I have been unable to actually cause it intentionally - they just show up in the log. |
|
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
neralex
![](modules/Forums/images/avatars/gallery/blank.gif)
|
Posted:
Tue Dec 17, 2019 3:13 pm |
|
kd8hho wrote: | I just made a new site, (i got bored and its been awhile lol) anyway using the latest RN (php7) everything seems to work fine outside of nukespam. it does not give me a way to put in my SFS and PHpot api keys, any ideas how to fix? I was thinking maybe sql didn't install correctly and was missing something but I found the lines in the db and attempted to manually enter the key via phpmyadmin but the key gets wiped out. |
Darn, this was my fault.
Let me say THANK YOU for this report! It was a simple logic-mistake while fixing some PHP7-warnings some moons ago.
You can fix it easily, just open /modules/nukeSPAM/admin/nukeSPAMConfig.php and find:
php Code:if (!empty($key) && !empty($seo_config[$key])) {
|
Replace it with:
php Code:if (!empty($key) && isset($seo_config[$key])) {
|
You can also download this file again from the master-branch on github and replace it with yours.
FYI: just added to the github repo: https://github.com/neralex/RavenNuke/commit/1e8174fe1f21d44a1d5d8d5281e7c9b883cd2118
![Wink](modules/Forums/images/smiles/icon_wink.gif) |
|
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
neralex
![](modules/Forums/images/avatars/gallery/blank.gif)
|
Posted:
Tue Dec 17, 2019 3:17 pm |
|
Doulos, thank you. I will test it in the next days and keep an eye on it. Somewhere is the cause for these warnings. |
|
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
kd8hho
![](modules/Forums/images/avatars/gallery/blank.gif)
|
Posted:
Tue Dec 17, 2019 4:02 pm |
|
neralex wrote: | Darn, this was my fault.
Let me say THANK YOU for this report! It was a simple logic-mistake while fixing some PHP7-warnings some moons ago.
|
Welcome, it is kind of an important thing lol. the fix you gave fixes the issue. |
|
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
Doulos
![](modules/Forums/images/avatars/gallery/blank.gif)
|
Posted:
Wed Dec 18, 2019 3:55 am |
|
FYI, this did not stop the PHP warnings for this issue:
neralex wrote: | Thanks for the report.
This is not a real issue. This is the result, when you request this file outside of the functinality. If you are logged in as user and your are using the "Send to a Friend" link from a story of the News module, you will get a form, where you can enter "Your Friend's Name" and "Your Friend's E-mail". If you are not logged in, then you get a redirect to the full article-view of the story. Only if you doesn't pass the variable into this function, then you get this warning. This behavoir is outside of the logic of the functionality but it is not a bad idea to prevent this usage.
Example: Only registered users can see links on this board! Get registered or login!
If you want prevent this warning, you could add an header-redirect to the index before the variable: $sid is used in this file.
Find:
php Code:$pagetitle = '- ' . _RECOMMEND;
|
Add after:
php Code:if (empty($sid)) {Header('Location: index.php');}
|
Note: added to the github repo: https://github.com/neralex/RavenNuke/commit/6fbc168acbae25d07104365b25c3fe5836335f62
|
|
|
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
neralex
![](modules/Forums/images/avatars/gallery/blank.gif)
|
Posted:
Wed Dec 18, 2019 8:08 am |
|
Not sure from which files you are getting all these warnings but not from this file because you can not use it anymore without enter a sid-value in the URL. If the sid is empty, then you get an redirect to the index. Do you have an older installation of RN running on your server, besides the patched php7 package? |
|
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
Doulos
![](modules/Forums/images/avatars/gallery/blank.gif)
|
Posted:
Wed Dec 18, 2019 1:34 pm |
|
neralex wrote: | Not sure from which files you are getting all these warnings but not from this file because you can not use it anymore without enter a sid-value in the URL. If the sid is empty, then you get an redirect to the index. Do you have an older installation of RN running on your server, besides the patched php7 package? |
No, only RN252. However, it is modified and then upgraded 2.51 version that I incrementally updated as you posted things to this thread, not one built up from a fresh install. Whenever I find a warning (or error) the first thing I do is upload the files referenced as well as all known associated files to the server. I am finding that in many cases the files on the server are a different size than those being uploaded. In the latest case of this warning all files were the same size as the latest Git master-branch. I always update my local copy of the master-branch before uploading.
Sorry if this is causing you troubles trying to fix my issues. |
|
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
neralex
![](modules/Forums/images/avatars/gallery/blank.gif)
|
Posted:
Wed Dec 18, 2019 2:52 pm |
|
Ok please test it with this link-example and replace the sid-value with a value of an existing Story-id (sid) in your database.
/modules.php?name=News&file=friend&op=FriendSend&sid=4
Then remove the sid-value from the link in your browser-bar, hit enter and check your php error-logs. If the issue still exist, then you should get a new log-entry. |
|
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
Doulos
![](modules/Forums/images/avatars/gallery/blank.gif)
|
Posted:
Thu Dec 19, 2019 3:47 am |
|
Works exactly as you said it should. No error with sid - index page without sid. Makes no sense to me why I am still getting this warning occasionally.
Anyway, here is the latest Code:[19-Dec-2019 00:25:16 America/Chicago] PHP Notice: Undefined index: y in /home/clanfga/public_html/modules/GCalendar/viewweek.php on line 252
[19-Dec-2019 00:25:16 America/Chicago] PHP Notice: Undefined index: m in /home/clanfga/public_html/modules/GCalendar/viewweek.php on line 253
[19-Dec-2019 00:25:16 America/Chicago] PHP Notice: Undefined index: d in /home/clanfga/public_html/modules/GCalendar/viewweek.php on line 254
|
Yes, the files are from the latest git master |
|
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
neralex
![](modules/Forums/images/avatars/gallery/blank.gif)
|
Posted:
Thu Dec 19, 2019 11:43 am |
|
Doulos wrote: | Anyway, here is the latest Code:[19-Dec-2019 00:25:16 America/Chicago] PHP Notice: Undefined index: y in /home/clanfga/public_html/modules/GCalendar/viewweek.php on line 252
[19-Dec-2019 00:25:16 America/Chicago] PHP Notice: Undefined index: m in /home/clanfga/public_html/modules/GCalendar/viewweek.php on line 253
[19-Dec-2019 00:25:16 America/Chicago] PHP Notice: Undefined index: d in /home/clanfga/public_html/modules/GCalendar/viewweek.php on line 254
|
Yes, the files are from the latest git master |
Thanks, it is fixed: https://github.com/neralex/RavenNuke/commit/e079d0618f55fadf1e859477a94e80cf37f6a8a0 |
|
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
kd8hho
![](modules/Forums/images/avatars/gallery/blank.gif)
|
Posted:
Fri Dec 20, 2019 11:43 am |
|
one thing bugs me, RSS feeds in the blocks is there any way we can get the rss feed link to open in a new tab? |
|
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
neralex
![](modules/Forums/images/avatars/gallery/blank.gif)
|
Posted:
Fri Dec 20, 2019 11:59 am |
|
kd8hho wrote: | one thing bugs me, RSS feeds in the blocks is there any way we can get the rss feed link to open in a new tab? |
EDIT: Removed because wrong block-file! |
Last edited by neralex on Sun Dec 22, 2019 4:01 am; edited 1 time in total |
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
kd8hho
![](modules/Forums/images/avatars/gallery/blank.gif)
|
Posted:
Fri Dec 20, 2019 12:12 pm |
|
neralex wrote: | kd8hho wrote: | one thing bugs me, RSS feeds in the blocks is there any way we can get the rss feed link to open in a new tab? |
EDIT: Removed because wrong block-file! |
not working for me, still opens in current window. chromium/linux |
|
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
neralex
![](modules/Forums/images/avatars/gallery/blank.gif)
|
Posted:
Sat Dec 21, 2019 6:47 am |
|
At first to make one thing clear - this not a BUG - this is only based your own personal preferences.
If you are using the built-in function in the Blocks-Administration, then you can only modify the mainfile.php but this is not recommanded because after each upgrade to a new version, you will have to modify it again. So make you a notice on a save place for reminding on this.
open mainfile.php and find:
php Code:$content .= '<a href="' . $item->get_permalink() . '" title="';
|
Replace it with:
php Code:$content .= '<a target="_blank" href="' . $item->get_permalink() . '" title="';
|
BTW: a simple click on your mouse-wheel just do it.
![Wink](modules/Forums/images/smiles/icon_wink.gif) |
|
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
kd8hho
![](modules/Forums/images/avatars/gallery/blank.gif)
|
Posted:
Sat Dec 21, 2019 3:01 pm |
|
neralex wrote: | At first to make one thing clear - this not a BUG - this is only based your own personal preferences.
If you are using the built-in function in the Blocks-Administration, then you can only modify the mainfile.php but this is not recommanded because after each upgrade to a new version, you will have to modify it again. So make you a notice on a save place for reminding on this.
open mainfile.php and find:
php Code:$content .= '<a href="' . $item->get_permalink() . '" title="';
|
Replace it with:
php Code:$content .= '<a target="_blank" href="' . $item->get_permalink() . '" title="';
|
BTW: a simple click on your mouse-wheel just do it.
|
thanks, that was the ticket. I had done it before on a old site I had some years ago but could not for the life of me remember how I did it. (I been away from the game for a long while now lol)
(i have forgot a lot, since I had the heart attack back in sept. my memory is well bad.)
the last thing I hope, Downloads admin - add download. wasn't there a browser upload function? I see in the submit downloads module the only way to add is via browser upload, I was thinking browser upload was also in the downloads admin but I don't see it, just the text box for manually linking url. |
|
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
Doulos
![](modules/Forums/images/avatars/gallery/blank.gif)
|
Posted:
Sat Dec 21, 2019 7:28 pm |
|
Another one: Code:[21-Dec-2019 18:18:45 America/Chicago] PHP Warning: array_keys() expects parameter 1 to be array, string given in /home/meme/public_html/modules/Your_Account/public/new_confirm.php on line 159
|
|
|
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
neralex
![](modules/Forums/images/avatars/gallery/blank.gif)
|
Posted:
Sun Dec 22, 2019 3:51 am |
|
kd8hho, no worries.
There is no upload-function inside the Downloads-Administration. It makes also not really sense to a add it because it comes along with to many server-sided limitations. If you have file-access via FTP, you can paste the path in the form. If not, you can paste a path to a external source without to get trouble with limitations like upload-size etc, which can only be controlled by an server-admin. On shared-hosting you will reached the limitations quickly. |
Last edited by neralex on Sun Dec 22, 2019 4:12 am; edited 1 time in total |
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
|