Drupal 6 & PHP 5.3

Events happening in the community are now at Drupal community events on www.drupal.org.
viral007in's picture

Have any one faced issues with Drupal 6 and PHP 5.3, do share your experience

Comments

Its almost perfect..

swarad07's picture

Drupal 6.14 and above does work with PHP 5.3 but there are still some contributed modules that might not work, and will throw warnings messages.

I would recommend 5.2.x for Drupal core 6.

More info at http://drupal.org/requirements
Drupal 6.14's release notes. http://drupal.org/node/579476

I have same problem

tejasdarji's picture

My drupal-6 is hosted on ubuntu 9.10.
Now ubuntu is stop support for 9.10 Because ubuntu support only 2years. Currently ubuntu 11.04 is release.
My problem is ubuntu 10+ is come with php-5.3, We can downgrade php-5.3 to 5.2 but its not work properly some php libraries are not working.
I have tried with drupal 6 and php-5.3 but some warning and errors are occur.

I met with the same problem

vishalgala's picture

I was having Drupal 6.14 and php 5.3 does not support drupal 6.14, so I updated my core version to
Drupal 6.22 and it was working fine for php 5.3.

Please try updating your core version if it works.

Only supressing error message

drupalnesia's picture

Drupal 6.22 (when this post written) still not yet fully compatible to PHP 5.3. What the patch does only supressing the error message, that's why on certain server you still see this incompatible error message.

To be details see this bootstrap.inc code from Drupal 6.22:

// Hide E_DEPRECATED messages.
if (defined('E_DEPRECATED')) {
  error_reporting(error_reporting() & ~E_DEPRECATED);
}

Above code mean not show any error related to deprecated :)

So, if you now how to replace any deprecated function then use PHP 5.3, otherwise stuck on 5.2.

@tejasdarji: you need to edit your PHP 5.3 php.ini file. Just use E_DEPRECATED, read this article for detail http://www.electrictoolbox.com/php-prevent-e-deprecated-error-messages/

6.26 and PHP 5.3.13

jmoughon's picture

I am running 6.26 and php 5.3.13 and all error and problems are gone. The issue with Drupal 6 in Windows show configuration file permission errors are gone as well.

schroeder-71's picture

I had to install drupal 6.32 on PHP 5.3.28 and it took me 4 days to get a real login to the system.
After crawling through the net and trying almost every solution without any success it turned out o be a version problem with the PHP 5.3.28 version. The cookie set to the session id to allow site access contained a longer session id than the mysql database session table had stored. Obviously the drupal 6 database installer only installs a 64 character field for the session_id in the session table, whereas the PHP function to generate a new session id now generates a string with 128 characters. That 128 characters where stored in the cookie, but got cut to 64 characters in the database. So the cookie session_id was not the same as in the database, access was not allowed.
Solution is simple: delete all entries in the session table and force the session_id field to be a 128 character field, e.g. via phpmyadmin. Login and work.

Helpfull Snipet

damondt's picture

I find the following snippet for the main .htaccess file to be helpful when deploying D6 on newer php distributions.

php_value date.timezone America/New_York
php_value error_reporting E_ALL
php_value display_errors 1
php_value display_startup_errors 1
php_value memory_limit 256M

India

Group notifications

This group offers an RSS feed. Or subscribe to these personalized, sitewide feeds:

Hot content this week