GoDaddy PHP Mail Script

RobertNZana
RobertNZana used Ask the Experts™
on
Using GoDaddy Windows Hosting.  Do I HAVE to use their asp/php mail scripts?  http://help.godaddy.com/article/512#gdform

Has anyone got a custom asp or php mailer that they are using on GoDaddy with Windows hosting?  Thanks.

I can't even find the php and asp files provided by GoDaddy even though I "reinstalled" them.
Comment
Watch Question

Do more with

Expert Office
EXPERT OFFICE® is a registered trademark of EXPERTS EXCHANGE®
Commented:
I've always used PHPMailer. I haven't used GoDaddy's hosting before, but I highly doubt that they restrict what types of mailer programs they use:
http://sourceforge.net/projects/phpmailer/
Commented:
I pretty sure that it is GoDaddy that does not allow the use of the mail() function in PHP and that you must use SMTP to send emails. I don't know anything about their restrictions as far as ASP goes, but would assume them to be the same. If you are using PHP then gr8gonzo's suggestion would be your best bet. If you whant to use ASP then you'll need to find an ASP mailer that can do SMTP mail.
Principal Data Engineer
Commented:
I use it on Godaddy although there are plenty of suggestions to say you can't because of spammers, but, here's my mail script that does work and it's very simple.

<?php

/**
 * @author elvin66@xtra.co.nz
 * @copyright 2009
 */

//<!-- Generate the email <!-->

$email = "someone@somewhere.com";
$headers = "MIME-Version: 1.0" . "\r\n";
$headers .= "From: you@yourplace.com" . "\r\n";
$headers .= "Reply-To: you@yourplace.com" . "\r\n";
$headers .= "X-Mailer: PHP/" . phpversion();

$subject = "Subject line goes here";
$message= "Hello "
."This is a test email"
."Goodbye";

if($send_contact = mail($email,$subject,$message,$headers)
){
      echo "Mail sent to ".$email;
}else{
      echo "Failed to send email";
}

?>
             
// just change the email addresses obviously and it should send just fine      
//You may also wish to add some more headers for functionality like for eg:

$headers .= "Cc: \r\n";
$headers .= "Bcc: \r\n";

Author

Commented:
I ended up using the mail scripts from http://www.tectite.com/ 

They work great

Thanks for all the advice!

Do more with

Expert Office
Submit tech questions to Ask the Experts™ at any time to receive solutions, advice, and new ideas from leading industry professionals.

Start 7-Day Free Trial