Saving check box values in a multi page form

Hi guys. I have a multi page form each page has different products and prices.

Its a simple form where users select products by ticking a check box. Once they submit the form it creates an invoice.

If someone selects multiple products from the first page how do i save these values so they can move to nest page and so on for when the decide to check out?

here is the code i use for the check box

name lang[]
value 1::::1.20::No Nails

code for quantity edit box
amount qnty[]

code for calculation
$qnty = $_POST[‘qnty’];

if(!empty($_POST['desc'])) {
    $l = $_POST['desc'];

    foreach($l as $value){
        $v = explode("::",$value);
        $q = $qnty[$v[0]-1];
        $p = $v[2]*$qnty[$v[0]-1];
        echo "<tr><td>".$v[3]."</td><td>".$v[2]."</td><td>".$q."</td><td>" . sprintf("%.2f", $p) . "</td></tr>";
        $totalprice +=  $p;



i want the values of each page saved until they decide to checkout

any help please ?

add the items to a session based cart. use the item id as the cart array index and the quantity as the stored value for each array entry.

thank you but that went straight over my head as a newbie. i will investigate.

Sponsor our Newsletter | Privacy Policy | Terms of Service