-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathforgot.php
More file actions
329 lines (293 loc) · 15.5 KB
/
forgot.php
File metadata and controls
329 lines (293 loc) · 15.5 KB
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
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
<?php
define('INCLUDE_CHECK', true);
require 'neocon.php';
require 'functions.php';
// Those two files can be included only if INCLUDE_CHECK is defined
session_name('neoLogin');
// Starting the session
session_set_cookie_params(2*7*24*60*60);
// Making the cookie live for 2 weeks
session_start();
if ($_SESSION['id'] && !isset($_COOKIE['tzRemember']) && !$_SESSION['rememberMe']) {
// If you are logged in, but you don't have the tzRemember cookie (browser restart)
// and you have not checked the rememberMe checkbox:
$_SESSION = array();
session_destroy();
// Destroy the session
}
if (isset($_GET['logoff'])) {
$_SESSION = array();
session_destroy();
header("Location: index.php");
exit;
}
if ($_POST['submit']=='Send Recovery Email') {
if ($_POST['email']) {
$_POST['email'] = mysql_real_escape_string($_POST['email']);
$row = mysql_fetch_assoc(mysql_query("SELECT dbContactNumber,dbUsr,dbPassword,dbPrimaryEmail FROM contacts WHERE dbPrimaryEmail='{$_POST['email']}'"));
if ($row['dbPrimaryEmail'] = $_POST['email']) {
send_mail('webmaster@neoterichovercraft.com',
$row['dbPrimaryEmail'],
'Neoteric Hovercraft password recovery',
'Your username at neoterichovercraft.com is '. $row['dbUsr'] .'
<br />You may reset your password at <a href="http://neoterichovercraft.com/showroom/reset.php?email='. md5($row['dbContactNumber']) .'">our password recovery page</a>');
} else {
$_SESSION['err'] = "The email could not be sent.<br/>Make sure you have entered the<br/>correct username or email.<br/>If you have not registered<br/>your information with us,<br/>please do so by clicking<br/>the top-right corner of the screen.";
header("Location: confirmation.php");
exit;
}
} elseif ($_POST['user']) {
$_POST['user'] = mysql_real_escape_string($_POST['user']);
$row = mysql_fetch_assoc(mysql_query("SELECT dbContactNumber,dbUsr,dbPassword,dbPrimaryEmail FROM contacts WHERE dbUsr='{$_POST['user']}'"));
if ($row['dbUsr'] = $_POST['user']) {
send_mail('webmaster@neoterichovercraft.com',
$row['dbPrimaryEmail'],
'Neoteric Hovercraft password recovery',
'Your username at neoterichovercraft.com is '. $row['dbUsr'] .'
<br />You may reset your password at <a href="http://neoterichovercraft.com/showroom/reset.php?email='. md5($row['dbContactNumber']) .'">our password recovery page</a>');
} else {
$_SESSION['err'] = "The email could not be sent.<br/>Make sure you have entered the<br/>correct username or email.<br/>If you have not registered<br/>your information with us,<br/>please do so by clicking<br/>the top-right corner of the screen.";
header("Location: confirmation.php");
exit;
}
}
}
if ($_SESSION['msg']) {
// The script below shows the sliding panel on page load
$script = '
<script type="text/javascript">
$(function(){
$("div#panel").show();
$("#toggle a").toggle();
});
</script>';
}
?>
<!DOCTYPE html>
<!--[if lt IE 7 ]><html class="ie ie6" lang="en"> <![endif]-->
<!--[if IE 7 ]><html class="ie ie7" lang="en"> <![endif]-->
<!--[if IE 8 ]><html class="ie ie8" lang="en"> <![endif]-->
<!--[if (gte IE 9)|!(IE)]><!-->
<html lang="en">
<!--<![endif]-->
<head>
<link rel="icon" type="image/ico" href="favicon.ico">
<!-- Basic Page Needs
================================================== -->
<meta charset="utf-8">
<title>Neoteric Hovercraft - Hovercraft Showroom</title>
<meta name="description" content="The official website for Neoteric Hovercraft: the world's original light hovercraft manufacturer.">
<meta name="author" content="Ryan Guthrie and Erica Dee Fox.">
<meta name="keywords" content="hovercraft, light hovercraft, shipbuilding, aircraft, manufacturing, hovercraft manufacturing, neoteric, neoteric hovercraft">
<!-- Mobile Specific Metas
================================================== -->
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
<!-- CSS
================================================== -->
<link rel="stylesheet" href="css/zerogrid.css">
<link rel="stylesheet" href="css/animate.css">
<link rel="stylesheet" href="css/font-awesome.min.css">
<link rel="stylesheet" href="css/style.css">
<link rel="stylesheet" href="css/responsiveslides.css">
<link rel="stylesheet" type="text/css" href="login_panel/css/slide.css" media="screen" />
<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.3.2/jquery.min.js"></script>
<!-- PNG FIX for IE6 -->
<!-- http://24ways.org/2007/supersleight-transparent-png-in-ie6 -->
<!--[if lte IE 6]>
<script type="text/javascript" src="login_panel/js/pngfix/supersleight-min.js"></script>
<![endif]-->
<script src="login_panel/js/slide.js" type="text/javascript"></script>
<?php echo $script; ?>
<script src="js/jquery-latest.min.js"></script>
<script src="js/script.js"></script>
<script src="js/jquery183.min.js"></script>
<script src="js/responsiveslides.min.js"></script>
<script>
// You can also use "$(window).load(function() {"
$(function() {
// Slideshow
$("#slider").responsiveSlides({
auto: true,
pager: false,
nav: true,
speed: 400,
timeout: 15000,
pauseControls: false,
namespace: "callbacks",
before: function() {
$('.events').append("<li>before event fired.</li>");
},
after: function() {
$('.events').append("<li>after event fired.</li>");
}
});
});
</script>
<!--[if lt IE 8]>
<div style=' clear: both; text-align:center; position: relative;'>
<a href="http://windows.microsoft.com/en-US/internet-explorer/products/ie/home?ocid=ie6_countdown_bannercode">
<img src="http://storage.ie6countdown.com/assets/100/images/banners/warning_bar_0000_us.jpg" border="0" height="42" width="820" alt="You are using an outdated browser. For a faster, safer browsing experience, upgrade for free today." />
</a>
</div>
<![endif]-->
<!--[if lt IE 9]>
<script src="js/html5.js"></script>
<script src="js/css3-mediaqueries.js"></script>
<![endif]-->
</head>
<body>
<div class="wrap-body">
<!--////////////////////////////////////Header-->
<header class="bg-theme animated slideInDown">
<div class="wrap-header zerogrid">
<div class="row" style="width: 100vw;">
<div id="cssmenu">
<ul>
<li class='active'><a href="shopping.php">Build Your Own Hovercraft</a>
<ul class="craft-drop">
<li><a href="../recconf.php">Recreational </a></li>
<li><a href="../rescconf.php">Rescue</a></li>
<li><a href="../comconf.php">Commercial</a></li>
<li><a href="../milconf.php">Military</a></li>
<li><a href="shopping.php">
<?php echo $_SESSION['hovercraft'] ?
'<i class="fa fa-shopping-cart" aria-hidden="true"></i>
My Cart
<br /><b>'. $_SESSION['hovercraft'] .'</b>'
: '<b>Start Building!</b>';?>
</a>
</li>
</ul>
<li>
<a href="cart.php">
<i class="fa fa-shopping-cart" aria-hidden="true"></i>
<?php echo $_SESSION['hovercraft'] ?
'<b>' . $_SESSION['hovercraft'] . '</b>'
: 'My Cart';?>
</a>
</li>
</li>
<li><a href="used.php">Buy Used Craft</a></li>
<li><a href="#">Buy Parts</a>
<ul>
<li><a href="accessories.php">Accessories</a></li>
<li><a href="bodymarine.php">Body & Marine</a></li>
<li><a href="drivetrain.php">Drivetrain</a></li>
<li><a href="electrical.php">Electrical & Radio</a></li>
<li><a href="trainingdocs.php">Training & Documents</a></li>
</ul>
</li>
<?php echo $_SESSION['usr'] ? '<li><a href="userinfo.php">'.$_SESSION["usr"].'</a><ul><li><a href="?logoff">Log Out</a></li></ul></li>': '<li class="active"><a href="login.php">Log In or Register</a></ul>';?>
</ul>
</div>
<a class="logo" href="index.php"><img src="images/logo.png" /></a>
</div>
</div>
</header>
<section id="container" style="padding-top:100px;padding-bottom:50px;">
<div class="zerogrid">
<div class="col-3-3 ">
<div class="intro-header">
<h2>I forgot my password!</h2>
</div>
<div class="wrap-col intro-wrap">
<div class="row">
<div class="col-1-2">
<div class='embed-container'><iframe src="https://www.youtube.com/embed/XN1vyp2CRF0?rel=0&controls=1&showinfo=0" frameborder="0" allowfullscreen></iframe>
</div>
</div>
<div class="col-1-2 ">
<ul>
<li class="intro-body">If you've forgotten your password, enter your email address or username, and your username & password reset page will be emailed to you.</li>
<li class="intro-body">
<form action="" method="post"><label class="grey" for="email">Email:</label><br/><input type="text" name="email" id="email" value="" size="30" /></li>
<li class="intro-body"><label class="grey" for="user">Username:</label><br/><input type="text" name="user" id="user" value="" size="30" /></li>
<li class="intro-body"><input type="submit" name="submit" value="Send Recovery Email" class="bt_login login-button" style="float:none;" /></form>
</li>
</ul>
</div>
</div>
</div>
</div>
</section>
<!--////////////////////////////////////Footer-->
<footer class="bg-theme animated slideInUp">
<div class="wrap-header zerogrid">
<div class="row">
<div id="cssmenu">
<ul class="fa-ul">
<li><a href="http://neoterichovercraft.blogspot.com/" target="_blank"><i class="fa fa-bold fa-lg"></i></a></li>
<li><a href="../../aboutus.php#contact"><i class="fa fa-envelope fa-lg"></i></a></li>
<li><a href="https://www.facebook.com/Neoteric.Hovercraft.Inc/" target="_blank"><i class="fa fa-facebook fa-lg"></i></a></li>
<li><a href="https://www.linkedin.com/company/neoteric-hovercraft-inc" target="_blank"><i class="fa fa-linkedin fa-lg"></i></a></li>
<li><a href="https://twitter.com/neohovercraft" target="_blank"><i class="fa fa-twitter fa-lg"></i></a></li>
<li><a href="https://www.youtube.com/user/NeotericHovercraft" target="_blank"><i class="fa fa-youtube fa-lg"></i></a></li>
</ul>
</div>
<a class="logo" href="http://www.NeotericHovercraft.com">
<p>© 2016 Neoteric Hovercraft, Inc.</p>
</a>
<a href="privacypolicy.php" class="logo">
<p><i>Privacy Policy</i></p>
</a>
</div>
<div id='ss_menu'>
<div><a href="../../aboutus.php#contact"><i class="fa fa-envelope"></i></a></div>
<div><a href="https://www.facebook.com/Neoteric.Hovercraft.Inc/" target="_blank"><i class="fa fa-facebook"></i></a></div>
<div><a href="https://twitter.com/neohovercraft" target="_blank"><i class="fa fa-twitter"></i></a></div>
<div><a href="https://www.youtube.com/user/NeotericHovercraft" target="_blank"><i class="fa fa-youtube"></i></a></div>
<div class='menu'>
<div class='share' id='ss_toggle' data-rot='180'>
<div class='circle'></div>
<div class='bar'></div>
</div>
</div>
</div>
</div>
</footer>
</div>
<script>
$(document).ready(function(ev) {
var toggle = $('#ss_toggle');
var menu = $('#ss_menu');
var rot;
$('#ss_toggle').on('click', function(ev) {
rot = parseInt($(this).data('rot')) - 180;
menu.css('transform', 'rotate(' + rot + 'deg)');
menu.css('webkitTransform', 'rotate(' + rot + 'deg)');
if ((rot / 180) % 2 == 0) {
//Moving in
toggle.parent().addClass('ss_active');
toggle.addClass('close');
} else {
//Moving Out
toggle.parent().removeClass('ss_active');
toggle.removeClass('close');
}
$(this).data('rot', rot);
});
menu.on('transitionend webkitTransitionEnd oTransitionEnd', function() {
if ((rot / 180) % 2 == 0) {
$('#ss_menu div i').addClass('ss_animate');
} else {
$('#ss_menu div i').removeClass('ss_animate');
}
});
});
</script>
<script type="text/javascript">
var _gaq = _gaq || [];
_gaq.push(['_setAccount', 'UA-36251023-1']);
_gaq.push(['_setDomainName', 'jqueryscript.net']);
_gaq.push(['_trackPageview']);
(function() {
var ga = document.createElement('script');
ga.type = 'text/javascript';
ga.async = true;
ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js';
var s = document.getElementsByTagName('script')[0];
s.parentNode.insertBefore(ga, s);
})();
</script>
</body>
</html>