php confirm box

Solutions on MaxInterview for php confirm box by the best coders in the world

showing results for - "php confirm box"
Giulio
03 Apr 2019
1If you want to do this only in PHP, you will need to add "steps" in your script, like:
2
3step1 (show form) -> step2 (ask validation) -> step3 (validate)
4To do so, you can use sessions to keep form content, and GET parameter to track the step. Otherwise the simplest solution is to use javascript:
5
6echo "<td><a onClick=\"javascript: return confirm('Please confirm deletion');\" href='delete.php?id=".$query2['id']."'>x</a></td><tr>"; //use double quotes for js inside php!