PHP 5.3 generate warnings on Content Translate page:
warning: Parameter 1 to theme_i18n_node_select_translation() expected to be a reference, value given in C:\HTTP\Default\web\includes\theme.inc on line 617.
warning: Parameter 1 to theme_i18n_node_select_translation() expected to be a reference, value given in C:\HTTP\Default\web\includes\theme.inc on line 617.
This is PHP 5.3 incompatibility issue, like other modules ( Views for example - http://drupal.org/node/452384 ).
Removing the ampersand '&' in first parameters may be sufficient for resolve this bug.
Platform: Apache/2.2.13 (Win32) PHP/5.3.0. MySQL: 5.1.39-community.
Comments
Comment #1
jose reyero commentedI guess there will be more than that one, though I'm not using PHP 5.3 yet, nor I'll be using it for a while given the troubles it causes.
Patches welcomed.
Comment #2
hass commentedI tried to get my DEV environment running on XAMPP 1.7.1, 1.7.0 with MySQL 5.1.33 and others - I've skipped 1.7.2 for the reason that D5 does not run on PHP 5.3 and this are ***damn*** buggy database server versions!!! The issues started with not being able to restore a valid backup from 5.0.x (duplicate entries in search tables - looks like collation bugs) and ends with a completely broken site with very strange errors. Wasted 2 days with this sh** without getting a real idea what's wrong and I'm downgraded back and forth and ended with XAMPP 1.6.8 having PHP 5.2.x and MySQL 5.0.x - unbelievable :-(((. Than I found this http://www.palantir.net/blog/beware-mysql-51-my-son...
How are you able to run Drupal on this versions???
Comment #3
W32 commentedFrom your link:
Current version is 5.1.33, so it's been fixed in the last two releases: http://dev.mysql.com/doc/refman/5.1/en/news-5-1-32.html
Comment #4
hass commentedI'm still not able to restore my older db on 5.1.x without errors - this is selfspeaking enough. Ignoring them can help but drupal 6.14 is also broken afterward. Debugging have only shown that mysql got/produced connection resets.
Plus it's written in the drupal docs that you should only use mysql 5.0.x
Comment #5
W32 commentedOk. Thank you.
Comment #6
berdirtheme() functions cannot have any by-reference params, so it is save to remove them.
Comment #7
berdirAll other theme functions are ok and I haven't found any php 5.3 related issues when clicking throug the UI.
As stated before, theme() function can't have by reference arguments.
Comment #8
muhleder commented+1 from me. Works to remove the error message. Not seeing any bugs as a result, similar to 5.3 patches used in other modules.
Comment #9
spacereactor commentedcan this be add into 6.x-1.3 so we dun have to edit this with every update. THK!
Comment #10
jose reyero commentedFixed, thanks.
Comment #11
veloce GT commentedI still get the following error when translating a book node:
* warning: Parameter 1 to theme_i18n_node_select_translation() expected to be a reference, value given in C:\xampp\htdocs\drupal\includes\theme.inc on line 656.
* warning: Parameter 1 to theme_i18n_node_select_translation() expected to be a reference, value given in C:\xampp\htdocs\drupal\includes\theme.inc on line 656.
Xampp for Windows 1.7.3
PHP Version 5.3.1
Internationalization 6.x-1.3
Comment #12
berdirThis has been fixed on the 4th, 1.3 has been released on the third, so this fix is not part of the official release. Try the -dev release.
Comment #13
veloce GT commentedThanks for the info. I just relied on the given version number:
Version: 6.x-1.1 » 6.x-1.3
Status: needs review » fixed
and didn't mention the date. Shouldn't the given version number have been 6.x-1.x-dev?
Comment #14
b3liev3 commentedThe patch seems to work. It's again and again the same problem with PHP 5.3
Comment #16
atsakoumis commentedHello,
I also had the same problem:
warning: Parameter 1 to theme_i18n_node_select_translation() expected to be a reference, value given in ...\includes\theme.inc on line 656.
warning: Parameter 1 to theme_i18n_node_select_translation() expected to be a reference, value given in ...\theme.inc on line 656.
Try to remove "&" from the file i18n/i18n.pages.inc (user modules directory)
line 262 : function theme_i18n_node_select_translation(&$elements) {