• Resolved borkenkaefer

    (@borkenkaefer)


    I use mailpoet on a debian linux system together with the packaged wordpress version of debian (version 4.7.5).

    Starting from mailpoet version 24.0 a fatal php error is thrown. I think something with reading the db configuration changed. Any suggestions or fixes?

    
    2019/05/03 09:32:06 [error] 3825#3825: *147952 FastCGI sent in stderr: "PHP message: PHP Fatal error:  Uncaught Error: Call to undefined method wpdb::parse_db_host() in /var/lib/wordpress/wp-content/plugins/mailpoet/lib/WP/Functions.php:533
    Stack trace:
    #0 /var/lib/wordpress/wp-content/plugins/mailpoet/lib/Config/Env.php(64): MailPoet\WP\Functions->parseDbHost('10.0.5.11')
    #1 /var/lib/wordpress/wp-content/plugins/mailpoet/lib/Config/Env.php(57): MailPoet\Config\Env::initDbParameters('10.0.5.11', 'wp.dev.domain.tld', 'db_password', 'db_name')
    #2 /var/lib/wordpress/wp-content/plugins/mailpoet/mailpoet_initializer.php(17): MailPoet\Config\Env::init('/var/lib/wordpr...', '3.24.0', '10.0.5.11', 'db_user', 'db_password', 'wp_laebigilorra...')
    #3 /var/lib/wordpress/wp-content/plugins/mailpoet/mailpoet.php(101): require_once('/var/lib/wordpr...')
    #4 /usr/share/wordpress/wp-settings.php(304): include_once('/var/lib/wordpr...')
    #5 /usr/share/wordpress/wp-config.php(59): require_once('/usr/share/word...')

    In wp-config.php the database is configured like this: define('DB_HOST', '10.0.5.11');

Viewing 2 replies - 1 through 2 (of 2 total)
  • Wysija

    (@wysija)

    Hello @borkenkaefer,

    Thank you for the issue report, apologies for the inconvenience.
    $wpdb::parse_db_host() has actually been added in WordPress 4.9.x and is not available in older WordPress versions.
    We did not add appropriate guards by mistake.

    Two options to resolve this issue:
    a) Please upgrade to WordPress 4.9 or newer
    b) Please downgrade the MailPoet 3 plugin down to 3.23.2

    We would recommend you to upgrade to the newest WordPress version you can, as they also include security fixes and other improvements.

    Thread Starter borkenkaefer

    (@borkenkaefer)

    Thank you for your answer and your suggestions.

    a) is not an option and debians wordpress packages also includes security fixes, so no reason to upgrade for the moment. I probably will stick with b) for the moment or maybe I’ll create my own parse_db_host().

    Please adapt the required wordpress version on https://ww.wp.xz.cn/plugins/mailpoet/ and for the future, please specify such changes in the changelog.

Viewing 2 replies - 1 through 2 (of 2 total)

The topic ‘PHP Fatal error: Uncaught Error: Call to undefined method wpdb::parse_db_host()’ is closed to new replies.