-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Needed for Testing changepassword page
- Loading branch information
1 parent
3434ecf
commit 72f3f7e
Showing
149 changed files
with
47,505 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,67 @@ | ||
<html> | ||
<head> | ||
<title>Change password</title> | ||
<link rel="stylesheet" href="css/main.css"> | ||
<link href='https://fonts.googleapis.com/css?family=Roboto:400,300,500' rel='stylesheet' type='text/css'> | ||
<link href="//netdna.bootstrapcdn.com/font-awesome/4.1.0/css/font-awesome.min.css" rel="stylesheet"> | ||
<script src="js/jquery-1.8.2.min.js"></script> | ||
<script src="js/jquery.validate.min.js"></script> | ||
<script src="js/main.js"></script> | ||
<style type="text/css"> | ||
a:link {color: #ffffff} | ||
a:visited {color: #ffffff} | ||
a:hover {color: #ffffff} | ||
a:active {color: #ffffff} | ||
</style> | ||
</head> | ||
<body> | ||
<?php include("header.php"); ?> | ||
<form id="login-form" class="login-form" name="form1" method="post" action="changepw.php"> | ||
<div id="form-content"> | ||
<div class="welcome"> | ||
Do you want to change your password? | ||
<br /> | ||
Email ID: <input type="text" name="email"><br/> | ||
Current password: <input type="password" name="opw"><br/> | ||
New password: <input type="password" name="npw"><br/><br/> | ||
<center><input type="submit" name="changepw" value="Change password"></center> | ||
</div> | ||
</div> | ||
</form> | ||
</body> | ||
</html> | ||
<?php | ||
$connect = mysql_connect("localhost","root","newhorizon"); | ||
mysql_select_db("foodies") or die("couldn't find database"); | ||
if (isset($_POST['changepw'])){ | ||
$email=$_POST['email']; | ||
$opw=$_POST['opw']; | ||
$npw=$_POST['npw']; | ||
$query = mysql_query("select * from php_users_login where email='$email'"); | ||
$numrows = mysql_num_rows($query); | ||
if($numrows!=0) | ||
{ | ||
while($row = mysql_fetch_assoc($query)) | ||
{ | ||
$dbemail = $row['email']; | ||
$dbpassword = $row['password']; | ||
} | ||
if($dbemail==$email&&$opw==$dbpassword) | ||
{ | ||
$sql2 ="UPDATE php_users_login SET password= '$npw' WHERE email= '$dbemail';"; | ||
if(mysql_query($sql2)) | ||
{ | ||
echo "<script type='text/javascript'>alert('Password changed successfully');</script>"; | ||
} | ||
else | ||
{ | ||
echo "<script type='text/javascript'>alert('Error');</script>"; | ||
} | ||
} | ||
else | ||
echo "<script type='text/javascript'>alert('Incorrect password');</script>"; | ||
} | ||
else | ||
echo "<script type='text/javascript'>alert('User does not exist');</script>"; | ||
} | ||
?> |
Empty file.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,320 @@ | ||
*{ font-family: 'Roboto', sans-serif; } | ||
html, | ||
button, | ||
input, | ||
select, | ||
textarea { | ||
color: #222; | ||
} | ||
html { | ||
font-size: 1em; | ||
line-height: 1.4; | ||
} | ||
|
||
::-moz-selection { | ||
background: #b3d4fc; | ||
text-shadow: none; | ||
} | ||
::selection { | ||
background: #b3d4fc; | ||
text-shadow: none; | ||
} | ||
|
||
hr { | ||
display: block; | ||
height: 1px; | ||
border: 0; | ||
border-top: 1px solid #ccc; | ||
margin: 1em 0; | ||
padding: 0; | ||
} | ||
audio, | ||
canvas, | ||
img, | ||
video { | ||
vertical-align: middle; | ||
} | ||
fieldset { | ||
border: 0; | ||
margin: 0; | ||
padding: 0; | ||
} | ||
textarea { | ||
resize: vertical; | ||
} | ||
* { | ||
-webkit-box-sizing: border-box; | ||
-moz-box-sizing: border-box; | ||
box-sizing: border-box; | ||
} | ||
*:before, | ||
*:after { | ||
-webkit-box-sizing: border-box; | ||
-moz-box-sizing: border-box; | ||
box-sizing: border-box; | ||
} | ||
body { | ||
background: #333333 url('background.jpg') no-repeat center bottom fixed; | ||
-webkit-background-size: cover; | ||
-moz-background-size: cover; | ||
-o-background-size: cover; | ||
background-size: cover; | ||
font-weight: 300; | ||
} | ||
.login-form { | ||
margin: 50px auto; | ||
background: white; | ||
padding: 30px 0; | ||
position: relative; | ||
-webkit-box-shadow: 0 0 5px 3px rgba(0, 0, 0, 0.125); | ||
box-shadow: 0 0 5px 3px rgba(0, 0, 0, 0.125); | ||
height: 400px; | ||
} | ||
.login-form #form-loading { | ||
text-align: center; | ||
position: absolute; | ||
top: 0; | ||
bottom: 0; | ||
width: 100%; | ||
opacity: 0.5; | ||
filter: alpha(opacity=50); | ||
z-index: 1000; | ||
background: #555555; | ||
} | ||
.login-form #form-loading i { | ||
font-size: 100px; | ||
} | ||
.login-form #form-message { | ||
text-align: center; | ||
color: #555555; | ||
} | ||
.login-form .h1 { | ||
font-size: 30px; | ||
color: #3EC038; | ||
padding: 15px 15px 35px 15px; | ||
text-transform: uppercase; | ||
text-align: center; | ||
} | ||
.login-form .logo { | ||
height: auto; | ||
max-width: 100%; | ||
} | ||
.login-form .group { | ||
*zoom: 1; | ||
-webkit-transition: all ease .2s; | ||
transition: all ease .2s; | ||
border-left: 4px solid #fff; | ||
padding: 10px 0; | ||
} | ||
.login-form .group:before, | ||
.login-form .group:after { | ||
content: " "; | ||
display: table; | ||
} | ||
.login-form .group:after { | ||
clear: both; | ||
} | ||
.login-form .group > label { | ||
padding-left: 15px; | ||
padding-top: 5px; | ||
color: #555555; | ||
font-size: 16px; | ||
display: block; | ||
} | ||
.login-form .group > label.empty { | ||
display: block; | ||
height: 1px; | ||
padding: 0; | ||
margin: 0; | ||
} | ||
.login-form .group > div { | ||
padding: 0 15px; | ||
} | ||
.login-form .group > div.addon-right { | ||
position: relative; | ||
padding-right: 50px; | ||
} | ||
.login-form .group > div.addon-right > i { | ||
position: absolute; | ||
right: 25px; | ||
top: 9px; | ||
z-index: 999; | ||
color: #555555; | ||
} | ||
.login-form .group > div .error-message { | ||
font-size: 12px; | ||
color: red; | ||
margin-top: 5px; | ||
} | ||
.login-form .group.active { | ||
background: #F6F6F6; | ||
border-left-color: #40C2FF; | ||
-webkit-box-shadow: inset 0px 0px 3px rgba(0, 0, 0, 0.03); | ||
box-shadow: inset 0px 0px 3px rgba(0, 0, 0, 0.03); | ||
} | ||
.login-form input[type=submit] { | ||
border: none; | ||
background: #65CA60; | ||
color: white; | ||
padding: 5px 20px; | ||
text-transform: uppercase; | ||
font-weight: 500; | ||
border-radius: 1px; | ||
-webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075); | ||
box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075); | ||
-webkit-transition: background ease-in-out .15s; | ||
transition: background ease-in-out .15s; | ||
cursor:pointer; | ||
} | ||
.login-form input[type=button] { | ||
border: none; | ||
background: #65CA60; | ||
color: white; | ||
padding: 5px 20px; | ||
text-transform: uppercase; | ||
font-weight: 500; | ||
border-radius: 1px; | ||
-webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075); | ||
box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075); | ||
-webkit-transition: background ease-in-out .15s; | ||
transition: background ease-in-out .15s; | ||
cursor:pointer; | ||
} | ||
.login-form input[type=submit]:hover { | ||
background: #5AC253; | ||
} | ||
.login-form { | ||
width: 320px; | ||
} | ||
@media (min-width: 550px) { | ||
.login-form { | ||
width: 520px; | ||
} | ||
.login-form .group > label { | ||
float: left; | ||
width: 180px; | ||
} | ||
.login-form .group > div { | ||
margin-left: 180px; | ||
padding-left: 0; | ||
} | ||
} | ||
.form-control { | ||
display: block; | ||
width: 100%; | ||
height: 34px; | ||
padding: 6px 12px; | ||
font-size: 14px; | ||
line-height: 1.428571429; | ||
color: #555555; | ||
background-color: #ffffff; | ||
background-image: none; | ||
border: 1px solid #cccccc; | ||
border-radius: 1px; | ||
-webkit-box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075); | ||
box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075); | ||
-webkit-transition: border-color ease-in-out .15s, box-shadow ease-in-out .15s; | ||
transition: border-color ease-in-out .15s, box-shadow ease-in-out .15s; | ||
} | ||
.form-control:focus { | ||
border-color: #66afe9; | ||
outline: 0; | ||
-webkit-box-shadow: inset 0 1px 1px rgba(0,0,0,.075), 0 0 8px rgba(102, 175, 233, 0.6); | ||
box-shadow: inset 0 1px 1px rgba(0,0,0,.075), 0 0 8px rgba(102, 175, 233, 0.6); | ||
} | ||
.form-control::-moz-placeholder { | ||
color: #999999; | ||
opacity: 1; | ||
} | ||
.form-control:-ms-input-placeholder { | ||
color: #999999; | ||
} | ||
.form-control::-webkit-input-placeholder { | ||
color: #999999; | ||
} | ||
.form-control[disabled], | ||
.form-control[readonly], | ||
fieldset[disabled] .form-control { | ||
cursor: not-allowed; | ||
background-color: #eeeeee; | ||
opacity: 1; | ||
} | ||
textarea.form-control { | ||
height: auto; | ||
} | ||
.hide { | ||
display: none !important; | ||
} | ||
.show { | ||
display: block !important; | ||
} | ||
.one-line { | ||
text-overflow: ellipsis; | ||
white-space: nowrap; | ||
overflow: hidden; | ||
} | ||
.arrow-up { | ||
border-left-color: transparent; | ||
border-right-color: transparent; | ||
border-top-style: none; | ||
} | ||
.arrow-down { | ||
border-left-color: transparent; | ||
border-right-color: transparent; | ||
border-bottom-style: none; | ||
} | ||
.arrow-right { | ||
border-top-color: transparent; | ||
border-bottom-color: transparent; | ||
border-right-style: none; | ||
} | ||
.arrow-left { | ||
border-top-color: transparent; | ||
border-bottom-color: transparent; | ||
border-left-style: none; | ||
} | ||
.arrow { | ||
width: 0; | ||
height: 0; | ||
display: inline-block; | ||
vertical-align: middle; | ||
border-color: white; | ||
border-width: 5px; | ||
border-style: solid; | ||
} | ||
.arrow.up { | ||
border-left-color: transparent; | ||
border-right-color: transparent; | ||
border-top-style: none; | ||
} | ||
.arrow.down { | ||
border-left-color: transparent; | ||
border-right-color: transparent; | ||
border-bottom-style: none; | ||
} | ||
.arrow.right { | ||
border-top-color: transparent; | ||
border-bottom-color: transparent; | ||
border-right-style: none; | ||
} | ||
.arrow.left { | ||
border-top-color: transparent; | ||
border-bottom-color: transparent; | ||
border-left-style: none; | ||
} | ||
label.err { | ||
color: red; | ||
display: block; | ||
margin: 0; | ||
width: auto; | ||
} | ||
em { | ||
display: block; | ||
margin: 5px 0 0px 180px; | ||
font-style: inherit; | ||
} | ||
.welcome{ | ||
line-height: 50px; | ||
padding-left:30px; | ||
color: #555555; | ||
} |
Oops, something went wrong.