Fixing Deprecated: Assigning the return value of new by reference is deprecated
-
We’re running PHP 5.3.8 – need to run this because of new features in PHP
WP 3.2.1
We’re getting Deprecated: Assigning the return value of new by reference is deprecated in errors all over the admin. We have a very large blog. This is significantly slowing down the server….
I need a fix to this deprecated problem. Sounds like a core wordpress problem. Not turn off error reporting, but a fix because having thousands of these deprecated errors really adds up.
Does anyone have a timeframe for when this will be solved, or an easy solution?
-
Whats the full and complete error?
If it’s caused by a plugin or theme, you’ll need to turn that OFF to resolve the issue, but it’s probably not core, or everyone on PHP 5.3.8 would have reported this.
Turned off all plugins. Theme is twenty eleven. When I log into admin under Dashboard incoming links I have the following, and there are a LOT more than listed here. Also have similar errors under WordPress Blog and Plugins on the dashboard.
Deprecated: Assigning the return value of new by reference is deprecated in /home/nfcsocia/public_html/wp-includes/class-simplepie.php on line 738
Deprecated: Assigning the return value of new by reference is deprecated in /home/nfcsocia/public_html/wp-includes/class-simplepie.php on line 1108
Deprecated: Assigning the return value of new by reference is deprecated in /home/nfcsocia/public_html/wp-includes/class-simplepie.php on line 1602
Deprecated: Assigning the return value of new by reference is deprecated in /home/nfcsocia/public_html/wp-includes/class-simplepie.php on line 1643
Deprecated: Assigning the return value of new by reference is deprecated in /home/nfcsocia/public_html/wp-includes/class-simplepie.php on line 1663
Deprecated: Assigning the return value of new by reference is deprecated in /home/nfcsocia/public_html/wp-includes/class-simplepie.php on line 1693
Deprecated: Assigning the return value of new by reference is deprecated in /home/nfcsocia/public_html/wp-includes/class-simplepie.php on line 1763
Deprecated: Assigning the return value of new by reference is deprecated in /home/nfcsocia/public_html/wp-includes/class-simplepie.php on line 1974
Deprecated: Assigning the return value of new by reference is deprecated in /home/nfcsocia/public_html/wp-includes/class-simplepie.php on line 1978
Deprecated: Assigning the return value of new by reference is deprecated in /home/nfcsocia/public_html/wp-includes/class-simplepie.php on line 2377
Deprecated: Assigning the return value of new by reference is deprecated in /home/nfcsocia/public_html/wp-includes/class-simplepie.php on line 2392
Deprecated: Assigning the return value of new by reference is deprecated in /home/nfcsocia/public_html/wp-includes/class-simplepie.php on line 2396
Deprecated: Assigning the return value of new by reference is deprecated in /home/nfcsocia/public_html/wp-includes/class-simplepie.php on line 2400
there are no problems with my wp on PHP 5.3.8
When I log into admin under Dashboard incoming links I have the following
Do you have debugging turned on in your wp-config.php file?
I don’t know where it came from – same thing hit me out of the blue. I have it too now on WP 3.3.1 and PHP 5.3. I just deactivated ALL plugins but its still there. wp-config.php set to
define('WP_DEBUG', false);
I’m also getting the same annoying error.
Hello,
We too are running WP 3.3.1 and PHP 5.3.8 and are encountering an endless stream of these errors.
23-Mar-2012 15:33:14 PHP Deprecated: Assigning the return value of new by reference is deprecated in /home/oursitename/public_html/wp-includes/class-simplepie.php on line 14904
23-Mar-2012 15:33:14 PHP Deprecated: Assigning the return value of new by reference is deprecated in /home/oursitename/public_html/wp-includes/class-simplepie.php on line 14418
23-Mar-2012 15:33:14 PHP Deprecated: Assigning the return value of new by reference is deprecated in /home/oursitename/public_html/wp-includes/class-simplepie.php on line 14368
23-Mar-2012 15:33:14 PHP Deprecated: Assigning the return value of new by reference is deprecated in /home/oursitename/public_html/wp-includes/class-simplepie.php on line 14294
23-Mar-2012 15:33:14 PHP Deprecated: Assigning the return value of new by reference is deprecated in /home/oursitename/public_html/wp-includes/class-simplepie.php on line 14269
23-Mar-2012 15:33:14 PHP Deprecated: Assigning the return value of new by reference is deprecated in /home/oursitename/public_html/wp-includes/class-simplepie.php on line 14197
23-Mar-2012 15:33:14 PHP Deprecated: Assigning the return value of new by reference is deprecated in /home/oursitename/public_html/wp-includes/class-simplepie.php on line 14133
23-Mar-2012 15:33:14 PHP Deprecated: Assigning the return value of new by reference is deprecated in /home/oursitename/public_html/wp-includes/class-simplepie.php on line 14087
23-Mar-2012 15:33:14 PHP Deprecated: Assigning the return value of new by reference is deprecated in /home/oursitename/public_html/wp-includes/class-simplepie.php on line 13052
and on and on
Phil D
Have the same issue after MediaTemple (grid-service) upgraded to 5.3.10.
Showing multiple errors (100+) from the WordPress 3.3.2 dashboard under Incoming Links, WordPress Blog, Plugins, etc. Example:
Deprecated: Assigning the return value of new by reference is deprecated in zzz/public_html/wp-includes/class-simplepie.php on line 1763Site Stats:
WordPress 3.3.2
Active Plugins:
DigitalAccessPass LiveLinks 1.8.1
Exclude Pages from Navigation 1.92
Google Doc Embedder 2.4.2
S3 Media Vault 0.2
Inactive Plugins:
Akismet 2.5.6
Hello Dolly 1.6
Active Theme: OptimizePress 1.5I have tried the following methods and the same errors show up:
1. Deactivated all plugins
2. Renamed plugins folder
3. Activated Twentyten and then tried TwentyEleven
4. Added the following code to php.ini:
error_reporting = E_ALL & ~E_NOTICE
display_errors = Off
5. Added the following code to wp-config.php:
error_reporting(0);Media Temple upgrade info:
https://kb.mediatemple.net/questions/245/FAQs+on+PHP+EOL#gsI found this article with the exact same issue with PHP 5.3.10:
https://stackoverflow.com/questions/10722381/php-deprecated-errors-wont-disappear-on-wordpress-dashboard/10740845#10740845I have exhausted all methods. It must be something to do with WordPress and PHP 5.3.10. Any other suggestions would be appreciated.
I have contacted MediaTemple several times and this issue has not been resolved. Here is their latest reply:
While updating to PHP 5.3 should not affect most websites, it appears your website may not be compatible with current versions of PHP. (mt) Media Temple currently only supports PHP 5.3 on the (gs) Grid-Service and (dv) Dedicated-Virtual Server.
All versions of PHP prior to 5.3 were removed from our services because they are no longer supported by PHP and will not received any future updates or security fixes.
We understand the process to become compliant with PHP 5.3 may not be easy for you; however, it is required if you would like to host the affected websites with (mt) Media Temple on a (gs) Grid-Service or (dv) Dedicated-Virtual Server.
You may need to manually edit your code or move to a (ve) Server. If you are not able to do this yourself, you may want to consult a web developer who can make these changes for you.
Are they trying to tell me that WordPress does not work with PHP 5.3? Any suggestions would be appreciated.
Just dump media temple. I use hostgator personally. I really hate media template – their support department is horrible.
I am a user of HostGator myself. However my client prefers MT so I need to get this fixed.
I’m having the same issue with the same file on one of my sites: Deprecated: Assigning the return value of new by reference is deprecated in /home/name/public_html/wp-includes/class-simplepie.php
Also getting a similar error when using the search bar on the site: Deprecated: Assigning the return value of new by reference is deprecated in /home/name/public_html/wp-content/themes/themename/search.php on line 3
It conducts the search properly, but the error appears at the top of the screen, and the template becomes distorted.
same problem here, haven’t found a solution yet. Tried ini_set on error_reporting and display_errors without avail. None of the other proposed solutions have worked for me yet, still trying to figure out the issue.
@wpsecuritylock, @adamc., @producerism, @soobahkdo, @the8thlegion, @sawtooth500:
In case you still need to resolve this error, HERE IS A SIMPLE FIX- Open /wp-includes/class-simplepie.php in your editing tool.
- Find instances of this text:
&$
- Replace with
$
- Save, and if required, upload to your server
- Reload the page on which you were seeing, “Assigning the return value of new by reference is deprecated”
For a complete, articulate explanation of this, see: this thread.
Happy editing!
@salty-sailor, this is not enough for me. In that file have also
&_gt; / &_lt; / &= / =& / && / &_amp; / ...
(who know?)I must replace hims?
- The topic ‘Fixing Deprecated: Assigning the return value of new by reference is deprecated’ is closed to new replies.