PHPMailer GoDaddy Server SMTP Connection Refused
This user experienced a sudden failure in PHPMailer functionality after their site was migrated from a Windows to a Linux server on GoDaddy. The error message they received was:
SMTP -> ERROR: Failed to connect to server: Connection refused (111)SMTP Connect() failed.
Despite verifying their settings, the issue persisted. They confirmed that their GoDaddy account remained unchanged, and tech support could find no server settings issues.
Suspecting a server-related cause, they investigated further. They discovered that using the localhost as the SMTP Host value, while commenting out various authentication settings like SMTPAuth, Username, etc., resolved the issue.
$mail2->Host = localhost; //$mail2->SMTPAuth = false; //$mail2->Username = '[email protected]'; //$mail2->Password = '*******'; //$mail2->SMTPSecure = 'tls'; //$mail2->Port = 465;
The user concluded that the issue had something to do with the transition to a Linux server and suggested that the tech support personnel may not be aware of certain server settings. They recommended investigating further if anyone else encounters similar problems.
The above is the detailed content of Why is PHPMailer Failing to Connect to SMTP on GoDaddy\'s Linux Server?. For more information, please follow other related articles on the PHP Chinese website!