Strict Standards: Only variables should be assigned by reference
Hello,
I have a new cPanel/WHM installation with PHP 5.4.28 and I migrated a Joomla 3 website to the server, and I get the error:
"Strict Standards: Only variables should be assigned by reference in...."
As soon as I recompile to PHP 5.3.27, the error goes away.
Can you please tell me what could be the issue?
Error_logs don't show anything.
Thank you.
-
Hello, That's a warning, not really an error. In your /usr/local/lib/php.ini file, see what you have for error_reporting. If you don't see: ~E_STRICT
in that line, please add it, and then restart Apache with:# /scripts/restartsrv_httpd
See if that resolves the warning you're seeing.0 -
I had: [QUOTE]error_reporting = E_ALL & ~E_NOTICE & ~E_DEPRECATED
and I changed it to: [QUOTE]error_reporting = E_ALL & ~E_NOTICE & ~E_DEPRECATED & ~E_STRICT
restarted apache, still the same.0 -
Hello, The problem in this case was that several of the PHP scripts were resetting the error_reporting log... The fix in this case was to modify the file in question and remove the & from that file. The error now no longer appears. But there may be other places where it will appear. There is not much that can be done if many of the php files simply reset the error_reporting line. 0 -
[quote="cPanelPeter, post: 1642452">Hello, The problem in this case was that several of the PHP scripts were resetting the error_reporting log... The fix in this case was to modify the file in question and remove the & from that file. The error now no longer appears. But there may be other places where it will appear. There is not much that can be done if many of the php files simply reset the error_reporting line.
Thanks a lot Peter. Fully understood your points. In case anyone else having same problems, my errors were raising from: [QUOTE] plugins/content/xtypo/xtypo.php plugins/system/supersticky/supersticky.php
And as Peter said, remove the & from that file, and the line being reported. Thank you.0
Please sign in to leave a comment.
Comments
4 comments