Skip to content
Snippets Groups Projects
Commit 01d6e7b4 authored by fildfreeze's avatar fildfreeze
Browse files
parents 9b425cbe 15b62abc
Branches
No related merge requests found
......@@ -134,10 +134,14 @@ body {
width: 47%;
}
.form-signup .form-group span {
.form-signup .form-group span i {
display: none;
}
.form-signup .form-group span i:nth-of-type(2) {
color: #B33A3A;
}
.form-signup input[type=checkbox] {
margin-top: 15px;
}
......
.mainHeader {
width: 500px;
height: 50px;
}
.header1 {
float: left;
}
.header2 {
float: right;
font-family: "Trebuchet MS";
}
.title {
font-family: "Hoefler Text";
font-size: 31px;
font-weight: bold;
color: black;
height: 27px;
}
.title.red {
color: #cb0a1d;
}
.title.green {
color : #066422;
}
.subtitle {
color: #4f9500;
font-size: 16px;
}
.username {
padding-top: 10px;
}
.username.bold {
font-weight: bold;
}
.logout {
text-align: right;
text-decoration: underline;
color: blue;
}
.menu{
margin: 10px;
width: 165px;
height: 45px;
display: table-cell;
border: 1px solid black;
text-align: center;
vertical-align: middle;
line-height: 45px;
font-family: "Trebuchet MS";
font-weight: bold;
font-size: 24px;
}
.menu:hover {
background-color: #3a563f;
color: white;
}
.menu.active {
background: #3a563f;
border: 1px solid #253828;
color: white;
}
.contentBox {
width: 550px;
height: 480px;
margin: 0 auto;
background: white;
}
h1 {
color: #494949;
font-size: 35px;
font-family: "Trebuchet MS";
margin-top: 10px;
margin-bottom: 15px;
}
.stepBox {
color: #414141;
display: inline-block;
border: 1px solid black;
width: 135px;
height: auto;
padding: 3px;
margin-right: 30px;
margin-bottom: 30px;
font-family: "Arial";
font-size: 15px;
}
.stepBox.active {
background: #ffff97;
}
.number {
width: 30px;
height: 30px;
border-radius: 50%;
font-size: 20px;
color: black;
line-height: 30px;
text-align: center;
background: #d1d1d1;
float: left;
margin: 5px;
margin-right: 8px;
}
.step {
margin: 2px;
}
.form {
width: 450px;
display: table;
margin-left: 10px;
}
.formBox {
width: 470px;
}
.labelBox {
float: left;
clear: left;
margin: 10px;
font-family: Arial;
color: #414141;
font-size: 20px;
}
.inputBox {
width: 250px;
height: 25px;
float: right;
clear: right;
margin: 2px;
font-size: 17px;
}
input[type=submit] {
display: table;
margin: 0 auto;
margin-top: 185px;
cursor: pointer;
width: 110px;
height: 50px;
border-radius: 10px;
border: 1px solid black;
background: #82d504;
font-size: 22px;
font-weight: bold;
font-family: Garamond;
}
\ No newline at end of file
......@@ -47,7 +47,7 @@
color: blue;
}
.menu {
.menu{
margin: 10px;
width: 165px;
height: 45px;
......@@ -61,6 +61,11 @@
font-size: 24px;
}
.menu:hover {
background-color: #3a563f;
color: white;
}
.menu.active {
background: #3a563f;
border: 1px solid #253828;
......
-- --------------------------------------------------------
-- Host: 127.0.0.1
-- Versi server: 10.1.26-MariaDB - mariadb.org binary distribution
-- OS Server: Win32
-- HeidiSQL Versi: 9.4.0.5125
-- --------------------------------------------------------
/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET NAMES utf8 */;
/*!50503 SET NAMES utf8mb4 */;
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
-- Pengeluaran data tidak dipilih.
-- Pengeluaran data tidak dipilih.
/*!40101 SET SQL_MODE=IFNULL(@OLD_SQL_MODE, '') */;
/*!40014 SET FOREIGN_KEY_CHECKS=IF(@OLD_FOREIGN_KEY_CHECKS IS NULL, 1, @OLD_FOREIGN_KEY_CHECKS) */;
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
......@@ -13,37 +13,54 @@ function getUsernameValidation(){
var response = xmlhttp.responseText;
console.log(response);
if(response === "true"){
document.getElementById("wrongUsername").style.display = "none";
document.getElementById("checkUsername").style.display = "block";
}
else {
document.getElementById("checkUsername").style.display = "none";
document.getElementById("wrongUsername").style.display = "block";
}
}
}
xmlhttp.send();
}
function validateEmail(email) {
var re = /^(([^<>()[\]\\.,;:\s@\"]+(\.[^<>()[\]\\.,;:\s@\"]+)*)|(\".+\"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/;
return re.test(email);
}
function getEmailValidation(){
var xmlhttp = new XMLHttpRequest();
if(!xmlhttp){
return;
}
var email = document.getElementById("email");
console.log(email);
var url = "validation.php?e=" + email.value;
console.log(url);
xmlhttp.open("GET", url, true);
xmlhttp.onreadystatechange = function(){
if (xmlhttp.readyState == 4 && xmlhttp.status == 200){
var response = xmlhttp.responseText;
console.log(response);
if(response === "true"){
document.getElementById("checkEmail").style.display = "block";
}
else {
document.getElementById("checkEmail").style.display = "none";
console.log(email.value);
console.log(validateEmail(email.value));
if (!validateEmail(email.value)){
document.getElementById("checkEmail").style.display = "none";
document.getElementById("wrongEmail").style.display = "block";
}
else {
var xmlhttp = new XMLHttpRequest();
if(!xmlhttp){
return;
}
console.log(email);
var url = "validation.php?e=" + email.value;
console.log(url);
xmlhttp.open("GET", url, true);
xmlhttp.onreadystatechange = function(){
if (xmlhttp.readyState == 4 && xmlhttp.status == 200){
var response = xmlhttp.responseText;
console.log(response);
if(response === "true"){
document.getElementById("wrongEmail").style.display = "none";
document.getElementById("checkEmail").style.display = "block";
}
else {
document.getElementById("checkEmail").style.display = "none";
document.getElementById("wrongEmail").style.display = "block";
}
}
}
}
xmlhttp.send();
xmlhttp.send();
}
}
\ No newline at end of file
......@@ -19,7 +19,7 @@
</div>
</div>
<div class="form-login">
<form action="login.php" method="POST">
<form action="auth.php" method="POST" autocomplete="off">
<div class="form-group">
<label for="username">Username </label>
<input id="username" type="text" name="username" placeholder="your username" required>
......
......@@ -2,7 +2,7 @@
<html>
<head>
<title>Make an order</title>
<link rel="stylesheet" type="text/css" href="order_ojek.css">
<link rel="stylesheet" type="text/css" href="css/orderojek.css">
</head>
<body>
<div class="contentBox">
......
......@@ -21,18 +21,18 @@
</div>
</div>
<div class="form-signup">
<form action="register.php" method="POST">
<form action="createuser.php" method="POST" autocomplete="off">
<div class="form-group">
<label for="name">Your Name</label>
<input id="name" type="text" name="name" placeholder="your name" required>
</div>
<div class="form-group">
<label for="username">Username</label>
<input id="username" type="text" name="username" placeholder="your username" onfocusout="getUsernameValidation()" required> <span id="checkUsername"><i class="material-icons">check_circle</i></span>
<input id="username" type="text" name="username" placeholder="your username" onfocusout="getUsernameValidation()" required> <span><i class="material-icons" id="checkUsername">check</i><i class="material-icons" id="wrongUsername">info</i></span>
</div>
<div class="form-group">
<label for="email">Email</label>
<input id="email" type="text" name="email" placeholder="your email" onfocusout="getEmailValidation()" required><span id="checkEmail"><i class="material-icons">check_circle</i></span>
<input id="email" type="text" name="email" placeholder="your email" onfocusout="getEmailValidation()" required><span><i class="material-icons" id="checkEmail">check</i><i class="material-icons" id="wrongEmail">info</i></span>
</div>
<div class="form-group">
<label for="password">Password</label>
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment