InputSelect


This page is testing the new (:input select ... :) markup in forms, as well as testing the ability to retain values across form submissions.

We'll start with (:input select ...:). The basic form of a select box is a sequence of options:


(:input form:)
(:input select name=abc value=1:)
(:input select name=abc value=2:)
(:input select name=abc value=3:)
(:input submit:)
(:input end:)

To have options with labels different from the value of the control, use the label=option:

(:input form:)
(:input select name=abc value=1 label=alpha :)
(:input select name=abc value=2 label=beta  :)
(:input select name=abc value=3 label=gamma :)
(:input submit:)
(:input end:)

Or, the values can be specified positionally:

(:input select name=abc 1 alpha :)
(:input select name=abc 2 beta  :)
(:input select name=abc 3 gamma :)

We can specify the size of the selection box:

(:input select name=abc 1 alpha size=3 :)
(:input select name=abc 2 beta  :)
(:input select name=abc 3 gamma :)

The "multiple" option works:

(:input select name=abc 1 alpha size=3 multiple:)
(:input select name=abc 2 beta  :)
(:input select name=abc 3 gamma :)

So, here's a dropdown list of pages in the Test group:

(:if false:)
[[#dropdownlist]]
(:input select name=n {=$FullName} "{=$Name}":)
[[#dropdownlistend]]
(:if:)

(:pagelist fmt=#dropdownlist group=Test:)

A group page navigator:

>>display=none<<[@
[[#navigator]]
(:if equal {=$FullName} {*$FullName}:)
(:input select name=n  selected=selected {=$FullName} "{=$Name}":)
(:if ! equal {=$FullName} {*$FullName}:)
(:input select name=n {=$FullName} "{=$Name}":)
[[#navigatorend]]
@](:nl:)>><<

(:comment pagelist fmt=#navigator group=Test:)
[[#navigator]]
(:if equal {=$FullName} {*$FullName}:)
(:input select name=n  selected=selected {=$FullName} "{=$Name}":)
(:if ! equal {=$FullName} {*$FullName}:)
(:input select name=n {=$FullName} "{=$Name}":)
[[#navigatorend]]
 0: 00.00 00.00 config start
 1: 00.01 00.01 config end
 2: 00.11 00.11 MarkupToHTML begin
 3: 00.11 00.11 MarkupToHTML begin
 4: 00.12 00.11 MarkupToHTML end
 5: 00.12 00.11 MarkupToHTML begin
 6: 00.12 00.12 MarkupToHTML end
 7: 00.12 00.12 MarkupToHTML begin
 8: 00.12 00.12 MarkupToHTML end
 9: 00.12 00.12 MarkupToHTML begin
10: 00.13 00.12 MarkupToHTML end
11: 00.13 00.12 MarkupToHTML begin
12: 00.13 00.12 MarkupToHTML end
13: 00.13 00.12 MarkupToHTML begin
14: 00.13 00.12 FPLTemplate: Chain begin
15: 00.13 00.12 FPLTemplate: FPLTemplateLoad
16: 00.13 00.12 FPLTemplate: FPLTemplateDefaults
17: 00.13 00.12 FPLTemplate: FPLTemplatePageList
18: 00.13 00.12 MakePageList pre
19: 00.13 00.12 PageListSources begin
20: 00.13 00.12 PageStore::ls begin wiki.d/{$FullName}
21: 00.14 00.12 PageStore::ls merge wiki.d/{$FullName}
22: 00.14 00.13 PageStore::ls end wiki.d/{$FullName}
23: 00.14 00.13 PageStore::ls begin $FarmD/wikilib.d/{$FullName}
24: 00.14 00.13 PageStore::ls merge $FarmD/wikilib.d/{$FullName}
25: 00.14 00.13 PageStore::ls end $FarmD/wikilib.d/{$FullName}
26: 00.14 00.13 PageListSources end count=1109
27: 00.14 00.13 PageListSort pre ret=4 order=name
28: 00.14 00.13 MakePageList items count=1109, filters=
29: 00.14 00.13 MakePageList post count=1109, readc=0
30: 00.14 00.13 PageListSort begin
31: 00.14 00.13 PageListSort sort
32: 00.15 00.14 PageListSort end
33: 00.15 00.14 MakePageList end
34: 00.15 00.14 FPLTemplate: FPLTemplatePmWikiOrg
35: 00.15 00.14 MarkupToHTML begin
36: 00.15 00.14 MarkupToHTML end
37: 00.15 00.14 FPLTemplate: FPLTemplateSliceList
38: 00.15 00.14 FPLTemplate: FPLTemplateFormat
39: 00.21 00.19 MarkupToHTML begin
40: 00.30 00.28 MarkupToHTML end
41: 00.30 00.28 FPLTemplate: FPLTemplatePmWikiOrgPostFormat
42: 00.30 00.28 FPLTemplate: Chain end
43: 00.30 00.28 MarkupToHTML end
44: 00.30 00.28 MarkupToHTML begin
45: 00.30 00.28 MarkupToHTML end
46: 00.31 00.29 MarkupToHTML end
47: 00.31 00.29 MarkupToHTML begin
48: 00.32 00.29 ReadApprovedUrls SiteAdmin.ApprovedUrls begin
49: 00.32 00.30 ReadApprovedUrls SiteAdmin.ApprovedUrls end
50: 00.32 00.30 MarkupToHTML end
51: 00.32 00.30 MarkupToHTML begin
52: 00.33 00.31 MarkupToHTML end
53: 00.33 00.31 now
Peak memory: 4,385,744 bytes