2 error_reporting(E_ALL);
4 include_once("config.php");
5 include_once("output.php"); /* html output only */
6 include_once("db.php"); /* database only */
7 include_once("functions.php"); /* the rest */
14 echo "Database error, can't connect... Please wait a while and try again. ".
15 "If the problem doesn't go away feel free to contact $ADMIN_NAME at $ADMIN_EMAIL.";
21 /* done major error checking, output header of HTML page */
24 /* new user wants to register */
25 if(myisset("Rfullname","Remail","Rpassword","Rtimezone") )
29 if(DB_get_userid('name',$_REQUEST["Rfullname"]))
31 echo "please chose another name<br />";
34 if(DB_get_userid('email',$_REQUEST["Remail"]))
36 echo "this email address is already used ?!<br />";
41 $r=mysql_query("INSERT INTO User VALUES(NULL,".DB_quote_smart($_REQUEST["Rfullname"]).
42 ",".DB_quote_smart($_REQUEST["Remail"]).
43 ",".DB_quote_smart(md5($_REQUEST["Rpassword"])).
44 ",".DB_quote_smart($_REQUEST["Rtimezone"]).",NULL,NULL)");
47 echo " Welcome to e-DoKo, you are now registered, please visit the".
48 " <a href=\"".$HOST.$INDEX."\">homepage</a> to continue.";
50 echo " something went wrong, couldn't add you to the database, please contact $ADMIN_NAME at $ADMIN_EMAIL.";
53 /* page for registration */
56 echo "IMPORTANT: passwords are going over the net as clear text, so pick an easy password. No need to pick anything complicated here ;)<br /><br />";
58 <form action="register.php" method="post">
60 <legend>Register</legend>
63 <td><label for="Rfullname">Full name:</label></td>
64 <td><input type="text" id="Rfullname" name="Rfullname" size="20" maxsize="30" /> </td>
66 <td><label for="Remail">Email:</label></td>
67 <td><input type="text" id="Remail" name="Remail" size="20" maxsize="30" /></td>
69 <td><label for="Rpassword">Password(will be displayed in cleartext on the next page):</label></td>
70 <td><input type="password" id="Rpassword" name="Rpassword" size="20" maxsize="30" /></td>
72 <td><label for="Rtimezone">Timezone:</label></td>
74 <select id="Rtimezone" name="Rtimezone" size="1">
75 <option value="Europe/London">Berlin</option>
76 <option value="Europe/Berlin">Berlin</option>
77 <option value="America/Vancouver">Berkeley</option>
78 <option value="Pacific/Auckland">Wellington</option>
80 (If your timezone is not listed, just select whatever you want and email the admin your correct time zone.)
83 <td colspan="2"> <input type="submit" value="register" /></td>