root/trunk/examples/templates/example_parser_attributes.fhtml

Revision 117, 2.1 kB (checked in by argh, 4 years ago)

Massive update of the examples collection; added the patExampleGen examples framework; commented all examples; reworked all the templates...

  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
Line 
1 <patForms:Form name="foo">
2
3 <div class="piFrame">
4     <div class="piTitle">Area login</div>
5     <div class="piContent">
6        
7         <div class="piAbstract">
8             Please provide your credentials here to log into an area of your choice.
9         </div>
10        
11         <table border="0" cellpadding="2" cellspacing="0">
12             <tr>
13                 <td>Username</td>
14                 <td>
15                     <table cellpadding="0" cellspacing="0" border="0">
16                         <tr>
17                             <td><patForms:String name="username" required="yes" description="Please enter your name here" size="8" maxlength="8" accesskey="U" /></td>
18                             <td>&nbsp;Password&nbsp;</td>
19                             <td>
20                                 <!--
21                                     You can set any attribute of a tag via the patForms:attribute tag,
22                                     and you can easily mix the two. This comes in handy for ex. if you
23                                     generate the markup automatically...
24                                 -->
25                                 <patForms:String name="password" accesskey="P">
26                                     <patForms:Attribute name="type">password</patForms:Attribute>
27                                     <patForms:Attribute name="required">yes</patForms:Attribute>
28                                     <patForms:Attribute name="size">6</patForms:Attribute>
29                                     <patForms:Attribute name="maxlength">6</patForms:Attribute>
30                                 </patForms:String>
31                             </td>
32                             <td>&nbsp;Area&nbsp;</td>
33                             <td>
34                                 <!--
35                                     Even the values of an enum/set/switch element can be set via the
36                                     patForms:attribute tag, as you can see... In this case, it does
37                                     not make much sense, as it would have worked as easily without
38                                     it, but we're trying to make a point here :)
39                                 -->
40                                 <patForms:Enum name="area" required="yes">
41                                     <patForms:Attribute name="values">
42                                         <patForms:Option value="" label="Please select an area..."/>
43                                         <patForms:Option value="1" label="Secluded area"/>
44                                         <patForms:Option value="2">Hidden area</patForms:Option>
45                                         <patForms:Option value="3">Secret area</patForms:Option>
46                                         <patForms:Option value="4">Immaterial area</patForms:Option>
47                                     </patForms:Attribute>
48                                 </patForms:Enum>
49                             </td>
50                         </tr>
51                     </table>
52                 </td>
53             </tr>
54         </table>
55     </div>
56 </div>
57
58 <input type="submit" name="save" value="Save" accesskey="S" />
59
60 </patForms:Form>
Note: See TracBrowser for help on using the browser.