Insert info and email

Hey guys, need help agian with php.
I’ve created 6 different html contact forms that collect info and will store that info into a mySql db so the results can be searched later. This is not problem however. Each of those 6 forms will need the information sent to a different dept email address. Im stumped as to how to send the email AND send the info to the db at the same time. Seems like when I get one working the other one breaks. :frowning:

This is the insert.php that Im using which works fine


<?
include("dbinfo.php");
$name=$_POST['name'];
$company=$_POST['company'];
$title=$_POST['title'];
$email=$_POST['email'];
$phone=$_POST['phone'];
$state=$_POST['state'];
$contact_how=$_POST['contact_how'];
$message=$_POST['message'];
$query = "INSERT INTO contacts VALUES ('','$name','$company','$title','$email','$phone','$state','$contact_how','$message')";
mysql_query($query);
mysql_close();
?>

I need this to send an email and to direct to a confirmation page. I can pay some one a little money like 50$ via paypal. It would only take a good coder like 15 minutes to do :wink: May also need your services later down the line for developing the search form too. (thats if I cant figure it out) :stuck_out_tongue:
Thanks,
Josh

wooohooo! It’s works like a charm :smiley:
I may take you up on the search help. But I won’t be touching the pc that much tomorrow. Im gonna be riding my downhill bike hoping I dont die :lol:
If I need help I will post here.
Thanks again Digital! :slight_smile: