WordPress.org

Ready to get started?Download WordPress

Forums

ereg deprecated in php 5.3 (7 posts)

  1. chriscb65
    Member
    Posted 4 years ago #

    I've tried to upgrade my php version from 5.2.9 to 5.3.1 and there's an important modification in this version : ereg functions are now deprecated. Some wordpress' functions doesn't work : ftp update for exemple.

    You should replace all ereg functions by the preg equivalent.

    I've listed the file where the ereg functions are used :

    wp-admin/includes/class-ftp-pure.php
    wp-admin/includes/class-ftp.php
    wp-admin/includes/class-pclzip.php
    wp-admin/includes/class-ftp-sockets.php
    wp-includes/functions.wp-scripts.php
    wp-includes/class-phpmailer.php
    wp-includes/class-pop3.php
    wp-includes/gettext.php
    wp-includes/rewrite.php
    wp-includes/functions.wp-styles.php
  2. franciscocosta
    Member
    Posted 4 years ago #

    anyone has this files with ereg replaced by preg ?

  3. shiva7663
    Member
    Posted 4 years ago #

    This is one of the reasons that a lot of software packages don't yet support php5.3.x; another is the problem of E_DEPRECATED being an error instead of a warning, and not ignorable in php.ini. If you get a whole truckload of inexplicable error messages under php5.3, this is why.

  4. franciscocosta
    Member
    Posted 4 years ago #

    The only thing that is affecting me is updating plugins.
    When I choose the FTP connection type the page goes blank and the plugins don't update.
    I'm wandering if there is any patch for this, because manual updating sucks
    :)

  5. franciscocosta
    Member
    Posted 4 years ago #

    I've downgrade to PHP 5.2.10 and everything works correctly now...
    Maybe WordPress 2.9.1 is not fully compatible with PHP 5.3.1

  6. lbeachmike
    Member
    Posted 3 years ago #

    Does anybody know if WordPress 3.0.1 is compatible with PHP 5.3.2?

    Thanks.

    Mike

  7. mjwouda
    Member
    Posted 3 years ago #

    No, WordPress 3.0.1 is not compatible with PHP 5.3.2.
    Mine hoster has updated the PHP version to 5.3.2 so I had no choice. You have to suppress the 'E_DEPRECATED' notices. When ignoring this you can get something like this:

    Deprecated: Assigning the return value of new by reference is deprecated in /home/users/ftpuser/domain.com/wp-settings.php on line 204
    Deprecated: Assigning the return value of new by reference is deprecated in /home/users/ftpuser/domain.com/wp-settings.php on line 219
    Deprecated: Assigning the return value of new by reference is deprecated in /home/users/ftpuser/domain.com/wp-settings.php on line 226
    Deprecated: Assigning the return value of new by reference is deprecated in /home/users/ftpuser/domain.com/wp-settings.php on line 233
    Deprecated: Assigning the return value of new by reference is deprecated in /home/users/ftpuser/domain.com/wp-settings.php on line 258
    Deprecated: Function set_magic_quotes_runtime() is deprecated in /home/users/ftpuser/domain.com/wp-settings.php on line 27

Topic Closed

This topic has been closed to new replies.

About this Topic