Jump to content

Mail Function Not Working on Server


webspinner

Recommended Posts

I got everything working on my new site, then moved the files to the real domain and now my PHP mail script stopped working.  >:(

 

Do I need to do something based on the error below, or does the sys admin need to do it on his end?

 

Thx!

 

Rick

 

Warning: mail() [function.mail]: Failed to connect to mailserver at "localhost" port 25, verify your "SMTP" and "smtp_port" setting in php.ini or use ini_set() in d:\webspace\ADMIN\mysite.com\WWW\contact.php on line 25

 

Warning: mail() [function.mail]: Failed to connect to mailserver at "localhost" port 25, verify your "SMTP" and "smtp_port" setting in php.ini or use ini_set() in d:\webspace\ADMIN\mysite.com\WWW\contact.php on line 26

We encountered an error sending your mail, please notify [email protected]

Link to comment
https://forums.phpfreaks.com/topic/48950-mail-function-not-working-on-server/
Share on other sites

What is the hosting you have?  Is it paid for?  Do you have shared hosting, vps, or dedicated?  Do you have to set up the mail server yourself?  Could it be possible that when you moved your files to the real domain you might have needed to update some DNS records?  We really need a bit more information. From the looks, I would say your on a VPS or Dedicated server.

I have a paid, cheap host.  UCVHost.com  It is shared.  I asked them if I had to set up PHP and they said no.

 

The really strange thing is that I have more than one domain with this host.... and the exact same HTML form and php script works fine on one account... yet on this account, I'm getting the errors I posted above.

 

Does that give anyone any ideas what might be wrong?  Their wonderful tech support said it's my code... However the same code works on another one of their own boxes!

 

:-\

 

Rick

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.