Author |
Message |
testy1
Involved
![Involved Involved](modules/Forums/images/ranks/4stars.gif)
![](modules/Forums/images/avatars/gallery/blank.gif)
Joined: Apr 06, 2008
Posts: 484
|
Posted:
Tue Oct 27, 2009 5:32 pm |
|
Some errors and assorted for future reference.
Currently using php 5.3 and thought I would log some of the errors.
Deprecated: Assigning the return value of new by reference is deprecated in includes\xmlrpc\xmlrpc.php on line 554
Fixed these errors using the following function, although probably not the best way :(
Code:function & rn_newref(&$new_value) {
return $new_value;
}
|
then for example find:
Code:
$client =& new xmlrpc_client('/version.php', 'nukeseo.com', 80);
|
Change To:
Code:
$client =& rn_newref(new xmlrpc_client('/version.php', 'nukeseo.com', 80));
|
Error: Function split() is deprecated in includes\xmlrpc\xmlrpc.php on line 2272
Find:
Code:$ar = split("\r?\n", trim(substr($data, 0, $pos)));
|
Change To:
Code:
$ar = explode("\r?\n", trim(substr($data, 0, $pos)));
|
Other Errors:
All ereg need to be replaced
Code:
ereg()
ereg_replace()
|
Link:
Code:admin.php?op=ABTrackedAgentsPages&tid=1
|
Notice: Undefined variable: perpage in admin\modules\nukesentinel\ABTrackedAgentsPages.php on line 23 |
|
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
nuken
RavenNuke(tm) Development Team
![](modules/Forums/images/avatars/3234de284ee21bd39eecd.jpg)
Joined: Mar 11, 2007
Posts: 2024
Location: North Carolina
|
Posted:
Tue Oct 27, 2009 5:52 pm |
|
Those deprecated warnings in php 5.3 are known. They are still fully supported in php 5.3 and will be up until php 6. They will all be addressed well before php 6 is released. To remove them for testing purposes, in rnconfig.php find Code:$error_reporting = E_ALL^E_NOTICE;
| and replace with Code:$error_reporting = E_ALL^E_NOTICE^E_DEPRECATED;
| and that will suppress the reporting of deprecated errors.
EDIT: also the best way to handle the deprecated split and ereg will be with the Perl-compatible preg family IMO. |
_________________ Only registered users can see links on this board! Get registered or login!
Last edited by nuken on Tue Nov 03, 2009 6:26 pm; edited 1 time in total |
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
testy1
![](modules/Forums/images/avatars/gallery/blank.gif)
|
Posted:
Tue Oct 27, 2009 9:09 pm |
|
nuken wrote: | Those depreciated warnings in php 5.3 are known. They are still fully supported in php 5.3 and will be up until php 6. They will all be addressed well before php 6 is released. To remove them for testing purposes, in rnconfig.php find Code:$error_reporting = E_ALL^E_NOTICE;
| and replace with Code:$error_reporting = E_ALL^E_NOTICE^E_DEPRECATED;
| and that will suppress the reporting of depreciated errors.
EDIT: also the best way to handle the depreciated split and ereg will be with the Perl-compatible preg family IMO. |
I understand its just a notice basically but ultimately it should be fixed.Well thats the way I code anyway.Just thought I'd post it up for future reference.I always thought explode was faster unless you specifically needed to use regex. |
|
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
Raven
Site Admin/Owner
![](modules/Forums/images/avatars/45030c033f18773153cd2.gif)
Joined: Aug 27, 2002
Posts: 17088
|
Posted:
Wed Oct 28, 2009 12:23 am |
|
Thanks Testy1 . Btw, Explode carries some security issues if not handled just right.
Nuken: You are correct and we should probably add $error_reporting = E_ALL^E_NOTICE^E_DEPRECATED; as our default. Please enter a Mantis issue on this and mark it for v2.40.01 . Thanks! |
Last edited by Raven on Wed Oct 28, 2009 6:25 pm; edited 1 time in total |
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
nuken
![](modules/Forums/images/avatars/gallery/blank.gif)
|
Posted:
Wed Oct 28, 2009 9:36 am |
|
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
eldorado
Involved
![Involved Involved](modules/Forums/images/ranks/4stars.gif)
![](modules/Forums/images/avatars/52f4453749f5c4a233463.gif)
Joined: Sep 10, 2008
Posts: 424
Location: France,Translator
|
Posted:
Wed Oct 28, 2009 5:50 pm |
|
Raven wrote: | Please enter a Mantis issue on this and mark it for v2.30.01 . Thanks! |
yey retroactive fix
nah just kidding it's late and I've been fiddling with 5.3 tonight , getting on my nerves.
Btw , I didn't get how you cloned split() |
_________________ Only registered users can see links on this board! Get registered or login! (My RN site)- Only registered users can see links on this board! Get registered or login!(cod4 clan) - Only registered users can see links on this board! Get registered or login! |
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
Raven
![](modules/Forums/images/avatars/gallery/blank.gif)
|
Posted:
Wed Oct 28, 2009 6:27 pm |
|
Thanks for the catch ![killing me](modules/Forums/images/smiles/killingme.gif) |
|
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
montego
Site Admin
![](modules/Forums/images/avatars/0c0adf824792d6d341ef4.gif)
Joined: Aug 29, 2004
Posts: 9457
Location: Arizona
|
Posted:
Sat Oct 31, 2009 9:05 am |
|
This is assigned to me and this is how I intend to implement and would like some testing by Testy1 as I do not have 5.3 nor the time ATM to install it:
Code:
$error_reporting = E_ALL^E_NOTICE; // This is the default and means: All errors except Notices
if (defined('E_DEPRECATED')) $error_reporting = $error_reporting^E_DEPRECATED; // If want to see these warnings when running PHP5.3, comment out this IF statement
|
I am still needing to hunt down the constant value so that I can place it in the comments above.
Let me know how this works. It will gracefully degrade for lower PHP's which do not have that constant defined. |
_________________ Only registered users can see links on this board! Get registered or login!
Only registered users can see links on this board! Get registered or login! |
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
eldorado
![](modules/Forums/images/avatars/gallery/blank.gif)
|
Posted:
Sat Oct 31, 2009 5:59 pm |
|
huhm....? I'll test this ![Smile](modules/Forums/images/smiles/icon_smile.gif) |
|
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
testy1
![](modules/Forums/images/avatars/gallery/blank.gif)
|
Posted:
Sat Oct 31, 2009 9:54 pm |
|
As a quick note; I have used xampp on my windows box for about 3 years, but recently decided to try wamp.It allows me to easily install the multiple versions of php, mysql, apache (including beta versions) with a quick automated install.and at the click of a button it restarts the server with a different version.I wont be going back to xampp
Ok some testing;
My Version Info
Apache: 2.2.13
PHP: 5.3.0
MySQL: 5.1.36
With a default install of ravennuke 2.4 it displays the following errors at the top of the page
Code:
Deprecated: Function set_magic_quotes_runtime() is deprecated in E:\wamp\www\raven\rnconfig.php on line 267
Deprecated: Function ereg() is deprecated in E:\wamp\www\raven\includes\ipban.php on line 22
Deprecated: Function eregi() is deprecated in E:\wamp\www\raven\modules\Your_Account\includes\mainfileend.php on line 17
Deprecated: Function eregi() is deprecated in E:\wamp\www\raven\modules\Your_Account\includes\constants.php on line 17
|
After making suggested changes in rnconfig.php I get the following error still.
Code:
Deprecated: Function set_magic_quotes_runtime() is deprecated in E:\wamp\www\raven\rnconfig.php on line 267
|
so it seems that there also needs to be a php version check to the new ini setting at the bottom of rnconfig.php
Note: It also displays all the errors once you comment out your changes.Also the changes you suggested seem to work fine in php version 5.2.11.
Some other test's I did for further info if needed....
Apache: 2.2.13
PHP: 5.2.11
MySQL: 5.1.36
Quote: |
Test 1
Code:
$error_reporting = E_ALL;
|
The above outputs
Test 2
Code:
$error_reporting = E_NOTICE;
|
The above outputs
Test 3
Code:
$error_reporting = E_STRICT;
|
The above outputs
Test 4
Code:
$error_reporting = E_ALL^E_NOTICE;
|
The above outputs
|
Apache: 2.2.13
PHP: 5.3.0
MySQL: 5.1.36
Quote: |
Test 1
Code:
$error_reporting = E_ALL;
|
The above outputs
Test 2
Code:
$error_reporting = E_NOTICE;
|
The above outputs
Test 3
Code:
$error_reporting = E_STRICT;
|
The above outputs
Test 4
Code:
$error_reporting = E_ALL^E_NOTICE;
|
The above outputs
Test 5
Code:
$error_reporting = E_DEPRECATED;
|
The above outputs
|
|
|
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
montego
![](modules/Forums/images/avatars/gallery/blank.gif)
|
Posted:
Tue Nov 03, 2009 6:43 am |
|
testy1, this is excellent info... I did manage to find the constant values. That is a real PITA about the other error and THANKS for letting me know that!
The reason for that is the error level isn't actually set until further down in mainfile.php which is why the warning is still be shown. I don't think I can just move that, which would be the ideal. I'll look into it.
Thanks again m8! |
|
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
testy1
![](modules/Forums/images/avatars/gallery/blank.gif)
|
Posted:
Tue Nov 03, 2009 4:03 pm |
|
just moving it sounds way to easy lol,
Good rule of thumb is if you have 1 hour spare it will take at least 4 hours ![Smile](modules/Forums/images/smiles/icon_smile.gif) |
|
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
Unit1
Worker
![Worker Worker](modules/Forums/images/ranks/3stars.gif)
![](modules/Forums/images/avatars/blank.gif)
Joined: Oct 26, 2004
Posts: 134
Location: Boston
|
Posted:
Tue Nov 03, 2009 4:39 pm |
|
testy1 wrote: | just moving it sounds way to easy lol,
Good rule of thumb is if you have 1 hour spare it will take at least 4 hours |
So True ![Laughing](modules/Forums/images/smiles/icon_lol.gif) |
_________________ * 5 Simple rules to be happy: * Free Your Heart from Hatred * Free Your Mind from Worries * Live Simply * Give More * Expect Less. |
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
silicastorm
New Member
![New Member New Member](modules/Forums/images/ranks/1star.gif)
![](modules/Forums/images/avatars/d9a471454b5f1a6f99d03.jpg)
Joined: Jan 15, 2010
Posts: 22
Location: Abu Dhabi, UAE
|
Posted:
Wed Jan 27, 2010 10:18 pm |
|
Good Day,
Currently in production server running phpnuke 8.0 + Nuke Sentinal 2.6.01 and combined with the bbantispam has stabilized the site from intrusions.
Now starting a migration with a complete new install of RN in a test environment.
In Windose platform with XAMPP 1.7.3 I was able to complete the installation without issue to "Install RavenNuke Tables" - with no issue.
Now attempting to access admin.php and recieve the following error:
Quote: | Deprecated: Function ereg() is deprecated in C:\xampp\htdocs\dspx360\includes\ipban.php on line 22 |
Followed Montego suggestion to edit rnconfig.php
Code:$error_reporting = E_ALL^E_NOTICE; // This is the default and means: All errors except Notices
if (defined('E_DEPRECATED')) $error_reporting = $error_reporting^E_DEPRECATED; // If want to see these warnings when running PHP5.3, comment out this IF statement
|
but now only a white page with the comical "Nice Try"
Let me know if I have missed something, |
_________________ http://www.xbox360project.com |
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
Raven
![](modules/Forums/images/avatars/gallery/blank.gif)
|
Posted:
Thu Jan 28, 2010 2:35 am |
|
Check your server log and/or PHP log for errors. |
|
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
Raven
![](modules/Forums/images/avatars/gallery/blank.gif)
|
Posted:
Thu Jan 28, 2010 2:38 am |
|
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
silicastorm
![](modules/Forums/images/avatars/gallery/blank.gif)
|
Posted:
Thu Jan 28, 2010 10:15 am |
|
This is the Apache Error Log:
Quote: | [Thu Jan 28 20:09:44 2010] [notice] Digest: generating secret for digest authentication ...
[Thu Jan 28 20:09:44 2010] [notice] Digest: done
[Thu Jan 28 20:09:44 2010] [notice] Apache/2.2.14 (Win32) DAV/2 mod_ssl/2.2.14 OpenSSL/0.9.8l mod_autoindex_color PHP/5.3.1 mod_apreq2-20090110/2.7.1 mod_perl/2.0.4 Perl/v5.10.1 configured -- resuming normal operations
[Thu Jan 28 20:09:44 2010] [notice] Server built: Nov 11 2009 14:29:03
[Thu Jan 28 20:09:44 2010] [notice] Parent: Created child process 2164
[Thu Jan 28 20:09:46 2010] [notice] Digest: generating secret for digest authentication ...
[Thu Jan 28 20:09:46 2010] [notice] Digest: done
[Thu Jan 28 20:09:46 2010] [notice] Child 2164: Child process is running
[Thu Jan 28 20:09:46 2010] [notice] Child 2164: Acquired the start mutex.
[Thu Jan 28 20:09:46 2010] [notice] Child 2164: Starting 150 worker threads.
[Thu Jan 28 20:09:46 2010] [notice] Child 2164: Starting thread to listen on port 80.
[Thu Jan 28 20:09:46 2010] [notice] Child 2164: Starting thread to listen on port 443.
[Thu Jan 28 20:09:46 2010] [notice] Child 2164: Starting thread to listen on port 80.
[Thu Jan 28 20:09:46 2010] [notice] Child 2164: Starting thread to listen on port 443. |
@ Raven: sorry but I have no idea what math you want me to do...
Quote: | Then to combine settings just do the math Wink
|
|
|
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
Palbin
Site Admin
![](modules/Forums/images/avatars/Dilbert/Dilbert_-_Dogbert_King.gif)
Joined: Mar 30, 2006
Posts: 2583
Location: Pittsburgh, Pennsylvania
|
Posted:
Thu Jan 28, 2010 11:29 am |
|
Try changing it to just this
Code:
$error_reporting = E_ALL^E_NOTICE^E_DEPRECATED;
|
|
_________________ "Debugging is twice as hard as writing the code in the first place. Therefore, if you write the code as cleverly as possible, you are, by definition, not smart enough to debug it." — Brian W. Kernighan. |
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
Palbin
![](modules/Forums/images/avatars/gallery/blank.gif)
|
Posted:
Thu Jan 28, 2010 11:32 am |
|
montego wrote: | This is assigned to me and this is how I intend to implement and would like some testing by Testy1 as I do not have 5.3 nor the time ATM to install it:
Code:
$error_reporting = E_ALL^E_NOTICE; // This is the default and means: All errors except Notices
if (defined('E_DEPRECATED')) $error_reporting = $error_reporting^E_DEPRECATED; // If want to see these warnings when running PHP5.3, comment out this IF statement
|
I am still needing to hunt down the constant value so that I can place it in the comments above.
Let me know how this works. It will gracefully degrade for lower PHP's which do not have that constant defined. |
Montego, I don't have 5.3 either, but wouldn't it have to be this?
if (defined('E_DEPRECATED')) $error_reporting = $error_reporting . ^E_DEPRECATED; |
|
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
silicastorm
![](modules/Forums/images/avatars/gallery/blank.gif)
|
Posted:
Thu Jan 28, 2010 11:50 am |
|
Ok made the suggested revision and returned the following error:
Quote: | Parse error: syntax error, unexpected '^' in C:\xampp\htdocs\dspx360\rnconfig.php on line 83 |
Thanks for your help guys,,, is this because I am using XAMPP with PHP 5.3.1 ?
Should I find an old version of XAMPP to install?
Didn't expect to have issues this early in the install.... sorry to bother you guys with this as it is only a test environment. |
|
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
Palbin
![](modules/Forums/images/avatars/gallery/blank.gif)
|
Posted:
Thu Jan 28, 2010 1:02 pm |
|
Replace everything you have done with simply this:
Code:
$error_reporting = E_ALL^E_NOTICE^E_DEPRECATED;
|
|
|
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
silicastorm
![](modules/Forums/images/avatars/gallery/blank.gif)
|
Posted:
Thu Jan 28, 2010 1:24 pm |
|
Right back to the same error in the beginning: White Page "Nice Try" |
|
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
montego
![](modules/Forums/images/avatars/gallery/blank.gif)
|
Posted:
Fri Jan 29, 2010 7:00 am |
|
silicastorm, I believe you have gotten past the PHP errors and are now running into a situation where you are trying to do something that RN's code does not like. So, one issue down and now on to the next.
I have searched through my library of 2.30.00 and 2.40.00 distributions and I cannot find "Nice Try" as text within the code. I know it has to be there, so my searches are failing me. Unfortunately, I have to get moving to get to work... I'll try this again tonight if no-one beats me to it.
Palbin, per your question here
Code:
Montego, I don't have 5.3 either, but wouldn't it have to be this?
if (defined('E_DEPRECATED')) $error_reporting = $error_reporting . ^E_DEPRECATED;
|
The answer is that $error_reporting is NOT a string, therefore, we don't concatenate it. We're trying to adjust the final integer value that is holds to include the removal of deprecated warnings. |
|
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
spasticdonkey
RavenNuke(tm) Development Team
![](modules/Forums/images/avatars/48fb116845dfecf66294c.gif)
Joined: Dec 02, 2006
Posts: 1693
Location: Texas, USA
|
Posted:
Fri Jan 29, 2010 7:40 am |
|
this is in includes/ipban.php
Code:$ip = $_SERVER['REMOTE_ADDR'];
if(!ereg('^([0-9]{1,3})\\.([0-9]{1,3})\\.([0-9]{1,3})\\.([0-9]{1,3})$', $ip)) die('Nice try!!');
|
I think your problem may be related to your XAMPP and/or test sever setup |
|
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
silicastorm
![](modules/Forums/images/avatars/gallery/blank.gif)
|
Posted:
Fri Jan 29, 2010 9:02 pm |
|
Ok, thanks everyone,,,
1) now uninstalling XAMPP
2) installed Wamp Server
a. activated "rewrite_module" - Apache
b. using PHP 5.2.9
c. activated PHP "magic quotes gpc"
Recieve this error at top of page: (No more white blank page) can see CMS
Quote: | Notice: Use of undefined constant E_DEPRECATED - assumed 'E_DEPRECATED' in C:\wamp\www\dspx360\rnconfig.php on line 82 |
And this is line 82:
Code:*********************************************************************************/
$error_reporting = E_ALL^E_NOTICE^E_DEPRECATED;
/*********************************************************************************
|
|
|
|
|
![](themes/RavenIce/forums/images/spacer.gif) |
|