Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Newer
Older
100644 63 lines (58 sloc) 1.772 kb
01a7f58 Ross Lagerwall Initial commit
authored
1 <?php
2 include("common.php");
3
4 if ($_SESSION['loggedIn'] == true)
5 {
6 header("location: index.php");
7 exit();
8 }
9
10 outHtml1("Register");
11 outHtml2("Register","index.php",false);
12 ?>
13
14 <form method="POST" action="registerExecute.php">
15 <table class='list'>
16 <tr>
17 <td class='listlefta'>Username</td>
18 <td class='listrighta'><input type="text" name="username"></td>
19 </tr>
20 <tr>
21 <td class='listlefta'>Password</td>
22 <td class='listrighta'><input type="password" name="password"></td>
23 </tr>
24 <tr>
25 <td class='listlefta'>Email Address</td>
26 <td class='listrighta'><input type="text" name="email"></td>
27 </tr>
28 <tr>
29 <td class='listlefta'>Hide Email</td>
30 <td class='listrighta'><input type="checkbox" name="hideEmail" value="yes"></td>
31 </tr>
32 </table>
33 <?php
34 if ($_GET['badRegister'] == 1)
35 {
36 echo "<div style='margin-top: 10px' align='center'>Username already exists!</div>";
37 }
38 else if ($_GET['badRegister'] == 2)
39 {
40 echo "<div style='margin-top: 10px' align='center'>Please fill in username and password!</div>";
41 }
42 else if ($_GET['badRegister'] == 3)
43 {
44 echo "<div style='margin-top: 10px' align='center'>Username or password too short!</div>";
45 }
46 else if ($_GET['badRegister'] == 4)
47 {
48 echo "<div style='margin-top: 10px' align='center'>Bad email address!</div>";
49 }
50 else if ($_GET['badRegister'] == 5)
51 {
52 echo "<div style='margin-top: 10px' align='center'>Username must contain only letters, numbers and the underscore!</div>";
53 }
54 ?>
55 <div id='submitDiv'>
56 <input type="submit" name="submit" value="Register">
57 </div>
58 </form>
59
60 <?php
61 outHtml3();
62 ?>
Something went wrong with that request. Please try again.