@ 2017-07-07T02:13:16Z <?php
if(!empty($_POST["register-user"])) {
/* Form Required Field Validation */
foreach($_POST as $key=>$value) {
if(empty($_POST[$key])) {
$error_message = "Todos los datos son obligatorios. All Fields are required";
break;
}
}
/* Password Matching Validation */
if($_POST['password'] != $_POST['confirm_password']){
$error_message = 'Las claves deben ser iguales. Passwords should be same<br>';
}
/* Email Validation */
if(!isset($error_message)) {
if (!filter_var($_POST["EMAIL"], FILTER_VALIDATE_EMAIL)) {
$error_message = "El email no es válido. Invalid Email Address";
}
}
/* Validation to check if gender is selected */
if(!isset($error_message)) {
if(!isset($_POST["GENERO"])) {
$error_message = " Todos los datos son obligatorios. All Fields are required";
}
}
/* Validation to check if Terms and Conditions are accepted */
if(!isset($error_message)) {
if(!isset($_POST["terms"])) {
$error_message = "Debe aceptar las condiciones del registro";
}
}
if(!isset($error_message)) {
require_once("dbcontroller.php");
$db_handle = new DBController();
$query = "INSERT INTO registered_users (CI, password, NOMBRE, APELLIDO, GENERO, FECHA-NACIMIENTO, DIRECCION, CP, CIUDAD, PAIS, CELULARA, CELULARB, EMAIL) VALUES
('" . $_POST["CI"] . "' , '" . $_POST["password"] . "' , '" . $_POST["NOMBRE"] . "' , '" . $_POST["APELLIDO"] . "' , '" . $_POST["GENERO"] . "' , ['" . $_POST["FECHA-NACIMIENTO"] . "' , '" . $_POST["DIRECCION"] . "' , '" . $_POST["CP"] . "' , '" . $_POST["CIUDAD"] . "' , '" . $_POST["PAIS"] . "' , '" . $_POST["CELULARA"] . "' , '" . $_POST["CELULARB"] . "' , '" . $_POST["EMAIL"] . "')";
$result = $db_handle->insertQuery($query);
if(!empty($result)) {
$error_message = "";
$success_message = "Felicitaciones. Has completado el registro correctamente. Congratulations. You have registered successfully!";
unset($_POST);
} else {
$error_message = "No se completado el registro. Vuelve a intentarlo. Problem in registration. Try Again!";
}
}
}
?>
<html>
<head>
<title>Registro de Socios</title>
<style>
body{
width:610px;
font-family:calibri;
}
.error-message {
padding: 7px 10px;
background: #fff1f2;
border: #ffd5da 1px solid;
color: #d6001c;
border-radius: 4px;
}
.success-message {
padding: 7px 10px;
background: #cae0c4;
border: #c3d0b5 1px solid;
color: #027506;
border-radius: 4px;
}
.demo-table {
background: #d9eeff;
width: 100%;
border-spacing: initial;
margin: 2px 0px;
word-break: break-word;
table-layout: auto;
line-height: 1.8em;
color: #333;
border-radius: 4px;
padding: 20px 40px;
}
.demo-table td {
padding: 15px 0px;
}
.demoInputBox {
padding: 10px 30px;
border: #a9a9a9 1px solid;
border-radius: 4px;
}
.btnRegister {
padding: 10px 30px;
background-color: #3367b2;
border: 0;
color: #FFF;
cursor: pointer;
border-radius: 4px;
margin-left: 10px;
}
</style>
</head>
<body>
<form name="frmRegistration" method="post" action="">
<table border="0" width="500" align="center" class="demo-table">
<?php if(!empty($success_message)) { ?>
<div class="success-message"><?php if(isset($success_message)) echo $success_message; ?></div>
<?php } ?>
<?php if(!empty($error_message)) { ?>
<div class="error-message"><?php if(isset($error_message)) echo $error_message; ?></div>
<?php } ?>
<tr>
<td colspan="2" align="center"><strong>Datos de Acceso</strong></td>
</tr>
<tr>
<td>CI</td>
<td><input type="text" class="demoInputBox" name="CI" value="<?php if(isset($_POST['CI'])) echo $_POST['CI']; ?>"></td>
</tr>
<tr>
<td>Password</td>
<td><input type="password" class="demoInputBox" name="password" value=""></td>
</tr>
<tr>
<td>Confirmar Password</td>
<td><input type="password" class="demoInputBox" name="confirm_password" value=""></td>
</tr>
<tr>
<td colspan="2" align="center"><strong>Datos Personales</strong></td>
</tr>
<tr>
<td>Nombre</td>
<td><input type="text" class="demoInputBox" name="NOMBRE" value="<?php if(isset($_POST['NOMBRE'])) echo $_POST['NOMBRE']; ?>"></td>
</tr>
<tr>
<td>Apellido</td>
<td><input type="text" class="demoInputBox" name="APELLIDO" value="<?php if(isset($_POST['APELLIDO'])) echo $_POST['APELLIDO']; ?>"></td>
</tr>
<tr>
<td>Género</td>
<td><input type="radio" name="GENERO" value="MASCULINO" <?php if(isset($_POST['GENERO']) && $_POST['GENERO']=="MASCULINO") { ?>checked<?php } ?>> MASCULINO
<input type="radio" name="GENERO" value="FEMENINO" <?php if(isset($_POST['GENERO']) && $_POST['GENERO']=="FEMENINO") { ?>checked<?php } ?>> FEMENINO
</td>
</tr>
<tr>
<td>Fecha de Nacimiento</td>
<td><input type="text" class="demoInputBox" name="FECHA-NACIMIENTO" value="<?php if(isset($_POST['FECHA-NACIMIENTO'])) echo $_POST['FECHA-NACIMIENTO']; ?>"></td>
</tr>
<tr>
<td colspan="2" align="center"><strong>Datos de Contacto</strong></td>
</tr>
<tr>
<td>Dirección</td>
<td><input type="text" class="demoInputBox" name="DIRECCION" value="<?php if(isset($_POST['DIRECCION'])) echo $_POST['DIRECCION']; ?>"></td>
</tr>
<tr>
<td>CP</td>
<td><input type="text" class="demoInputBox" name="CP" value="<?php if(isset($_POST['CP'])) echo $_POST['CP']; ?>"></td>
</tr>
<tr>
<td>Ciudad</td>
<td><input type="text" class="demoInputBox" name="CIUDAD" value="<?php if(isset($_POST['CIUDAD'])) echo $_POST['CIUDAD']; ?>"></td>
</tr>
<tr>
<td>País</td>
<td><input type="text" class="demoInputBox" name="PAIS" value="<?php if(isset($_POST['PAIS'])) echo $_POST['PAIS']; ?>"></td>
</tr>
<tr>
<td>Celular 1</td>
<td><input type="text" class="demoInputBox" name="CELULARA" value="<?php if(isset($_POST['CELULARA'])) echo $_POST['CELULARA']; ?>"></td>
</tr>
<tr>
<td>Celular 2</td>
<td><input type="text" class="demoInputBox" name="CELULARB" value="<?php if(isset($_POST['CELULARB'])) echo $_POST['CELULARB']; ?>"></td>
</tr>
<tr>
<td>Email</td>
<td><input type="text" class="demoInputBox" name="EMAIL" value="<?php if(isset($_POST['EMAIL'])) echo $_POST['EMAIL']; ?>"></td>
</tr>
<tr>
<td colspan="2" align="center"><strong>Datos de Afiliación</strong></td>
</tr>
<tr>
<td>Número de Socio</td>
<td> </td>
</tr>
<tr>
<td>Fecha de Ingreso</td>
<td> </td>
</tr>
<tr>
<td>Vencimiento de Membresía</td>
<td> </td>
</tr>
<tr>
<td>Categoría</td>
<td> </td>
</tr>
<tr>
<td>Estado de Afiliación</td>
<td> </td>
</tr>
<tr>
<td colspan=2>
<input type="checkbox" name="terms"> Al registrarme acepto las condiciones de afiliación al club <input type="submit" name="register-user" value="Registrarme" class="btnRegister"></td>
</tr>
</table>
</form>
</body></html>
Enable javascript to submit You have javascript disabled. You will not be able to edit any code.
Here you find the average performance (time & memory) of each version. A grayed out version indicates it didn't complete successfully (based on exit-code).
Version System time (s) User time (s) Memory (MiB) 8.3.6 0.007 0.011 16.74 8.3.5 0.012 0.003 16.23 8.3.4 0.009 0.006 18.83 8.3.3 0.007 0.007 18.67 8.3.2 0.000 0.008 20.09 8.3.1 0.003 0.005 21.85 8.3.0 0.006 0.003 17.66 8.2.18 0.011 0.011 16.85 8.2.17 0.006 0.009 22.96 8.2.16 0.009 0.006 20.34 8.2.15 0.008 0.000 24.18 8.2.14 0.000 0.008 24.66 8.2.13 0.006 0.003 22.15 8.2.12 0.004 0.004 26.35 8.2.11 0.005 0.005 21.13 8.2.10 0.004 0.008 18.03 8.2.9 0.006 0.003 19.34 8.2.8 0.008 0.000 18.16 8.2.7 0.000 0.008 17.63 8.2.6 0.008 0.000 17.93 8.2.5 0.006 0.003 18.10 8.2.4 0.000 0.009 22.33 8.2.3 0.003 0.006 21.05 8.2.2 0.005 0.002 18.21 8.2.1 0.000 0.007 17.97 8.2.0 0.002 0.005 18.09 8.1.28 0.010 0.010 25.92 8.1.27 0.005 0.003 23.96 8.1.26 0.004 0.004 26.35 8.1.25 0.005 0.003 28.09 8.1.24 0.003 0.006 21.15 8.1.23 0.008 0.004 17.64 8.1.22 0.004 0.004 17.78 8.1.21 0.008 0.000 18.77 8.1.20 0.006 0.003 17.34 8.1.19 0.000 0.008 17.35 8.1.18 0.005 0.003 18.10 8.1.17 0.000 0.008 18.72 8.1.16 0.004 0.004 19.02 8.1.15 0.000 0.008 20.60 8.1.14 0.004 0.004 19.61 8.1.13 0.003 0.003 18.93 8.1.12 0.007 0.000 17.51 8.1.11 0.004 0.004 17.48 8.1.10 0.007 0.000 17.40 8.1.9 0.004 0.004 17.38 8.1.8 0.007 0.000 17.38 8.1.7 0.003 0.003 17.53 8.1.6 0.004 0.004 17.47 8.1.5 0.003 0.005 17.58 8.1.4 0.004 0.004 17.55 8.1.3 0.004 0.004 17.60 8.1.2 0.004 0.004 17.58 8.1.1 0.003 0.005 17.48 8.1.0 0.008 0.000 17.61 8.0.30 0.003 0.005 18.77 8.0.29 0.007 0.000 16.60 8.0.28 0.008 0.000 18.41 8.0.27 0.007 0.000 17.21 8.0.26 0.003 0.003 16.78 8.0.25 0.000 0.006 16.89 8.0.24 0.000 0.007 17.05 8.0.23 0.006 0.003 16.95 8.0.22 0.000 0.007 16.95 8.0.21 0.004 0.004 16.92 8.0.20 0.004 0.004 17.02 8.0.19 0.000 0.008 16.99 8.0.18 0.004 0.004 16.92 8.0.17 0.004 0.004 16.99 8.0.16 0.004 0.004 16.83 8.0.15 0.000 0.007 16.90 8.0.14 0.004 0.004 16.90 8.0.13 0.003 0.003 13.28 8.0.12 0.000 0.008 16.91 8.0.11 0.004 0.004 16.89 8.0.10 0.003 0.005 16.95 8.0.9 0.000 0.007 16.76 8.0.8 0.014 0.003 16.95 8.0.7 0.002 0.005 16.98 8.0.6 0.000 0.008 16.80 8.0.5 0.004 0.004 16.76 8.0.3 0.011 0.008 17.02 8.0.2 0.013 0.015 17.40 8.0.1 0.005 0.002 17.08 8.0.0 0.005 0.016 16.77 7.4.33 0.000 0.005 15.55 7.4.32 0.000 0.007 16.66 7.4.30 0.003 0.003 16.55 7.4.29 0.003 0.007 16.66 7.4.28 0.000 0.008 16.43 7.4.27 0.004 0.004 16.66 7.4.26 0.005 0.000 13.30 7.4.25 0.004 0.004 16.54 7.4.24 0.004 0.004 16.56 7.4.23 0.000 0.007 16.55 7.4.22 0.014 0.003 16.52 7.4.21 0.007 0.007 16.54 7.4.20 0.005 0.002 16.54 7.4.16 0.007 0.013 16.54 7.4.15 0.008 0.012 17.40 7.4.14 0.014 0.006 17.86 7.4.13 0.012 0.012 16.57 7.4.12 0.013 0.008 16.49 7.4.11 0.010 0.006 16.44 7.4.10 0.017 0.003 16.49 7.4.9 0.013 0.004 16.54 7.4.8 0.008 0.008 19.39 7.4.7 0.012 0.004 16.38 7.4.6 0.010 0.013 16.51 7.4.5 0.008 0.008 16.38 7.4.4 0.013 0.003 16.67 7.4.3 0.011 0.007 16.66 7.4.0 0.004 0.013 15.05 7.3.33 0.005 0.000 13.19 7.3.32 0.002 0.002 12.99 7.3.31 0.005 0.003 16.30 7.3.30 0.007 0.000 16.21 7.3.29 0.005 0.011 16.32 7.3.28 0.005 0.011 16.31 7.3.27 0.013 0.007 17.40 7.3.26 0.016 0.004 16.40 7.3.25 0.010 0.010 16.38 7.3.24 0.008 0.009 16.55 7.3.23 0.009 0.009 16.53 7.3.21 0.009 0.009 16.36 7.3.20 0.008 0.011 16.25 7.3.19 0.004 0.016 16.33 7.3.18 0.013 0.003 16.61 7.3.17 0.013 0.004 16.42 7.3.16 0.013 0.003 16.34 7.3.12 0.006 0.013 14.79 7.3.11 0.003 0.010 15.01 7.3.10 0.003 0.012 14.71 7.3.9 0.003 0.010 14.74 7.3.8 0.000 0.010 14.79 7.3.7 0.007 0.010 14.84 7.3.6 0.004 0.008 14.83 7.3.5 0.012 0.000 14.76 7.3.4 0.003 0.006 14.64 7.3.3 0.009 0.006 14.79 7.3.2 0.007 0.007 16.67 7.3.1 0.008 0.004 16.51 7.3.0 0.007 0.007 16.66 7.2.33 0.009 0.009 16.33 7.2.32 0.007 0.011 16.72 7.2.31 0.008 0.009 16.48 7.2.30 0.012 0.006 16.71 7.2.29 0.010 0.007 16.38 7.2.25 0.003 0.015 14.79 7.2.24 0.009 0.009 15.09 7.2.23 0.007 0.004 15.00 7.2.22 0.007 0.010 15.26 7.2.21 0.006 0.009 15.18 7.2.20 0.012 0.003 15.07 7.2.19 0.003 0.006 15.12 7.2.18 0.010 0.003 15.08 7.2.17 0.003 0.006 15.13 7.2.6 0.010 0.007 16.55 7.2.0 0.009 0.003 19.16 7.1.33 0.006 0.006 15.74 7.1.32 0.004 0.008 15.83 7.1.31 0.000 0.015 15.39 7.1.30 0.004 0.008 15.78 7.1.29 0.003 0.005 15.90 7.1.28 0.006 0.003 15.40 7.1.27 0.007 0.007 15.46 7.1.26 0.007 0.007 15.54 7.1.20 0.012 0.003 15.59 7.1.10 0.006 0.006 17.75 7.1.7 0.120 0.017 15.28 7.1.6 0.120 0.023 33.33 7.1.5 0.153 0.013 32.83 7.1.4 0.127 0.013 32.33 7.1.3 0.170 0.023 32.67 7.1.2 0.163 0.013 32.75 7.1.1 0.123 0.010 14.82 7.1.0 0.010 0.010 14.71 7.0.20 0.173 0.010 14.89 7.0.19 0.187 0.013 14.95 7.0.18 0.083 0.013 14.36 7.0.17 0.210 0.010 14.31 7.0.16 0.177 0.020 14.37 7.0.15 0.110 0.003 14.52 7.0.14 0.097 0.010 14.29 7.0.13 0.053 0.007 14.63 7.0.12 0.007 0.007 14.64 7.0.11 0.143 0.013 14.41 7.0.10 0.077 0.007 14.54 7.0.9 0.033 0.017 14.59 7.0.8 0.160 0.013 14.32 7.0.7 0.003 0.013 14.40 7.0.6 0.017 0.017 14.41 7.0.5 0.063 0.010 14.47 7.0.4 0.003 0.013 14.61 7.0.3 0.190 0.013 14.65 7.0.2 0.003 0.010 14.41 7.0.1 0.157 0.017 14.81 7.0.0 0.010 0.010 14.61
preferences:dark mode live preview
47.55 ms | 401 KiB | 5 Q