You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I've always sent from PHPMailer with ease, it always works well. However, after updating to the newer version, I ran composer install within the PHPMailer directory and then ran composer require phpmailer/phpmailer within the directory my functions file is at, which sends the email. Hoping this would work well. However, when I used the example to try and send a test email, an error arose: Parse error: syntax error, unexpected 'use' (T_USE) I don't understand what went wrong.
Code to reproduce
use PHPMailer\PHPMailer\PHPMailer;
use PHPMailer\PHPMailer\Exception;
I then required once the autoload file which loaded fine.
Any ideas?
The text was updated successfully, but these errors were encountered:
Problem description
I've always sent from PHPMailer with ease, it always works well. However, after updating to the newer version, I ran
composer install
within the PHPMailer directory and then rancomposer require phpmailer/phpmailer
within the directory my functions file is at, which sends the email. Hoping this would work well. However, when I used the example to try and send a test email, an error arose:Parse error: syntax error, unexpected 'use' (T_USE)
I don't understand what went wrong.Code to reproduce
use PHPMailer\PHPMailer\PHPMailer;
use PHPMailer\PHPMailer\Exception;
I then required once the autoload file which loaded fine.
Any ideas?
The text was updated successfully, but these errors were encountered: