|
Cookbook /
FoxValidationExamplesSummary: examples for using Fox input validation
Version: 2008-03-06
Prerequisites: PmWiki 2.2.0 beta, Fox
Status: new
Maintainer: HansB
Categories: Uncategorized
Questions answered by this recipeHow do I create a form which uses input validation? Examples for Fox form validationExample 1 %red%(:foxmessage form1 ptvupdate=1 list=nocheck:) (:fox form1 template=Site.FoxTemplates#example :) (:foxcheck target match='Test*' msg="pagename needs to begin with: Test":) (:foxcheck date regex='[12]\d\d\d-(0\d|1[0-2])-([0-2]\d|3[01])' msg='please enter date as YYYY-MM-DD':) (:foxcheck time regex='([0-1]\d|2[0-3]):[0-5]\d' msg='enter time as HH:MM using 24 hour format':) (:foxcheck author msg='please sign as author!':) Page: (:input text target:) %red%(:foxmessage form1 target:)%%\\ Date: (:input text date:) %red%(:foxmessage form1 date:)%%\\ Time: (:input text time:) %red%(:foxmessage form1 time:)%%\\ Author: (:input text author:) %red%(:foxmessage form1 author:)%%\\ (:input submit post Enter:) (:foxend form1:) NotesRelease Notes
See AlsoContributorsComments |