-
Notifications
You must be signed in to change notification settings - Fork 0
/
SMakeAppResult.php
127 lines (119 loc) · 3.76 KB
/
SMakeAppResult.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
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
<?php
session_start();
include('connect.php');
if(!isset($_SESSION['userID'])){
// echo 'Please Log in!';
header("Location:login.html");
exit();
}if($_SESSION['Role'] !== 'Student')
{
header("Location:login.html");
exit();
}
?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Make Appointment</title>
<link href="css/style.css" rel="stylesheet">
<script src="js/jquery.js"></script>
<style>
.cal-table {
background: #3eabe7 none repeat scroll 0 0;
border: 1px solid #3eabe7;
color: #000000;
font-family: 新宋体;
font-size: 14px;
margin-top: 10px;
width: 771px;
}
table, tr, td {
border-collapse: collapse;
border-spacing: 0;
margin: 0;
padding: 0;
}
.cal-table td {
background: #ffffff none repeat scroll 0 0;
height: 32px;
text-align: center;
}
.cal-table th {
background: #3eabe7 none repeat scroll 0 0;
height: 40px;
text-align:center;
color:#FFFFFF;
}
</style>
</head>
<body class="pos_r">
<div class="header of_hidden">
<div class="l_logo">
<a href="javascript:;" class="top_logo"><img src="images/logo.png" /></a>
</div>
<div class="r_menu">
<ul>
<li ><a href="SHome.php"><img src="images/icon_1.png" /><span><b>Home Page</b></span></a></li>
<li ><a href="SApp.php"><img src="images/icon_2.png" /><span><b>My Appointment</b></span></a></li>
<li style="background:#0081cd" ><a href="javascript:;"><img src="images/icon_3.png" /><span><b>Make Appointmentg</b></span></a>
</li>
<li></li>
<li></li>
<li></li>
<li></li>
<li><a href="logout.php"><img src="images/icon_8.png" /><span><b>Log out</b></span></a></li>
</ul>
</div>
</div>
<div class="wrap">
<div class="full_wrap">
<div class="left_side">
<div class="l_msg1">Welcome</div>
<div class="l_msg2">Student</div>
<div class="l_msg3"> <?php
if(isset($_SESSION['firstName'])){
echo $_SESSION['firstName'].' '.$_SESSION['lastName']; }
?></div>
</div>
<div class="main_content">
<?php
$examId=$_POST["examId"];
include('connect.php');
$sql = "select * from exam where examId = '$examId'";//get the test result
$result = mysql_query($sql);//sql
if(mysql_num_rows($result)==1) // the test exist
{
$row=mysql_fetch_assoc($result);
echo "id: ".$row["examId"]. " CourseName: ".$row["course"]. " startDate: ".$row["startDate"]." endDate: ".$row["endDate"]." startTime: ".$row["startTime"]." <br>";
}
else
{
echo "The test is not exist";
}
$_SESSION['examId']=$examId;
session_register("examId");
?>
<form action="SMakeAppConfirm.php" >
<input type="submit" name="confirm" value="confirm">
</form>
<form action="SMakeApp.php" >
<input type="submit" name="cancel" value="cancel">
</form>
</div>
</div>
</div>
<div class="footer">
<div class="container">
<p>Copyright<span>©</span> 2015 Test Center</p>
</div>
</div>
<script>
var _w_h = $(window).height()-$('.header').outerHeight(true)-$('.footer').outerHeight(true);
$('.wrap').css('min-height',_w_h+'px');
$(window).resize(function(){
var _w_h = $(window).height()-$('.header').outerHeight(true)-$('.footer').outerHeight(true);
$('.wrap').css('min-height',_w_h+'px');
});
</script>
</body>
</html>