include("includes.php"); session_start(); /************************************************************************************************** * VSP Server PHP Kit Build Order Page *************************************************************************************************** *************************************************************************************************** * Change history * ============== * * 18/10/2007 - Nick Selby - New kit version *************************************************************************************************** * Description * =========== * * Displays details of the products and allows the user to enter a number of each item to buy. * It then validates the selection and forwards the user to the customer details page. ***************************************************************************************************/ // Check for the proceed button click, and if so, go validate the order if (isset($_REQUEST["proceed"])){ /** We need the user to have selected at least one item, so let's see what they've chosen ** *** by looping through the submitted Quanity fields **/ $strCart=""; for ($iLoop=1; $iLoop <= count($arrProducts); $iLoop++) { $strQuantity = "Quantity" . $iLoop; $strThisQuantity=$_REQUEST[$strQuantity]; if ($strThisQuantity>0) { $strCart=$strCart . $strThisQuantity . ","; } } if (strlen($strCart)==0){ // Nothing was selected, so simply redesiplay the page with an error $strPageError="You did not select any item to purchase. Please select at least 1 Subscription."; $_SESSION["strCart"]=""; } else { // Save the cart to the session object $_SESSION["strCart"]=$strCart; // Proceed to the customer details screen ob_end_flush(); redirect("customerDetails.php"); } } else if (isset($_REQUEST["back"])) { ob_end_flush(); redirect("welcome.php"); } ?>
|
||||
include("resourceBar.php") ?> |
|