Advertisement

10.09.2008 at 10:35PM PDT, ID: 23803236 | Points: 250
[x]
Attachment Details

PHP Email Form Security

Asked by tru504187211 in PHP and Databases

Tags: ,

I was told by a member (who helped me on my last question) that for my 'TO' field on my PHP email form page, that a /r/n was necessary to keep the page from becoming a mail relay for spammers.  Basically, I wanted to know if it is safe with simply a /n as removing the /r allowed the 'sender' to appear to Outlook, otherwise it would go to spam without a sender.

Is there a safe way to go about having the sender appear as the sender (even hard coded) but with keeping the form secure?Start Free Trial
1:
2:
3:
4:
5:
6:
$to="info@domain.com";
$headers.= "MIME-Version: 1.0\n";
$headers.= "Content-type: text/html; ";
$headers.= "charset=iso-8859-1\n";
$headers.= "From: Online Form <info@domain.com>\n"; 
$subject = "Customer Survey - Online Form";
[+][-]10.10.2008 at 02:00PM PDT, ID: 22690767

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 14-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]11.17.2008 at 08:11PM PST, ID: 22982011

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 14-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]11.18.2008 at 05:48AM PST, ID: 22984389

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 14-day free trial to view this Expert Comment or ask the Experts your question.

 
 
Loading Advertisement...
20081112-EE-VQP-43 / EE_QW_2_20070628