r6998: - added support for application[] data, which is global to all clients using...
[samba.git] / swat / esptest / formtest.html
1 <HTML>
2 <TITLE>
3 Samba4 ESP test
4 </TITLE>
5 <BODY>
6 <h1>Samba4 form test</h1>
7
8 <form name="FormTest" method="POST" action="@@request['SCRIPT_NAME']"> 
9     firstName: <input name="firstName" type="text" value=""><br>
10     lastName:  <input name="lastName"  type="text" value=""><br>
11     <input name="submit" type="submit" value="OK">
12     <input name="submit" type="submit" value="Cancel"><br>
13 </form>
14
15 <%
16   /* if its a post then the user has filled in the form, so
17      report the values 
18   */
19   if (request['REQUEST_METHOD'] == "POST") {
20
21   /* if they cancelled then take them back to the list of tests */
22   if (form['submit'] == "Cancel") {
23      redirect("index.html");
24   }
25 %>
26   You chose firstName=@@form['firstName'] lastName=@@form['lastName']
27 <%
28
29    function showArray(name, array) {
30       write("<h3>Array: " + name + "</h3>\n");
31       for (v in array) {
32             write(name + "[" + v + "]=" + array[v] + "<br>\n");
33       }
34    }
35
36    showArray("form",    form);
37   }
38 %>
39
40 </BODY>
41 </HTML>