scapadmin
Forum Replies Created
-
thx
I will check out the newsletter.
A
The issue is resolved.
this scenario would fix the procedure. So just email or just via an app. I believe the options are confusion and demand more knowledge from 2FA than most people have. For most it is just access to a webshop…
An option to pre-cook everything would be valuable. Which means a separate email check needs to be successfully performed prior to executing of the policy.
Best
Arjan
In both cases no emails were received. In case of a new user registration the email verification provided auto login and a forward to the specific page for 2FA activation. This email with the 6-digid code is the missing email. Which led to not finishing the procedure.
Best
Arjan
These are the wp-config.php entries:
global $phpmailer;
if ((!is_object( $phpmailer ) || !is_a( $phpmailer, ‘PHPMailer’ )) &&
file_exists(ABSPATH . ‘/wp-includes/class-phpmailer.php’) &&
file_exists(ABSPATH . ‘/wp-includes/class-smtp.php’)) {
require_once ABSPATH . ‘/wp-includes/class-phpmailer.php’;
require_once ABSPATH . ‘/wp-includes/class-smtp.php’;
$phpmailer = new PHPMailer( true );
}
$phpmailer->UseSendmailOptions = false;This could be the reason of my problems, but I don’t know. Both files existed. I have deleted them and now the plugin works again.
Is this a leftover from previous plugin version prior to WP5.5? Should I change my wp-config.php?
Best
Arjan
Hi
I have used the debug mode, with the following result:
Deprecated: class-phpmailer.php is deprecated since version 5.5.0! Use wp-includes/PHPMailer/PHPMailer.php instead. The PHPMailer class has been moved to wp-includes/PHPMailer subdirectory and now uses the PHPMailer\PHPMailer namespace. in /www/wp-includes/functions.php on line 4967 Deprecated: class-smtp.php is deprecated since version 5.5.0! Use wp-includes/PHPMailer/SMTP.php instead. The SMTP class has been moved to the wp-includes/PHPMailer subdirectory and now uses the PHPMailer\PHPMailer namespace. in /www/wp-includes/functions.php on line 4967 Fatal error: Cannot declare class PHPMailer\PHPMailer\SMTP, because the name is already in use in /www/wp-includes/PHPMailer/SMTP.php on line 30
I’ve searched all server files for calling PHPmailer. 3 php files were flagged:
class-updraftplus.php (latest version tested up to WP5.6)
class-wc-email.php (version WC 4.7)
class-wcpdf-main.php (latest version tested up to WP5.6) containingWhen all 3 are deactivated I still get the error.
I’ve searched all server files for calling class-phpmailer or class-smtp. Only class-wcpdf-main.php was flagged:
global $phpmailer;
if ( ! ( $phpmailer instanceof \PHPMailer ) ) {
require_once ABSPATH . WPINC . ‘/class-phpmailer.php’;
require_once ABSPATH . WPINC . ‘/class-smtp.php’;
$phpmailer = new \PHPMailer( true );
}
$phpmailer::$validator = ‘php’;I deleted class-wcpdf-main.php, but the same result.
The Theme is free of phpmailer, class-smtp or class-phpmailer.
Conclusion: I still don’t know what is the root of of the fatal error.
Do you have another suggestion?
Arjan
Do I need to manually clean up some leftovers from previous SMTP plugin’s
Currently I have nothing SMTP running but the WP-core SMTP.php still mentions smtp class.
Reading other threads and forums I noticed that the plugin should ignore this or not.
Am I getting lost?
Hi @capuderg,
Thanks for the explanation. I checked the mu-plugins. Just one ‘health-check-troubleshooting-mode.php’
I have to dig into the theme. I never experienced this problem with WP 5.3 and before.
Is there an easy way to scan the php’s or should I go one by one?
Arjan
I have followed the troubleshooting guide. Without any other plugin and a default theme. The fatal error still remains happening when WP-MAIL-SMTP is activated.
FastCGI: server “/var/run/php74-cgi/php-cgi” stderr: PHP message: PHP Fatal error: Cannot declare class PHPMailer\\PHPMailer\\SMTP, because the name is already in use in /www/wp-includes/PHPMailer/SMTP.php on line 30
Please advise. The webshop is down!!!
Hi @sanzeeb3,
Thx for your reply. All plugins are up-to-date and so is the theme. Installing the SMTP plugin still crashes the site at activation.
It seems it doesn’t expect ‘smtp class’ in line 30 of smtp.php.
Why should this has to do with the theme?
The system crash happened after WP update to WP 5.5. PHP version is 7.4.x