• Hello, I am unable to connect to SMTP despite entering the correct information. I am using version 2.2.1 of the Solid Mail plugin.

    I am getting these errors. How can I resolve the issue?

    wordpress-1  | NOTICE: PHP message: PHP Fatal error:  Uncaught Error: Class "WP_PHPMailer" not found in /var/www/wp-content/plugins/wp-smtp/src/Mail/SolidMailer.php:24
    wordpress-1 | Stack trace:
    wordpress-1 | #0 /var/www/wp-content/plugins/multilingualpress/vendor/composer/ClassLoader.php(576): include()
    wordpress-1 | #1 /var/www/wp-content/plugins/multilingualpress/vendor/composer/ClassLoader.php(427): Composer\Autoload\{closure}('/var/www/wp-con...')
    wordpress-1 | #2 /var/www/wp-content/plugins/wp-smtp/src/Mail/Admin/ScreenConnectors.php(142): Composer\Autoload\ClassLoader->loadClass('SolidWP\\Mail\\So...')
    wordpress-1 | #3 /var/www/wp-includes/class-wp-hook.php(324): SolidWP\Mail\Admin\ScreenConnectors->send_test_email('')
    wordpress-1 | #4 /var/www/wp-includes/class-wp-hook.php(348): WP_Hook->apply_filters('', Array)
    wordpress-1 | #5 /var/www/wp-includes/plugin.php(517): WP_Hook->do_action(Array)
    wordpress-1 | #6 /var/www/wp-admin/admin-ajax.php(192): do_action('wp_ajax_solidwp...')
    wordpress-1 | #7 {main}
    wordpress-1 | thrown in /var/www/wp-content/plugins/wp-smtp/src/Mail/SolidMailer.php on line 24

    Thank you for your feedback and assistance!

Viewing 3 replies - 1 through 3 (of 3 total)
  • Ben Meredith

    (@benmeredithgmailcom)

    Hey @brendanapimani !

    Glad you reached out here. The error Class "WP_PHPMailer" not found indicates a problem “above the level” of Solid Mail. I’ll explain in detail below, but the “quick fix” here is to ensure that your WordPress installation itself is complete and that nothing has prevented the default WP_PHPMailer class from loading. That class can sometimes be blocked by overzealous hosts or maybe a firewall plugin or something, or it could be evidence of your WordPress installation being somehow incomplete.

    The short answer: this indicates a non-standard WordPress installation, and Solid Mail requires that class to do anything.

    Longer explanation:

    WordPress creates a PHP “class” to send emails, which is essentially extending the PHPMailer class. That class creates a wp_mail() function, which in turn is what Solid Mail (and other plugins) can extend to make email more reliable in WordPress. You can read more about that whole process here: https://solidwp.com/documentation/general-wp/learn-more/understanding-email-deliverability-in-wordpress/

    All of that is built on the premise that WP_PHPMailer is available. On your site, it’s saying that calss is not available, which is something either your web host has control over, or some third-party software is hijacking WP_PHPMailer in a way that makes Solid Mail not able to function on your site.

    Thread Starter brendanapimani

    (@brendanapimani)

    Hello @benmeredithgmailcom,

    Thank you for your feedback and detailed explanations!

    What I don’t understand is that just a few days ago, my emails were working perfectly and sending fine. How can the ‘WP_PHPMailer’ class disappear?

    In addition, I had the Check & Log Email plugin installed, but I uninstalled it in case it was causing incompatibility with Solid Mail. I also updated Solid Mail recently.

    I am on a multisite, and this only affects my main site, apimani.fr, even though I have the same configuration on pro.apimani.fr. The only difference, in my opinion, is the SMTP connection, which is different (because the email and password are different, but otherwise it is the same mail server).

    Do you have any ideas for tests I could run, ways to restore the ‘WP_PHPMailer’ class, or anything else that might help me?

    Thank you for your help and your time.

    Thread Starter brendanapimani

    (@brendanapimani)

    Hello @benmeredithgmailcom,

    Any news ?

    Thank you for your help and your time.

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

You must be logged in to reply to this topic.