Merge branch 'master' into marijn-nietslecht

This commit is contained in:
Marijn Jansen
2017-01-27 11:23:42 +01:00
15 changed files with 564 additions and 138 deletions

View File

@@ -4,12 +4,14 @@ function placeFriendButtons() {
friendshipStatus = data;
$buttonContainer = $("div.friend-button-container");
$buttonContainer.children().remove();
$("#start-profile-chat-form").hide();
if (friendshipStatus == -1) {
return;
} else if(friendshipStatus == 0) {
$buttonContainer.append($("<button class=\"green friend-button\" value=\"request\"><i class=\"fa fa-handshake-o\"></i> Bevriend</button>"));
} else if(friendshipStatus == 1) {
$buttonContainer.append($("<button class=\"red friend-button\" value=\"delete\"><i class=\"fa fa-times\"></i> Verwijder</button>"));
$("#start-profile-chat-form").show();
} else if(friendshipStatus == 2) {
$buttonContainer.append($("<button class=\"red friend-button\" value=\"delete\"><i class=\"fa fa-times\"></i> Trek verzoek in</button>"));
} else if(friendshipStatus == 3) {

View File

@@ -19,16 +19,24 @@
</script>";
}
// define variables and set to empty values
$name = $surname = $bday = $username = $password = $confirmpassword = $location = $housenumber = $email = $confirmEmail = $captcha = $ip = "";
$genericErr = $nameErr = $surnameErr = $bdayErr = $usernameErr = $passwordErr = $confirmpasswordErr = $locationErr = $housenumberErr = $emailErr = $confirmEmailErr = $captchaErr = "";
$correct = true;
$day_date = "dag";
$month_date = "maand";
$year_date = "jaar";
// Define variables and set to empty values
$uname = $psw ="";
$user = $psw ="";
$loginErr = $resetErr ="";
if ($_SERVER["REQUEST_METHOD"] == "POST") {
switch ($_POST["submit"]) {
case "login":
try {
$uname = ($_POST["uname"]);
validateLogin($_POST["uname"], $_POST["psw"]);
$user = ($_POST["user"]);
validateLogin($_POST["user"], $_POST["psw"]);
} catch(loginException $e) {
$loginErr = $e->getMessage();
}
@@ -46,7 +54,96 @@
</script>";
}
break;
case "register":
try {
$name = test_input(($_POST["name"]));
checkInputChoice($name, "lettersAndSpaces");
} catch(lettersAndSpacesException $e){
$correct = false;
$nameErr = $e->getMessage();
}
try {
$surname = test_input(($_POST["surname"]));
checkInputChoice($surname, "lettersAndSpaces");
}
catch(lettersAndSpacesException $e){
$correct = false;
$surnameErr = $e->getMessage();
}
try{
$day_date = test_input(($_POST["day_date"]));
$month_date = test_input(($_POST["month_date"]));
$year_date = test_input(($_POST["year_date"]));
$bday = $year_date . "-" . $month_date . "-" . $day_date;
checkInputChoice($bday, "bday");
} catch(bdayException $e){
$correct = false;
$bdayErr = $e->getMessage();
}
try{
$username = str_replace(' ', '', test_input(($_POST["username"])));
checkInputChoice($username, "username");
} catch(usernameException $e){
$correct = false;
$usernameErr = $e->getMessage();
}
try{
$password = str_replace(' ', '', test_input(($_POST["password"])));
checkInputChoice($password, "longerEight");
matchPassword();
} catch(passwordException $e){
$correct = false;
$passwordErr = $e->getMessage();
} catch(confirmPasswordException $e){
$correct = false;
$confirmPasswordErr = $e->getMessage();
}
try{
$location = test_input(($_POST["location"]));
checkInputChoice($location, "lettersAndSpaces");
} catch(lettersAndSpacesException $e){
$correct = false;
$locationErr = $e->getMessage();
}
try{
$email = test_input(($_POST["email"]));
checkInputChoice($email, "email");
$confirmEmail = test_input(($_POST["confirmEmail"]));
matchEmail();
} catch(emailException $e){
$correct = false;
$emailErr = $e->getMessage();
} catch(confirmEmailException $e){
$correct = false;
$confirmEmailErr = $e->getMessage();
}
try{
$captcha = $_POST['g-recaptcha-response'];
checkCaptcha($captcha);
} catch(captchaException $e){
$correct = false;
$captchaErr = $e->getMessage();
}
try {
getIp();
registerCheck($correct);
sendConfirmEmailUsername($username);
} catch(registerException $e){
echo "<script>
window.onload = function() {
$('#registerModal').show();
}
</script>";
$genericErr = $e->getMessage();
}
}
}
// // Trying to login

View File

@@ -14,9 +14,12 @@
header("location: login.php");
}
// define variables and set to empty values
$name = $surname = $bday = $username = $password = $confirmpassword = $location = $housenumber = $email = $captcha = $ip = "";
$genericErr = $nameErr = $surnameErr = $bdayErr = $usernameErr = $passwordErr = $confirmpasswordErr = $locationErr = $housenumberErr = $emailErr = $captchaErr = "";
$name = $surname = $bday = $username = $password = $confirmpassword = $location = $housenumber = $email = $confirmEmail = $captcha = $ip = "";
$genericErr = $nameErr = $surnameErr = $bdayErr = $usernameErr = $passwordErr = $confirmpasswordErr = $locationErr = $housenumberErr = $emailErr = $confirmEmailErr = $captchaErr = "";
$correct = true;
$day_date = "dag";
$month_date = "maand";
$year_date = "jaar";
// Trying to register an account
if ($_SERVER["REQUEST_METHOD"] == "POST") {
@@ -38,7 +41,10 @@
}
try{
$bday = test_input(($_POST["bday"]));
$day_date = test_input(($_POST["day_date"]));
$month_date = test_input(($_POST["month_date"]));
$year_date = test_input(($_POST["year_date"]));
$bday = $year_date . "-" . $month_date . "-" . $day_date;
checkInputChoice($bday, "bday");
} catch(bdayException $e){
$correct = false;
@@ -76,9 +82,14 @@
try{
$email = test_input(($_POST["email"]));
checkInputChoice($email, "email");
$confirmEmail = test_input(($_POST["confirmEmail"]));
matchEmail();
} catch(emailException $e){
$correct = false;
$emailErr = $e->getMessage();
} catch(confirmEmailException $e){
$correct = false;
$confirmEmailErr = $e->getMessage();
}
try{

View File

@@ -28,10 +28,12 @@ body {
form {
/*background-color: #a87a87;*/
border-radius: 12px;
height: 85%;
height: 80%;
margin: auto;
width: 80%;
width: 600px;
overflow-y:auto;
overflow-x: hidden;
}
@@ -130,7 +132,11 @@ label {
margin: 34px auto;
overflow-y: auto;
padding: 20px;
width: 45%;
width: 600px;
}
select{
width: 18%;
}
ul {
@@ -160,7 +166,7 @@ ul {
margin: auto;
padding: 0;
border: 1px solid #888;
width: 500px;
width: 589px;
box-shadow: 0 4px 8px 0 rgba(0,0,0,0.2),0 6px 20px 0 rgba(0,0,0,0.19);
-webkit-animation-name: animatetop;
-webkit-animation-duration: 0.4s;
@@ -200,10 +206,11 @@ ul {
color: black;
}
.modal-body {padding: 2px 16px;}
.modal-body {
padding: 2px 16px;
}
.modal-footer {
padding: 2px 16px;
background-color: #FBC02D;
color: black;
}

View File

@@ -275,3 +275,16 @@ div[data-title]:hover:after {
display: inline-block;
vertical-align: middle;
}
::-webkit-scrollbar {
width: 5px;
height: 5px;
}
::-webkit-scrollbar-track {
background: none;
}
::-webkit-scrollbar-thumb {
-webkit-border-radius: 20px;
border-radius: 20px;
background: #4CAF50;
}

View File

@@ -30,6 +30,7 @@ div.posts div.post {
width: calc(100% - 40px);
cursor: pointer;
transition-duration: 250ms;
word-wrap: break-word;
}
div.posts div.post:hover {

View File

@@ -38,7 +38,6 @@ function checkName($variable){
if (empty($variable)) {
throw new lettersAndSpacesException("Verplicht!");
} else if (!preg_match("/^[a-zA-Z ]*$/", $variable)) {
throw new lettersAndSpacesException("Alleen letters en spaties zijn toegestaan!");
}
}
@@ -48,12 +47,12 @@ function validateBday($variable){
if (empty($variable)) {
throw new bdayException("Verplicht!");
} else {
if (!(validateDate($variable, "Y/m/d"))) {
if (!(validateDate($variable, "Y-m-d"))) {
throw new bdayException("Geen geldige datum");
} else {
$dateNow = date("Y/m/d");
$dateNow = date("Y-m-d");
if ($dateNow < $variable) {
throw new bdayException("Geen geldige datum");
throw new bdayException("Geen geldige datum!");
}
}
}
@@ -97,6 +96,12 @@ function validateEmail($variable){
}
}
function matchEmail(){
if (strtolower($_POST["email"]) != strtolower($_POST["confirmEmail"])){
throw new confirmEmailException("Emails matchen niet!");
}
}
/* checks if an input is a valid email. */
function resetEmail($variable){
if (empty($variable)) {
@@ -206,6 +211,14 @@ class emailException extends Exception
}
}
class confirmEmailException extends Exception
{
public function __construct($message = "", $code = 0, Exception $previous = null)
{
parent::__construct($message, $code, $previous);
}
}
class captchaException extends Exception
{
public function __construct($message = "", $code = 0, Exception $previous = null)

View File

@@ -9,10 +9,11 @@ function getUser() {
FROM
`user`
WHERE
`username` LIKE :username
`username` LIKE :username OR
`email` LIKE :username
");
$stmt->bindParam(":username", $_POST["uname"]);
$stmt->bindParam(":username", test_input($_POST["user"]));
$stmt->execute();
return $stmt->fetch(PDO::FETCH_ASSOC);
}
@@ -20,7 +21,7 @@ function getUser() {
function validateLogin($username, $password){
// Empty username or password field
if (empty($username) || empty($password)) {
throw new loginException("Gebruikersnaam of wachtwoord is niet ingevuld");
throw new loginException("Inloggegevens zijn niet ingevuld");
}
else {
$psw = test_input($password);

View File

@@ -1,8 +1,9 @@
<?php
function getOldChatMessages($user2ID) {
require_once ("friendship.php");
$user1ID = $_SESSION["userID"];
if (getFriendshipStatus($user2ID) == 1) {
$stmt = $GLOBALS["db"]->prepare("
SELECT
*
@@ -23,9 +24,14 @@ function getOldChatMessages($user2ID) {
$stmt->execute();
return json_encode($stmt->fetchAll());
} else {
return "[]";
}
}
function sendMessage($destination, $content) {
require_once("friendship.php");
if (getFriendshipStatus($destination) == 1) {
$stmt = $GLOBALS["db"]->prepare("
INSERT INTO
`private_message`
@@ -47,9 +53,14 @@ function sendMessage($destination, $content) {
"destination" => $destination,
"content" => $content
));
} else {
return false;
}
}
function getNewChatMessages($lastID, $destination) {
require_once("friendship.php");
if (getFriendshipStatus($destination) == 1) {
$stmt = $GLOBALS["db"]->prepare("
SELECT
*
@@ -73,19 +84,22 @@ function getNewChatMessages($lastID, $destination) {
$stmt->execute();
return json_encode($stmt->fetchAll());
} else {
return "[]";
}
}
function selectAllUnreadChat() {
$stmt = $GLOBALS["db"]->prepare("
SELECT
LEFT(CONCAT(`user`.`fname`, ' ', `user`.`lname`), 15) as `fullname`,
LEFT(CONCAT(`user`.`fname`, ' ', `user`.`lname`), 15) AS `fullname`,
`user`.`userID`,
IFNULL(
`profilepicture`,
'../img/avatar-standard.png'
) AS profilepicture,
LEFT(`private_message`.`content`, 15) as `content`
LEFT(`private_message`.`content`, 15) AS `content`
FROM
`private_message`,
`friendship`,
@@ -101,7 +115,8 @@ function selectAllUnreadChat() {
`friendship`.chatLastVisted2 IS NULL)) AND
`private_message`.`origin` = `user`.`userID` AND
`private_message`.`destination` = :userID AND
`user`.`role` != 'banned'
`user`.`role` != 'banned' AND
`friendship`.`status` = 'confirmed'
GROUP BY `user`.`userID`

View File

@@ -10,7 +10,7 @@ function getExistingUsername() {
`username` LIKE :username
");
$stmt->bindParam(":username", $_POST["username"]);
$stmt->bindParam(":username", test_input($_POST["username"]));
$stmt->execute();
return $stmt->rowCount();
@@ -26,7 +26,7 @@ function getExistingEmail() {
`email` LIKE :email
");
$stmt->bindParam(":email", $_POST["email"]);
$stmt->bindParam(":email", test_input($_POST["email"]));
$stmt->execute();
return $stmt->rowCount();
@@ -42,7 +42,7 @@ function getResetEmail() {
`email` LIKE :email
");
$stmt->bindParam(":email", $_POST["forgotEmail"]);
$stmt->bindParam(":email", test_input($_POST["forgotEmail"]));
$stmt->execute();
return $stmt->rowCount();
@@ -70,15 +70,21 @@ function registerAccount() {
$hash=password_hash($_POST["password"], PASSWORD_DEFAULT);
$stmt->bindParam(":fname", $_POST["name"]);
$stmt->bindParam(":lname", $_POST["surname"]);
$stmt->bindParam(":bday", $_POST["bday"]);
$stmt->bindParam(":username", $_POST["username"]);
$stmt->bindParam(":password", $hash);
$stmt->bindParam(":location", $_POST["location"]);
$stmt->bindParam(":email", (strtolower($_POST["email"])));
$stmt->bindParam(":fname", test_input($_POST["name"]));
$stmt->bindParam(":lname", test_input($_POST["surname"]));
$stmt->bindParam(":bday", test_input($_POST["bday"]));
$stmt->bindParam(":username", test_input($_POST["username"]));
$stmt->bindParam(":password", test_input($hash));
$stmt->bindParam(":location", test_input($_POST["location"]));
$stmt->bindParam(":email", test_input(strtolower($_POST["email"])));
$stmt->execute();
$stmt->rowCount();
}
function submitselect($date, $value){
if ($date == $value){
echo "selected";
}
}
?>

View File

@@ -35,6 +35,7 @@ function getUsername($userID) {
function selectUser($me, $other) {
$stmt = $GLOBALS["db"]->prepare("
SELECT
`userID`,
`username`,
`birthdate`,
`location`,
@@ -94,7 +95,7 @@ function selectAllUserGroups($userID) {
`group_page`.`groupID` = `group_member`.`groupID`
WHERE
`userID` = :userID AND
`role` = 1
`role` = 'member'
");
$stmt->bindParam(':userID', $userID, PDO::PARAM_INT);
@@ -331,9 +332,10 @@ function searchSomeUsers($n, $m, $search) {
FROM
`user`
WHERE
`username` LIKE :keyword OR
(`username` LIKE :keyword OR
`fname` LIKE :keyword OR
`lname` LIKE :keyword
`lname` LIKE :keyword) AND
`role` != 'banned'
ORDER BY
`fname`,
`lname`,

View File

@@ -74,6 +74,7 @@
name="content"
id="newContent"
placeholder="Schrijf een bericht..."
autocomplete="off"
autofocus
required
/>

View File

@@ -13,12 +13,12 @@
<!-- Login name -->
<div class="login_containerlogin">
<label><b>Gebruikersnaam</b></label>
<label><b>Gebruikersnaam/Email</b></label>
<input type="text"
placeholder="Voer uw gebruikersnaam in"
name="uname"
value="<?php echo $uname ?>"
title="Moet 6 of meer karakters bevatten"
placeholder="Voer uw gebruikersnaam/email in"
name="user"
value="<?php echo $user ?>"
title="Moet een geldige gebruiker zijn"
>
</div>
@@ -86,31 +86,232 @@
</form>
</div>
</div>
<script>
// Get the modal
var modal = document.getElementById('myModal');
<!-- Trigger/Open The Modal -->
<button id="registerBtn" class="button">Registreer een account</button>
<!-- The Modal -->
<div id="registerModal" class="modal">
<form action="<?php echo htmlspecialchars($_SERVER["PHP_SELF"]);?>"
return= $correct
method="post"
name="forgotPassword">
<!-- Modal content -->
<div class="modal-content">
<div class="modal-header">
<span class="close">&times;</span>
<h3>Registreer uw account</h3>
</div>
<div class="modal-body">
<form action="<?php echo htmlspecialchars($_SERVER["PHP_SELF"]);?>"
return= $correct
method="post">
<!-- Error message -->
<div class="login_containerfault"><?php echo $genericErr;?></span></div>
<!-- Register name -->
<div class="login_containerregister">
<label><b>Naam</b></label>
<input type="text"
placeholder="Voer uw naam in"
name="name"
value="<?php echo $name ?>"
title="Mag alleen letters bevatten"
>
*<span class="error"><?php echo $nameErr;?></span>
</div>
<!-- Register surname -->
<div class="login_containerregister">
<label><b>Achternaam</b></label>
<input type="text"
placeholder="Voer uw achternaam in"
name="surname"
value="<?php echo $surname ?>"
title="Mag alleen letters bevatten"
>
*<span class="error"> <?php echo $surnameErr;?></span>
</div>
<!-- Register birthday -->
<div class="login_containerregister">
<label><b>Geboortedatum</b></label>
<!-- <input type="date"-->
<!-- name="bday"-->
<!-- value="--><?php //echo $bday ?><!--"-->
<!-- id="bday"-->
<!-- placeholder="1996/01/01"-->
<!-- data-fv-date-max=""-->
<!-- data-date="" data-date-format="DD MMMM YYYY"-->
<!-- >-->
<select name="day_date" >
<option>dag</option>
<?php
for($i=1; $i<32; $i++) {
$i = sprintf("%02d", $i);
?>
<option value="<?= $i ?>" <?php submitselect($day_date, $i)?>><?= $i ?></option>
<?php
}
?>
</select>
<select name="month_date">
<option>Maand</option>
<option value="01" <?php submitselect($month_date, "01")?>>Januari</option>
<option value="02" <?php submitselect($month_date, "02")?>>Februari</option>
<option value="03" <?php submitselect($month_date, "03")?>>Maart</option>
<option value="04" <?php submitselect($month_date, "04")?>>April</option>
<option value="05" <?php submitselect($month_date, "05")?>>Mei</option>
<option value="06" <?php submitselect($month_date, "06")?>>Juni</option>
<option value="07" <?php submitselect($month_date, "07")?>>Juli</option>
<option value="08" <?php submitselect($month_date, "08")?>>Augustus</option>
<option value="09" <?php submitselect($month_date, "09")?>>September</option>
<option value="10" <?php submitselect($month_date, "10")?>>Oktober</option>
<option value="11" <?php submitselect($month_date, "11")?>>November</option>
<option value="12" <?php submitselect($month_date, "12")?>>December</option>
</select>
<select name="year_date">
<option>Jaar</option>
<?php
$year = (new DateTime)->format("Y");
for($i=$year; $i > $year - 100; $i--) {
?>
<option value="<?= $i ?>" <?php submitselect($year_date, $i)?>><?= $i ?></option>
<?php
}
?>
</select>
*<span class="error"> <?php echo $bdayErr;?></span>
</div>
<!-- Register username -->
<div class="login_containerregister">
<label><b>Gebruikersnaam</b></label>
<input type="text"
placeholder="Voer uw gebruikersnaam in"
name="username"
value="<?php echo $username ?>"
title="Moet minimaal 6 karakters bevatten"
>
*<span class="error"> <?php echo $usernameErr;?></span>
<ul>
<li>Minstens 6 karakters</li>
</ul>
</div>
<!-- Register password -->
<div class="login_containerregister">
<label><b>Wachtwoord</b></label>
<input type="password"
placeholder="Voer uw wachtwoord in"
name="password"
value="<?php echo $password ?>"
id="password"
>
*<span class="error"> <?php echo $passwordErr;?></span>
<ul>
<li>Minstens 8 karakters</li>
</ul>
</div>
<!-- Repeat password -->
<div class="login_containerregister">
<label><b>Herhaal wachtwoord</b></label>
<input type="password"
placeholder="Herhaal wachtwoord"
name="confirmpassword"
value="<?php echo $confirmpassword ?>"
id="confirmpassword"
title="Herhaal wachtwoord"
>
*<span class="error"> <?php echo $confirmpasswordErr;?></span>
</div>
<!-- Register location -->
<div class="login_containerregister">
<label><b>Locatie</b></label>
<input type="text"
placeholder="Voer uw woonplaats in"
name="location"
value="<?php echo $location ?>"
pattern="[A-Za-z]{1,}"
title="Mag alleen letters bevatten">
*<span class="error"> <?php echo $locationErr;?></span>
</div>
<!-- Register email -->
<div class="login_containerregister">
<label><b>Email</b></label>
<input type="text"
placeholder="Voer uw email in"
name="email"
value="<?php echo $email ?>"
id="email"
title="Voer een geldige email in">
*<span class="error"> <?php echo $emailErr;?></span>
</div>
<!-- Register email -->
<div class="login_containerregister">
<label><b>Herhaal email</b></label>
<input type="text"
placeholder="Herhaal uw email"
name="confirmEmail"
value="<?php echo $confirmEmail ?>"
id="email"
title="Herhaal uw email">
*<span class="error"> <?php echo $confirmEmailErr;?></span>
</div>
<div class="login_containerregister">
<div class="g-recaptcha" data-sitekey="6Lc72xIUAAAAADumlWetgENm7NGd9Npyo0c_tYYQ"></div>
<span class="error"> <?php echo $captchaErr;?></span>
</div>
</div>
<div class="modal-footer">
<div class="login_containerfault"><span><?php echo $resetErr; ?></span></div>
<button type="submit"
value="register"
name="submit"
id="frm1_submit">
Registreer
</button>
</div>
</div>
</form>
</div>
</div>
<script>
// Get the button that opens the modal
var modal = document.getElementById('myModal');
var btn = document.getElementById("myBtn");
// Get the modal
var registerModal = document.getElementById('registerModal');
var registerBtn = document.getElementById("registerBtn");
// Get the <span> element that closes the modal
var span = document.getElementsByClassName("close")[0];
var registerSpan = document.getElementsByClassName("close")[1];
// When the user clicks the button, open the modal
btn.onclick = function() {
modal.style.display = "block";
}
registerBtn.onclick = function() {
registerModal.style.display = "block";
}
// When the user clicks on <span> (x), close the modal
span.onclick = function() {
modal.style.display = "none";
}
// When the user clicks anywhere outside of the modal, close it
window.onclick = function(event) {
if (event.target == modal) {
modal.style.display = "none";
}
registerSpan.onclick = function() {
registerModal.style.display = "none";
}
</script>

View File

@@ -1,7 +1,13 @@
<div class="content">
<div class="profile-box platform">
<img class="left profile-picture" src="<?php echo $user["profilepicture"] ?>">
<form id="start-profile-chat-form" class="right" action="chat.php" method="get">
<button name="username"
class="friend-button green"
value="<?php echo $user["userID"] ?>">
<i class="fa fa-comment-o"></i> Chat
</button>
</form>
<div class="friend-button-container">
</div>

View File

@@ -40,14 +40,52 @@
<!-- Register birthday -->
<div class="login_containerregister">
<label><b>Geboortedatum</b></label>
<input type="text"
name="bday"
value="<?php echo $bday ?>"
id="bday"
placeholder="1996/01/01"
data-fv-date-max=""
>
<label><b>Geboortedatum(Dag/Maand/Jaar)</b></label>
<!-- <input type="date"-->
<!-- name="bday"-->
<!-- value="--><?php //echo $bday ?><!--"-->
<!-- id="bday"-->
<!-- placeholder="1996/01/01"-->
<!-- data-fv-date-max=""-->
<!-- data-date="" data-date-format="DD MMMM YYYY"-->
<!-- >-->
<select name="day_date" >
<option>dag</option>
<?php
for($i=1; $i<32; $i++) {
$i = sprintf("%02d", $i);
?>
<option value="<?= $i ?>" <?php submitselect($day_date, $i)?>><?= $i ?></option>
<?php
}
?>
</select>
<select name="month_date">
<option>Maand</option>
<option value="01" <?php submitselect($month_date, "01")?>>Januari</option>
<option value="02" <?php submitselect($month_date, "02")?>>Februari</option>
<option value="03" <?php submitselect($month_date, "03")?>>Maart</option>
<option value="04" <?php submitselect($month_date, "04")?>>April</option>
<option value="05" <?php submitselect($month_date, "05")?>>Mei</option>
<option value="06" <?php submitselect($month_date, "06")?>>Juni</option>
<option value="07" <?php submitselect($month_date, "07")?>>Juli</option>
<option value="08" <?php submitselect($month_date, "08")?>>Augustus</option>
<option value="09" <?php submitselect($month_date, "09")?>>September</option>
<option value="10" <?php submitselect($month_date, "10")?>>Oktober</option>
<option value="11" <?php submitselect($month_date, "11")?>>November</option>
<option value="12" <?php submitselect($month_date, "12")?>>December</option>
</select>
<select name="year_date">
<option>Jaar</option>
<?php
$year = (new DateTime)->format("Y");
for($i=$year; $i > $year - 100; $i--) {
?>
<option value="<?= $i ?>" <?php submitselect($year_date, $i)?>><?= $i ?></option>
<?php
}
?>
</select>
*<span class="error"> <?php echo $bdayErr;?></span>
</div>
@@ -118,6 +156,18 @@
*<span class="error"> <?php echo $emailErr;?></span>
</div>
<!-- Register email -->
<div class="login_containerregister">
<label><b>Herhaal email</b></label>
<input type="text"
placeholder="Herhaal uw email"
name="confirmEmail"
value="<?php echo $confirmEmail ?>"
id="email"
title="Herhaal uw email">
*<span class="error"> <?php echo $confirmEmailErr;?></span>
</div>
<div class="login_containerregister">
<div class="g-recaptcha" data-sitekey="6Lc72xIUAAAAADumlWetgENm7NGd9Npyo0c_tYYQ"></div>
<span class="error"> <?php echo $captchaErr;?></span>