forked from erlyaws/yaws
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathform.yaws
57 lines (34 loc) · 1.14 KB
/
form.yaws
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
<erl>
out(A) ->
{ssi, "TAB.inc", "%%",[{"form", "choosen"}]}.
</erl>
<div id="entry">
<h2>POST example </h2>
<p>This is a simple example where we get to fill in
a series of fields and POST the data by hitting the Submit button
at the end.
<p>
The action is set to the yaws file <tt>/post.yaws </tt> which
gets POSTed data in its <tt>ARG#arg.clidata</tt> field.
<form METHOD=POST
ACTION="/post.yaws"
This is a serious poll.
<p>Your favourite programming language? <input NAME="lang" TYPE=text SIZE="48">
<p>Imperative ? <input NAME="imperative" TYPE=checkbox>
How many tabs to you indent? <input NAME="tabs" TYPE=int>
<p>Which OS do you use?
<ol>
<li>Windows 95 pro ultra <input NAME="os1" TYPE=checkbox VALUE="w95">
<li>Windows XP beta cracked <input NAME="os2" TYPE=checkbox VALUE="xpbeta">
<li>Windows <input NAME="os3" TYPE=checkbox VALUE="windows">
<li>Other<input NAME="other" SIZE=40>
</ol>
Your email <input NAME="contact" SIZE="42">
<p>Submit this POST to get an explanation of how to process the
POSTed data.
<p><input TYPE=submit> <input TYPE=reset>
</form>
</div>
<erl>
out(A) -> {ssi, "END2",[],[]}.
</erl>