[ Date Index ] [ Thread Index ] [ <= Previous by date / thread ] [ Next by date / thread => ]
Hi all, I wonder if any one can give me a hand with a bit of PHP (again!). I'm trying to write a small script that will e-mail the contents of a form to me. The form looks like this (for now): <form action="send.php" method="post"> <p>Name<input type="text" name="name" /></p> <p>E-mail<input type="text" name="email" /></p> <p><input type="submit" /></p> </form> And the PHP I think I need is this: <? $name = $_REQUEST['name']; $email = $_REQUEST['email']; $to = "jonathan.roberts.uk@xxxxxxxxxxxxxx"; $subject = "test" $message = "$name.'\n'.$email"; $headers = "From: $email"; mail($to,$subject,$message,$headers); ?> Can any body spot anything wrong, because I can't seem to get this to work how I imagine!! Jon -- The Mailing List for the Devon & Cornwall LUG http://mailman.dclug.org.uk/listinfo/list FAQ: http://www.dcglug.org.uk/linux_adm/list-faq.html