# Contact Forms Doubt

**URL:** <https://forum.kirupa.com/t/contact-forms-doubt/256135>\
**Category:** programming\
**Created:** [March 31, 2008, 7:14am UTC](https://forum.kirupa.com/t/contact-forms-doubt/256135 "2008-03-31T07:14:07Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![chaman85](https://avatars.discourse-cdn.com/v4/letter/c/b9e5f3/32.png) [@chaman85](https://forum.kirupa.com/u/chaman85)\
**Post date:** [March 31, 2008, 7:14am UTC](https://forum.kirupa.com/t/contact-forms-doubt/256135/1 "2008-03-31T07:14:07Z")

</div>

Hi, I´m Kind of new trying to add a contact form to a Web Page, I don´t know too much about programming so I tried to make it using this kirupa´s tutorial:

[http://www.kirupa.com/web/php\_contact\_form4.htm](http://www.kirupa.com/web/php_contact_form4.htm)

I understood it and followed every step, I uploaded the files I´ve generated to the site and I made some tests, in the browser (Safari), When I Click Submit, in the contact.html file, appears the mailer.php file with the next message:

“Data has been submitted to [christian8513@hotmail.com](mailto:christian8513@hotmail.com)!  
Warning: mail() [function.mail]: “sendmail\_from” not set in php.ini or custom “From:” header missing in I:\FerozoWebHosting\celltrack.com.mx\public\_html\mailer.php on line 19”

So I think something’s wrong because i´ve tried with a pair of e-mail adresses in the code and nothing happened, haven’t received nothing, I hope someone can help me, the codes used are these:

FOR THE CONTACT FILE

\<html\>

\<head\>  
\<meta http-equiv=“Content-Language” content=“en-us”\>  
\<meta http-equiv=“Content-Type” content=“text/html; charset=windows-1252”\>  
\<title\>New Page 1\</title\>  
\</head\>

\<body\>

\<form method=“POST” action=“mailer.php”\>  
Name:  
\<input type=“text” name=“name” size=“19”\>\<br\>  
\<br\>  
E-Mail:  
\<input type=“text” name=“email” size=“19”\>\<br\>  
\<br\>

```
&lt;input type="checkbox" name="check[]" value="blue_color"&gt; Blue&lt;br&gt;
&lt;input type="checkbox" name="check[]" value="green_color"&gt; Green&lt;br&gt;
&lt;input type="checkbox" name="check[]" value="orange_color"&gt; Orange&lt;br&gt;
&lt;br&gt;
&lt;input type="radio" value="yes" name="radio"&gt; YES&lt;br&gt;
&lt;input type="radio" value="no" name="radio"&gt; NO
&lt;br&gt;
&lt;br&gt;
&lt;select size="1" name="drop_down"&gt;
&lt;option&gt;php&lt;/option&gt;
&lt;option&gt;xml&lt;/option&gt;
&lt;option&gt;asp&lt;/option&gt;
&lt;option&gt;jsp&lt;/option&gt;
&lt;/select&gt;&lt;br&gt;
&lt;br&gt;
Message:&lt;br&gt;
&lt;textarea rows="9" name="message" cols="30"&gt;&lt;/textarea&gt;&lt;br&gt;
&lt;br&gt;
&lt;input type="submit" value="Submit" name="submit"&gt;

```

\</form\>

\</body\>

\</html\>

AND FOR THE MAILER FILE:

\<!DOCTYPE html PUBLIC “-//W3C//DTD XHTML 1.0 Transitional//EN” “[http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd](http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd)”\>  
\<html xmlns=“[http://www.w3.org/1999/xhtml](http://www.w3.org/1999/xhtml)”\>  
\<head\>  
\<meta http-equiv=“Content-Type” content=“text/html; charset=ISO-8859-1” /\>  
\<title\>Untitled Document\</title\>  
\</head\>

\<body\>\<?php  
if(isset($\_POST[‘submit’])) {  
$to = "christian8513@hotmail.com";  
$subject = “Form Cellular Track”;  
$name\_field = $\_POST[‘name’];  
$email\_field = $\_POST[‘email’];  
$message = $\_POST[‘message’];

$body = “From: $name\_field  
E-Mail: $email\_field  
Message:  
$message”;

echo “Data has been submitted to $to!”;  
mail($to, $subject, $body);  
} else {  
echo “blarg!”;  
}  
?\>  
\</body\>  
\</html\>

THANK YOU VERY MUCH YOU GUYS!!
