Okay I'm doing the whole email form thing on my site, and I want the name and email address from the form to go into the header, here's my code
<?php
$to = ' culturaldissection@hotmail.com';
$name = $_POST['name'];
$email = $_POST['email'];
$subject = $_POST['subject'];
$message = $_POST['message'];
$headers = 'From: $name $email' . "\r\n" .
'Reply-To: $email' . "\r\n" .
'X-Mailer: PHP/' . phpversion();
mail($to, $subject, $message, $headers);
echo "Your message has been sent, thank you";
?>
Also I'm hoping to adapt this for an e-card service, so would I have to put the selected card and a message into a function called $content for instance then do something like;
$message = '$content';
or am I on completely the wrong track?
__________________
Aslan & Beez Web Design - Today, Tomorrow, Forever
|