if (isset($_SESSION['shipping' . $blog_id]['tax'])) {
         $theamount += $_SESSION['shipping' . $blog_id]['tax'];
     }
     $Cost = $theamount - $_POST['shipping_1'];
     $ExtraCost = $_POST['shipping_1'];
     //webtopay uses comma not decimal point
     $checkid = $token = time() . rand(0, 100);
     $_POST['RefNr'] = $checkid;
     if (isset($_COOKIE['ap_id'])) {
         $_POST['affiliate'] = $_COOKIE['ap_id'];
     }
     orderhandle($_POST, $checkid);
     if (isset($_COOKIE['ap_id'])) {
         unset($_POST['affiliate']);
     }
     $p = new webtopay_class();
     $p->webtopay_url = 'https://www.webtopay.com/pay/';
     // webtopay url
     $echoit .= $p->eshop_submit_webtopay_post($_POST);
     break;
 case 'process':
     // Process and order...
     // There should be no output at this point.  To process the POST data,
     // the submit_webtopay_post() function will output all the HTML tags which
     // contains a FORM which is submited instantaneously using the BODY onload
     // attribute.  In other words, don't echo or printf anything when you're
     // going to be calling the submit_webtopay_post() function.
     // This is where you would have your form validation  and all that jazz.
     // You would take your POST vars and load them into the class like below,
     // only using the POST values instead of constant string expressions.
     // For example, after ensureing all the POST variables from your custom
Esempio n. 2
0
     $ExtraCost = $espost['shipping_1'];
     //webtopay uses comma not decimal point
     $checkid = $token = time() . rand(0, 100);
     $espost['RefNr'] = $checkid;
     if (isset($_COOKIE['ap_id'])) {
         $espost['affiliate'] = $_COOKIE['ap_id'];
     }
     orderhandle($espost, $checkid);
     if (isset($_COOKIE['ap_id'])) {
         unset($espost['affiliate']);
     }
     /*
     		//necessary evil fix
     		$_SESSION['orderhandle']=true;
     */
     $p = new webtopay_class();
     $p->webtopay_url = 'https://www.webtopay.com/pay/';
     // webtopay url
     $echoit .= $p->eshop_submit_webtopay_post($espost);
     break;
 case 'process':
     // Process and order...
     // There should be no output at this point.  To process the POST data,
     // the submit_webtopay_post() function will output all the HTML tags which
     // contains a FORM which is submited instantaneously using the BODY onload
     // attribute.  In other words, don't echo or printf anything when you're
     // going to be calling the submit_webtopay_post() function.
     // This is where you would have your form validation  and all that jazz.
     // You would take your POST vars and load them into the class like below,
     // only using the POST values instead of constant string expressions.
     // For example, after ensureing all the POST variables from your custom