SMTP is not working anymore!!!!

Status
Not open for further replies.

digisoft

New Member
Messages
42
Reaction score
0
Points
0
Hi. I am new to this good host. Yesterday I was using the SMTP relay with no problems. But today I can't send single mail. My configuration for SMTP was:
localhost on port 25 with no password and no username. It worked great but today I receive this error:

Warning: fsockopen() [function.fsockopen]: unable to connect to localhost:25 (Connection timed out) in /home/xxxxxxx/public_html/smtp.lib.php on line 228
 
Last edited:

digisoft

New Member
Messages
42
Reaction score
0
Points
0
Thanks for the reply but it still doesn't work :(
I am on server cossacks
 
Last edited:

Corey

I Break Things
Staff member
Messages
34,551
Reaction score
205
Points
63
hmm, it works for me, are you still getting the same error? If so can you access other parts of your site?
 

digisoft

New Member
Messages
42
Reaction score
0
Points
0
Yes other parts are working. I really don't know why doesn't work when yesterday it was just fine.
 

Corey

I Break Things
Staff member
Messages
34,551
Reaction score
205
Points
63
Can you link me to where it's trying to send the E-mail?
 

digisoft

New Member
Messages
42
Reaction score
0
Points
0
Ok here is my PHP code for sending mail that was working yesterday with no problem.

PHP:
<?
require 'smtp.lib.php';

$mail = new smtp;

$mail->debug(true);

$mail->open('localhost', 25);

//$mail->start_tls(); --> it is not used because it has //

//$mail->auth('', ''); --> it is not used because it has //

$mail->from('somethink@not_important.com');

$mail->to("my_mail_is_here@gmail.com");

$mail->subject("MESSAGE SUBJECT");

$mail->body("MESSAGE BODY IS HERE");

$mail->send();

$mail->close();
?>
 
Last edited by a moderator:

Corey

I Break Things
Staff member
Messages
34,551
Reaction score
205
Points
63
I think I know why. I had the firewall off for part of the day yesterday. In order to send mail out using SMTP and not just sendmail you need to authenticate. It doesn't look like your script is authenticating.

-Corey
 

lambada

New Member
Messages
2,444
Reaction score
0
Points
0
From the looks of your reply, this is solved.

If i'm mistaken, please re-open.

:lockd:
 
Status
Not open for further replies.
Top