php - How can I redirect after a form submission? -


this question has answer here:

currently coding post command php pushes data e-mail. i'm looking find way redirect afterward server has sent e-mail url.

<?php $email_from = 'my@e-mail.co.uk'; $email_subject = "new form submission"; $email_body = "you have received new insurance enquiry $firstname $lastname $gender born on $dobday $dobmonth $dobyear $smoker after $insurtype want cover $cover,000 $years years $meandpartner  contact information: mobile: $mobile telephone: $landline e-mail: $email street: $street city: $city postcode: $postcode  partner details: $pfirstname $plastname $pgender $pdobday $pdobmonth $pdobyear $psmoker  " ?>  <?php $to = "my@email.co.uk"; $headers = "from: $email_from \r\n"; $headers .= "reply-to: my@email.co.uk"; mail($to,$email_subject,$email_body,$headers); ?> 

you can use header :

header('location: mypage.php'); 

more informations here : http://php.net/manual/en/function.header.php


Comments

Popular posts from this blog

php - Permission denied. Laravel linux server -

google bigquery - Delta between query execution time and Java query call to finish -

python - Pandas two dataframes multiplication? -