Here is how I have done it.
First the form code:
[php]
<form action="email.php" method="post">
Name<br><input type="text" name="username" size="50">
<p style="text-align: center; font-family:arial, verdana, lucida, helvetica, sans-serif;font-size: 16px">
Email Address<br><input type="text" name="useraddr" size="50">
<p style="text-align: center; font-family:arial, verdana, lucida, helvetica, sans-serif;font-size: 16px">
Comment<br>
<textarea name="comments" cols="50" rows="20"></textarea><br>
<input type="submit" value="Send Comment">
</form>
[/php]
And then the code that is executed when you click on "Send Comment":
[php]
<?php
$comments = $_POST['comments'];
$username = $_POST['username'];
$useraddr = $_POST['useraddr'];
$to = "destination@domain.com";
$re = "Website Comment Form";
$msg = $comments;
$headers = 'From: ' . $username . ' <' . $useraddr . '>' . "\r\n" .
'Reply-To: ' . $username . ' <' . $useraddr . '>' . "\r\n" .
'X-Mailer: PHP/' . phpversion();
mail( $to,$re,$msg,$headers );
?>
<html>
<head><title>Messsage Received</title></head>
<body>
<center><h3 class=h16>Thank You For Your Comments</h3></center>
<p>
<center>Message received from <?php echo( $username ); ?>
<br>
Reply to <?php echo( $useraddr ); ?></center>
</body>
</html>
[/php]
This is very basic but has worked for me. I need to beef it up with Captcha so bots can't exploit it