-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathsearch_order_no.php
38 lines (27 loc) · 899 Bytes
/
search_order_no.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
32
33
34
35
36
37
38
<?php
error_reporting(0);
session_start();
include_once("Config.php");
$res = $pro->findOne(array('Order.order_no' => (int)$_POST['search']));
if($_POST['search']=='all')
{
header("Location: total_order_history.php");
}
if($res && $res['Order']['by']=='customer')
{
$_SESSION['order_no']=$_POST['search'];
header("Location: found_customer_order_no.php");
// echo $_POST['search'];
//echo "<script type='text/javascript'>alert('Hello You are successfully Loged_In '); window.location.href='Customer_Pro.php';</script>";
//echo "<h2>Hiii..!! ".$_POST['U_name']."</font></h2>";
}
else if($res && $res['Order']['by']=='admin')
{
$_SESSION['order_no']=$_POST['search'];
header("Location: found_admin_order_id.php");
}
else
{
echo "<script type='text/javascript'>alert('No Such order '); window.location.href='total_order_history.php';</script>";
}
?>