-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbyepage.php
215 lines (194 loc) · 6.32 KB
/
byepage.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
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
<?php
//Declaration of variables
$uEmail = '';
$uPassword = '';
$errorMsg3 = '';
$numofRows = 0;
$errJar3 = "";
function SetCheck()
{
if( isset($_POST['SigninSubmit']) == "Sign in" || isset($_POST['formSubmit']) == "Submit")
{
return isset($_POST['uEmail'], $_POST['uPassword']);
}
}
//Cleaning up and collecting login details
if(SetCheck() == TRUE)
{
$uEmail = $_POST['uEmail'];
$uPassword = $_POST['uPassword'];
$uEmail = htmlspecialchars($_POST['uEmail']);
$uPassword = htmlspecialchars($_POST['uPassword']);
//Checking login details against database
include("/doc_cabinet_connect.php");
if(dbconnect('doc_cabinet')){
$uEmail = $uEmail;
$uPassword = $uPassword;
//Crosscheck login details
$query = sprintf("SELECT * FROM users_details WHERE user_Email ='%s' AND user_PW ='%s'",
mysql_real_escape_string($uEmail),
md5(mysql_real_escape_string($uPassword)));
$result = mysql_query($query);
if($result)
{
if(@mysql_result($result,0,0) > 0)
{
session_start();
$_SESSION['login_status'] = "1";
$_SESSION['uEmail'] = "$uEmail";
$_SESSION['uPassword'] = "$uPassword";
if ($_SESSION['login_status'] = "1")
{
header("Location:yourdocstream.php");
exit;
}
}
else
{
$errJar3 .="<li>Either your <b>Email Address and/or Password may be incorrect</b>.</li>";
session_start();
$_SESSION['login_status'] = '';
}
}
else
{
//$errjar3 .="<li>Oops! Please <b>Reload the page</b> and <b>try Signing In again</b>.</li>";
}
}else{
$errJar3 .= '<li>Oops! Please <b>Reload the page</b> and <b>try Signing In again</b>.</li>';
}
if(!empty($errJar3)){
$errorMsg3 .= "<ul>" .$errJar3. "</ul>";
}
}
//Script for directing to sign up page.
if(isset($_POST['SignUp']) == "SignUp"){
header("Location:signup.php");
exit;
}
?>
<!DOCTYPE html>
<html>
<head>
<title>Bye | Sign In</title>
<link rel = "stylesheet" type ="text/css" href = "css/bootstrap.min.css">
<link rel = "stylesheet" type = "text/css" href = "css/codedoc.css">
</head>
<body>
<script src="js/jquery-1.8.1.js"></script>
<script src="js/bootstrap.min.js"></script>
<script src = "js/docindex.js"></script>
<!--HEADER SECTION-->
<div class="headr">
<div class="container">
<div class="span12">
<div class="row-fluid">
<!--SITE LOGO-->
<div class="span8"><img src = "img/pyrusclogo v4.gif"></div>
<!--LOGIN FORM ON HEADER-->
<div class="span4">
<form class="form-inline" method="post" action="signin.php">
<div id ="headr-login2">
<label>
<p style = "color:#ffffff;">Don't have an account yet? </p>
</label>
<button type="submit" class="btn" name ="SignUp" value = "SignUp">Register</button>
</div>
</form>
</div>
</div>
</div>
</div>
</div>
<!--FLAG SECTION-->
<?php
if(!empty($errorMsg3)){
echo('<div class = "redflag"><div class ="container"><div class = "row-fluid"><div class = "errFlagMgr">'.$errorMsg3.'</div></div></div></div>');
}
?>
<!--CONTENT SECTION-->
<div class = "container">
<div class = "row-fluid">
<div class = "span12">
<h2 class = "docHeadr" style = "margin-top:1em;">Thank You for using Pyruscape.</h2><hr>
</div>
</div>
<div class = "row-fluid">
<div class = "span12">
<div class = "span5" style = "margin-top:-0.8em;">
<!--VALUE EXPLAINATION-->
<div class="span9">
<div id = "explainr">
<h3> Do invite others to:</h3>
<ul>
<li><b>Upload</b> their documents or memos to Pyruscape.</li><br>
<li>Make use of the good tools we provide, to aid the seamless <b>dispatch</b> of their documents or memos across their organisations or departments.</li><br>
<li>Get the ability to <b>track</b> their document or memo's movement across their organisations or departments.</li><br>
</ul>
</div>
</div>
</div>
<div class = "span3">
<div id = "signin-form" style = "margin-top:4em;">
<form class="form-horizontal" method="post" action = "signin.php">
<table>
<tr>
<td>
<div class="control-group">
<label class="control-label" for="inputEmail">Email</label>
<div class="controls">
<input type="text" id="inputEmail" placeholder="Email" name = "uEmail">
</div>
</div>
</td>
</tr>
<tr>
<td>
<div class="control-group">
<label class="control-label" for="inputPassword">Password</label>
<div class="controls">
<input type="password" id="inputPassword" placeholder="Password" name = "uPassword">
</div>
</div>
</td>
</tr>
<tr>
<td>
<div class="control-group">
<div class="controls">
<label class="checkbox">
<input type="checkbox"> Remember me
</label>
<button type="submit" class="btn" name = "SigninSubmit" value = "Sign in">Sign in</button>
</div>
</div>
</td>
</tr>
</table>
</form>
</div>
</div>
</div>
</div>
</div>
<!--FOOTER-->
<div class="footr" style = "margin-top:3.5em;">
<div class="container">
<div class ="span12">
<div class = "footrLinks">
<div class="copyright">© <?php echo date("Y");?>
<a href ="">Kaelahi Technologies</a>
<a href ="">About Us</a>
<a href ="">Contact</a>
<a href ="">Career</a>
<a href ="">FAQ</a>
<a href ="">Privacy Statement</a>
<a href ="">Terms and Conditions</a>
<a href ="">Blog</a>
</div>
</div>
</div>
</div>
</div>
</body>
</html>