...

View Full Version : How to ask for approval before DB update



chornbeck
06-22-2006, 04:22 PM
If I have a simple HTML form, which through a PHP script inserts and updates records in a MySQL DB, how can I set it up where after form submission, the user would see all the form data displayed, where a "Are you sure the information is correct"? kind of prompt comes up to allow them to review the info and make confirmation before SQL update or insertion happens?

lansing
06-22-2006, 04:40 PM
This is a simple way of doing it. I don't know if it is the best way thou...

Make the data post to page2.php....place the posted data into Hidden input boxes that are in a form & then echo the posted data in the page. Have 2 buttons at bottom of page...the Save or Submit & Go Back button. If the user likes the info display then when he clicks the Submit button then the hidden input boxes will post to the current processing script. Then the Go Back button is self explanatory.

I would suggest not to use JavaScript to make a Prompt or anything pop up since it wouldn't work on browsers that doesn't support it or the user has JS disabled.



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum