Hey all,
I'm sure this is simple for some but here goes. I have a script that stores customer information in the database through a MySQL query. After it stores it I need it to redirect to a summary page with all the users information based on their auto_incremented ID that will be assigned at the time of the insertion. Here's what I have so far (I left out the top of the script where the variables are pulled from the form submission since it's irrelevant:
//Store the information into the customers table of the database
$query = "INSERT INTO customers SET
fname = '".$fname."',
lname = '".$lname."',
address = '".$address."',
city = '".$city."',
state = '".$state."',
zip = '".$zip."',
category = '".$category."',
business = '".$business."',
hphone = '".$hphone."',
wphone = '".$wphone."',
mphone = '".$mphone."',
email = '".$email."',
entered = '".$entered."'";
$result = mysql_query($query);
//Redirect to customer's summary page
header("Location: /cstucson/priv/tracker/customers/view-customer.php?id=");