Page edit controls
This feature also defines a number of custom types for implementing page edit controls. These are (more are forthcoming):
(:input e_form:)
(:input e_text rows=n cols=n:)
(:input e_save:)
(:input e_saveedit:)
(:input e_cancel:)
(:e_preview:)
(:input e_minor:)
(:input e_author:)
However, they only display as controls when viewed with ?action=edit
.
Thus, an edit page could be formatted with something like:
Custom input controls
This feature also allows wiki administrators to design custom input controls through the $InputTags array. Documentation of this feature will be forthcoming.
See for a custom input tag for instance: Test.JumpBox .
Example: Input text box which clears a value set when clicked (using script with onfocus event):
Add to your local config file:
# input text box will keep initial value, unless name contains '-clear'
$InputTags['text'][':html'] = "<input type='text' \$InputFormArgs
onfocus=\"if(this.name.indexOf('-clear')!=-1) this.value=''\" />";
Now if you want an input textbox, which will be cleared when clicking it, add to the name '-clear', like:
(:input text box1-clear "Value will clear":)
Or alternatively add to local config:
# input text box will clear initial value, unless name contains '-fix'
$InputTags['text'][':html'] = "<input type='text' \$InputFormArgs
onfocus=\"if(this.name.indexOf('-fix')==-1) this.value=''\" />";
Now any textbox will clear when clicked, unless its name contains '-fix', like:
(:input text box2-fix "Value will stay":)
Don't do this, instead use (:input text name placeholder="Value will stay":)
. A placeholder will appear when the field is empty, and doesn't require JavaScript. --Petko June 06, 2024, at 04:17 AM
(:input auth_form:)
When someone hits "Save" on a page, we don't want to lose their edits so, any variables that are posted as part of the save get preserved in the AuthForm, so that when they send the password it's just like they were re-posting the page
This is used in Site.AuthForm . Basically it's <form action='{$_SERVER['REQUEST_URI']}'
method='post'
name='authform'>\$PostVars
where $PostVars
is a sequence of <input type='hidden'
name='...'
value='...'
/>
tags that encode whatever was posted when the auth_form was generated. Essentially $PostVars
takes the contents of $_POST
and submits them as part of the auth form.
So, here's a dropdown list of pages in the Test group:
(:if false:)
[[#dropdownlist]]
(:input select name=n {=$FullName} "{=$Name}":)
[[#dropdownlistend]]
(:ifend:)
(:pagelist fmt=#dropdownlist group=Test:)
00962 01295 01300 12Over4 2003Titlespaced 2006-01-01 20060308 20070402-Draft 20070417 20070417-Draft 20070809 20070809-AnotherTest 20070905 20071019-SomeHybridPageName 20071107 20080806 20090110 20090701 20090702 20090703 20090704 20110502 2016Skin 4tildes 50AllRecentChanges Abc2 AbcMusic Abilità Accented Accented-Talk Accentued AccessKeyToEdit AccessKeyToEdit-Draft AccueilTest AdaptSkinTable AddLinkBookmarklet AdjacentImages AdminConference2007-05-11 AdvancedTable AdvTable AlignColumn AllowPassword AlternativeViewProposal AmanitaPantherina Ampersand AmpersandTitle AmpersandTitle2 Anchor AnchorInclude AnchorInclude1 AnchorInclude2 AnchorLinks Anchors AnchorSpacing ARCSNoLocalTimes ArrayFormTest Arrow Attach AttachAttach AttachDelta Attached AttachExample AttachExample2 AttachExist AttachList Attachment AttachWithImage AttachWithSpaces AttachWithText AttrExample AuthConditions AuthHeader AuthList AuthList2 AuthListShort AuthorCookie AuthorLink AuthorRequired AuthPw AuthUser AutoTOC BackgroundImage BackgroundImages Backlink Backlink-aux BackLinkInPTV BackLinks Backlinks Backlinks2 BacklinksAndSecurity BacklinksAndSecurityPrivatePage BacklinksAndSecurityPublicPage Backtick BadDollarVar Banner Bar BaseA BaseB BaseC BaseName BasePageEmbeddedPTVs1 BasePageEmbeddedPTVs2 BasePageEmbeddedPTVs3 BasicAuth BasicEditing BeginningMiddleEnd Ben BensonHedges BGColor BigBigSummary BigEdit BigWithInclude BigWithInclude2 BISyntax BlankLines Block-In-A-Div BlockInclude BlockIncludeTest BlockIncludeTest2 Blocks BoldOrderedList Book BooklikeParagraphs Bookmarklet BorderColorImg Box1 BoxCode Bridge Bridge2 BrowserCondition BrowseTrail BugOrFeature BugWithInclude1 BugWithInclude2 Button BWSS BWSSMeeting Calendar CamelCasedLinks Captcha CategoryPV CategoryReferences CategoryRequired CategoryTestPageWithoutLink CategoryUploadDummy CategoryUploadsDummy CategoryUploadsDummy2 CCLicense CellCenter CenteredBlock CenteredInterMapImage CenterHeading CFrame CharMarkupInTitle CheckBoxArray Chess ChessMarkup ChopTitle Christian Cjc Codeblock CodeTest ColorByDate ColumnLists ColumnPageList ColumnSpanning CommandPrompt Commentary CommentFormat Comments CommentsTargets CondAuth CondAuthLocked CondAuthNotLocked CondExists CondExists2 CondExtend ConditionAction ConditionalStatementsAndVerticalSpace Conditions ConditionTest Confluence ContentTemplate ConvertAccentedChars CookbookColumned CookbookList CookbookSideBar CopyPasteCalendar CopyPasteCalendar2 CopyPasteCalendar3 CopyPasteCalendar4 CorePLMT CorePLMT2 Count CountFmt CountGlyphs CreatedFile CreatedMarkup CreateLinkTests CreateTime CreatingNewPages Creole Creole-Sandbox CrossGroupTrail CSS CSSClearProperty CSSMarkup CssMarkup2 CSSPopups CtimeCookbookList Danger DataVars DateConditional DateMgtAndConditionals DateRange DaveG DaveG-PTV DC DC-Draft DefinitionLists Definitions Definitions2 DeletedPage DeletedPageList DemoPage Description DescriptionT Details DevelMarkup Diff2 DiffAuthor DigitalInit DirectiveAndText DirectiveAndText2 DisableMarkup DisplaysInLists Divend DivMarkup DivMarkupBug Divs DivTemp DMarkup DocToUTF8 DocumentationXref DOI DollarInComment DotInProfiles DoubleDiv DoubleSave DraftRestore DraftRestore2 DropDown DropDown-Draft DublinCore DuplicateMailPosts DynamicImage EachCount EasyGallery EasyGalleryPic1 EasyGalleryPic2 EasyGalleryPic3 EasyGalleryPic4 EasyGalleryPic5 EasyGalleryPic6 EasyGalleryTemplate EditConditional1 EditConditional2 Editform EditForm Editform-edit EditForm2 EditForm3 EditForm4 EditFormWrapDiv EditFromPmwiki-mode-Draft EditNoLeft Editor EditPreview EditPreviewForm EditQuickReference EditRedirect EmptyCategory EmptyLink EmptyList EmptyPage EmptyTargets Enabled EnableHTML EnablePageTitlePriority Equality EscapedLinks EscapedLinks-Draft Events EX ExcelPaste ExoticSectionNames ExprBug ExtendMarkup ExternalLinkWithLineContinuation ExtractList ExtractListFailure FAQ FAQClassic FAQTemp FileList FileManagers FileMarkup FileUrls FilmScript Flash Float Float2 FloatBreak FloatDiff FloatHistory FloatingColumns FloatingImage FloatLeftInItem FlowplayerAccess FmtCount FontStyles Foo FormatingBugs FormListTemplate FormPTVTest Forms ForumForm ForumList ForumTemplate FPLByGroup FPLCount FPLMySimple FPLTemplate Fractions Frame FrameCenter Frames FrameWikistyle FromHomePage Ftime FtimeGerman FtimeInPagelist FtimeLocale FTimeMarkup FullScreenPage FunWithTables FutureTOC GeminiThemes GeminiThemes1 GeminiThemes2 GeminiThemes3 Gimg GlobalVarSubstitutions GoogleChart GoogleSearch GroupAttributes GroupHeader GroupHome GroupListing GroupOnlySyntax GroupTitle GroupTitles GroupTrail GUIButtons HardPageBreak HashOnPageName HasPreformattedLine HeadingAnchor HeadingAndPre HeadingNoTitle HeadingsWithText1 HeadingsWithText2 HeadingsWithText3 HeadingsWithText4 HeadingsWithText5 HiddenLink Highlight-Cyrillic HighlightAction HighlightRows Hojdare HolaMundo HomeList HomePage HomePageLink Html HTMLCache HTMLStyleFmtOverride HTMLValidationWithIncludes HTMLValidationWithIncludes-help1 HTMLValidationWithIncludes-help2 HttpVariables-cg Höjdare IfAuthTest IfDate IfElseIf IfIndented IfLink IfMarkupTime IfMarkupTime2 IfMarkupTime3 IfNested Image ImageBorder ImageBorders ImageCaption ImageFloat ImageFrameTest ImageHeightWidth ImageLines ImageLink ImageLinkHTTPS ImageMarginTest ImageNameWithSpaces Images ImagesTemp ImageTable ImageTest ImageThumbLink ImageThumbLink-Img1 ImageThumbLink-Img2 Include Include2 IncludeAll IncludeAndAnchor IncludeBugA IncludeBugB IncludeBugWithLabel IncludeBugWithLabelSrc IncludeCategory IncludeCategorySource IncludeData IncludedPage IncludedSection IncludedStyleDefinitionInCamelCase IncludeFromComment IncludeFromOther IncludeFromSelf IncludeFromSelfPage IncludeFromSelfPage2 IncludeLength IncludeLength2 IncludeLinebreaksPage IncludeLines IncludeLinksTest IncludeLinksTest2 IncludeManyPages IncludeOneLine IncludeOneLineSrc IncludeOtherPages IncludeRedirect IncludeRedirectB IncludeRestOfPage IncludeSamePage IncludeSelf IncludeTest IncludeTest1 IncludeTest2 IncludeVariable IncludeVariable2 IncludeVars IncludeVars2 IncludeVarTest IncludeVarTestBase IncludeWithBasepage IncludeWithoutNewline IncludeWithPTV IncludeWithPTV2 IncludeWithPTVTemplate IncludeWithPV IncludeWithPVTest IncludeWithVariable IncludingPage IncorrectIndentation Indent IndentParas Indents IndentStyle Index IndexOf Infobox InlcudeTemplate InlineBreaks InlinePageList InlinePHP InlineStyle InputDefault InputDefault2 InputDefaults InputDefaultSelect InputElementTitle InputForSelectingPage InputSelect InputSelectData InputSelectJiri InputSelectNestingSource InputTextareaDefault Insert InterMap InterMapLinks InternationalAuthor InvalidEditSummary ItalicsInTitle ItemListWithHorizontalSpace ItemListWithSpecialStyling JSFeed JsMath JumpBox JumpTop Justify JustText KeepKeep KeepMarkup Keywords Kmarie LargePage LastModified LastModifiedHost LatestNews Latestnews-Draft Layers Layout LB LeftBar LightSkinEditPage LinebreakLink Linebreaks LinebreaksAndWhitespacePre LineContinutation1 LinesWithSpaces Link2 LinkAndNonBreakingSpace LinkHTMLOutput LinkInPTV LinkMarkupClass LinksToSomePage LinksWithDash LinkTarget LinkTest LinkTitle LinkTitles LinkToGroup ListBasicAudiencePages ListCategoryMatchingTwoCategories ListId ListMainPages ListPagesWithoutACategory Lists LocalCSS Localization LockedPage Login Logout LongCodeLine LongLinkText LongListItems Ma MacIE52ScreenShots Macron MailForm MailtoLink MalformedPagelist ManuallySetEnumeratedLists Map Markup MarkupCharacters MarkupExpr MarkupExpressions MarkupExprPlus MarkupExprPlusAnomalies Markups MarkupTricks Math122-200702 MaxPostSize MaxPTVTest MbMX MediaViewerTestWithPageTextVars MediaViewerTestWithPageTextVarsTest MediaWiki MenuBar MetaKeywords Metaphors MissingCSS MobileFirstPrinciple ModuleGuidelines-Old Monospace MonospaceWordWrap MoreStyles MultiLang MultilineList MultiLinePageTextVariables MultilinePTVs MultipleLinePTV MultiUrl MyTest Mz NameISOWeek NarrowContent NestedInclude NestedInclude1 NestedInclude2 NestedInclude3 NestedPTV1 NestedPTV2 NestedVars NestTableAndDiv NewCleanUrlsRecipe NewDefSkinMod Newline NewPageBox NewRecentChanges News NextEventAnchor NoAction NoBold NoChars NoEditLinks NoFlash Nofollow NoFooter NoFooterPage NoHeaderPage NoHostLogging NoLeft NoLeftPage NoNestTest NonExistentTitles NonTrailPage NonTrailPage2 NoQuest NoRightPage NoSummaryPages Note Notebook-NT-Skin Notebook-NT-Skin-LeftFloat Notify NumArticles NumberedLists NumericPassword ObsoleteSkinList OldAl OneLinePagelist OneLineTemplate OnlinePresence OnTrail Opacity Orongorongo OSM OutlineTest Overflow P Page-name-with-hyphens PageCount PageExists PageIndex Pagelist PageList2 PageListA PagelistAcrossGroups PageListAnchors PageListB PagelistBug1 PagelistByCategory PagelistByCategory-cg PageListCache PageListCalls PageListCount PagelistCount PagelistDateError PagelistDefaults PagelistDescriptionFormat PagelistExample PageListFmt PageListFmtGroup PagelistFmtGroupsWithLinksToListPage PageListGrouping PageListIf PageListIf2 PagelistIfMx PagelistIfMx1 PagelistIfMx2 PagelistIfMx3 PagelistIfOntrail PageListJoinLine PageListLastModified PageListLink PagelistLink PageListLinks PageListLinkWithPtv1 PageListLinkWithPtv2 PageListLinkWithPtv3 PageListLinkWithPtv4 PageListLinkWithPtv5 PagelistOfPagelists PageListOptions PageListOrderingWithPgVar PagelistParameterVariables PageListRecent PagelistRecentChanges PageListRecursionLink PageListRecursionTrail PageListSelf PagelistServerError PagelistSortName PageListSortPTV PagelistSortVariable PageListTemplate PagelistTemplateRequest PageListTemplates PagelistTemplateSamples PageListTest PageListTime PageListTitles PageListTItleSpaced PageListTrail PageListTrail2 PageListTrail3 PageListTrailNot PageListVariableNone PageListWithPgVar PageListWithPgVar1 PageListWithPgVar2 PagelistWithUndefinedFormat PageName PageNameCases Pagenamecases2 PageNameWithPmWikiInIt PageNotFound PageNäme PagesInPmWikiGroupWithRedirect PagesLastModifiedByYou PageSource PageTextVariables PageTrailDepth PageUrlVar PageUrlVarInclude PageVariable PageVariable-Talk PageVariableInPageList PageVarSelection PageWithEntity PagewithOnlyPagelist PageWithTeaser Paragraph ParagraphFloats ParagraphInList ParaIndent ParseArgs PasswdList Password PasswordAndEmacs PasswordProtectedPage PData Pdf PeterKernSWiki PitsFormCheckVersionInput PITSList PL PLC PLTVarOption PmCal PmCal-Examples PmCal-Examples2 PmSlide PmSyntax PmSyntax-ChordPro PmSyntax-MermaidJS PmSyntaxHighlighting PMWiki PmWiki Podcast PopUp PopUpTrimmed PostStopWatch PreAndEscape PreCssHack PreFmtNotWorking Preform Preform2 Preform3 Preformat Preformatted PreformattedBlock2 PreformattedText PreformattedTextAndTAB PreOverflow Present PreSpaces PreviewChange PreWithFormatting PreWrap PrintSkin Printtest ProfileBug ProfileList ProfilesMigrationUTF8 Properties ProtectEmail Ptest PTT Ptv PTV PTV-Petko1 PTV-Petko2 PTV-Petko3 PTV-Petko4 PTV-Petko5 PTV-Petko6 PTV-Summary PTV2 PTV3-Draft Ptva PTVandCategory PTVandCategoryLocked PTVarEscape PTVAudience Ptvb PTVbug PTVBulleted PtvDisplay PTVInclude PTVInclude2 PTVinPagelist PtvMaybe PtvMayBe PtvNO PtvNo PtvSome-Times PtvSomeTimes PTVStyle PtvTemplate PTVWithPageList PtvYES PtvYes PurpleCow PWAd PwdEditImpliesRead QandAPageTextVariables QueryString Quicktoc Quienc QuotesInLinks RadioButtons Rand RandomPageList RaphaëlÊtreInouï RatingByAuthor RB05Week14 ReadPass ReadProtected ReallyReallyReallyLongPageName ReallyReallyReallyLongPageName-noItIsReallyExtremelyLong ReallyReallyReallyLongPageNamenoItIsReallyExtremelyLong ReallySimple RecentChanges RecentChangesByDate RedirectAnchor RedirectDestination RedirectFromMenu RedirectRandomPage RedirectToAnotherPage RedirectToGroup RedirectToGroup2 Refresh RelativeLengths RelativeLinksPagelist RelLinks Reqtest ResponsiveSkinBackground ResponsiveSkinMaxWidth RevMarkup Rfloat RightBar RightFloat RightLink Rollover RotateMarkup RowStyling RSSFeedLinks RTL SafeModeGID Sandbox Sandbox-Draft Sandbox2 ScrollTable Search Search2 SearchBox SearchBox2 SearchBoxArgs SearchBoxInclude SearchBoxPageList SearchBoxTrail SearchByTitle SearchCloud SearchForm SearchParamsLeak SearchResults SearchResultsWithCateogory SearchSort SearchTerms SectionEdit Sections SelectPageSpaced SelfTarget ShouldWork SideBar SideBarList Sidenotes SigCount Simple SimplePlaylist SimpleTablesAndPagelists SimpleTalkCommentFmt SimpleViewer SimultaneousEdits SimultaneousEdits1 SiteAdminProposal SiteAllRecentChanges SiteGroupMarkup SiteHomePage SiteMap SkinEditList SkinList SkinMarkup Skins SkinTestAssortment SkinTestBlockMarkups SkinTestCompact SkinTestCompact-2007 SkinTestForms SkinTestHeadings SkinTestImages SkinTestLists SkinTestLongPre SkinTestMenu SkinTestSelectSkin SkinTestTables SkinTestText Skype SlideShow SloveneSearch SmallCaps SomePage SpacedLinks SpacesInMarkups SpacesInSimpleTables SpaceWikiWord SpaceWikiWords Spacing SpanInLink SpecialLinks SpecialReferencesSource SpecialReferencesTarget SquareBracketsInLink SSWB StackedInclude StackedInclude2 StackedInclude3 Stanchor Start StickyNotes StickyNotes1 Sting StmLink Stubs StyleClass StyleInLinkText Superscripts Superscripts-Draft TableAndImage TableBackground TableBorders TableBug TableCellSpace TableDirectives TableHeaders TableInList TableProblem1 TableTest Tabs Tags Template TemplateLast TemplateLinks TemplateListIncomplete TemplateListIncomplete-Talk Templating Terminology Test Test2 Test34 TestCache TestData TestDe TestDirectiveMarkup TestFtime TestGroup Testicus Testjoe123 TestLP Testm TestStyles TestToC TestÄöü Text TextArea TextareaFontTest TextTransform TextVars ThickBox Title TitleInc TitleInc2 TitleLinkWithQuery Titlespaced2004-05-08 TitleTest Tjolahoppsan TmpFeed TmplDisplay TOC1 ToolTip Tooltips Top10NotRecentlyModified Topic1 TopNav Trail Trail-crossgroup Trail3 TrailFromPagelist TrailIndex TrailPage1 TrailPage2 TrailPage3 TrailPage4 TrailPath TriadSkinItalicTextBug TuringCaptcha Umlauts UmlautUploads UploadForm Uploading UploadSimpleForm UploadsQuickReference URL UrlApprovals UrlError UrlParens UrlsWithDates UrlWithQuotes UserAndLevel UseTable UsingTabForPreformattedText UTF8RTL VariablesAndFriends VerticalSpace VerticalSpacing1 VeryLongHeading VeryLongLinkText ViewDiff VoteOnFirstLastMarkup VoteOnLeadingWhitespace VoteOnLeadingWhitespace-Talk VoteOnNestedDivMarkup VoteOnNestedDivMarkup-Talk VoteOnSiteHeader VoteOnSiteHeader-Talk Voting Vspace Weird Whitespace WhitespaceRules WidthAttr WikiDefines WikiSandbox WikiStyle WikiStyleClass WikiStyleDefines WikiStyleInCamelCase WikiStylePercent WikiStyleRED WikiStyleRight WikiStyles WikiStylesInlists WikiStyleToTheEnd WikiSystémy-Draft Wikitest WikiTrail WikiTrail1 WikiTrail2 WikiTrail3 WikiTrail4 WikiTrail5 WikiTrail6 WikiTrail7 WikiTrailPagelist WikiTrails WikiTrailsDraft WikiWord WikiWord2 WikiWord3 WikiWordCount WikiWordsAndStyles WildcardLinkSyntax Wildcards WildcardSlash WindowsFileUrls Withattrib2 WithHtml Word-Break WordLinks WordWrap Wrap WSExtra WSIndent WSIndent2 WSIndent3 WSPlusCode WTF2 XLPageUpdate XMLTest XMLTest2 XYTrail XYTrail1 XYTrail2 XYTrail3 XYTrail4 XYTrail5 XYTrail6 ZAPMcode ZipExport ß Ōrongorongo Пренасочване ТестНаКирилица
A group page navigator:
>>comment<<
[[#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:)
>><<
(:pagelist fmt=#navigator group=Test:)
00962 01295 01300 12Over4 2003Titlespaced 2006-01-01 20060308 20070402-Draft 20070417 20070417-Draft 20070809 20070809-AnotherTest 20070905 20071019-SomeHybridPageName 20071107 20080806 20090110 20090701 20090702 20090703 20090704 20110502 2016Skin 4tildes 50AllRecentChanges Abc2 AbcMusic Abilità Accented Accented-Talk Accentued AccessKeyToEdit AccessKeyToEdit-Draft AccueilTest AdaptSkinTable AddLinkBookmarklet AdjacentImages AdminConference2007-05-11 AdvancedTable AdvTable AlignColumn AllowPassword AlternativeViewProposal AmanitaPantherina Ampersand AmpersandTitle AmpersandTitle2 Anchor AnchorInclude AnchorInclude1 AnchorInclude2 AnchorLinks Anchors AnchorSpacing ARCSNoLocalTimes ArrayFormTest Arrow Attach AttachAttach AttachDelta Attached AttachExample AttachExample2 AttachExist AttachList Attachment AttachWithImage AttachWithSpaces AttachWithText AttrExample AuthConditions AuthHeader AuthList AuthList2 AuthListShort AuthorCookie AuthorLink AuthorRequired AuthPw AuthUser AutoTOC BackgroundImage BackgroundImages Backlink Backlink-aux BackLinkInPTV BackLinks Backlinks Backlinks2 BacklinksAndSecurity BacklinksAndSecurityPrivatePage BacklinksAndSecurityPublicPage Backtick BadDollarVar Banner Bar BaseA BaseB BaseC BaseName BasePageEmbeddedPTVs1 BasePageEmbeddedPTVs2 BasePageEmbeddedPTVs3 BasicAuth BasicEditing BeginningMiddleEnd Ben BensonHedges BGColor BigBigSummary BigEdit BigWithInclude BigWithInclude2 BISyntax BlankLines Block-In-A-Div BlockInclude BlockIncludeTest BlockIncludeTest2 Blocks BoldOrderedList Book BooklikeParagraphs Bookmarklet BorderColorImg Box1 BoxCode Bridge Bridge2 BrowserCondition BrowseTrail BugOrFeature BugWithInclude1 BugWithInclude2 Button BWSS BWSSMeeting Calendar CamelCasedLinks Captcha CategoryPV CategoryReferences CategoryRequired CategoryTestPageWithoutLink CategoryUploadDummy CategoryUploadsDummy CategoryUploadsDummy2 CCLicense CellCenter CenteredBlock CenteredInterMapImage CenterHeading CFrame CharMarkupInTitle CheckBoxArray Chess ChessMarkup ChopTitle Christian Cjc Codeblock CodeTest ColorByDate ColumnLists ColumnPageList ColumnSpanning CommandPrompt Commentary CommentFormat Comments CommentsTargets CondAuth CondAuthLocked CondAuthNotLocked CondExists CondExists2 CondExtend ConditionAction ConditionalStatementsAndVerticalSpace Conditions ConditionTest Confluence ContentTemplate ConvertAccentedChars CookbookColumned CookbookList CookbookSideBar CopyPasteCalendar CopyPasteCalendar2 CopyPasteCalendar3 CopyPasteCalendar4 CorePLMT CorePLMT2 Count CountFmt CountGlyphs CreatedFile CreatedMarkup CreateLinkTests CreateTime CreatingNewPages Creole Creole-Sandbox CrossGroupTrail CSS CSSClearProperty CSSMarkup CssMarkup2 CSSPopups CtimeCookbookList Danger DataVars DateConditional DateMgtAndConditionals DateRange DaveG DaveG-PTV DC DC-Draft DefinitionLists Definitions Definitions2 DeletedPage DeletedPageList DemoPage Description DescriptionT Details DevelMarkup Diff2 DiffAuthor DigitalInit DirectiveAndText DirectiveAndText2 DisableMarkup DisplaysInLists Divend DivMarkup DivMarkupBug Divs DivTemp DMarkup DocToUTF8 DocumentationXref DOI DollarInComment DotInProfiles DoubleDiv DoubleSave DraftRestore DraftRestore2 DropDown DropDown-Draft DublinCore DuplicateMailPosts DynamicImage EachCount EasyGallery EasyGalleryPic1 EasyGalleryPic2 EasyGalleryPic3 EasyGalleryPic4 EasyGalleryPic5 EasyGalleryPic6 EasyGalleryTemplate EditConditional1 EditConditional2 Editform EditForm Editform-edit EditForm2 EditForm3 EditForm4 EditFormWrapDiv EditFromPmwiki-mode-Draft EditNoLeft Editor EditPreview EditPreviewForm EditQuickReference EditRedirect EmptyCategory EmptyLink EmptyList EmptyPage EmptyTargets Enabled EnableHTML EnablePageTitlePriority Equality EscapedLinks EscapedLinks-Draft Events EX ExcelPaste ExoticSectionNames ExprBug ExtendMarkup ExternalLinkWithLineContinuation ExtractList ExtractListFailure FAQ FAQClassic FAQTemp FileList FileManagers FileMarkup FileUrls FilmScript Flash Float Float2 FloatBreak FloatDiff FloatHistory FloatingColumns FloatingImage FloatLeftInItem FlowplayerAccess FmtCount FontStyles Foo FormatingBugs FormListTemplate FormPTVTest Forms ForumForm ForumList ForumTemplate FPLByGroup FPLCount FPLMySimple FPLTemplate Fractions Frame FrameCenter Frames FrameWikistyle FromHomePage Ftime FtimeGerman FtimeInPagelist FtimeLocale FTimeMarkup FullScreenPage FunWithTables FutureTOC GeminiThemes GeminiThemes1 GeminiThemes2 GeminiThemes3 Gimg GlobalVarSubstitutions GoogleChart GoogleSearch GroupAttributes GroupHeader GroupHome GroupListing GroupOnlySyntax GroupTitle GroupTitles GroupTrail GUIButtons HardPageBreak HashOnPageName HasPreformattedLine HeadingAnchor HeadingAndPre HeadingNoTitle HeadingsWithText1 HeadingsWithText2 HeadingsWithText3 HeadingsWithText4 HeadingsWithText5 HiddenLink Highlight-Cyrillic HighlightAction HighlightRows Hojdare HolaMundo HomeList HomePage HomePageLink Html HTMLCache HTMLStyleFmtOverride HTMLValidationWithIncludes HTMLValidationWithIncludes-help1 HTMLValidationWithIncludes-help2 HttpVariables-cg Höjdare IfAuthTest IfDate IfElseIf IfIndented IfLink IfMarkupTime IfMarkupTime2 IfMarkupTime3 IfNested Image ImageBorder ImageBorders ImageCaption ImageFloat ImageFrameTest ImageHeightWidth ImageLines ImageLink ImageLinkHTTPS ImageMarginTest ImageNameWithSpaces Images ImagesTemp ImageTable ImageTest ImageThumbLink ImageThumbLink-Img1 ImageThumbLink-Img2 Include Include2 IncludeAll IncludeAndAnchor IncludeBugA IncludeBugB IncludeBugWithLabel IncludeBugWithLabelSrc IncludeCategory IncludeCategorySource IncludeData IncludedPage IncludedSection IncludedStyleDefinitionInCamelCase IncludeFromComment IncludeFromOther IncludeFromSelf IncludeFromSelfPage IncludeFromSelfPage2 IncludeLength IncludeLength2 IncludeLinebreaksPage IncludeLines IncludeLinksTest IncludeLinksTest2 IncludeManyPages IncludeOneLine IncludeOneLineSrc IncludeOtherPages IncludeRedirect IncludeRedirectB IncludeRestOfPage IncludeSamePage IncludeSelf IncludeTest IncludeTest1 IncludeTest2 IncludeVariable IncludeVariable2 IncludeVars IncludeVars2 IncludeVarTest IncludeVarTestBase IncludeWithBasepage IncludeWithoutNewline IncludeWithPTV IncludeWithPTV2 IncludeWithPTVTemplate IncludeWithPV IncludeWithPVTest IncludeWithVariable IncludingPage IncorrectIndentation Indent IndentParas Indents IndentStyle Index IndexOf Infobox InlcudeTemplate InlineBreaks InlinePageList InlinePHP InlineStyle InputDefault InputDefault2 InputDefaults InputDefaultSelect InputElementTitle InputForSelectingPage InputSelect InputSelectData InputSelectJiri InputSelectNestingSource InputTextareaDefault Insert InterMap InterMapLinks InternationalAuthor InvalidEditSummary ItalicsInTitle ItemListWithHorizontalSpace ItemListWithSpecialStyling JSFeed JsMath JumpBox JumpTop Justify JustText KeepKeep KeepMarkup Keywords Kmarie LargePage LastModified LastModifiedHost LatestNews Latestnews-Draft Layers Layout LB LeftBar LightSkinEditPage LinebreakLink Linebreaks LinebreaksAndWhitespacePre LineContinutation1 LinesWithSpaces Link2 LinkAndNonBreakingSpace LinkHTMLOutput LinkInPTV LinkMarkupClass LinksToSomePage LinksWithDash LinkTarget LinkTest LinkTitle LinkTitles LinkToGroup ListBasicAudiencePages ListCategoryMatchingTwoCategories ListId ListMainPages ListPagesWithoutACategory Lists LocalCSS Localization LockedPage Login Logout LongCodeLine LongLinkText LongListItems Ma MacIE52ScreenShots Macron MailForm MailtoLink MalformedPagelist ManuallySetEnumeratedLists Map Markup MarkupCharacters MarkupExpr MarkupExpressions MarkupExprPlus MarkupExprPlusAnomalies Markups MarkupTricks Math122-200702 MaxPostSize MaxPTVTest MbMX MediaViewerTestWithPageTextVars MediaViewerTestWithPageTextVarsTest MediaWiki MenuBar MetaKeywords Metaphors MissingCSS MobileFirstPrinciple ModuleGuidelines-Old Monospace MonospaceWordWrap MoreStyles MultiLang MultilineList MultiLinePageTextVariables MultilinePTVs MultipleLinePTV MultiUrl MyTest Mz NameISOWeek NarrowContent NestedInclude NestedInclude1 NestedInclude2 NestedInclude3 NestedPTV1 NestedPTV2 NestedVars NestTableAndDiv NewCleanUrlsRecipe NewDefSkinMod Newline NewPageBox NewRecentChanges News NextEventAnchor NoAction NoBold NoChars NoEditLinks NoFlash Nofollow NoFooter NoFooterPage NoHeaderPage NoHostLogging NoLeft NoLeftPage NoNestTest NonExistentTitles NonTrailPage NonTrailPage2 NoQuest NoRightPage NoSummaryPages Note Notebook-NT-Skin Notebook-NT-Skin-LeftFloat Notify NumArticles NumberedLists NumericPassword ObsoleteSkinList OldAl OneLinePagelist OneLineTemplate OnlinePresence OnTrail Opacity Orongorongo OSM OutlineTest Overflow P Page-name-with-hyphens PageCount PageExists PageIndex Pagelist PageList2 PageListA PagelistAcrossGroups PageListAnchors PageListB PagelistBug1 PagelistByCategory PagelistByCategory-cg PageListCache PageListCalls PageListCount PagelistCount PagelistDateError PagelistDefaults PagelistDescriptionFormat PagelistExample PageListFmt PageListFmtGroup PagelistFmtGroupsWithLinksToListPage PageListGrouping PageListIf PageListIf2 PagelistIfMx PagelistIfMx1 PagelistIfMx2 PagelistIfMx3 PagelistIfOntrail PageListJoinLine PageListLastModified PageListLink PagelistLink PageListLinks PageListLinkWithPtv1 PageListLinkWithPtv2 PageListLinkWithPtv3 PageListLinkWithPtv4 PageListLinkWithPtv5 PagelistOfPagelists PageListOptions PageListOrderingWithPgVar PagelistParameterVariables PageListRecent PagelistRecentChanges PageListRecursionLink PageListRecursionTrail PageListSelf PagelistServerError PagelistSortName PageListSortPTV PagelistSortVariable PageListTemplate PagelistTemplateRequest PageListTemplates PagelistTemplateSamples PageListTest PageListTime PageListTitles PageListTItleSpaced PageListTrail PageListTrail2 PageListTrail3 PageListTrailNot PageListVariableNone PageListWithPgVar PageListWithPgVar1 PageListWithPgVar2 PagelistWithUndefinedFormat PageName PageNameCases Pagenamecases2 PageNameWithPmWikiInIt PageNotFound PageNäme PagesInPmWikiGroupWithRedirect PagesLastModifiedByYou PageSource PageTextVariables PageTrailDepth PageUrlVar PageUrlVarInclude PageVariable PageVariable-Talk PageVariableInPageList PageVarSelection PageWithEntity PagewithOnlyPagelist PageWithTeaser Paragraph ParagraphFloats ParagraphInList ParaIndent ParseArgs PasswdList Password PasswordAndEmacs PasswordProtectedPage PData Pdf PeterKernSWiki PitsFormCheckVersionInput PITSList PL PLC PLTVarOption PmCal PmCal-Examples PmCal-Examples2 PmSlide PmSyntax PmSyntax-ChordPro PmSyntax-MermaidJS PmSyntaxHighlighting PMWiki PmWiki Podcast PopUp PopUpTrimmed PostStopWatch PreAndEscape PreCssHack PreFmtNotWorking Preform Preform2 Preform3 Preformat Preformatted PreformattedBlock2 PreformattedText PreformattedTextAndTAB PreOverflow Present PreSpaces PreviewChange PreWithFormatting PreWrap PrintSkin Printtest ProfileBug ProfileList ProfilesMigrationUTF8 Properties ProtectEmail Ptest PTT Ptv PTV PTV-Petko1 PTV-Petko2 PTV-Petko3 PTV-Petko4 PTV-Petko5 PTV-Petko6 PTV-Summary PTV2 PTV3-Draft Ptva PTVandCategory PTVandCategoryLocked PTVarEscape PTVAudience Ptvb PTVbug PTVBulleted PtvDisplay PTVInclude PTVInclude2 PTVinPagelist PtvMaybe PtvMayBe PtvNO PtvNo PtvSome-Times PtvSomeTimes PTVStyle PtvTemplate PTVWithPageList PtvYES PtvYes PurpleCow PWAd PwdEditImpliesRead QandAPageTextVariables QueryString Quicktoc Quienc QuotesInLinks RadioButtons Rand RandomPageList RaphaëlÊtreInouï RatingByAuthor RB05Week14 ReadPass ReadProtected ReallyReallyReallyLongPageName ReallyReallyReallyLongPageName-noItIsReallyExtremelyLong ReallyReallyReallyLongPageNamenoItIsReallyExtremelyLong ReallySimple RecentChanges RecentChangesByDate RedirectAnchor RedirectDestination RedirectFromMenu RedirectRandomPage RedirectToAnotherPage RedirectToGroup RedirectToGroup2 Refresh RelativeLengths RelativeLinksPagelist RelLinks Reqtest ResponsiveSkinBackground ResponsiveSkinMaxWidth RevMarkup Rfloat RightBar RightFloat RightLink Rollover RotateMarkup RowStyling RSSFeedLinks RTL SafeModeGID Sandbox Sandbox-Draft Sandbox2 ScrollTable Search Search2 SearchBox SearchBox2 SearchBoxArgs SearchBoxInclude SearchBoxPageList SearchBoxTrail SearchByTitle SearchCloud SearchForm SearchParamsLeak SearchResults SearchResultsWithCateogory SearchSort SearchTerms SectionEdit Sections SelectPageSpaced SelfTarget ShouldWork SideBar SideBarList Sidenotes SigCount Simple SimplePlaylist SimpleTablesAndPagelists SimpleTalkCommentFmt SimpleViewer SimultaneousEdits SimultaneousEdits1 SiteAdminProposal SiteAllRecentChanges SiteGroupMarkup SiteHomePage SiteMap SkinEditList SkinList SkinMarkup Skins SkinTestAssortment SkinTestBlockMarkups SkinTestCompact SkinTestCompact-2007 SkinTestForms SkinTestHeadings SkinTestImages SkinTestLists SkinTestLongPre SkinTestMenu SkinTestSelectSkin SkinTestTables SkinTestText Skype SlideShow SloveneSearch SmallCaps SomePage SpacedLinks SpacesInMarkups SpacesInSimpleTables SpaceWikiWord SpaceWikiWords Spacing SpanInLink SpecialLinks SpecialReferencesSource SpecialReferencesTarget SquareBracketsInLink SSWB StackedInclude StackedInclude2 StackedInclude3 Stanchor Start StickyNotes StickyNotes1 Sting StmLink Stubs StyleClass StyleInLinkText Superscripts Superscripts-Draft TableAndImage TableBackground TableBorders TableBug TableCellSpace TableDirectives TableHeaders TableInList TableProblem1 TableTest Tabs Tags Template TemplateLast TemplateLinks TemplateListIncomplete TemplateListIncomplete-Talk Templating Terminology Test Test2 Test34 TestCache TestData TestDe TestDirectiveMarkup TestFtime TestGroup Testicus Testjoe123 TestLP Testm TestStyles TestToC TestÄöü Text TextArea TextareaFontTest TextTransform TextVars ThickBox Title TitleInc TitleInc2 TitleLinkWithQuery Titlespaced2004-05-08 TitleTest Tjolahoppsan TmpFeed TmplDisplay TOC1 ToolTip Tooltips Top10NotRecentlyModified Topic1 TopNav Trail Trail-crossgroup Trail3 TrailFromPagelist TrailIndex TrailPage1 TrailPage2 TrailPage3 TrailPage4 TrailPath TriadSkinItalicTextBug TuringCaptcha Umlauts UmlautUploads UploadForm Uploading UploadSimpleForm UploadsQuickReference URL UrlApprovals UrlError UrlParens UrlsWithDates UrlWithQuotes UserAndLevel UseTable UsingTabForPreformattedText UTF8RTL VariablesAndFriends VerticalSpace VerticalSpacing1 VeryLongHeading VeryLongLinkText ViewDiff VoteOnFirstLastMarkup VoteOnLeadingWhitespace VoteOnLeadingWhitespace-Talk VoteOnNestedDivMarkup VoteOnNestedDivMarkup-Talk VoteOnSiteHeader VoteOnSiteHeader-Talk Voting Vspace Weird Whitespace WhitespaceRules WidthAttr WikiDefines WikiSandbox WikiStyle WikiStyleClass WikiStyleDefines WikiStyleInCamelCase WikiStylePercent WikiStyleRED WikiStyleRight WikiStyles WikiStylesInlists WikiStyleToTheEnd WikiSystémy-Draft Wikitest WikiTrail WikiTrail1 WikiTrail2 WikiTrail3 WikiTrail4 WikiTrail5 WikiTrail6 WikiTrail7 WikiTrailPagelist WikiTrails WikiTrailsDraft WikiWord WikiWord2 WikiWord3 WikiWordCount WikiWordsAndStyles WildcardLinkSyntax Wildcards WildcardSlash WindowsFileUrls Withattrib2 WithHtml Word-Break WordLinks WordWrap Wrap WSExtra WSIndent WSIndent2 WSIndent3 WSPlusCode WTF2 XLPageUpdate XMLTest XMLTest2 XYTrail XYTrail1 XYTrail2 XYTrail3 XYTrail4 XYTrail5 XYTrail6 ZAPMcode ZipExport ß Ōrongorongo Пренасочване ТестНаКирилица
In the examples above, setting the name to n ("name=n") will make the form navigate to the page identified in the selected value of the input on submission. If you don't want to navigate to the page, try changing the name to something else.
Comments
Is it possible to fill the dropdown list with the content of a page (where I have written all the options line by line)? A kind of (:include:) but inside the dropdownlist. Such a feature should be nice for long lists! PhilB ? January 29, 2007, at 01:48 AM
What change would be needed in the php script in order to correctly process the "multiple" option in the test1 test2 ? Currently they are listed (thru GET method) as individual name=value1?name=value2 etc and so when the php script processes them it assigns whichever is the last one as the actual value. Thus instead of n values you end up with exactly 1 value, always the last one. The net effect is that form values are not maintained through the submission process. I can figure out how to process it otherwise in php, but I don't know what sort of data structure is being used for that "multiple" option -- is it an array? --Peter Bowers October 28, 2007
Sandbox
Feel free to use the space below to experiment with creating forms.
(:input form vtest :)
(:input select name=test value=1 label=test1:)
(:input select name=test value=2 label=test2:) \\\
(:input text name=comment value="test12":)
(:input radio foo 1 xyz:)
(:input radio foo 2 abc:)
(:input submit:)
(:input end:)
(:Message:
Can a textarea's default value
have a line-break in it?"
:)
(:input defaults source=PmWiki.Forms:)
(:input textarea name=$:Message rows=4:)
Yes! It works now.
How does the textarea above work? you are setting the "name" attribute and it displays in the textarea "content". This makes no sense to me --gnuzoo June 05, 2024, at 11:22 PM
See Cookbook:InputDefault#source . --Petko June 06, 2024, at 03:29 AM
General field attributes (see their counterparts in HTML forms for a more detailed description)
Setting focus=1
causes that field to receive the initial focus when the form is first opened.
Setting readonly=1
causes that field to be displayed but the user cannot change the value
(:input checkbox|radio checked=checked:)
Setting checked=checked
causes that checkbox or radio button to be selected.
(:input select selected=selected:)
Setting selected=selected
causes that option to be selected.
This appears to md5-hash the contents of the field.
This manually sets the id attribute of the field.
Sets the name of the field (see above)
Sets the value of the field. (see above) (For checkboxes, submit buttons, etc this is the value the field will contain if the checkbox is checked or if the button has been pressed. For submit buttons this is also the label displayed on the button.) How does this interact with the (:input defaults:)
? Which "wins"? The "value" wins, "default" applies when no value is set, see Cookbook:InputDefault .
Default is "inputbox" for textbox.
How many rows (lines) the element will occupy (normally used for textarea and select fields)
How many columns are visible (how wide the field appears).
This is largely analogous to cols=n
The contents of the field will be limited to this maximum number of characters.
I believe this is only on the (:input action={$PageUrl} ...:)
specification...? And so probably doesn't belong here?
I believe this is only on the (:input form method=GET:)
...? And so probably doesn't belong here?
A control key which can be pressed to go to that field. For instance, accesskey=u allows a user to press ALT-U (in windows) to select that item.
Allows the order of the fields (when traversing with tab or shift-tab) to be manually specified.
Allows multiple items to be selected in a SELECT field
Indicates that this checkbox (or radio button) is selected
The field will be greyed-out in some manner and the user will be unable to modify the value in any way.
The user will be unable to modify the value in any way.
An alternate text that will be displayed if the browser cannot properly render the field. Also used for accessibility in some cases.
Checkboxes for updating PTVs
Checkboxes only send a value if checked, whereas they send just nothing when not checked. So, there is no way to update/zero an already set value just by unchecking a checkbox. There is an easy and well-working hack though:
More on the matter on this short thread .
Luigi 21 December 2014
Is there any syntax to generate <button> tag?
I want to generate buttons like this , is it possible in any way?
Finar September 06, 2019, at 11:28 AM
No, you need to add a custom markup , something like this:
Markup('(:btn:)', 'inline',
'/\\(:btn(.*?):\\)(.*?)\\(:endbtn:\\)/', 'MyFmtButton');
function MyFmtButton($m) {
return "<button ".PQA($m[1]).">{$m[2]}</button>";
}
Then in the page, use
(:btn class="btn btn-primary btn-sm" disabled=disabled data-role="something" title="Tooltip title":)Label(:endbtn:)
--Petko September 06, 2019, at 03:54 PM
Q: Is there any possibility to send the form action to a target="_blank"?
I already tried (:input form "https://…" post target="_blank":)
but that's not the way.
Matthias D ? May 06, 2020, at 09:22 AM
Only if you don't use Cookbook:PmForm which uses "target" for something different. Add to config.php
:
function CustomInputAttrs(){
global $InputAttrs;
$InputAttrs[] = "target";
}
$PostConfig['CustomInputAttrs'] = 400;
I'll think how to make both compatible -- probably deprecate the PmForm "target" attribute for something else, to allow regular forms to use it. --Petko May 07, 2020, at 05:38 PM
Couldn't believe it working, because it never ever didn't look like :-) but it does wonderfully 👍 Perfekt! Thanks! 🙋🏻♂ Matthias D ? May 07, 2020, at 07:24 PM
Is there a way to put it in a checkbox (i.e. user option)?, e.g.:(:input checkbox target "_blank" ...:)
- Frank March 29, 2022, at 04:57 PM
It is not possible to change the target attribute of a <form> element with only a checkbox. However, it may be possible to add a JavaScript function that observes the checkbox and adds or removes the attribute when the the checkbox changes state. --Petko March 30, 2022, at 03:20 PM
Thanks for the tip. In case anyone else is interested, this works for me:
function newwin() {
var x = document.getElementById("form-id");
var y = document.getElementById("checkbox-id");
if (y.checked === true) { x.setAttribute("target", "_blank"); }
else { x.setAttribute("target", ""); }
};
In the checkbox string: onchange="newwin();"
- Frank March 30, 2022, at 07:23 PM