-
Notifications
You must be signed in to change notification settings - Fork 1
/
delbill.php
31 lines (31 loc) · 883 Bytes
/
delbill.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
<?php
session_start();
require "config.php";
require "models/db.php";
require "models/product.php";
require "models/manufacture.php";
require "models/protype.php";
require "models/cart.php";
require "models/user.php";
require "models/bill.php";
$product = new Product();
$manu = new Manufacture();
$type = new Protype();
$cart = new Cart();
$user = new User();
$bill = new Bill();
if (isset($_GET['id'])) {
# code...
$id = $_GET['id'];
$check = $user->check($_SESSION['user']);
foreach ($check as $values) {
if ($bill->deletebill($id, $values['user_id'])) {
# code...
// $getAllBillid = $bill->getAllBillid($values['user_id'], $id);
// foreach ($getAllBillid as $values) {
// unset($_SESSION['cart'][$values['product_id']]);
// }
header("location:myorder.php");
}
}
}