php
By: dyvus | Date: Nov 20 2006 09:50 | Format: PHP | Expires: never | Size: 3.66 KB | Hits: 1613
- <?php
- include "include/db/inc_db_connect.php";
- include "include/php/inc_functions.php";
- include "include/content/top.php";
- echo "- Registreer";
- include "include/content/top2.php";
- if($_POST["send_form"] == "ja"){
- $user = $_POST['username'];
- $pass1 = $_POST['pass1'];
- $pass2 = $_POST['pass2'];
- $email = $_POST['email'];
- $sql = "SELECT username FROM users WHERE username = '" . $user . "'";
- {
- {
- $checkusr = "1";
- }
- }
- $checkmail = checkmail($email);
- if($checkusr == 1){
- $check .= "De loginnaam die u heeft gekozen bestaat al.<br>";
- $check .= "U bent vergeten uw loginnaam in te vullen.<br>";
- }
- $check .= "U bent vergeten uw wachtwoord in te vullen.<br>";
- }elseif($pass1 != $_POST['pass2']){
- $check .= "U heeft 2 ongelijke wachtwoorden ingevult.<br>";
- }
- $check .= "U bent vergeten uw email in te vullen.<br>";
- }elseif(!$checkmail == 1){
- $check .= "U heeft een verkeerd email adres ingevult.<br>";
- }
- $username = secure($user);
- $email = secure($email);
- $sql = "INSERT INTO users (username, password, email, regdatum)
- VALUES ('$username', '$password', '$email', '$datum')";
- // De registratie is voltooid.
- echo "De registratie is voltooid.<br>U kunt nu inloggen.";
- }else{
- echo $check;
- ?>
- <form action="index.php?p=register" method="post">
- <table>
- <tr>
- <td>Loginnaam</td>
- <td> </td>
- <td><input size="30" type="text" value="<?php print($_POST["username"]); ?>" name="username"></td>
- </tr>
- <tr>
- <td>Wachtwoord</td>
- <td> </td>
- <td><input type="password" value="" name="pass1"></td>
- </tr>
- <tr>
- <td>Wachtwoord (controle)</td>
- <td> </td>
- <td><input type="password" value="" name="pass2"></td>
- </tr>
- <tr>
- <td>E-mail</td>
- <td> </td>
- <td><input size="30" type="text" value="<?php print($_POST["email"]); ?>" name="email"></td>
- </tr>
- <tr>
- <td> </td>
- <td> </td>
- <td> </td>
- </tr>
- <tr>
- <td><input type="hidden" name="send_form" value="ja"><input type="Submit" name="Submit" value="Registreer"></td>
- </tr>
- </table>
- </form>
- <?php
- }
- }else{
- ?>
- <form action="index.php?p=register" method="post">
- <table>
- <tr>
- <td>Loginnaam</td>
- <td> </td>
- <td><input size="30" type="text" value="<?php print($_POST["username"]); ?>" name="username"></td>
- </tr>
- <tr>
- <td>Wachtwoord</td>
- <td> </td>
- <td><input type="password" value="" name="pass1"></td>
- </tr>
- <tr>
- <td>Wachtwoord (controle)</td>
- <td> </td>
- <td><input type="password" value="" name="pass2"></td>
- </tr>
- <tr>
- <td>E-mail</td>
- <td> </td>
- <td><input size="30" type="text" value="<?php print($_POST["email"]); ?>" name="email"></td>
- </tr>
- <tr>
- <td> </td>
- <td> </td>
- <td> </td>
- </tr>
- <tr>
- <td><input type="hidden" name="send_form" value="ja"><input type="Submit" name="Submit" value="Registreer"></td>
- </tr>
- </table>
- </form>
- <?php
- }
- include "include/content/midden.php";
- include "include/content/bottom.php";
- ?>
Latest pastes
2 days ago
3 days ago
3 days ago
4 days ago
5 days ago