Showing results for 
Show  only  | Search instead for 
Did you mean: 
Go to solution

PHPMailer codes won't send a message to an email

I have a project that needs to be done and our group life is on the line with this problem occurs to us. The problem is that it won't send a message to an email. In xampp localhost this phpmailer script works but after uploading to godaddy it happens to have some sort of problem. I tried various fix/solution with the forums I'd seen here in godaddy and still it won't work. For example like changing the host, port, smtp's auth and secure, and etc. Could somebody out there help me to find a fix for this even godaddy help support? I've been going at it for the past 2 weeks. Am I missing something? Do I have something to configure in cPanel? This is the script I made but it is just for a trial.



if(isset($_POST['register'])) {
require ('phpmailer/PHPMailerAutoload.php');
$mail = new PHPMailer();
$mail->SMTPAuth = true;
$mail->SMTPSecure = 'ssl';
$mail->Host = '';
$mail->Port = '465';
$mail->Username = '';
$mail->Password = '***************';
$mail->Subject ='MSU-MSAT Alumni Registration Confirmation';
$mail->Body = 'hello lagudas 3' ;
echo "Message Sent OK\n";
} catch (phpmailerException $e) {
echo $e->errorMessage(); //Pretty error messages from PHPMailer
} catch (Exception $e) {
echo $e->getMessage();

<!DOCTYPE html>

<meta charset="utf-8">

<title>Register - Alumni</title>


<section class="center-text">
<form action="<?php echo htmlspecialchars($_SERVER['PHP_SELF']); ?>" method="POST" >
<input class="btn btn-primary" type="submit" name="register" value="Register">



It would be a lot of appreciate if someone out there helps me. You can contact me to my email as well in Hoping all of your kind consideration.


Re: PHPMailer codes won't send a message to an email

Rockstar I Rockstar I
Rockstar I

Re: PHPMailer codes won't send a message to an email

Hi @nuemeranjj16 ,


A while back I ran into a similar problem.  After several attempts of using the "normal settings" GoDaddy help said to try to put the name of the "relay server" in the settings.  That's what the support agent did and it worked.  GoDaddy support identified the server name for me because I couldn't find it.  I not completely sure how all of this works sometimes, but that was the solution in my  case.  The other setting that was scrutinized was the internal/external setting in cPanel for the email server.  


Not one of my better answers for sure, but hope this helps!


Not Just Pretty Sites, Pretty Doggone Smart Sites