PHP Multi-Step Fill poll Form implementation Method _php tutorial

Source: Internet
Author: User
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 ...

  • Contact Us

    The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

    If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

    A Free Trial That Lets You Build Big!

    Start building with 50+ products and up to 12 months usage for Elastic Compute Service

    • Sales Support

      1 on 1 presale consultation

    • After-Sales Support

      24/7 Technical Support 6 Free Tickets per Quarter Faster Response

    • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.