Hi, this is the first thing I’ve tried with php so I’m a bit confused. I found some tutorials online and took different elements from them all for my email form, and also tried to do that with the code but the frankencode doesnt work. I want each different thing on the drop down menus to be able to go to a different email address. Right now theyre all set on the same email so I can test it.
The website is here
http://myareasbest.com/contact.html
and heres my code
<?php $mailto = $_POST['me']; if($mailto == 'info') { $subject = "Question/Comment"; $name_field = $_POST['name']; $email_field = $_POST['email']; $message = $_POST['message']; $email = "[email protected]"; }elseif($mailto == 'complaints'){ $email = "[email protected]"; echo "Email has been submitted to $to!"; mail($to, $subject, $body); }; ?>