If you do not have a script properly configured to send mail, it may send emails out in the form of ftpuser@(unix|nt)XX.hsphere.cc. For example, davejoe2@unix18.hsphere.cc. This is bad because it's not a proper email address, but more importantly look at this: if you have a lot of domains under that account (for example, 30) and each domain sends 100 emails out, you've exceeded the 2,000 emails per day limit and will get blacklisted.
How do I fix it?
For PHP you will need to change your script from this:
mail($to,$subject,$body);to this:
mail($to,$subject,$body,'From: user@domain.com','-fuser@domain.com');Replace user@domain.com with your from email address, and make sure to include the dash before the email address in the last parameter!
If you are on Windows, you will also need to do the following:
- download the attached php.ini
- Open up the php.ini file in a text editor like Notepad.
- Search for sendmail_from and replace the email address that is there with your from email address.
- Save the file and put it in the root directory of your site.
php_value sendmail_from user@domain.comIf such a file does not exist, you will need to create it.
For formmail.cgi, you will need to properly configure your formmail.cgi file so that it sends out from a proper from address.
- Open the your formmail.cgi file with a text editor.
- Change the following line:
$mailprog = '/usr/sbin/sendmail -i -t';
to$mailprog = '/usr/sbin/sendmail -i -t -fYour From Email Address';
Note that there is a -f followed by the email address without spaces. - Save the file and upload it to the server.
Attached File(s)
-
php.ini (38.29K)
Number of downloads: 36

Sign In
Register
Help
MultiQuote