Hi all,
I have set up a database containing a persons email address.
In my PHP webpage I want to allow the user the option of emailing that person.
I have it set up so that when the user ticks the check box (corresponding to a person in the database) , and hits Submit an email will be automatically sent to that person stored in the DB.
How do I do this??
Will something like this work.... (can't test it on my server cos php needs 2b upgraded!)
$email=implode(',',$rep); // $rep is name of checkbox
echo '<h2>Thank you '.ucwords($name).' for your email</h2>';
mail($email, $subject, $content, $headers);
What do I set $email variable to???
Thanks very much for your help.
Kevin.