diff index-rlg.html @ 19:188bbd857124

RLG-Web: add user registration Update the server and client sides of RLG-Web to make use of the new registration feature of sqlickrypt.
author John "Elwin" Edwards <elwin@sdf.org>
date Tue, 22 May 2012 20:54:33 -0700
parents ad0a31e52007
children 82be54381964
line wrap: on
line diff
--- a/index-rlg.html	Mon May 21 21:40:56 2012 -0700
+++ b/index-rlg.html	Tue May 22 20:54:33 2012 -0700
@@ -14,6 +14,7 @@
   <img src="/bell.png" alt="bell" id="bell">
 </div>
 <div id="termwrap">TERM</div>
+<div class="modal" id="keyboard">
 <div class="keyrow">
   <div class="key" onclick="vkey('`')">`</div>
   <div class="key" onclick="vkey('1')">1</div>
@@ -82,21 +83,46 @@
 <span onclick="textsize(false)">Smaller</span>
 <span onclick="textsize(true)">Larger</span>
 </div>
-<div>
+</div>
+<div class="modal" id="login">
 <form id="loginform" action="/login" method="post">
 <div>
 Name: <input type="text" name="name" id="input_name"> 
+</div>
+<div>
 Password: <input type="password" name="pw" id="input_pw">
+</div>
+<div>
 Choose game: <select name="game" id="input_game">
   <option label="Rogue V3" value="rogue3">Rogue V3</option>
   <option label="Rogue V4" value="rogue4">Rogue V4</option>
   <option label="Rogue V5" value="rogue5">Rogue V5</option>
   <option label="Super-Rogue" value="srogue">Super-Rogue</option>
 </select>
+</div>
+<div>
 <input type="submit" value="Play" onclick="formlogin(event)">
 </div>
 </form>
 </div>
+<div class="rbutton" onclick="setmode(&quot;register&quot;)">Register</div>
+<div class="modal" id="register">
+<form id="regform" action="/addacct" method="post">
+<div>
+Name: <input type="text" name="name" id="regin_name"> 
+</div>
+<div>
+Password: <input type="password" name="pw" id="regin_pw">
+</div>
+<div>
+E-mail (optional): <input type="text" name="email" id="regin_email">
+</div>
+<div>
+<input type="submit" value="Sign up" onclick="formreg(event)">
+<input type="reset" value="Cancel" onclick="setmode(&quot;login&quot, event)">
+</div>
+</form>
+</div>
 <div id="debug">
 <p>Debugging Output</p>
 </div>