hi guys new here
seems this topic is quite a hot one neways ive used a code off here from the admin i think he seems very intelligant but its not working for me at all, i dont know whether i can use this code in a simple html page or php page, heres the code :
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Untitled Document</title>
</head>
<?php
if(isset($_POST['submit'])) {
$to = "youremail.com";
$subject = $_POST['subject'];
$message = $_POST['message'];
mail($to, $subject, $message);
echo "Your mail has been sent!";
} else { ?>
<form method="post">
Subject: <input type="text" name="subject" /><br />
Message: <textarea name="message"></textarea><br />
<input type="submit" name="submit" value="send the mail" />
<?php } ?>
<body>
</body>
</html>
can anyone identify the problem, i am copy and pasting this in a html page
cheers


