Cart

image
image
image
image
image
$value) { if ($_POST["code"] == $key) { unset($_SESSION["shopping_cart"][$key]); $status = "
Product is removed from your cart!
"; } if (empty($_SESSION["shopping_cart"])) unset($_SESSION["shopping_cart"]); } } } if (isset($_POST['action']) && $_POST['action'] == "change") { foreach ($_SESSION["shopping_cart"] as &$value) { if ($value['code'] === $_POST["code"]) { $value['quantity'] = $_POST["quantity"]; break; // Stop the loop after we've found the product } } } ?>
3456, 'amount' => $finalamount * 100, 'currency' => 'INR', 'payment_capture' => 1 ]; $razorpayOrder = $api->order->create($orderData); $razorpayOrderId = $razorpayOrder['id']; $_SESSION['razorpay_order_id'] = $razorpayOrderId; $displayAmount = $amount = $orderData['amount']; if ($displayCurrency !== 'INR') { $url = "https://api.fixer.io/latest?symbols=$displayCurrency&base=INR"; $exchange = json_decode(file_get_contents($url), true); $displayAmount = $exchange['rates'][$displayCurrency] * $amount / 100; } $data = [ "key" => $keyId, "amount" => $finalamount, "name" => $row['Name'], "image" => "", "prefill" => [ "name" => $row['Name'], "email" => $row['EmailID'], "contact" => $row['MobileNo'], ], "notes" => [ //"address" => $_POST['address'], // "merchant_order_id" => "12312321", ], "theme" => [ "color" => "#ED316B" ], "order_id" => $razorpayOrderId, ]; if ($displayCurrency !== 'INR') { $data['display_currency'] = $displayCurrency; $data['display_amount'] = $displayAmount; } $json = json_encode($data); //echo $json; ?> ">
TEST NAME QUANTITY PRICE TOTAL

" />
" />
+  399
' . $sum . '
'; } else { $sum = $total_price; ?> +  399
' . $sum . '
'; } } if (isset($_POST['deletemembership']) && $_POST['deletemembership'] == "remove") { unset($_SESSION["delmembership"]); $sum = $total_price; } ?>

Your cart is empty!"; } ?>