Initial commit
This commit is contained in:
17
login/interfaces/instruct.css
Normal file
17
login/interfaces/instruct.css
Normal file
@@ -0,0 +1,17 @@
|
||||
#area{
|
||||
position: absolute;
|
||||
text-align: center;
|
||||
width: 300px;
|
||||
left: 0;
|
||||
top: 0;
|
||||
right: 0;
|
||||
bottom: 0;
|
||||
margin: auto;
|
||||
user-select: none;
|
||||
font-family: Arial, Helvetica, sans-serif;
|
||||
}
|
||||
img{
|
||||
width: 45%;
|
||||
height: 45%;
|
||||
margin: none;
|
||||
}
|
||||
16
login/interfaces/login_admin.php
Normal file
16
login/interfaces/login_admin.php
Normal file
@@ -0,0 +1,16 @@
|
||||
<html>
|
||||
<head>
|
||||
<title>Admin</title>
|
||||
<link rel="stylesheet" href="./profile.css" type="text/css" />
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<div id="area">
|
||||
<img src="../../icon/admin.svg">
|
||||
<h2 style="margin: none;"><?php session_start(); echo $_SESSION['username']; ?></h2>
|
||||
<p>User Type: Administrator</p>
|
||||
<a href="../logout.php" style="text-decoration: none; color: white; background-color: rgba(69, 67, 67, 0.6);
|
||||
border-radius: 5px; align-items: center; left: 50%;">Log out</a>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
30
login/interfaces/login_buyer.php
Normal file
30
login/interfaces/login_buyer.php
Normal file
@@ -0,0 +1,30 @@
|
||||
<html>
|
||||
<head>
|
||||
<title>User</title>
|
||||
<link rel="stylesheet" href="./profile.css" type="text/css" />
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<div id="area">
|
||||
<img src="../../icon/buyer.svg">
|
||||
<h2 style="margin: none;">
|
||||
<?php
|
||||
include '../../indexes/ConnectDB.php';
|
||||
session_start();
|
||||
echo $_SESSION['username'];
|
||||
?>
|
||||
</h2>
|
||||
<p>User Type: Buyer</p>
|
||||
<?php
|
||||
$sql = "SELECT money FROM buyer WHERE name='" . $_SESSION['username'] . "'";
|
||||
$res = mysqli_query($conn, $sql);
|
||||
$money = mysqli_fetch_array($res);
|
||||
?>
|
||||
<p>Balance: ¥<?php echo $money['money']; ?></p>
|
||||
<a href="../../indexes/process/receipt.php" style="text-decoration: none; color: white; background-color: rgba(69, 67, 67, 0.6);
|
||||
border-top-left-radius: 5px; border-bottom-left-radius: 5px;">My Receipt</a>
|
||||
<a href="../logout.php" style="text-decoration: none; color: white; background-color: rgba(69, 67, 67, 0.6);
|
||||
border-top-right-radius: 5px; border-bottom-right-radius: 5px;">Log out</a>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
18
login/interfaces/login_failed.php
Normal file
18
login/interfaces/login_failed.php
Normal file
@@ -0,0 +1,18 @@
|
||||
<html>
|
||||
<head>
|
||||
<title>Error Occurred</title>
|
||||
<link rel="stylesheet" href="./instruct.css" type="text/css" />
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<div id="area">
|
||||
<img src="../../icon/close.svg">
|
||||
<h2 style="margin: none; padding: none;">Oops!</h2>
|
||||
<h2>Your Username or Password is incorrect!</h2>
|
||||
<a href='../../login.html' style="text-decoration: none;">Try again</a>
|
||||
<script type='text/javascript'>
|
||||
setTimeout(function() {window.location.href = '../login.html';}, 1500);
|
||||
</script>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
31
login/interfaces/login_seller.php
Normal file
31
login/interfaces/login_seller.php
Normal file
@@ -0,0 +1,31 @@
|
||||
<html>
|
||||
<head>
|
||||
<title>Seller</title>
|
||||
<link rel="stylesheet" href="./profile.css" type="text/css" />
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<div id="area">
|
||||
<img src="../../icon/seller.svg">
|
||||
<h2 style="margin: none;">
|
||||
<?php
|
||||
include '../../indexes/ConnectDB.php';
|
||||
session_start();
|
||||
echo $_SESSION['username'];
|
||||
?>
|
||||
</h2>
|
||||
<p>User Type: Seller</p>
|
||||
<?php
|
||||
$sql = "SELECT profit FROM seller WHERE name='" . $_SESSION['username'] . "'";
|
||||
$res = mysqli_query($conn, $sql);
|
||||
$money = mysqli_fetch_array($res);
|
||||
?>
|
||||
<p>Profit: ¥<?php echo $money['profit']; ?></p>
|
||||
<a href="../../indexes/process/receipt.php" style="text-decoration: none; color: white; background-color: rgba(69, 67, 67, 0.6);
|
||||
border-top-left-radius: 5px; border-bottom-left-radius: 5px;">My Receipt</a>
|
||||
<a href="../logout.php" style="text-decoration: none; color: white; background-color: rgba(69, 67, 67, 0.6);
|
||||
border-top-right-radius: 5px; border-bottom-right-radius: 5px;">Log out</a>
|
||||
</div>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
16
login/interfaces/login_success.php
Normal file
16
login/interfaces/login_success.php
Normal file
@@ -0,0 +1,16 @@
|
||||
<html>
|
||||
<head>
|
||||
<title>Success</title>
|
||||
<link rel="stylesheet" href="./instruct.css" type="text/css" />
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<div id="area">
|
||||
<img src="../../icon/check.svg">
|
||||
<h1>Welcome, <?php include '../../indexes/ConnectDB.php'; session_start(); echo $_SESSION['username']; ?>!</h1>
|
||||
<script type='text/javascript'>
|
||||
setTimeout(function() {window.top.location.href = '../../home.php';}, 1000);
|
||||
</script>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
34
login/interfaces/profile.css
Normal file
34
login/interfaces/profile.css
Normal file
@@ -0,0 +1,34 @@
|
||||
#area{
|
||||
position: absolute;
|
||||
text-align: center;
|
||||
width: 200px;
|
||||
left: 0;
|
||||
top: 0;
|
||||
right: 0;
|
||||
bottom: 0;
|
||||
margin: auto;
|
||||
user-select: none;
|
||||
font-family: Arial, Helvetica, sans-serif;
|
||||
}
|
||||
img{
|
||||
width: 100%;
|
||||
height: 100px;
|
||||
margin: none;
|
||||
margin-top: 10%;
|
||||
}
|
||||
a{
|
||||
display:table-cell;
|
||||
vertical-align: middle;
|
||||
border: 1px solid rgba(35, 34, 34, 0.6);
|
||||
width: 200px;
|
||||
height: 32px;
|
||||
line-height: 30px;
|
||||
text-align: center;
|
||||
font-family: Arial, Helvetica, sans-serif;
|
||||
box-shadow: 0px 0px 0px rgba(69, 67, 67, 0.6);
|
||||
transition: 0.3s;
|
||||
cursor: hand;
|
||||
}
|
||||
a:hover {
|
||||
box-shadow: 0px 0px 10px #424242;
|
||||
}
|
||||
18
login/interfaces/register_failed.php
Normal file
18
login/interfaces/register_failed.php
Normal file
@@ -0,0 +1,18 @@
|
||||
<html>
|
||||
<head>
|
||||
<title>Error Occurred</title>
|
||||
<link rel="stylesheet" href="./instruct.css" type="text/css" />
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<div id="area">
|
||||
<img src="../../icon/close.svg">
|
||||
<h2 style="margin: none; padding: none;">Oops!</h2>
|
||||
<h2>your username seems has already been registered.</h2>
|
||||
<a href='../../login.html' style="text-decoration: none;">Try again</a>
|
||||
<script type='text/javascript'>
|
||||
setTimeout(function() {window.location.href = '../register.html';}, 1500);
|
||||
</script>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
18
login/interfaces/register_interrupted.php
Normal file
18
login/interfaces/register_interrupted.php
Normal file
@@ -0,0 +1,18 @@
|
||||
<html>
|
||||
<head>
|
||||
<title>Error Occurred</title>
|
||||
<link rel="stylesheet" href="./instruct.css" type="text/css" />
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<div id="area">
|
||||
<img src="../../icon/close.svg">
|
||||
<h2 style="margin: none; padding: none;">Oops!</h2>
|
||||
<h2>Errors occurred during registeration, please try agian later.</h2>
|
||||
<a href='../../login.html' style="text-decoration: none;">Try again</a>
|
||||
<script type='text/javascript'>
|
||||
setTimeout(function() {window.location.href = '../register.html';}, 1500);
|
||||
</script>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
16
login/interfaces/register_success.php
Normal file
16
login/interfaces/register_success.php
Normal file
@@ -0,0 +1,16 @@
|
||||
<html>
|
||||
<head>
|
||||
<title>Success</title>
|
||||
<link rel="stylesheet" href="./instruct.css" type="text/css" />
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<div id="area">
|
||||
<img src="../../icon/check.svg">
|
||||
<h1>Successfully registered!</h1>
|
||||
<script type='text/javascript'>
|
||||
setTimeout(function() {window.location.href = '../login.html';}, 1000);
|
||||
</script>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
Reference in New Issue
Block a user