Beispiel #1
0
<?php

if (isset($order3_billing)) {
    if (!cartCheckMinTotalOrderAmount()) {
        Redirect('index.php?shopping_cart=yes&min_order=error');
    }
    if (!isset($_GET["order3_billing"]) || !isset($_GET["shippingAddressID"]) || !isset($_GET["shippingMethodID"]) || !isset($_GET["billingAddressID"])) {
        Redirect("index.php?page_not_found=yes");
    }
    $_GET["shippingAddressID"] = (int) $_GET["shippingAddressID"];
    $_GET["billingAddressID"] = (int) $_GET["billingAddressID"];
    $_GET["shippingMethodID"] = (int) $_GET["shippingMethodID"];
    if ($_GET["shippingAddressID"] != 0 && !regAddressBelongToCustomer(regGetIdByLogin($_SESSION["log"]), $_GET["shippingAddressID"])) {
        Redirect("index.php?page_not_found=yes");
    }
    if ($_GET["billingAddressID"] != 0 && !regAddressBelongToCustomer(regGetIdByLogin($_SESSION["log"]), $_GET["billingAddressID"])) {
        Redirect("index.php?page_not_found=yes");
    }
    if ($_GET["shippingMethodID"] != 0) {
        if (!shShippingMethodIsExist($_GET["shippingMethodID"])) {
            Redirect("index.php?page_not_found=yes");
        }
    }
    if (!cartCheckMinOrderAmount()) {
        Redirect("index.php?shopping_cart=yes");
    }
    if (isset($_POST["continue_button"])) {
        RedirectProtected("index.php?order4_confirmation=yes&" . "shippingAddressID=" . $_GET["shippingAddressID"] . "&" . "shippingMethodID=" . $_GET["shippingMethodID"] . "&" . "billingAddressID=" . $_GET["billingAddressID"] . "&" . "paymentMethodID=" . $_POST["select_payment_method"] . (isset($_GET['shServiceID']) ? "&shServiceID=" . $_GET['shServiceID'] : ''));
    }
    if (isset($_GET["selectedNewAddressID"])) {
        RedirectProtected("index.php?order3_billing=yes&" . "shippingAddressID=" . $_GET["shippingAddressID"] . "&" . "shippingMethodID=" . $_GET["shippingMethodID"] . "&" . "billingAddressID=" . $_GET["selectedNewAddressID"] . (isset($_GET['shServiceID']) ? "&shServiceID=" . $_GET['shServiceID'] : ''));
Beispiel #2
0
<?php

if (isset($order2_shipping)) {
    //var_dump($_GET);
    if (!cartCheckMinTotalOrderAmount()) {
        Redirect('index.php?shopping_cart=yes&min_order=error');
    }
    if (!isset($_GET["order2_shipping"]) || !isset($_GET["shippingAddressID"])) {
        Redirect("index.php?page_not_found=yes");
    }
    $_GET["shippingAddressID"] = (int) $_GET["shippingAddressID"];
    if ($_GET["shippingAddressID"] == 0) {
        $addrs = regGetAllAddressesByLogin($_SESSION["log"]);
    } else {
        if (!regAddressBelongToCustomer(regGetIdByLogin($_SESSION["log"]), $_GET["shippingAddressID"])) {
            Redirect("index.php?page_not_found=yes");
        }
    }
    if (!cartCheckMinOrderAmount()) {
        Redirect("index.php?shopping_cart=yes");
    }
    function _getOrder()
    {
        $cust_password = "";
        $Email = "";
        $first_name = "";
        $last_name = "";
        $subscribed4news = "";
        $additional_field_values = "";
        $countryID = "";
        $zoneID = "";