SMTP problem with PHP form in Godaddy hosting! -


i testing (nice) simple form css tricks. in website hosted in godaddy.

and got following warning:

warning: mail() [function.mail]: smtp server response: 451 see 

http://pobox.com/~djb/docs/smtplf.html in d:\hosting\4923367\html\test\contactengine on line 32.

(i checked page didn't see useful)

contactengine.php

<?php  $emailfrom = "chriscoyier@gmail.com"; $emailto = "janoochen@gmail.com"; $subject = "nice & simple contact form css-tricks"; $name = trim(stripslashes($_post['name'])); $tel = trim(stripslashes($_post['tel'])); $email = trim(stripslashes($_post['email'])); $message = trim(stripslashes($_post['message']));  // validation $validationok=true; if (!$validationok) {   print "<meta http-equiv=\"refresh\" content=\"0;url=error.htm\">";   exit; }  // prepare email body text $body = ""; $body .= "name: "; $body .= $name; $body .= "\n"; $body .= "tel: "; $body .= $tel; $body .= "\n"; $body .= "email: "; $body .= $email; $body .= "\n"; $body .= "message: "; $body .= $message; $body .= "\n";  // send email $success = mail($emailto, $subject, $body, "from: <$emailfrom>");  // redirect success page if ($success){   print "<meta http-equiv=\"refresh\" content=\"0;url=contactthanks.php\">"; } else{   print "<meta http-equiv=\"refresh\" content=\"0;url=error.htm\">"; } ?> 

any suggestions?

this link provides solution. try replacing newlines \r\n

in mail message headers , content, new lines supposed denoted both carriage return (cr) , line feed (lf)


Comments

Popular posts from this blog

c++ - How do I get a multi line tooltip in MFC -

asp.net - In javascript how to find the height and width -

c# - DataTable to EnumerableRowCollection -