|
Cookbook /
FormsPlusSummary: Form extensions adding new HTML5 input types
Version: 2011-02-22
Prerequisites:
Status: new
Maintainer: HansB
Discussion: FormsPlus-Talk?
Download: formsplus.phpΔ
DescriptionForm markup extensions adding new input types 'date', 'datetime', 'datetime-local', 'time', 'week', 'month', 'number', 'email', 'url', 'tel', 'search', 'color', 'range', as well as 'frame' = 'fieldset', 'frameend' = 'fieldsetend', 'label'. InstallationDownload formsplus.phpΔ, copy to cookbook folder, and add to config.php: include_once('cookbook/formsplus.php');
ConfigurationNo further configuration required. New form input markup types are now available. UsageUse new input types like the default PmWiki input types within the Example:
(:input form id="dummy" action="" method="post":)
(:input frame legend="Sample form with new HTML5 controls":)
(:input label date1 "date:":)
(:input date id="date1" name="date1" value="{(ftime %F now)}":)
(:input label time1 "time:":)
(:input time id="time1" name="time1" value="{(ftime %H:%M now)}":)
(:input label email1 "email:":)
(:input email id="email1" name="email1" value="name@example.org":)
(:input label url1 "url:":)
(:input url id="url1" name="url1" value="http://example.org/":)
(:input label tel1 "tel:":)
(:input tel id="tel1" name="tel1" value="0123456789":)
(:input label number1 "number:":)
(:input number id="number1" name="number1" value="123":)
(:input label range1 "range:":)
(:input range id="range1" value="50" min="0" max="100" step="1" :)
(:input label color1 "color:":)
(:input color id="color1" name="color1" value="#abcdef":)
(:input submit value="Submit":)
(:input reset value="Reset":)
(:input frameend:)
(:input end:)
Notes'frame' (='fieldset') and 'label' is widely supported. Change log / Release notes
See also
ContributorsCommentsSee discussion at FormsPlus-Talk? User notes? : If you use, used or reviewed this recipe, you can add your name. These statistics appear in the Cookbook listings and will help newcomers browsing through the wiki. |