Example #1
0
 case 'clearPoints':
     echo $onePageCheckout->clearPoints();
     break;
 case 'setShippingMethod':
     echo $onePageCheckout->setShippingMethod($_POST['method']);
     break;
 case 'setSendTo':
 case 'setBillTo':
     echo $onePageCheckout->setCheckoutAddress($action);
     break;
 case 'checkEmailAddress':
     echo $onePageCheckout->checkEmailAddress($_POST['emailAddress']);
     break;
 case 'saveAddress':
 case 'addNewAddress':
     echo $onePageCheckout->saveAddress($action);
     break;
 case 'selectAddress':
     echo $onePageCheckout->setAddress($_POST['address_type'], $_POST['address']);
     break;
 case 'redeemVoucher':
     echo $onePageCheckout->redeemCoupon($_POST['code']);
     break;
 case 'setMembershipPlan':
     echo $onePageCheckout->setMembershipPlan($_POST['planID']);
     break;
 case 'updateCartView':
     if ($cart->count_contents() == 0) {
         echo 'none';
     } else {
         include DIR_WS_INCLUDES . 'checkout/cart.php';