File: form_package.html

package info (click to toggle)
libapache2-mod-rivet 3.2.2-1
  • links: PTS
  • area: main
  • in suites: bookworm
  • size: 6,296 kB
  • sloc: xml: 8,554; tcl: 7,568; ansic: 7,094; sh: 5,017; makefile: 195; sql: 91; lisp: 78
file content (217 lines) | stat: -rw-r--r-- 42,928 bytes parent folder | download
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
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
<html><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8"><title>form</title><link rel="stylesheet" type="text/css" href="rivet.css"><meta name="generator" content="DocBook XSL Stylesheets Vsnapshot"><link rel="home" href="index.html" title="Apache Rivet 3.2"><link rel="up" href="form.html" title="Form: An HTML Form Fields Generation Utility"><link rel="prev" href="form.html" title="Form: An HTML Form Fields Generation Utility"><link rel="next" href="calendar_package.html" title="Calendar Package"></head><body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"><div class="navheader"><table width="100%" summary="Navigation header"><tr><th colspan="3" align="center">form</th></tr><tr><td width="20%" align="left"><a accesskey="p" href="form.html"><img src="images/prev.png" alt="Prev"></a> </td><th width="60%" align="center">Form: An HTML Form Fields Generation Utility</th><td width="20%" align="right"> <a accesskey="n" href="calendar_package.html"><img src="images/next.png" alt="Next"></a></td></tr></table></div><div class="refentry"><a name="form_package"></a><div class="titlepage"></div><div class="refnamediv"><h2>Name</h2><p>form —  a Tcl command object for creating HTML forms</p></div><div class="refsynopsisdiv"><h2>Synopsis</h2><div class="cmdsynopsis" style="width:80%"><div style="border: 1px solid #282; margin:1ex ; padding:.4ex; padding-left: 0.8ex;   word-spacing:1ex "><span style="font-weight:bold ; font-family:monospace">form</span>   <span style="font-family:monospace; font-weight: bold;"><em class="replaceable"><code>form_name</code></em></span>  ?<span style="font-family:monospace; font-weight: bold;">-option1 <em class="replaceable"><code>value_1</code></em></span>? ?<span style="font-family:monospace; font-weight: bold;">-option2 <em class="replaceable"><code>value_2</code></em></span>? ?<span style="font-family:monospace; font-weight: bold;">...</span>?</div></div></div><div class="refsect1"><a name="idm3534"></a><p style="width:90%">
				creates and returns a new Tcl command named <em class="replaceable"><code>form_name</code></em>.
			</p><div class="refsect2"><a name="idm3538"></a><h3>Options</h3><div class="variablelist"><dl class="variablelist"><dt></dt><dd><div style="padding:4 ; margin-top:3 ; margin-bottom:3 ; width:75%"><div class="cmdsynopsis" style="width:80%"><div style="border: 1px solid #282; margin:1ex ; padding:.4ex; padding-left: 0.8ex;   word-spacing:1ex "> <span style="font-family:monospace; font-weight: bold;">-method</span>  ?<span style="font-family:monospace; font-weight: bold;">post|get</span>?</div></div><div style="margin-bottom:1.5ex ; padding .5ex">
			      			The http method for sending the form data back to the server.
			      			Possible values are get or post
			      		</div></div></dd><dt></dt><dd><div style="padding:4 ; margin-top:3 ; margin-bottom:3 ; width:75%"><div class="cmdsynopsis" style="width:80%"><div style="border: 1px solid #282; margin:1ex ; padding:.4ex; padding-left: 0.8ex;   word-spacing:1ex "> <span style="font-family:monospace; font-weight: bold;">-name</span>  ?<span style="font-family:monospace; font-weight: bold;"><em class="replaceable"><code>form_name</code></em></span>?</div></div><div style="margin-bottom:1.5ex ; padding .5ex">
		      				a name for the form being created: this value becomes the value of the 
		      				attribute 'name' in the &lt;form&gt; tag.
		      			</div></div></dd><dt></dt><dd><div style="padding:4 ; margin-top:3 ; margin-bottom:3 ; width:75%"><div class="cmdsynopsis" style="width:80%"><div style="border: 1px solid #282; margin:1ex ; padding:.4ex; padding-left: 0.8ex;   word-spacing:1ex "> <span style="font-family:monospace; font-weight: bold;">-defaults</span>  ?<span style="font-family:monospace; font-weight: bold;"><em class="replaceable"><code>default_values</code></em></span>?</div></div><div style="margin-bottom:1.5ex ; padding .5ex">
								an array of default values	to be assigned to the fields of the form. 
								Every name in the array is matched with an input field, when
								a given field gets added to the form it is initialized with the 
								value of the corresponding variable in the array. 
								This option works well in conjuction with the 
								<span style="font-family:monospace"><span class="command"><strong>load_response</strong></span></span> command of Rivet when default 
								values come from another form.
							</div></div></dd><dt></dt><dd><div style="padding:4 ; margin-top:3 ; margin-bottom:3 ; width:75%"><div class="cmdsynopsis" style="width:80%"><div style="border: 1px solid #282; margin:1ex ; padding:.4ex; padding-left: 0.8ex;   word-spacing:1ex "> <span style="font-family:monospace; font-weight: bold;">-emit</span>  ?<span style="font-family:monospace; font-weight: bold;"><em class="replaceable"><code>true(default)|false</code></em></span>?</div></div><div style="margin-bottom:1.5ex ; padding .5ex">
								a Tcl accepted representation of a Boolean value. Change a form object
								instance behavior so that methods generating HTML form entries return
								to the caller their output as string instead of directly sending it to stdout
							</div></div></dd><dt></dt><dd><div style="padding:4 ; margin-top:3 ; margin-bottom:3 ; width:75%"><div class="cmdsynopsis" style="width:80%"><div style="border: 1px solid #282; margin:1ex ; padding:.4ex; padding-left: 0.8ex;   word-spacing:1ex "> <span style="font-family:monospace; font-weight: bold;">-action</span>  ?<span style="font-family:monospace; font-weight: bold;"><em class="replaceable"><code>URL</code></em></span>?</div></div><div style="margin-bottom:1.5ex ; padding .5ex">
								The URL the data are being sent to. If no  ?<span style="font-family:monospace; font-weight: bold;">-action</span>? switch is specified
								the data are sent to the form's URL.
							</div></div></dd></dl></div></div></div><div class="refsect1"><a name="idm3577"></a><h2>Form Object Commands</h2><p style="width:90%">
	Form object commands follow the usual syntax of Tcl commands with a  ?<span style="font-family:monospace; font-weight: bold;"><em class="replaceable"><code>subcommand</code></em></span>? argument playing the
	role of a switch among various functionalities of the command. Form objects also need the  ?<span style="font-family:monospace; font-weight: bold;"><em class="replaceable"><code>name</code></em></span>? parameter 
				which is to become the value of the 'name' attribute in an input field. This argument is the key that has to be 
				used by the server-side script to retrieve the input field value. 
			</p><div class="variablelist"><dl class="variablelist"><dt></dt><dd><div style="padding:4 ; margin-top:3 ; margin-bottom:3 ; width:75%"><div class="cmdsynopsis" style="width:80%"><div style="border: 1px solid #282; margin:1ex ; padding:.4ex; padding-left: 0.8ex;   word-spacing:1ex ">
								form_object   <span style="font-family:monospace; font-weight: bold;">subcommand</span>  ?<span style="font-family:monospace; font-weight: bold;">name</span>? ?<span style="font-family:monospace; font-weight: bold;">-option1 <em class="replaceable"><code>value1</code></em></span>? ?<span style="font-family:monospace; font-weight: bold;">-option2 <em class="replaceable"><code>value2</code></em></span>? ?<span style="font-family:monospace; font-weight: bold;">...</span>?</div></div></div></dd></dl></div><p style="width:90%">			
				Options passed to a subcommand are copied into the tag as attribute="value" pairs. 
				Some subcommands (e.g. form, radiobuttons and checkboxes) treat specific options in a way 
				that fits the specific organization and function of these fields. 
			</p><p style="width:90%">
				Exceptions to this general syntax are the <span style="font-family:monospace"><span class="command"><strong>field</strong></span></span> and <span style="font-family:monospace"><span class="command"><strong>end</strong></span></span> subcommands.
				<span style="font-family:monospace"><span class="command"><strong>field</strong></span></span> is an abstract input field creation method and requires an additional
				parameter specifiyng the type of field to create. Every concrete input field generation command
				uses this subcommand internally to print the final html.
			</p></div><div class="refsect1"><a name="idm3600"></a><h2>Subcommands</h2><div class="refsect2"><a name="idm3602"></a><div class="variablelist"><dl class="variablelist"><dt></dt><dd><div style="padding:4 ; margin-top:3 ; margin-bottom:3 ; width:75%"><div class="cmdsynopsis" style="width:80%"><div style="border: 1px solid #282; margin:1ex ; padding:.4ex; padding-left: 0.8ex;   word-spacing:1ex "><span style="font-weight:bold ; font-family:monospace">start</span>  ?<span style="font-family:monospace; font-weight: bold;">name</span>? ?<span style="font-family:monospace; font-weight: bold;">-method <em class="replaceable"><code>get | post</code></em></span>? ?<span style="font-family:monospace; font-weight: bold;">-name <em class="replaceable"><code>form_name</code></em></span>? ?<span style="font-family:monospace; font-weight: bold;">-defaults <em class="replaceable"><code>default_values</code></em></span>? ?<span style="font-family:monospace; font-weight: bold;">-action <em class="replaceable"><code>URL</code></em></span>? ?<span style="font-family:monospace; font-weight: bold;">args</span>?</div></div><div style="margin-bottom:1.5ex ; padding .5ex">
								Print the &lt;form&gt; tag with all its attributes. 
								This command must be called as first in the form generation
								process. The following is a sample of code creating a form named 'formname' whose data will
								be sent via the GET method. Initial form fields values will be obtained from array 
		<code class="varname">response</code>
							</div><pre class="programlisting">
form myform -defaults response -method get -name formname
myform start
myform text	  text_entry -size 20
myform select option_selected -values {opt1 opt2 opt3 opt4}
myform submit submit -value Search
myform end</pre><div style="margin-bottom:1.5ex ; padding .5ex">
								The code prints a form that sends a text entry content and the option value 
								associated with a radiobutton. The URL of the server script is the same that
								created the form. Use the  ?<span style="font-family:monospace; font-weight: bold;">-url</span>? option to specify a different url.
							</div></div></dd></dl></div><div class="refsect3"><a name="idm3623"></a><div style="padding:4 ; margin-top:3 ; margin-left: 5%;">Options</div><div class="variablelist"><dl class="variablelist"><dt></dt><dd><div style="padding:4 ; margin-top:3 ; margin-left: 5%;  margin-bottom:3 ; width:70%;"><div class="cmdsynopsis" style="width:80%"><div style="border: 1px solid #282; margin:1ex ; padding:.4ex; padding-left: 0.8ex;   word-spacing:1ex "> <span style="font-family:monospace; font-weight: bold;">-method</span>  ?<span style="font-family:monospace; font-weight: bold;">post|get</span>?</div></div><div style="margin-bottom:1.5ex ; padding .5ex">
    				      			The method to be used to encode the form data. 
    				      			Possible values are get or post
    				      		</div></div></dd><dt></dt><dd><div style="padding:4 ; margin-top:3 ; margin-left: 5%;  margin-bottom:3 ; width:70%;"><div class="cmdsynopsis" style="width:80%"><div style="border: 1px solid #282; margin:1ex ; padding:.4ex; padding-left: 0.8ex;   word-spacing:1ex "> <span style="font-family:monospace; font-weight: bold;">-name</span>  ?<span style="font-family:monospace; font-weight: bold;"><em class="replaceable"><code>form_name</code></em></span>?</div></div><div style="margin-bottom:1.5ex ; padding .5ex">
    			      				a name for the form being generated: this value becomes the value of the 
    			      				attribute 'name' in the &lt;form&gt; tag.
    			      			</div></div></dd><dt></dt><dd><div style="padding:4 ; margin-top:3 ; margin-left: 5%;  margin-bottom:3 ; width:70%;"><div class="cmdsynopsis" style="width:80%"><div style="border: 1px solid #282; margin:1ex ; padding:.4ex; padding-left: 0.8ex;   word-spacing:1ex "> <span style="font-family:monospace; font-weight: bold;">-defaults</span>  ?<span style="font-family:monospace; font-weight: bold;"><em class="replaceable"><code>default_values</code></em></span>?</div></div><div style="margin-bottom:1.5ex ; padding .5ex">
									an array of default values	to be assigned to the fields of the form. 
									Every name in the array is matched with an input field, when
									a given field gets added to the form it is initialized with the 
									value of the corresponding variable in the array. 
									This option works well in conjuction with the 
									<span style="font-family:monospace"><span class="command"><strong>load_response</strong></span></span> command of Rivet when default values
									come from another form.
								</div></div></dd><dt></dt><dd><div style="padding:4 ; margin-top:3 ; margin-left: 5%;  margin-bottom:3 ; width:70%;"><div class="cmdsynopsis" style="width:80%"><div style="border: 1px solid #282; margin:1ex ; padding:.4ex; padding-left: 0.8ex;   word-spacing:1ex "> <span style="font-family:monospace; font-weight: bold;">-action</span>  ?<span style="font-family:monospace; font-weight: bold;"><em class="replaceable"><code>URL</code></em></span>?</div></div><div style="margin-bottom:1.5ex ; padding .5ex">
									The URL the data will be sent to. If no  ?<span style="font-family:monospace; font-weight: bold;">-action</span>? switch is specified
									the data are sent to the form's URL.
								</div></div></dd></dl></div></div></div><div class="refsect2"><a name="idm3655"></a><div class="variablelist"><dl class="variablelist"><dt></dt><dd><div style="padding:4 ; margin-top:3 ; margin-bottom:3 ; width:75%"><div class="cmdsynopsis" style="width:80%"><div style="border: 1px solid #282; margin:1ex ; padding:.4ex; padding-left: 0.8ex;   word-spacing:1ex "><span style="font-weight:bold ; font-family:monospace">end</span> </div></div><div style="margin-bottom:1.5ex ; padding .5ex">	
			      			Print the &lt;/form&gt; closing tag. This command must
								be called last in the form generation process
							</div></div></dd></dl></div></div><div class="refsect2"><a name="idm3662"></a><div class="variablelist"><dl class="variablelist"><dt></dt><dd><div style="padding:4 ; margin-top:3 ; margin-bottom:3 ; width:75%"><div class="cmdsynopsis" style="width:80%"><div style="border: 1px solid #282; margin:1ex ; padding:.4ex; padding-left: 0.8ex;   word-spacing:1ex "><span style="font-weight:bold ; font-family:monospace">field</span>  ?<span style="font-family:monospace; font-weight: bold;">name</span>? ?<span style="font-family:monospace; font-weight: bold;">type</span>? ?<span style="font-family:monospace; font-weight: bold;">args</span>?</div></div><div style="margin-bottom:1.5ex ; padding .5ex">	
		Print a field of the given  ?<span style="font-family:monospace; font-weight: bold;"><em class="replaceable"><code>type</code></em></span>? and  ?<span style="font-family:monospace; font-weight: bold;"><em class="replaceable"><code>name</code></em></span>?,
								including any default key-value pairs defined for this field 
								type and optional key-value pairs included with the statement
							</div></div></dd></dl></div><div class="refsect3"><a name="idm3676"></a><div style="padding:4 ; margin-top:3 ; margin-left: 5%;">Options</div><div class="variablelist"><dl class="variablelist"><dt></dt><dd><div style="padding:4 ; margin-top:3 ; margin-left: 5%;  margin-bottom:3 ; width:70%;"><div class="cmdsynopsis" style="width:80%"><div style="border: 1px solid #282; margin:1ex ; padding:.4ex; padding-left: 0.8ex;   word-spacing:1ex "> <span style="font-family:monospace; font-weight: bold;">-opt1</span>  ?<span style="font-family:monospace; font-weight: bold;">val1</span>?</div></div><div style="margin-bottom:1.5ex ; padding .5ex">
				      			Option description
				      		</div></div></dd></dl></div></div></div><div class="refsect2"><a name="idm3685"></a><div class="variablelist"><dl class="variablelist"><dt></dt><dd><div style="padding:4 ; margin-top:3 ; margin-bottom:3 ; width:75%"><div class="cmdsynopsis" style="width:80%"><div style="border: 1px solid #282; margin:1ex ; padding:.4ex; padding-left: 0.8ex;   word-spacing:1ex "> <span style="font-family:monospace; font-weight: bold;">radiobuttons</span>  ?<span style="font-family:monospace; font-weight: bold;">name</span>? ?<span style="font-family:monospace; font-weight: bold;">-values <em class="replaceable"><code>values</code></em></span>? ?<span style="font-family:monospace; font-weight: bold;">-labels <em class="replaceable"><code>labels</code></em></span>? ?<span style="font-family:monospace; font-weight: bold;">args</span>?</div></div><div style="margin-bottom:1.5ex ; padding .5ex">
								the <span style="font-family:monospace"><span class="command"><strong>radiobutton</strong></span></span> creates a whole radiobutton group
								with the values and labels specified in the argument list. 
								If no  ?<span style="font-family:monospace; font-weight: bold;">-labels</span>? switch is
								passed to the subcommand the values are printed as labels of 
								the radiobutton.
							</div><div class="refsect3"><a name="idm3700"></a><div style="padding:4 ; margin-top:3 ; margin-left: 5%;">Options</div><div class="variablelist"><dl class="variablelist"><dt></dt><dd><div style="padding:4 ; margin-top:3 ; margin-left: 5%;  margin-bottom:3 ; width:70%;"><div class="cmdsynopsis" style="width:80%"><div style="border: 1px solid #282; margin:1ex ; padding:.4ex; padding-left: 0.8ex;   word-spacing:1ex "> <span style="font-family:monospace; font-weight: bold;">-values</span>  ?<span style="font-family:monospace; font-weight: bold;"><em class="replaceable"><code>values_list</code></em></span>?</div></div><div style="margin-bottom:1.5ex ; padding .5ex">
												List of values associated with the radiobuttons to be displayed
											</div></div></dd><dt></dt><dd><div style="padding:4 ; margin-top:3 ; margin-left: 5%;  margin-bottom:3 ; width:70%;"><div class="cmdsynopsis" style="width:80%"><div style="border: 1px solid #282; margin:1ex ; padding:.4ex; padding-left: 0.8ex;   word-spacing:1ex "> <span style="font-family:monospace; font-weight: bold;">-labels</span>  ?<span style="font-family:monospace; font-weight: bold;"><em class="replaceable"><code>labels_list</code></em></span>?</div></div><div style="margin-bottom:1.5ex ; padding .5ex">
												List of labels to be printed with every radiobutton. There must
												be a label for every radiobutton
	 										</div></div></dd></dl></div></div><div style="margin-bottom:1.5ex ; padding .5ex">
								Example:
							</div><pre class="programlisting">
form myform -defaults response -method get -name formname
myform start
myform text text_entry -size 20
myform radiobuttons fruit -values {big medium small} \
              -labels {Watermelon Orange Strawberry} \
              -class myradiobclass
myform submit submit -value Search
myform end</pre><div style="margin-bottom:1.5ex ; padding .5ex">
								will print the following HTML code.
							</div><pre class="programlisting">
&lt;input type="radio" name="fruit" class="myradiobclass" value="big" /&gt;Watermelon
&lt;input type="radio" name="fruit" class="myradiobclass" value="medium" /&gt;Orange
&lt;input type="radio" name="fruit" class="myradiobclass" value="small" /&gt;Strawberry
</pre><div style="margin-bottom:1.5ex ; padding .5ex">
		if the <code class="varname">response</code> array has a variable for the name 'fruit' the corresponding 
								radiobutton field is automatically checked. The options  ?<span style="font-family:monospace; font-weight: bold;">values</span>? and  ?<span style="font-family:monospace; font-weight: bold;">labels</span>?
								are used internally and don't get into the tag attributes. If a  ?<span style="font-family:monospace; font-weight: bold;">labels</span>? 
								option is not given, labels are assigned using the  ?<span style="font-family:monospace; font-weight: bold;">values</span>? list.
							</div></div></dd></dl></div></div><div class="refsect2"><a name="idm3727"></a><div class="variablelist"><dl class="variablelist"><dt></dt><dd><div style="padding:4 ; margin-top:3 ; margin-bottom:3 ; width:75%"><div class="cmdsynopsis" style="width:80%"><div style="border: 1px solid #282; margin:1ex ; padding:.4ex; padding-left: 0.8ex;   word-spacing:1ex "> <span style="font-family:monospace; font-weight: bold;">checkbox</span>  ?<span style="font-family:monospace; font-weight: bold;">name</span>? ?<span style="font-family:monospace; font-weight: bold;">-label <em class="replaceable"><code>label</code></em></span>? ?<span style="font-family:monospace; font-weight: bold;">-value <em class="replaceable"><code>value</code></em></span>? ?<span style="font-family:monospace; font-weight: bold;">args</span>?</div></div><div style="margin-bottom:1.5ex ; padding .5ex">
								The   <span style="font-family:monospace; font-weight: bold;">checkbox</span>  subcommand emits a checkbox 
								type input field with the name, label and value attributes set 
								according to the parameters passed to the subcommand.
							</div><div style="margin-bottom:1.5ex ; padding .5ex">
								Example:
							</div><pre class="programlisting">form myform -defaults response -method get -name formname -action &lt;form_url&gt;
myform start
myform checkbox options -value opt1 -label "Option 1"
myform checkbox options -value opt2 -label "Option 2"
myform checkbox options -value opt3 -label "Option 3"
myform checkbox options -value opt4 -label "Option 4"
myform submit save_tps -value "Send Options"
myform end
myform destroy</pre><div style="margin-bottom:1.5ex ; padding .5ex">
								Provided opt2 was in response array (in the list valued 'options' variable) that 
								initialized the form, the output would look like this
							</div><pre class="programlisting">&lt;form  action="&lt;form_url&gt;" method="get" name="formname"&gt;
&lt;input type="checkbox" name="options"  id="autogen_1" label="Option 1" value="sopt1" /&gt;&lt;label for="autogen_1"&gt;Option 1&lt;/label&gt;
&lt;input type="checkbox" name="options"  id="autogen_2" label="Option 2" value="sopt2" /&gt;&lt;label for="autogen_2"&gt;Option 2&lt;/label&gt;
&lt;input type="checkbox" name="options"  id="autogen_3" label="Option 3" value="sopt3" /&gt;&lt;label for="autogen_3"&gt;Option 3&lt;/label&gt;
&lt;input type="checkbox" name="options"  id="autogen_4" label="Option 4" value="sopt4" /&gt;&lt;label for="autogen_4"&gt;Option 4&lt;/label&gt;
&lt;input type="submit" name="submit"  value="Send" /&gt;
&lt;/form&gt;</pre></div></dd></dl></div></div><div class="refsect2"><a name="idm3745"></a><div class="variablelist"><dl class="variablelist"><dt></dt><dd><div style="padding:4 ; margin-top:3 ; margin-bottom:3 ; width:75%"><div class="cmdsynopsis" style="width:80%"><div style="border: 1px solid #282; margin:1ex ; padding:.4ex; padding-left: 0.8ex;   word-spacing:1ex "> <span style="font-family:monospace; font-weight: bold;">checkboxes</span>  ?<span style="font-family:monospace; font-weight: bold;">name</span>? ?<span style="font-family:monospace; font-weight: bold;">-labels <em class="replaceable"><code>labels_list</code></em></span>? ?<span style="font-family:monospace; font-weight: bold;">-values <em class="replaceable"><code>values_list</code></em></span>? ?<span style="font-family:monospace; font-weight: bold;">args</span>?</div></div><div style="margin-bottom:1.5ex ; padding .5ex">
								The   <span style="font-family:monospace; font-weight: bold;">checkboxes</span>  is an extended form
								of the   <span style="font-family:monospace; font-weight: bold;">checkbox</span>  subcommand. 
								  <span style="font-family:monospace; font-weight: bold;">checkboxes</span> 
								prints as many checkboxes as the number of elements in the 
								 ?<span style="font-family:monospace; font-weight: bold;"><em class="replaceable"><code>labels_list</code></em></span>? argument								 
							</div><div class="refsect3"><a name="idm3763"></a><div style="padding:4 ; margin-top:3 ; margin-left: 5%;">Options</div><div class="variablelist"><dl class="variablelist"><dt></dt><dd><div style="padding:4 ; margin-top:3 ; margin-left: 5%;  margin-bottom:3 ; width:70%;"><div class="cmdsynopsis" style="width:80%"><div style="border: 1px solid #282; margin:1ex ; padding:.4ex; padding-left: 0.8ex;   word-spacing:1ex "> <span style="font-family:monospace; font-weight: bold;">-values</span>  ?<span style="font-family:monospace; font-weight: bold;"><em class="replaceable"><code>values_list</code></em></span>?</div></div><div style="margin-bottom:1.5ex ; padding .5ex">
												List of values associated with the checkboxes to be displayed
											</div></div></dd><dt></dt><dd><div style="padding:4 ; margin-top:3 ; margin-left: 5%;  margin-bottom:3 ; width:70%;"><div class="cmdsynopsis" style="width:80%"><div style="border: 1px solid #282; margin:1ex ; padding:.4ex; padding-left: 0.8ex;   word-spacing:1ex "> <span style="font-family:monospace; font-weight: bold;">-labels</span>  ?<span style="font-family:monospace; font-weight: bold;"><em class="replaceable"><code>labels_list</code></em></span>?</div></div><div style="margin-bottom:1.5ex ; padding .5ex">
												List of labels to be printed with every checkbox. There must
												be a label for every checkbox
	 										</div></div></dd></dl></div></div><div style="margin-bottom:1.5ex ; padding .5ex">
								Example:
							</div><pre class="programlisting">form myform -defaults response -method post -action &lt;form_url&gt;
myform start
myform checkboxes options -values {opt1 opt2 opt3 opt4} -labels {"Option 1" "Option 2" "Option 3" "Option 4"}
myform submit save_tps -value "Send Options"
myform end
myform destroy</pre><div style="margin-bottom:1.5ex ; padding .5ex">
								will print the following HTML code
							</div><pre class="programlisting">&lt;form  action="&lt;form_url&gt;" method="post"&gt;
&lt;input type="checkbox" name="options"  id="autogen_1" label="Option 1" value="opt1" /&gt;&lt;label for="autogen_1"&gt;Option 1&lt;/label&gt;
&lt;input type="checkbox" name="options"  id="autogen_2" label="Option 2" value="opt2" /&gt;&lt;label for="autogen_2"&gt;Option 2&lt;/label&gt;
&lt;input type="checkbox" name="options"  id="autogen_3" label="Option 3" value="opt3" /&gt;&lt;label for="autogen_3"&gt;Option 3&lt;/label&gt;
&lt;input type="checkbox" name="options"  id="autogen_4" label="Option 4" value="opt4" /&gt;&lt;label for="autogen_4"&gt;Option 4&lt;/label&gt;
&lt;input type="submit" name="save_tps"  value="Send Options" /&gt;
&lt;/form&gt;</pre></div></dd></dl></div></div><div class="refsect2"><a name="idm3784"></a><div class="variablelist"><dl class="variablelist"><dt></dt><dd><div style="padding:4 ; margin-top:3 ; margin-bottom:3 ; width:75%"><div class="cmdsynopsis" style="width:80%"><div style="border: 1px solid #282; margin:1ex ; padding:.4ex; padding-left: 0.8ex;   word-spacing:1ex "> <span style="font-family:monospace; font-weight: bold;">password</span>  ?<span style="font-family:monospace; font-weight: bold;">name</span>? ?<span style="font-family:monospace; font-weight: bold;">args</span>?</div></div><div style="margin-bottom:1.5ex ; padding .5ex">
								Same as text, but the input is obfuscated so as not to reveal the text being typed
							</div></div></dd></dl></div></div><div class="refsect2"><a name="idm3793"></a><div class="variablelist"><dl class="variablelist"><dt></dt><dd><div style="padding:4 ; margin-top:3 ; margin-bottom:3 ; width:75%"><div class="cmdsynopsis" style="width:80%"><div style="border: 1px solid #282; margin:1ex ; padding:.4ex; padding-left: 0.8ex;   word-spacing:1ex "> <span style="font-family:monospace; font-weight: bold;">hidden</span>  ?<span style="font-family:monospace; font-weight: bold;">name</span>? ?<span style="font-family:monospace; font-weight: bold;">args</span>?</div></div><div style="margin-bottom:1.5ex ; padding .5ex">
								hidden input element: typicall embedded in a form in order to
								pass status variables.
							</div></div></dd></dl></div></div><div class="refsect2"><a name="idm3802"></a><div class="variablelist"><dl class="variablelist"><dt></dt><dd><div style="padding:4 ; margin-top:3 ; margin-bottom:3 ; width:75%"><div class="cmdsynopsis" style="width:80%"><div style="border: 1px solid #282; margin:1ex ; padding:.4ex; padding-left: 0.8ex;   word-spacing:1ex "> <span style="font-family:monospace; font-weight: bold;">submit</span>  ?<span style="font-family:monospace; font-weight: bold;">name</span>? ?<span style="font-family:monospace; font-weight: bold;">args</span>?</div></div><div style="margin-bottom:1.5ex ; padding .5ex">
								emits the code for a classical HTML submit button. Example: the following
								code
							</div><div style="margin-bottom:1.5ex ; padding .5ex">
								<pre class="programlisting">
	form myform -defaults response -method get -name feedsearch
	myform start
	myform submit submit -value Search</pre>						
							</div><div style="margin-bottom:1.5ex ; padding .5ex">
								Would emit a form  like this
							</div><pre class="programlisting">
	&lt;form...&gt;
	&lt;input type="submit" name="submit" value="Search" /&gt; 
	&lt;/form&gt;</pre></div></dd></dl></div></div><div class="refsect2"><a name="idm3815"></a><div class="variablelist"><dl class="variablelist"><dt></dt><dd><div style="padding:4 ; margin-top:3 ; margin-bottom:3 ; width:75%"><div class="cmdsynopsis" style="width:80%"><div style="border: 1px solid #282; margin:1ex ; padding:.4ex; padding-left: 0.8ex;   word-spacing:1ex "> <span style="font-family:monospace; font-weight: bold;">button</span>  ?<span style="font-family:monospace; font-weight: bold;">name</span>? ?<span style="font-family:monospace; font-weight: bold;">args</span>?</div></div><div style="margin-bottom:1.5ex ; padding .5ex">
		emits the code for a button field having  ?<span style="font-family:monospace; font-weight: bold;"><em class="replaceable"><code>name</code></em></span>? as name
							</div></div></dd></dl></div></div><div class="refsect2"><a name="idm3826"></a><div class="variablelist"><dl class="variablelist"><dt></dt><dd><div style="padding:4 ; margin-top:3 ; margin-bottom:3 ; width:75%"><div class="cmdsynopsis" style="width:80%"><div style="border: 1px solid #282; margin:1ex ; padding:.4ex; padding-left: 0.8ex;   word-spacing:1ex "> <span style="font-family:monospace; font-weight: bold;">reset</span>  ?<span style="font-family:monospace; font-weight: bold;">name</span>? ?<span style="font-family:monospace; font-weight: bold;">args</span>?</div></div><div style="margin-bottom:1.5ex ; padding .5ex">
								Classical HTML reset button that resets the input fields
								back to their initial values
							</div></div></dd></dl></div></div><div class="refsect2"><a name="idm3835"></a><div class="variablelist"><dl class="variablelist"><dt></dt><dd><div style="padding:4 ; margin-top:3 ; margin-bottom:3 ; width:75%"><div class="cmdsynopsis" style="width:80%"><div style="border: 1px solid #282; margin:1ex ; padding:.4ex; padding-left: 0.8ex;   word-spacing:1ex "> <span style="font-family:monospace; font-weight: bold;">image</span>  ?<span style="font-family:monospace; font-weight: bold;">name</span>? ?<span style="font-family:monospace; font-weight: bold;">args</span>?</div></div><div style="margin-bottom:1.5ex ; padding .5ex">
								Emits an image input field
							</div></div></dd></dl></div></div><div class="refsect2"><a name="idm3844"></a><div class="variablelist"><dl class="variablelist"><dt></dt><dd><div style="padding:4 ; margin-top:3 ; margin-bottom:3 ; width:75%"><div class="cmdsynopsis" style="width:80%"><div style="border: 1px solid #282; margin:1ex ; padding:.4ex; padding-left: 0.8ex;   word-spacing:1ex "> <span style="font-family:monospace; font-weight: bold;">radio</span>  ?<span style="font-family:monospace; font-weight: bold;">name</span>? ?<span style="font-family:monospace; font-weight: bold;">args</span>?</div></div><div style="margin-bottom:1.5ex ; padding .5ex">
								Emits a radiobutton input field
							</div></div></dd></dl></div></div><div class="refsect2"><a name="idm3853"></a><div class="variablelist"><dl class="variablelist"><dt></dt><dd><div style="padding:4 ; margin-top:3 ; margin-bottom:3 ; width:75%"><div class="cmdsynopsis" style="width:80%"><div style="border: 1px solid #282; margin:1ex ; padding:.4ex; padding-left: 0.8ex;   word-spacing:1ex "> <span style="font-family:monospace; font-weight: bold;">color</span>  ?<span style="font-family:monospace; font-weight: bold;">name</span>? ?<span style="font-family:monospace; font-weight: bold;">args</span>?</div></div><div style="margin-bottom:1.5ex ; padding .5ex">
								Emits an HTML 5 "color" form field						
							</div></div></dd></dl></div></div><div class="refsect2"><a name="idm3862"></a><div class="variablelist"><dl class="variablelist"><dt></dt><dd><div style="padding:4 ; margin-top:3 ; margin-bottom:3 ; width:75%"><div class="cmdsynopsis" style="width:80%"><div style="border: 1px solid #282; margin:1ex ; padding:.4ex; padding-left: 0.8ex;   word-spacing:1ex "> <span style="font-family:monospace; font-weight: bold;">date</span>  ?<span style="font-family:monospace; font-weight: bold;">name</span>? ?<span style="font-family:monospace; font-weight: bold;">args</span>?</div></div><div style="margin-bottom:1.5ex ; padding .5ex">
								Emits an HTML 5 "date" form field						
							</div></div></dd></dl></div></div><div class="refsect2"><a name="idm3871"></a><div class="variablelist"><dl class="variablelist"><dt></dt><dd><div style="padding:4 ; margin-top:3 ; margin-bottom:3 ; width:75%"><div class="cmdsynopsis" style="width:80%"><div style="border: 1px solid #282; margin:1ex ; padding:.4ex; padding-left: 0.8ex;   word-spacing:1ex "> <span style="font-family:monospace; font-weight: bold;">datetime</span>  ?<span style="font-family:monospace; font-weight: bold;">name</span>? ?<span style="font-family:monospace; font-weight: bold;">args</span>?</div></div><div style="margin-bottom:1.5ex ; padding .5ex">
								Emits an HTML 5 "datetime" form field						
							</div></div></dd></dl></div></div><div class="refsect2"><a name="idm3880"></a><div class="variablelist"><dl class="variablelist"><dt></dt><dd><div style="padding:4 ; margin-top:3 ; margin-bottom:3 ; width:75%"><div class="cmdsynopsis" style="width:80%"><div style="border: 1px solid #282; margin:1ex ; padding:.4ex; padding-left: 0.8ex;   word-spacing:1ex "> <span style="font-family:monospace; font-weight: bold;">datetime_local</span>  ?<span style="font-family:monospace; font-weight: bold;">name</span>? ?<span style="font-family:monospace; font-weight: bold;">args</span>?</div></div><div style="margin-bottom:1.5ex ; padding .5ex">
								Emits an HTML 5 "datetime_local" form field						
							</div></div></dd></dl></div></div><div class="refsect2"><a name="idm3889"></a><div class="variablelist"><dl class="variablelist"><dt></dt><dd><div style="padding:4 ; margin-top:3 ; margin-bottom:3 ; width:75%"><div class="cmdsynopsis" style="width:80%"><div style="border: 1px solid #282; margin:1ex ; padding:.4ex; padding-left: 0.8ex;   word-spacing:1ex "> <span style="font-family:monospace; font-weight: bold;">email</span>  ?<span style="font-family:monospace; font-weight: bold;">name</span>? ?<span style="font-family:monospace; font-weight: bold;">args</span>?</div></div><div style="margin-bottom:1.5ex ; padding .5ex">
								Emits an HTML 5 "email" form field						
							</div></div></dd></dl></div></div><div class="refsect2"><a name="idm3898"></a><div class="variablelist"><dl class="variablelist"><dt></dt><dd><div style="padding:4 ; margin-top:3 ; margin-bottom:3 ; width:75%"><div class="cmdsynopsis" style="width:80%"><div style="border: 1px solid #282; margin:1ex ; padding:.4ex; padding-left: 0.8ex;   word-spacing:1ex "> <span style="font-family:monospace; font-weight: bold;">file</span>  ?<span style="font-family:monospace; font-weight: bold;">name</span>? ?<span style="font-family:monospace; font-weight: bold;">args</span>?</div></div><div style="margin-bottom:1.5ex ; padding .5ex">
								Emits an HTML 5 "file" form field						
							</div></div></dd></dl></div></div><div class="refsect2"><a name="idm3907"></a><div class="variablelist"><dl class="variablelist"><dt></dt><dd><div style="padding:4 ; margin-top:3 ; margin-bottom:3 ; width:75%"><div class="cmdsynopsis" style="width:80%"><div style="border: 1px solid #282; margin:1ex ; padding:.4ex; padding-left: 0.8ex;   word-spacing:1ex "> <span style="font-family:monospace; font-weight: bold;">month</span>  ?<span style="font-family:monospace; font-weight: bold;">name</span>? ?<span style="font-family:monospace; font-weight: bold;">args</span>?</div></div><div style="margin-bottom:1.5ex ; padding .5ex">
								Emits an HTML 5 "month" form field						
							</div></div></dd></dl></div></div><div class="refsect2"><a name="idm3916"></a><div class="variablelist"><dl class="variablelist"><dt></dt><dd><div style="padding:4 ; margin-top:3 ; margin-bottom:3 ; width:75%"><div class="cmdsynopsis" style="width:80%"><div style="border: 1px solid #282; margin:1ex ; padding:.4ex; padding-left: 0.8ex;   word-spacing:1ex "> <span style="font-family:monospace; font-weight: bold;">number</span>  ?<span style="font-family:monospace; font-weight: bold;">name</span>? ?<span style="font-family:monospace; font-weight: bold;">args</span>?</div></div><div style="margin-bottom:1.5ex ; padding .5ex">
								Emits an HTML 5 "number" form field						
							</div></div></dd></dl></div></div><div class="refsect2"><a name="idm3925"></a><div class="variablelist"><dl class="variablelist"><dt></dt><dd><div style="padding:4 ; margin-top:3 ; margin-bottom:3 ; width:75%"><div class="cmdsynopsis" style="width:80%"><div style="border: 1px solid #282; margin:1ex ; padding:.4ex; padding-left: 0.8ex;   word-spacing:1ex "> <span style="font-family:monospace; font-weight: bold;">range</span>  ?<span style="font-family:monospace; font-weight: bold;">name</span>? ?<span style="font-family:monospace; font-weight: bold;">args</span>?</div></div><div style="margin-bottom:1.5ex ; padding .5ex">
								Emits an HTML 5 "range" form field						
							</div></div></dd></dl></div></div><div class="refsect2"><a name="idm3934"></a><div class="variablelist"><dl class="variablelist"><dt></dt><dd><div style="padding:4 ; margin-top:3 ; margin-bottom:3 ; width:75%"><div class="cmdsynopsis" style="width:80%"><div style="border: 1px solid #282; margin:1ex ; padding:.4ex; padding-left: 0.8ex;   word-spacing:1ex "> <span style="font-family:monospace; font-weight: bold;">search</span>  ?<span style="font-family:monospace; font-weight: bold;">name</span>? ?<span style="font-family:monospace; font-weight: bold;">args</span>?</div></div><div style="margin-bottom:1.5ex ; padding .5ex">
								Emits an HTML 5 "search" form field						
							</div></div></dd></dl></div></div><div class="refsect2"><a name="idm3943"></a><div class="variablelist"><dl class="variablelist"><dt></dt><dd><div style="padding:4 ; margin-top:3 ; margin-bottom:3 ; width:75%"><div class="cmdsynopsis" style="width:80%"><div style="border: 1px solid #282; margin:1ex ; padding:.4ex; padding-left: 0.8ex;   word-spacing:1ex "> <span style="font-family:monospace; font-weight: bold;">tel</span>  ?<span style="font-family:monospace; font-weight: bold;">name</span>? ?<span style="font-family:monospace; font-weight: bold;">args</span>?</div></div><div style="margin-bottom:1.5ex ; padding .5ex">
								Emits an HTML 5 "tel" form field						
							</div></div></dd></dl></div></div><div class="refsect2"><a name="idm3952"></a><div class="variablelist"><dl class="variablelist"><dt></dt><dd><div style="padding:4 ; margin-top:3 ; margin-bottom:3 ; width:75%"><div class="cmdsynopsis" style="width:80%"><div style="border: 1px solid #282; margin:1ex ; padding:.4ex; padding-left: 0.8ex;   word-spacing:1ex "> <span style="font-family:monospace; font-weight: bold;">time</span>  ?<span style="font-family:monospace; font-weight: bold;">name</span>? ?<span style="font-family:monospace; font-weight: bold;">args</span>?</div></div><div style="margin-bottom:1.5ex ; padding .5ex">
								Emits an HTML 5 "time" form field						
							</div></div></dd></dl></div></div><div class="refsect2"><a name="idm3961"></a><div class="variablelist"><dl class="variablelist"><dt></dt><dd><div style="padding:4 ; margin-top:3 ; margin-bottom:3 ; width:75%"><div class="cmdsynopsis" style="width:80%"><div style="border: 1px solid #282; margin:1ex ; padding:.4ex; padding-left: 0.8ex;   word-spacing:1ex "> <span style="font-family:monospace; font-weight: bold;">url</span>  ?<span style="font-family:monospace; font-weight: bold;">name</span>? ?<span style="font-family:monospace; font-weight: bold;">args</span>?</div></div><div style="margin-bottom:1.5ex ; padding .5ex">
								Emits an HTML 5 "url" form field						
							</div></div></dd></dl></div></div><div class="refsect2"><a name="idm3970"></a><div class="variablelist"><dl class="variablelist"><dt></dt><dd><div style="padding:4 ; margin-top:3 ; margin-bottom:3 ; width:75%"><div class="cmdsynopsis" style="width:80%"><div style="border: 1px solid #282; margin:1ex ; padding:.4ex; padding-left: 0.8ex;   word-spacing:1ex "> <span style="font-family:monospace; font-weight: bold;">week</span>  ?<span style="font-family:monospace; font-weight: bold;">name</span>? ?<span style="font-family:monospace; font-weight: bold;">args</span>?</div></div><div style="margin-bottom:1.5ex ; padding .5ex">
								Emits an HTML 5 "week" form field						
							</div></div></dd></dl></div></div></div></div><div class="navfooter"><hr><table width="100%" summary="Navigation footer"><tr><td width="40%" align="left"><a accesskey="p" href="form.html"><img src="images/prev.png" alt="Prev"></a> </td><td width="20%" align="center"><a accesskey="u" href="form.html"><img src="images/up.png" alt="Up"></a></td><td width="40%" align="right"> <a accesskey="n" href="calendar_package.html"><img src="images/next.png" alt="Next"></a></td></tr><tr><td width="40%" align="left" valign="top">Form: An HTML Form Fields Generation Utility </td><td width="20%" align="center"><a accesskey="h" href="index.html"><img src="images/home.png" alt="Home"></a></td><td width="40%" align="right" valign="top"> Calendar Package</td></tr></table></div></body></html>