This article introduces the implementation of the PHP multi-step Fill poll form, roughly to get the user to fill in the content after the save in a hidden, and then the last step to submit to the database.
1.php
The code is as follows |
Copy Code |
|
2.php
The code is as follows |
Copy Code |
|
3.php
The code is as follows |
Copy Code |
|
4.php
The code is as follows |
Copy Code |
$base 1=$_request[' base1 ']; $base 2=$_request[' Base2 ']; $prcname =$_request[' Prcname ']; $price =$_request[' price ']; $prcXH =$_request[' prcxh ']; $other 1=$_request[' Other1 ']; $other 2=$_request[' Other2 ']; $sql 1= "INSERT INTO [base_table] (BASE1,BASE2) VALUES (' {$base 1} ', ' {$base 2} ')"; $sql 2= "INSERT INTO [prc_table] (PRCNAME,PRICE,PRCXH) VALUES (' {$prcname} ', ' {$price} ', ' {$prcXH} ')"; $sql 3= "INSERT INTO [other_table] (Other1,other2) VALUES (' {$other 1} ', ' {$other 2} ')"; Query ($sql 1); Query ($sql 2); Query ($sql 3); echo "Write complete"; ?> |
Summarize
The problem with this is that if the user accidentally closes the page data will be re-filled again oh, but this way a lot of large sites are doing this, including Baidu's Encyclopedia of the Novice upgrade is also handled.
http://www.bkjia.com/PHPjc/631595.html www.bkjia.com true http://www.bkjia.com/PHPjc/631595.html techarticle This article introduces the implementation of the PHP multi-step Fill poll form, roughly to get the user to fill in the content after the save in a hidden, and then the last step to submit to ...