Compiled PHP 7 missing mysql extension in WordPress

后端 未结 6 857
慢半拍i
慢半拍i 2020-12-15 05:51

I have built PHP 7 with a configuration that worked for a previous version of PHP. Now my WordPress websites get the message:

Your PHP installation a

6条回答
  •  生来不讨喜
    2020-12-15 06:12

    As has been mentioned elsewhere, the ext/mysql functions have been removed. We've been talking about this for some time.

    ext/mysql was built for MySQL 3.23 and only got very few additions since then while mostly keeping compatibility with this old version which makes the code a bit harder to maintain.

    If you're hell-bent on putting them back in, you can add them back to PHP 7 by using the ext/mysql PECL Library

    It's important to note that Wordpress 3.9 or later supports mysqli

    In WordPress 3.9, we added an extra layer to WPDB, causing it to switch to using the mysqli PHP library, when using PHP 5.5 or higher.

提交回复
热议问题