Reply to topic
PhpMailer problem
rpcarnell


Joined: 07 Dec 2006
Posts: 21
Reply with quote
I decided to use PHPMailer because someone told me using it will stop services like hotmail from treating every email coming from my website as spam.

The problem is that whenever my website sends an email, I get this message:


Language string failed to load: connect_host

In order to use PHPMailer, you need to alter the php.ini file. I haven't done that, and it still works, if I include the files in the php files that will use the phpmailer classes.

My script is finding the PHPMailer classes, and it worked when I used them with my Localhost Linux account, so what's the problem now? I didn't alter the php.ini file there either.

require("phpmailer/class.phpmailer.php");
$mail = new PHPMailer();
$mail->IsSMTP(); // telling the class to use SMTP
$mail->Host = "76.12.38.242"; // SMTP server
$mail->From = "personal@pilando.com";
$mail->AddAddress($_POST['email']);

$mail->Subject = "Confirme su membresía en Pilando.com";
$mail->Body = "Gracias por registrarse en nuestra página. Vaya a este link
para confirmar su registro:


http://www.pilando.com/confirm.php?hash=$hash&email=$encoded_email


Gracias por su interés.";
$mail->WordWrap = 50;
nathacof
Forum Admin

Joined: 24 Oct 2006
Posts: 192
Location: Dover, DE
Reply with quote
Have you checked your error logs to see exactly what the problem may be?

if you ssh into your account you should see a directory by the name of 'logs' in this directory will be the error logs for your account.

http://www.hostmysite.com/support/linux/general/errorcheck/

If you see no errors in the logs it's probably due to phpmailer intercepting the exception. In which case you will need to refer to the PHPMailer documentation.

If you need something configured in your PHP.ini (which is unlikely) contact support directly and we'll see if the change is appropriate for your account.
rpcarnell


Joined: 07 Dec 2006
Posts: 21
Reply with quote
Doesn't matter now. I won't be programming a confirmation email for quite some time.

But eventually I'll return to phpmailer, and if something goes wrong, I'll look at the logs. Thanks for your help.
ccstm


Joined: 26 Jul 2007
Posts: 2
Reply with quote
There are a lot of suggestions available throughout the web. This website (http://forums.phplist.com/viewtopic.php?p=35187) has quite a few options, should you try to attempt this again. PHPMailer is a great tool to use, so I hope it works out!
PhpMailer problem
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
All times are GMT  
Page 1 of 1  

  
  
 Reply to topic