php - How to post a collected value to a new page -
i still learning php , stuck - appreciated! scenario: html form user complete, among other things, have select radio button how many tickets want buy. php file compiles values email , sends off - part works - , redirects browser "thank completing form" page. display value collected in form on thank page: amount of tickets user selected radio button. how call 'tickets' value thank page? thank ever much!
here html form: http://menusolutions.co.za/maidens2014_booking_form.html
here "sendmail3.php" file sends mail:
$webmaster_email = "carin@menusolutions.co.za"; $feedback_page = "maidens2014.html"; $error_page = "maidens_error_message.html"; $thankyou_page = "maidens_thank_you.php"; $name = $_post['name'] ; $telephone = $_post['telephone'] ; $cell = $_post['cell'] ; $email_address = $_post['email_address'] ; $address = $_post['address'] ; $tickets = $_post['tickets'] ; $mail_body = "name: $name \n telephone: $telephone \n cell: $cell \n email: email_address \n address: $address \n tickets: $tickets"; mail( "$webmaster_email", "maidens bowled on 2014", $mail_body, "from: $email_address" ); header( "location: $thankyou_page" ); } ?>
and here thank page, upon need display 'tickets' value people can reminded how many tickets bought , amount need pay: http://menusolutions.co.za/maidens_thank_you.php
your appreciated! thank you!
you can send ticket value inside url or using session.
header( "location:". $thankyou_page.'?ticket='.$tickets );
and on page add below code,
$tickets = $_get['tickets']; echo $tickets . ' tickets.';
Comments
Post a Comment