# E-Mail Me Form



## silverado4 (Nov 9, 2004)

I could not get a PHP script for my e-mail form to work, because my isp does not support it, or won't enable it for me.

I found a web site "emailmeform.com" Is this a safe site to get an e-mail form?
When I receive a message from my site, I also get an I.D. Address at the end of the message. Is this safe? I don't want the I.D. Address, and I hope no one at emailmeform.com gets it.

I just want to know is this a safe form.

If not, does anyone have an html e-mail form or were can I go to get one?
Thanks


----------



## Techmonkeys (Feb 10, 2005)

Hey Silverado,

I got asked this question the other and knocked this script together, hopefully it willbe useful for you too.

Simply add the code in to your exisiting webpage or create a new file and call it "contact.php" and paste this code in.


```
<html>
<?php
	if (isset($_POST['submit'])) {  //Checks to see if the submit button has been clicked
		$name = $_POST['name'];
		$address = $_POST['address'];
		$email = $_POST['email'];
		$phone = $_POST['phone'];
		$comments = $_POST['comments'];
		
		$to = "[email protected]";   //Change this to the email address that wants to receive the mails
		$subject = "Query from website from $name";
		$message = "Name: $name \n Email: $email \n Address: $address \n Phone: $phone \n Comments: $comments \n";
		$headers = "From: $email";
		mail($to, $subject, $message, $headers);
		echo "<font='#004779'>Thank you for your comments and questions,<br /> we will try to reply within 48hrs.</font>";  // Whatever message you want to display
	} else {
?>
<form name="contactus" action="<?php echo $_SERVER['PHP_SELF']; ?>" method="POST">
	<table>
		<tr>
			<td>Name:</td>
			<td><input type="TEXT"  name="name" /></td>
		</tr>
		<tr>
			<td>Address:</td>
			<td><textarea rows="10" name="address"></textarea></td>
		</tr>
		<tr>
			<td>Email:</td>
			<td><input type="TEXT" size="26" name="email" /></td>
		</tr>
		<tr>
			<td>Phone Number:</td>
			<td><input type="TEXT" size="26" name="phone" /></td>
		</tr>
		<tr>
			<td>Comments:</td>
			<td><textarea rows="10" name="comments"></textarea></td>
		</tr>
		<tr>
			<td align="center" colspan="2"><input type="submit" name="submit" value="Send" /></td>
		</tr>
	</table>
</form>
<?php
}
?>
</html>
```


----------



## silverado4 (Nov 9, 2004)

After the send, it goes to a "blank" page, 404 error
What am I missing, don't get too technical, I'm new to HTML
Thanks

It was supposed to say "thank you for your comments"


----------



## Techmonkeys (Feb 10, 2005)

Hi again, sorry I should have got you to test whether your hosting supports PHP first.

Try this

Open notepad (START > RUN > *notepad* > OK) and paste this text in


```
<?php

phpinfo();

?>
```
Save the file as *phpinfo.php*

Now upload the file to your website, then browse to it and see what it displays, eg: www.yourdomain.com/phpinfo.php

It should give you lots of info about PHP, if not then your host does not support PHP, if it does then something else is wrong, so if you could post the full code of your page here we can take a look


----------



## silverado4 (Nov 9, 2004)

here is what I got from your php test.
I loaded the html in my software, and copied and
pasted the phpinfo, and uploaded it.

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">

PHPTEST













*PHPTEST*

Go to content




Main menu:


Home Page







<?php

phpinfo();

?>



Back to content | Back to main menu

I hope I did it right.


----------



## silverado4 (Nov 9, 2004)

I got an e-mail from my ISP Provider "WOW" (wowway.com) and said that they do not support PHP scripts.
But when I ran the phpinfo test, I didn't get any errors, all I got was a blank page, with the page source in last note.
Thanks


----------



## tony oh (Mar 22, 2007)

I have been using this one for a while...it goes in the cgi bin.

http://www.form2email.net/


----------



## Techmonkeys (Feb 10, 2005)

Indeed it looks like they dont support PHP. SO you are stuck with finding a solution such as the one Tony has recommended sorry.


----------



## Gopaldaas (Sep 13, 2008)

silverado4 said:


> I could not get a PHP script for my e-mail form to work, because my isp does not support it, or won't enable it for me.
> 
> I found a web site "emailmeform.com" Is this a safe site to get an e-mail form?
> When I receive a message from my site, I also get an I.D. Address at the end of the message. Is this safe? I don't want the I.D. Address, and I hope no one at emailmeform.com gets it.
> ...


Yes, the website provides free html forms, it is easy to build a form and just copy paste the html code at the end, it even provides spam filter. I.D address or I.P address, everytime a form is submitted emailmefom send you the values entered with the I.P address of the person who filled the form.

You can also try 123contactform,


----------

