From b0acb866dc6ac494b839182b90e29ce2bec07248 Mon Sep 17 00:00:00 2001 From: petko Date: Thu, 21 Mar 2024 12:42:26 +0000 Subject: Documentation update. git-svn-id: svn://pmwiki.org/pmwiki/trunk@4673 524c5546-5005-0410-9a3e-e25e191bd360 --- wikilib.d/PmWiki.ChangeLog | 10 +++++----- wikilib.d/PmWiki.IncludeOtherPages | 10 +++++----- 2 files changed, 10 insertions(+), 10 deletions(-) (limited to 'wikilib.d') diff --git a/wikilib.d/PmWiki.ChangeLog b/wikilib.d/PmWiki.ChangeLog index 20c8282b..d64450a8 100644 --- a/wikilib.d/PmWiki.ChangeLog +++ b/wikilib.d/PmWiki.ChangeLog @@ -1,9 +1,9 @@ version=pmwiki-2.3.31 ordered=1 urlencoded=1 author=Petko charset=UTF-8 -csum=Lock AllRecentChanges in case of concurrent uploads (+55) +csum=FileSizeCompact() allow for base 1000 (PITS:01499). (+54) name=PmWiki.ChangeLog -rev=1831 -targets=Cookbook.RecentChanges,PmWiki.MailingLists,PmWiki.UploadVariables,PmWiki.OtherVariables,PmWiki.LayoutVariables,PITS.01498,PmWiki.EditVariables,PmWiki.WikiStyles,PITS.01497,Cookbook.DarkColorScheme,PmWiki.LinkVariables,Cookbook.PmSyntax-Talk,PmWiki.Notify,PITS.01431,PITS.01495,PITS.01493,PmWiki.PagelistVariables,PITS.01494,Cookbook.FuseEdit,PmWiki.BasicVariables,PmWiki.SecurityVariables,PITS.01488,PITS.01489,Cookbook.SectionEdit,PITS.01486,PITS.01297,PITS.01485,Cookbook.EditHelp,PITS.01484,PITS.01208,PITS.01483,PITS.01480,PmWiki.PageVariables,PITS.01478,PITS.01477,Cookbook.PmSyntax,Cookbook.CustomSyntax,PITS.01418,PITS.00447,PITS.01475,PITS.00908,PITS.01095,PmWiki.ChangeLogArchive -text=(:Summary: Log of changes made to PmWiki by [[Release(Notes)]]:)\%0aSee [[Cookbook:RecentChanges | the cookbook recent changes page]] for additional updates and activity by other developers, or join the [[PmWiki (/) mailing lists]] to discuss feature development with us.%0a%0a(:Prerelease:Changes made to the [[PmWiki:Subversion | subversion pre-release]] of PmWiki. You can get \%0a[[https://www.pmwiki.org/pub/pmwiki-devel/pmwiki-latest-svn.zip|a full ZIP archive]] of the nightly version, or \%0a[[https://www.pmwiki.org/pub/pmwiki-devel/pmwiki-nightly.zip|a partial export]] with only the files changed since {$Version}.:)\%0a{$:xPrerelease}%0a%0a* Dark theme: add toggleImages(), add $ImgDarkSuffix, $FmtV['$PathUpload']. Restore light styles and pictures for printing.%0a* Responsive skin: white background when printing, move dark toggle label styles into skin.css.%0a* PmSyntax: only apply dark theme colors on screen (not print).%0a* Add upload extensions and image extension patterns AVIF, AVIFS.%0a* Lock AllRecentChanges in case of concurrent uploads.%0a[[#svn-revision-4670]]%0a* Update documentation.%0a%0a!!! Version 2.3.31 (2024-02-23) [[#v2331]]%0a* Add $EnableDarkThemeToggle, enable 3-way theme toggle, "Light", "Dark" and "Auto", add annotation tooltip showing the current theme on tap and on mouse over.%0a* Refactor config data passed to pmwiki-utils.php, refactor dark toggle functions into a separate script. %0a* Responsive skin add body attributes for group and page name, update dark theme, enable auto theme (browser preferences) by default.%0a* PmSyntax improve dark theme thanks to a script by Said Achmiz; expose color properties for reuse.%0a* Refactor redirect quiet (PITS:01498).%0a* Page attributes passwords form: allow for +addition and -removal of passwords, users, groups.%0a* Allow $EditTemplatesFmt entries to apply to specific pages with name= specification (suggested by Simon).%0a* Forms add attribute "form".%0a* Refactor $PostConfig to allow called functions to update it.%0a* Update RecipeCheck to also list skins, suggested by Simon.%0a* Refactor PrintFmt, add $EnablePrePrintFmt.%0a* [[WikiStyles]] add 'columns'.%0a* When Highlight.js is enabled, Vardoc links will be the same color as variables in highlighted code blocks.%0a* Refactor $EnableUploadVersions.%0a* Update documentation.%0a%0a!!! Version 2.3.30 (2024-01-22) [[#v2330]]%0a* Add prototype for dark theme toggle. See PITS:01497 and Cookbook:DarkColorScheme.%0a** PmWiki-responsive skin converted CSS colors to variables, added dark theme styles.%0a** Add skins/pmwiki/pmwiki-32.svg, enable default for $PageLogoUrl.%0a** PmSyntax added dark theme styles.%0a* $EnableUploadMimeMatch with Fileinfo not enabled to deny uploads.%0a* upload.php fix warning for PHP 8.%0a* RecipeCheck use https, suggested by Simon.%0a* PrintDiff() add $since argument.%0a* Add $EnableRedirectQuiet = 2. Prevent infinite redirect loops.%0a* Fix Attach: links with escaped path and filename.%0a* Improved readability for inline diffs in page history.%0a* Forms enable input e_author not only for action=edit, fix unquoted positional form action URL.%0a* Update documentation.%0a%0a!!! Version 2.3.29 (2023-12-18) [[#v2329]]%0a* Fix urlapprove.php for PHP 8.2. %0a* PmSyntax textarea remove styles for width, height (Cookbook:PmSyntax-Talk), allow for fractional dimensions of the highlighted area.%0a* $MarkupDirectiveFunctions allow dashes in attribute names.%0a* Update documentation.%0a%0a!!! Version 2.3.28 (2023-11-27) [[#v2328]]%0a* Add input ''month'' and ''color'' fields.%0a* Add $NotifyRelatedTrailFmt.%0a* Reverse simpletable row backgrounds when there is a thead element.%0a* Fix pmwiki-utils.js when window.localStorage is disabled.%0a* UrlApprovals allow https: URLs if the http: URL for the same domain has been approved (PITS:01431).%0a* Update documentation.%0a%0a!!! Version 2.3.27 (2023-10-23) [[#v2327]]%0a* When merging last edit, if there is no change summary, reuse the last one. %0a* Keep unknown date/time formats for undefined timezone (PITS:01495).%0a* DiffRenderSource() fix for PHP 8, keep ins/del tags on the same line.%0a* The ".diffmarkup" element now has the style "white-space: pre-wrap".%0a* Add new keyword shortcuts Ctrl+B (bold), Ctrl+I (italic), Ctrl+K (link/unlink).%0a* Update documentation.%0a%0a%0a!!! Version 2.3.26 (2023-09-28) [[#v2326]]%0a* Add configurable $InputLabelFmt snippet (PITS:01493).%0a* Add configurable $TrailFmt snippets.%0a* Add $EnableSearchAtLeastOneTerm, default disabled.%0a* Unset upload extensions if size for the extension is set to 0.%0a* Update feeds.php for PHP 8.2 (PITS:01494).%0a* Update documentation.%0a%0a%0a!!! Version 2.3.25 (2023-07-29) [[#v2325]]%0a* Updates for PHP 8.2.%0a* Fix pagelist when 2+ directives on the same line, reported by Simon.%0a* Fix possible bug with internal group(header|footer) directives caused by PRR().%0a* Update documentation.%0a%0a%0a!!! Version 2.3.24 (2023-06-06) [[#v2324]]%0a* Add $EnableUploadMimeMatch.%0a* Add $EnableMergeLastMinorEdit, edit functions MergeLastMinorEdit (based on Cookbook:FuseEdit), SaveChangeSummary (refactored out of HandleEdit).%0a* Fix LogoutCookies() doesn't use a $pagename argument.%0a* PmForm add condition 'validemail' for use in template require.%0a* Add $PmCryptAlgo, pmcrypt() to call password_verify() if it exists. %0a* Refactor HandleDownload() split ServeDownload($filepath, $upname).%0a* Add InsertEditFunction($newfn, $where='%3cPostPage').%0a* Add $AuthFormRespCode.%0a* Add $EnableDownloadRanges, default 1.%0a* When the token is expired, reopen edit form rather than abort.%0a* LocalTimes add $EnableRCListLastEdit.%0a* Update documentation.%0a%0a!!! Version 2.3.23 (2023-05-03) [[#v2323]]%0a* Refactor pmtoken() to use session tokens, enable for core actions.%0a* Add %25pmhlt%25[@(:input pmtoken:)@] helper.%0a* PmForm add $PmFormEnablePmToken.%0a* Refactor @@HandleLogoutA()@@ split @@LogoutCookies()@@. %0a* Fix PRCB() for PHP %3c 7.4.%0a* Update documentation.%0a%0a!!! Version 2.3.22 (2023-04-06) [[#v2322]]%0a* Add scripts/pmform.php, Site.PmFormTemplates.%0a* FmtDateTimeZ() can now accept Unix timestamps.%0a* Pagelists fix bug with multiple category=+A,+B entries.%0a* Update for PHP 8.1 (PITS:01488).%0a* MarkupDirectiveFunctions will now cast numeric arguments to floats.%0a* Prevent errors in custom PageVariables from generating internal server errors (PITS:01489).%0a* Improve inline diff for rare cases (end of page).%0a* Forms/buttons with @@data-pmconfirm="Question"@@ will ask the question before they are submitted.%0a* Update documentation.%0a%0a%0a!!! Version 2.3.21 (2023-03-06) [[#v2321]]%0a* Add $IsPmArchive, $PmArchiveDir.%0a* Sortable tables with %3ctime datetime=""> elements can be sorted by the datetime attribute. Fix for tables with preexisting %3cthead> element.%0a* Updates for PHP8.%0a* Add CSV upload extension.%0a* LocalTimes add mode=3 to show old dates as MM'YY.%0a* Fix bug with multiline $MarkupDirectiveFunctions, reported by Antti Tikanmäki.%0a* Add $EnableCopyCode and Copy code button to %3cpre> blocks, suggested by Alex Doré.%0a* Update PmTOC to work better with Cookbook:SectionEdit.%0a* Update documentation.%0a%0a!!! Version 2.3.20 (2023-02-12) [[#v2320]]%0a* Fix undefined variable warning, reported by Gregor Klarič.%0a%0a!!! Version 2.3.19 (2023-02-11) [[#v2319]]%0a* Only set cookie params if headers not sent. %0a* Update for PHP8.2, reported by Dfaure. PageVar() update for PHP 8.%0a* Add variable $DiffPrepareInlineFunction.%0a* PageListCache() remove unused global $PageIndexFile.%0a* Add configurable $LocalCSSDir, $LocalCSSDirUrl.%0a* DownloadUrl() add $FmtV['$LinkDownload'] with current or future download link.%0a* Add pm_recode() helper function (based on PageStore::recodefn), check for more transcode options.%0a* HandleBrowse() add $FmtV['$PageSourceText'].%0a* Add helper function KeepBlock().%0a* Add $FarmPubDirPrefix, pm_servefile(), $ServeFileExts.%0a* Update documentation.%0a%0a!!! Version 2.3.18 (2023-01-15) [[#v2318]]%0a* Refactor scripts/utils.php, add pm_json_encode() (PITS:01486).%0a* EditAutoText() fix for lines ending with multiple backslashes.%0a* PmSyntax optimize/refactor for large pages (cont.), fix inline escaped texts could ignore line markups, add EnableStopwatch.%0a* Notify fix typo in regular expression.%0a* {-Add $EnableUploadVersions >=10 to rename base.ext to base-1.ext, base-2.ext,...-} ''Redesigned in 2.3.31''%0a* CondAuth() fix bug with global $AuthList.%0a* Add helper function PRCB() for simpler preg_replace_callback passing variables.%0a* Update scripts/refcount.php for PHP 8, reported by George Murray.%0a* Add PageVariable $PageLogoUrl (PITS:01297).%0a* Update documentation.%0a%0a!!! Version 2.3.17 (2022-12-17) [[#v2317]]%0a* WikiStyles trim class names (PITS:01485).%0a* GUIEditButtons refactor to enable Undo in textarea; allow for custom functions to configure mopen, mclose, and unselect for their buttons.%0a* [[Cookbook:EditHelp|EditHelp]] refactor to allow undo; add shortcuts Ctrl+L convert selection to lowercase, Ctrl+Shift+L to uppercase, Ctrl+Shift+ArrowUp and ArrowDown to swap lines.%0a* Skip upgrade check if $EnableReadOnly.%0a* Fix bug with multiple $MarkupDirectiveFunctions.%0a* Add $EnableBaseNameConfig.%0a* PmSyntax optimize for larger pages (cont.).%0a* Input password add class "inputbox" like the other fields.%0a* CondAuth() added way to check for usergroup permissions.%0a* Update in pagelist.php for PHP 8.%0a* Documentation update.%0a%0a!!! Version 2.3.16 (2022-11-28) [[#v2316]]%0a* Class PPRC add generic callbacks.%0a* IncludeText() update for PHP 8, reported by V.Krishn.%0a* WikiStyle add 'overflow', 'notoc'.%0a* Add PmNonce().%0a* PmTOC update indented link style->classname. %0a* Responsive skin: replace %25pmhlt%25[@[[%3c%3c]]@] with %25hlt html%25[@%3cbr class='clearboth' />@], update PmTOC styles.%0a* $EnableListIncludedPages use class name instead of style. %0a* guiedit.js remove unneeded style.%0a* PmSyntax realign font for nested programming languages in the edit form, optimize for large pages.%0a* Only call session_status() if function exists.%0a* Edit form remove unsafe-inline script.%0a* Revert WikiStyleToClassName(), PrePrintFmt() -- need more work (PITS:01484).%0a* Documentation update.%0a%0a!!! Version 2.3.15 (2022-11-21) [[#v2315]]%0a* CSS pre, code relative/scalable font-size (pmwiki-responsive skin).%0a* PmSyntax add variable --pmsyntax-fontsize-editform and split from --pmsyntax-fontsize [[https://www.pmichaud.com/pipermail/pmwiki-users/2022-November/064936.html|#]].%0a* PmSyntax fix [@[[Highlight]]@] label font size and family (reported by Hans).%0a* Add variable $CookieSameSite default to 'Lax'%0a* Add argument $samesite to pmsetcookie(), default to $CookieSameSite, refactor for old and new PHP versions. %0a* Add function pm_session_start() respecting local configuration.%0a* CSP header add base-uri=self; object-src 'none'.%0a* Add $HTTPHeaders['XSSP'] = 'X-XSS-Protection: 1; mode=block'.%0a* Rewrite GUIButtons logic to avoid unsafe-inline JavaScript.%0a* Refactor WikiStyles, replace inline styles with class names to avoid unsafe-inline CSS.%0a* Refactor PQA(), tables, cells, to replace inline style="..." with class names to avoid unsafe-inline CSS.%0a* Add PrePrintFmt(), refactor PrintFmt(), PrintSkin() to process wiki pages, skin parts, and skin functions to HTML before outputting headers.%0a* Fix XSS vulnerability.%0a* Documentation update.%0a%0a!!! Version 2.3.14 (2022-11-03) [[#v2314]]%0a* Searchbox also escape custom field names.%0a* Prevent double-encoded entities in searchbox (reported by Simon).%0a* Trim $Author (PITS:01208).%0a* Replace autofocus inline JavaScript with attributes.%0a* Edit form: the label next to the "Minor edit" checkbox now toggles the checkbox.%0a* PmSyntax recognize %25pmhlt%25[@(:template requires? ...:)@].%0a* Update for PHP 8. %0a* Obsolete PCCF() from PHP 7.2 not 8.0.%0a* Add array $ObsoleteMarkups, function TraceMarkup(), update Markup(), Markup_e() and ObsoleteMarkup(), to retrieve and show files and line numbers for obsolete/disabled markup rules.%0a* Fix bug with PSFT format %25L.%0a* Update documentation.%0a%0a!!! Version 2.3.13 (2022-10-07) [[#v2313]]%0a* Close potential XSS vulnerability, reported by lukystreik (PITS:01483).%0a* Refactor $MultiFactorAuthFunction, add $FailedLoginsFunction.%0a* Update documentation.%0a%0a!!! Version 2.3.12 (2022-09-25) [[#v2312]]%0a* Stripmagic() cast null to "" and other fixes for PHP 8.%0a* Fix parse error for complex conditionals with empty variables (PITS:01480).%0a* PSFT() and MarkupExpression [@ftime@] add %25L as human readable local timestamp. %0a* MarkupRestore() fix wrong cast to empty string of false-ish values.%0a* PrintAuthForm() split from PmWikiAuth(). %0a* Fix warning for unneeded session_regenerate_id() (reported by George Murray).%0a* Update documentation.%0a%0a!!! Version 2.3.11 (2022-08-30) [[#v2311]]%0a* Add [[PageVariables]] %25pmhlt%25 [@{$GroupHomePage}@], [@{$GroupHomePageName}@], [@{$GroupHomePageTitle}@], [@{$GroupHomePageTitlespaced}@].%0a* Add $MarkupDirectiveFunctions.%0a* Fix stripmagic() for arrays recently broke after PHP8 update.%0a* Update documentation.%0a%0a!!! Version 2.3.10 (2022-08-20) [[#v2310]]%0a* Update for PHP 8.1 (reported by Armin Bühler).%0a* Forms will now prefill wildcard variables from $DefaultUnsetPageTextVars or $DefaultEmptyPageTextVars.%0a* $EnablePmSyntax = 3; will enable syntax highlighting in the edit form by default, without the user clicking on "Highlight". Fix occasional text mis-alignment between the text area and the highlighted block.%0a* Update documentation.%0a%0a!!! Version 2.3.9 (2022-08-18) [[#v239]]%0a* Add non-wildcard $DefaultUnsetPageTextVars to %25pmhlt%25[@(:input default:)@] (reported by Johnny).%0a* PmSyntax handles new selectors pre.pmhlt, code.pmhlt.%0a* Update for PHP 8 (PITS:01478).%0a* Update documentation.%0a%0a%0a!!! Version 2.3.8 (2022-07-22) [[#v238]]%0a* PmSyntax fix for 2 different %25pmhlt%25 [@%25hlt%25@] on the same line (reported by Simon).%0a* Fix broken include when the first page doesn't exist.%0a* Update documentation.%0a%0a!!! Version 2.3.7 (2022-06-28) [[#v237]]%0a* $HTTPHeaders add X-Frame-Options (suggested by Imagine Dragon) and Content-Security-Policy to disallow embedding in external websites by default.%0a* $EnableHighlight will now remember any links to PmWiki variables and restore them after the highlighting, see [[thread->https://www.pmwiki.org/pipermail/pmwiki-users/2022-June/064887.html]].%0a* $EnablePmSyntax will now process %25pmhlt%25[@%25hlt pmwiki%25@] in addition to [@%25pmhlt%25@] blocks, and escaped markup after it will be tentatively highlighted.%0a* Update documentation.%0a%0a!!! Version 2.3.6 (2022-06-19) [[#v236]]%0a* Fixes for PHP 8.%0a* Add form attribute "lang".%0a* Sortable tables allow for table headers to have markup such as bold (except links). It will now use a case-insensitive natural ordering.%0a* Allow for $UploadVerifyFunction to modify $upname.%0a* Add variable $PageIndexTermsFunction.%0a* Searchbox allow for removal of submit button if [@label=""@]; add default [@placeholder="$[Search]"@].%0a* Fix author.php may be included before some variables are defined, reported by Said Achmiz.%0a* $EnableHighlight convert code blocks to plain text, see [[thread->https://www.pmwiki.org/pipermail/pmwiki-users/2022-June/064887.html]].%0a* Documentation update.%0a%0a%0a!!! Version 2.3.5 (2022-05-23) [[#v235]]%0a* Fix broken list=grouphomes (PITS:01477).%0a* Add DisableSkinParts() helper function for recipes.%0a* HandlePostUpload: add @@$FmtV["$filepath"]@@ and @@$FmtV["$upurl"]@@ with the file path and direct URL to the newly uploaded file.%0a* In pmwiki-utils.js, replace forgotten ''let'' with ''var'' (suggested by SteP).%0a* Update for PHP 8.1.%0a* Update documentation.%0a%0a!!! Version 2.3.4 (2022-04-22) [[#v234]]%0a* Fixes for PHP 8 warnings, reported by Siegfried Seibert.%0a* Update documentation.%0a%0a!!! Version 2.3.3 (2022-03-26) [[#v233]]%0a* Fix for PHP 8 warnings, reported by Jean-Patrick Charrey, Dominique Faure and Siegfried Seibert.%0a* Update README.txt and docs/ files, suggested by Simon Davis.%0a* Update documentation.%0a%0a!!! Version 2.3.2 (2022-02-09) [[#v232]]%0a* Allow for $EnableLocalTimes to define custom duration of the pulled page history.%0a* Rename variable $EnableIncludedPages to $EnableListIncludedPages (avoid ambiguity).%0a* Remove $LinkAlt when an embedded picture without an alternative text fails to load.%0a* PmSyntax:%0a** Allow for line breaks \\ inside headings, tables, list items (like the core).%0a** Parallel processing of multiple blocks.%0a* Add scripts/utils.php; move loading of pmwiki-utils.js and PmSyntax to scripts/utils.js.%0a** Add $EnablePmUtils, default enabled.%0a** Parallel processing of the pmwiki-utils.js utility functions.%0a** Move pmwiki-utils.js move to $HTMLHeaderFmt (often prevents page redraw with the TOC/PmToggle/LocalTimes).%0a* Fix bug causing invalid page name when the name is "Group.0".%0a* Fix PHP 8.1.2 warnings, reported by Jürgen Godau and Dominique Faure.%0a* LocaltTimes fix "rcnew" classes for wikis with the older format.%0a* Update documentation.%0a%0a!!! Version 2.3.1 (2022-01-15) [[#v231]]%0a%0a* Fix the release script which broke the $VersionNum variable and the [@[[#anchor]]@] markup with the PmWiki-responsive skin.%0a%0a!!! Version 2.3.0 (2022-01-15) [[#v230]]%0a* Add PmSyntax, $EnablePmSyntax, $CustomSyntax, [@{$EnabledIMap}@], see Cookbook:PmSyntax, Cookbook:CustomSyntax.%0a* [@(:markup:)@] can now have @@class=norender@@ to only show the source code without processing it.%0a* Updates for PHP 8.1, hide warnings, add PSFT() replacement for strftime() and 2 callbacks, $EnableFTimeNew, update core function calls, add [@%25o@] for the ordinal suffix of the date (PITS:01418).%0a* Notify: @@tz=@@ (timezone) per-user.%0a* PageList add category= argument (PITS:00447, PITS:01475); link= and category= now accept multiple pages, wildcards, and negations (PITS:00908).%0a* [=[[!Category]]=] links can have alternative text (PITS:01095).%0a* Simplify/optimize pmwiki-utils.js when using datasets, simplify sorting of table rows without cloning, add LocalTimes().%0a* Page history diff anchors to also have "id=" attributes in addition to "name=".%0a* Add $EnableLocalTimes (default disabled) and styles, add HandleDiffList().%0a* Add markup %25pmhlt%25[@@2022-01-09T08:35:00Z@]%25%25 output as %3ctime>; localized if $EnableLocalTimes.%0a** Add $CurrentLocalTime in the above format, used by default in $RecentChangesFmt.%0a* Add $EnableRecentUploads (only Site.AllRecentChanges, only if $RecentUploadsFmt not defined).%0a* PmTOC update CSS for properly indented subheadings.%0a* Edit form $EnableIncludedPages, add placeholders to e_changesummary and e_author. Enable $EnableNotSavedWarning, add to sample-config.php. EditHelp to behave more like a word processor, typing "Enter" twice without writing text removes the preceding bullet.%0a* Responsive skin details>summary:hover {color:navy, cursor: pointer;}.%0a* PrintDiff() add classes for the delay between edits: diffday, diffweek, diffmonth, diffyear.%0a* Add helper function @@DownloadUrl($pagename, $path)@@ moved from @@LinkUpload()@@.%0a* Add [=$[ULby]=] i18n string 'uploaded by'.%0a* Update documentation.%0a%0a!!! [[#older]] Older versions%0a[[(PmWiki:)ChangeLog Archive]] - changes prior to version 2.3.0.%0a -time=1709786123 +rev=1832 +targets=Cookbook.RecentChanges,PmWiki.MailingLists,PmWiki.UploadVariables,PmWiki.OtherVariables,PITS.01499,PmWiki.LayoutVariables,PITS.01498,PmWiki.EditVariables,PmWiki.WikiStyles,PITS.01497,Cookbook.DarkColorScheme,PmWiki.LinkVariables,Cookbook.PmSyntax-Talk,PmWiki.Notify,PITS.01431,PITS.01495,PITS.01493,PmWiki.PagelistVariables,PITS.01494,Cookbook.FuseEdit,PmWiki.BasicVariables,PmWiki.SecurityVariables,PITS.01488,PITS.01489,Cookbook.SectionEdit,PITS.01486,PITS.01297,PITS.01485,Cookbook.EditHelp,PITS.01484,PITS.01208,PITS.01483,PITS.01480,PmWiki.PageVariables,PITS.01478,PITS.01477,Cookbook.PmSyntax,Cookbook.CustomSyntax,PITS.01418,PITS.00447,PITS.01475,PITS.00908,PITS.01095,PmWiki.ChangeLogArchive +text=(:Summary: Log of changes made to PmWiki by [[Release(Notes)]]:)\%0aSee [[Cookbook:RecentChanges | the cookbook recent changes page]] for additional updates and activity by other developers, or join the [[PmWiki (/) mailing lists]] to discuss feature development with us.%0a%0a(:Prerelease:Changes made to the [[PmWiki:Subversion | subversion pre-release]] of PmWiki. You can get \%0a[[https://www.pmwiki.org/pub/pmwiki-devel/pmwiki-latest-svn.zip|a full ZIP archive]] of the nightly version, or \%0a[[https://www.pmwiki.org/pub/pmwiki-devel/pmwiki-nightly.zip|a partial export]] with only the files changed since {$Version}.:)\%0a{$:xPrerelease}%0a%0a* Dark theme: add toggleImages(), add $ImgDarkSuffix, $FmtV['$PathUpload']. Restore light styles and pictures for printing.%0a* Responsive skin: white background when printing, move dark toggle label styles into skin.css.%0a* PmSyntax: only apply dark theme colors on screen (not print).%0a* Add upload extensions and image extension patterns AVIF, AVIFS.%0a* Lock AllRecentChanges in case of concurrent uploads.%0a* FileSizeCompact() allow for base 1000 (PITS:01499).%0a[[#svn-revision-4672]]%0a* Update documentation.%0a%0a!!! Version 2.3.31 (2024-02-23) [[#v2331]]%0a* Add $EnableDarkThemeToggle, enable 3-way theme toggle, "Light", "Dark" and "Auto", add annotation tooltip showing the current theme on tap and on mouse over.%0a* Refactor config data passed to pmwiki-utils.php, refactor dark toggle functions into a separate script. %0a* Responsive skin add body attributes for group and page name, update dark theme, enable auto theme (browser preferences) by default.%0a* PmSyntax improve dark theme thanks to a script by Said Achmiz; expose color properties for reuse.%0a* Refactor redirect quiet (PITS:01498).%0a* Page attributes passwords form: allow for +addition and -removal of passwords, users, groups.%0a* Allow $EditTemplatesFmt entries to apply to specific pages with name= specification (suggested by Simon).%0a* Forms add attribute "form".%0a* Refactor $PostConfig to allow called functions to update it.%0a* Update RecipeCheck to also list skins, suggested by Simon.%0a* Refactor PrintFmt, add $EnablePrePrintFmt.%0a* [[WikiStyles]] add 'columns'.%0a* When Highlight.js is enabled, Vardoc links will be the same color as variables in highlighted code blocks.%0a* Refactor $EnableUploadVersions.%0a* Update documentation.%0a%0a!!! Version 2.3.30 (2024-01-22) [[#v2330]]%0a* Add prototype for dark theme toggle. See PITS:01497 and Cookbook:DarkColorScheme.%0a** PmWiki-responsive skin converted CSS colors to variables, added dark theme styles.%0a** Add skins/pmwiki/pmwiki-32.svg, enable default for $PageLogoUrl.%0a** PmSyntax added dark theme styles.%0a* $EnableUploadMimeMatch with Fileinfo not enabled to deny uploads.%0a* upload.php fix warning for PHP 8.%0a* RecipeCheck use https, suggested by Simon.%0a* PrintDiff() add $since argument.%0a* Add $EnableRedirectQuiet = 2. Prevent infinite redirect loops.%0a* Fix Attach: links with escaped path and filename.%0a* Improved readability for inline diffs in page history.%0a* Forms enable input e_author not only for action=edit, fix unquoted positional form action URL.%0a* Update documentation.%0a%0a!!! Version 2.3.29 (2023-12-18) [[#v2329]]%0a* Fix urlapprove.php for PHP 8.2. %0a* PmSyntax textarea remove styles for width, height (Cookbook:PmSyntax-Talk), allow for fractional dimensions of the highlighted area.%0a* $MarkupDirectiveFunctions allow dashes in attribute names.%0a* Update documentation.%0a%0a!!! Version 2.3.28 (2023-11-27) [[#v2328]]%0a* Add input ''month'' and ''color'' fields.%0a* Add $NotifyRelatedTrailFmt.%0a* Reverse simpletable row backgrounds when there is a thead element.%0a* Fix pmwiki-utils.js when window.localStorage is disabled.%0a* UrlApprovals allow https: URLs if the http: URL for the same domain has been approved (PITS:01431).%0a* Update documentation.%0a%0a!!! Version 2.3.27 (2023-10-23) [[#v2327]]%0a* When merging last edit, if there is no change summary, reuse the last one. %0a* Keep unknown date/time formats for undefined timezone (PITS:01495).%0a* DiffRenderSource() fix for PHP 8, keep ins/del tags on the same line.%0a* The ".diffmarkup" element now has the style "white-space: pre-wrap".%0a* Add new keyword shortcuts Ctrl+B (bold), Ctrl+I (italic), Ctrl+K (link/unlink).%0a* Update documentation.%0a%0a%0a!!! Version 2.3.26 (2023-09-28) [[#v2326]]%0a* Add configurable $InputLabelFmt snippet (PITS:01493).%0a* Add configurable $TrailFmt snippets.%0a* Add $EnableSearchAtLeastOneTerm, default disabled.%0a* Unset upload extensions if size for the extension is set to 0.%0a* Update feeds.php for PHP 8.2 (PITS:01494).%0a* Update documentation.%0a%0a%0a!!! Version 2.3.25 (2023-07-29) [[#v2325]]%0a* Updates for PHP 8.2.%0a* Fix pagelist when 2+ directives on the same line, reported by Simon.%0a* Fix possible bug with internal group(header|footer) directives caused by PRR().%0a* Update documentation.%0a%0a%0a!!! Version 2.3.24 (2023-06-06) [[#v2324]]%0a* Add $EnableUploadMimeMatch.%0a* Add $EnableMergeLastMinorEdit, edit functions MergeLastMinorEdit (based on Cookbook:FuseEdit), SaveChangeSummary (refactored out of HandleEdit).%0a* Fix LogoutCookies() doesn't use a $pagename argument.%0a* PmForm add condition 'validemail' for use in template require.%0a* Add $PmCryptAlgo, pmcrypt() to call password_verify() if it exists. %0a* Refactor HandleDownload() split ServeDownload($filepath, $upname).%0a* Add InsertEditFunction($newfn, $where='%3cPostPage').%0a* Add $AuthFormRespCode.%0a* Add $EnableDownloadRanges, default 1.%0a* When the token is expired, reopen edit form rather than abort.%0a* LocalTimes add $EnableRCListLastEdit.%0a* Update documentation.%0a%0a!!! Version 2.3.23 (2023-05-03) [[#v2323]]%0a* Refactor pmtoken() to use session tokens, enable for core actions.%0a* Add %25pmhlt%25[@(:input pmtoken:)@] helper.%0a* PmForm add $PmFormEnablePmToken.%0a* Refactor @@HandleLogoutA()@@ split @@LogoutCookies()@@. %0a* Fix PRCB() for PHP %3c 7.4.%0a* Update documentation.%0a%0a!!! Version 2.3.22 (2023-04-06) [[#v2322]]%0a* Add scripts/pmform.php, Site.PmFormTemplates.%0a* FmtDateTimeZ() can now accept Unix timestamps.%0a* Pagelists fix bug with multiple category=+A,+B entries.%0a* Update for PHP 8.1 (PITS:01488).%0a* MarkupDirectiveFunctions will now cast numeric arguments to floats.%0a* Prevent errors in custom PageVariables from generating internal server errors (PITS:01489).%0a* Improve inline diff for rare cases (end of page).%0a* Forms/buttons with @@data-pmconfirm="Question"@@ will ask the question before they are submitted.%0a* Update documentation.%0a%0a%0a!!! Version 2.3.21 (2023-03-06) [[#v2321]]%0a* Add $IsPmArchive, $PmArchiveDir.%0a* Sortable tables with %3ctime datetime=""> elements can be sorted by the datetime attribute. Fix for tables with preexisting %3cthead> element.%0a* Updates for PHP8.%0a* Add CSV upload extension.%0a* LocalTimes add mode=3 to show old dates as MM'YY.%0a* Fix bug with multiline $MarkupDirectiveFunctions, reported by Antti Tikanmäki.%0a* Add $EnableCopyCode and Copy code button to %3cpre> blocks, suggested by Alex Doré.%0a* Update PmTOC to work better with Cookbook:SectionEdit.%0a* Update documentation.%0a%0a!!! Version 2.3.20 (2023-02-12) [[#v2320]]%0a* Fix undefined variable warning, reported by Gregor Klarič.%0a%0a!!! Version 2.3.19 (2023-02-11) [[#v2319]]%0a* Only set cookie params if headers not sent. %0a* Update for PHP8.2, reported by Dfaure. PageVar() update for PHP 8.%0a* Add variable $DiffPrepareInlineFunction.%0a* PageListCache() remove unused global $PageIndexFile.%0a* Add configurable $LocalCSSDir, $LocalCSSDirUrl.%0a* DownloadUrl() add $FmtV['$LinkDownload'] with current or future download link.%0a* Add pm_recode() helper function (based on PageStore::recodefn), check for more transcode options.%0a* HandleBrowse() add $FmtV['$PageSourceText'].%0a* Add helper function KeepBlock().%0a* Add $FarmPubDirPrefix, pm_servefile(), $ServeFileExts.%0a* Update documentation.%0a%0a!!! Version 2.3.18 (2023-01-15) [[#v2318]]%0a* Refactor scripts/utils.php, add pm_json_encode() (PITS:01486).%0a* EditAutoText() fix for lines ending with multiple backslashes.%0a* PmSyntax optimize/refactor for large pages (cont.), fix inline escaped texts could ignore line markups, add EnableStopwatch.%0a* Notify fix typo in regular expression.%0a* {-Add $EnableUploadVersions >=10 to rename base.ext to base-1.ext, base-2.ext,...-} ''Redesigned in 2.3.31''%0a* CondAuth() fix bug with global $AuthList.%0a* Add helper function PRCB() for simpler preg_replace_callback passing variables.%0a* Update scripts/refcount.php for PHP 8, reported by George Murray.%0a* Add PageVariable $PageLogoUrl (PITS:01297).%0a* Update documentation.%0a%0a!!! Version 2.3.17 (2022-12-17) [[#v2317]]%0a* WikiStyles trim class names (PITS:01485).%0a* GUIEditButtons refactor to enable Undo in textarea; allow for custom functions to configure mopen, mclose, and unselect for their buttons.%0a* [[Cookbook:EditHelp|EditHelp]] refactor to allow undo; add shortcuts Ctrl+L convert selection to lowercase, Ctrl+Shift+L to uppercase, Ctrl+Shift+ArrowUp and ArrowDown to swap lines.%0a* Skip upgrade check if $EnableReadOnly.%0a* Fix bug with multiple $MarkupDirectiveFunctions.%0a* Add $EnableBaseNameConfig.%0a* PmSyntax optimize for larger pages (cont.).%0a* Input password add class "inputbox" like the other fields.%0a* CondAuth() added way to check for usergroup permissions.%0a* Update in pagelist.php for PHP 8.%0a* Documentation update.%0a%0a!!! Version 2.3.16 (2022-11-28) [[#v2316]]%0a* Class PPRC add generic callbacks.%0a* IncludeText() update for PHP 8, reported by V.Krishn.%0a* WikiStyle add 'overflow', 'notoc'.%0a* Add PmNonce().%0a* PmTOC update indented link style->classname. %0a* Responsive skin: replace %25pmhlt%25[@[[%3c%3c]]@] with %25hlt html%25[@%3cbr class='clearboth' />@], update PmTOC styles.%0a* $EnableListIncludedPages use class name instead of style. %0a* guiedit.js remove unneeded style.%0a* PmSyntax realign font for nested programming languages in the edit form, optimize for large pages.%0a* Only call session_status() if function exists.%0a* Edit form remove unsafe-inline script.%0a* Revert WikiStyleToClassName(), PrePrintFmt() -- need more work (PITS:01484).%0a* Documentation update.%0a%0a!!! Version 2.3.15 (2022-11-21) [[#v2315]]%0a* CSS pre, code relative/scalable font-size (pmwiki-responsive skin).%0a* PmSyntax add variable --pmsyntax-fontsize-editform and split from --pmsyntax-fontsize [[https://www.pmichaud.com/pipermail/pmwiki-users/2022-November/064936.html|#]].%0a* PmSyntax fix [@[[Highlight]]@] label font size and family (reported by Hans).%0a* Add variable $CookieSameSite default to 'Lax'%0a* Add argument $samesite to pmsetcookie(), default to $CookieSameSite, refactor for old and new PHP versions. %0a* Add function pm_session_start() respecting local configuration.%0a* CSP header add base-uri=self; object-src 'none'.%0a* Add $HTTPHeaders['XSSP'] = 'X-XSS-Protection: 1; mode=block'.%0a* Rewrite GUIButtons logic to avoid unsafe-inline JavaScript.%0a* Refactor WikiStyles, replace inline styles with class names to avoid unsafe-inline CSS.%0a* Refactor PQA(), tables, cells, to replace inline style="..." with class names to avoid unsafe-inline CSS.%0a* Add PrePrintFmt(), refactor PrintFmt(), PrintSkin() to process wiki pages, skin parts, and skin functions to HTML before outputting headers.%0a* Fix XSS vulnerability.%0a* Documentation update.%0a%0a!!! Version 2.3.14 (2022-11-03) [[#v2314]]%0a* Searchbox also escape custom field names.%0a* Prevent double-encoded entities in searchbox (reported by Simon).%0a* Trim $Author (PITS:01208).%0a* Replace autofocus inline JavaScript with attributes.%0a* Edit form: the label next to the "Minor edit" checkbox now toggles the checkbox.%0a* PmSyntax recognize %25pmhlt%25[@(:template requires? ...:)@].%0a* Update for PHP 8. %0a* Obsolete PCCF() from PHP 7.2 not 8.0.%0a* Add array $ObsoleteMarkups, function TraceMarkup(), update Markup(), Markup_e() and ObsoleteMarkup(), to retrieve and show files and line numbers for obsolete/disabled markup rules.%0a* Fix bug with PSFT format %25L.%0a* Update documentation.%0a%0a!!! Version 2.3.13 (2022-10-07) [[#v2313]]%0a* Close potential XSS vulnerability, reported by lukystreik (PITS:01483).%0a* Refactor $MultiFactorAuthFunction, add $FailedLoginsFunction.%0a* Update documentation.%0a%0a!!! Version 2.3.12 (2022-09-25) [[#v2312]]%0a* Stripmagic() cast null to "" and other fixes for PHP 8.%0a* Fix parse error for complex conditionals with empty variables (PITS:01480).%0a* PSFT() and MarkupExpression [@ftime@] add %25L as human readable local timestamp. %0a* MarkupRestore() fix wrong cast to empty string of false-ish values.%0a* PrintAuthForm() split from PmWikiAuth(). %0a* Fix warning for unneeded session_regenerate_id() (reported by George Murray).%0a* Update documentation.%0a%0a!!! Version 2.3.11 (2022-08-30) [[#v2311]]%0a* Add [[PageVariables]] %25pmhlt%25 [@{$GroupHomePage}@], [@{$GroupHomePageName}@], [@{$GroupHomePageTitle}@], [@{$GroupHomePageTitlespaced}@].%0a* Add $MarkupDirectiveFunctions.%0a* Fix stripmagic() for arrays recently broke after PHP8 update.%0a* Update documentation.%0a%0a!!! Version 2.3.10 (2022-08-20) [[#v2310]]%0a* Update for PHP 8.1 (reported by Armin Bühler).%0a* Forms will now prefill wildcard variables from $DefaultUnsetPageTextVars or $DefaultEmptyPageTextVars.%0a* $EnablePmSyntax = 3; will enable syntax highlighting in the edit form by default, without the user clicking on "Highlight". Fix occasional text mis-alignment between the text area and the highlighted block.%0a* Update documentation.%0a%0a!!! Version 2.3.9 (2022-08-18) [[#v239]]%0a* Add non-wildcard $DefaultUnsetPageTextVars to %25pmhlt%25[@(:input default:)@] (reported by Johnny).%0a* PmSyntax handles new selectors pre.pmhlt, code.pmhlt.%0a* Update for PHP 8 (PITS:01478).%0a* Update documentation.%0a%0a%0a!!! Version 2.3.8 (2022-07-22) [[#v238]]%0a* PmSyntax fix for 2 different %25pmhlt%25 [@%25hlt%25@] on the same line (reported by Simon).%0a* Fix broken include when the first page doesn't exist.%0a* Update documentation.%0a%0a!!! Version 2.3.7 (2022-06-28) [[#v237]]%0a* $HTTPHeaders add X-Frame-Options (suggested by Imagine Dragon) and Content-Security-Policy to disallow embedding in external websites by default.%0a* $EnableHighlight will now remember any links to PmWiki variables and restore them after the highlighting, see [[thread->https://www.pmwiki.org/pipermail/pmwiki-users/2022-June/064887.html]].%0a* $EnablePmSyntax will now process %25pmhlt%25[@%25hlt pmwiki%25@] in addition to [@%25pmhlt%25@] blocks, and escaped markup after it will be tentatively highlighted.%0a* Update documentation.%0a%0a!!! Version 2.3.6 (2022-06-19) [[#v236]]%0a* Fixes for PHP 8.%0a* Add form attribute "lang".%0a* Sortable tables allow for table headers to have markup such as bold (except links). It will now use a case-insensitive natural ordering.%0a* Allow for $UploadVerifyFunction to modify $upname.%0a* Add variable $PageIndexTermsFunction.%0a* Searchbox allow for removal of submit button if [@label=""@]; add default [@placeholder="$[Search]"@].%0a* Fix author.php may be included before some variables are defined, reported by Said Achmiz.%0a* $EnableHighlight convert code blocks to plain text, see [[thread->https://www.pmwiki.org/pipermail/pmwiki-users/2022-June/064887.html]].%0a* Documentation update.%0a%0a%0a!!! Version 2.3.5 (2022-05-23) [[#v235]]%0a* Fix broken list=grouphomes (PITS:01477).%0a* Add DisableSkinParts() helper function for recipes.%0a* HandlePostUpload: add @@$FmtV["$filepath"]@@ and @@$FmtV["$upurl"]@@ with the file path and direct URL to the newly uploaded file.%0a* In pmwiki-utils.js, replace forgotten ''let'' with ''var'' (suggested by SteP).%0a* Update for PHP 8.1.%0a* Update documentation.%0a%0a!!! Version 2.3.4 (2022-04-22) [[#v234]]%0a* Fixes for PHP 8 warnings, reported by Siegfried Seibert.%0a* Update documentation.%0a%0a!!! Version 2.3.3 (2022-03-26) [[#v233]]%0a* Fix for PHP 8 warnings, reported by Jean-Patrick Charrey, Dominique Faure and Siegfried Seibert.%0a* Update README.txt and docs/ files, suggested by Simon Davis.%0a* Update documentation.%0a%0a!!! Version 2.3.2 (2022-02-09) [[#v232]]%0a* Allow for $EnableLocalTimes to define custom duration of the pulled page history.%0a* Rename variable $EnableIncludedPages to $EnableListIncludedPages (avoid ambiguity).%0a* Remove $LinkAlt when an embedded picture without an alternative text fails to load.%0a* PmSyntax:%0a** Allow for line breaks \\ inside headings, tables, list items (like the core).%0a** Parallel processing of multiple blocks.%0a* Add scripts/utils.php; move loading of pmwiki-utils.js and PmSyntax to scripts/utils.js.%0a** Add $EnablePmUtils, default enabled.%0a** Parallel processing of the pmwiki-utils.js utility functions.%0a** Move pmwiki-utils.js move to $HTMLHeaderFmt (often prevents page redraw with the TOC/PmToggle/LocalTimes).%0a* Fix bug causing invalid page name when the name is "Group.0".%0a* Fix PHP 8.1.2 warnings, reported by Jürgen Godau and Dominique Faure.%0a* LocaltTimes fix "rcnew" classes for wikis with the older format.%0a* Update documentation.%0a%0a!!! Version 2.3.1 (2022-01-15) [[#v231]]%0a%0a* Fix the release script which broke the $VersionNum variable and the [@[[#anchor]]@] markup with the PmWiki-responsive skin.%0a%0a!!! Version 2.3.0 (2022-01-15) [[#v230]]%0a* Add PmSyntax, $EnablePmSyntax, $CustomSyntax, [@{$EnabledIMap}@], see Cookbook:PmSyntax, Cookbook:CustomSyntax.%0a* [@(:markup:)@] can now have @@class=norender@@ to only show the source code without processing it.%0a* Updates for PHP 8.1, hide warnings, add PSFT() replacement for strftime() and 2 callbacks, $EnableFTimeNew, update core function calls, add [@%25o@] for the ordinal suffix of the date (PITS:01418).%0a* Notify: @@tz=@@ (timezone) per-user.%0a* PageList add category= argument (PITS:00447, PITS:01475); link= and category= now accept multiple pages, wildcards, and negations (PITS:00908).%0a* [=[[!Category]]=] links can have alternative text (PITS:01095).%0a* Simplify/optimize pmwiki-utils.js when using datasets, simplify sorting of table rows without cloning, add LocalTimes().%0a* Page history diff anchors to also have "id=" attributes in addition to "name=".%0a* Add $EnableLocalTimes (default disabled) and styles, add HandleDiffList().%0a* Add markup %25pmhlt%25[@@2022-01-09T08:35:00Z@]%25%25 output as %3ctime>; localized if $EnableLocalTimes.%0a** Add $CurrentLocalTime in the above format, used by default in $RecentChangesFmt.%0a* Add $EnableRecentUploads (only Site.AllRecentChanges, only if $RecentUploadsFmt not defined).%0a* PmTOC update CSS for properly indented subheadings.%0a* Edit form $EnableIncludedPages, add placeholders to e_changesummary and e_author. Enable $EnableNotSavedWarning, add to sample-config.php. EditHelp to behave more like a word processor, typing "Enter" twice without writing text removes the preceding bullet.%0a* Responsive skin details>summary:hover {color:navy, cursor: pointer;}.%0a* PrintDiff() add classes for the delay between edits: diffday, diffweek, diffmonth, diffyear.%0a* Add helper function @@DownloadUrl($pagename, $path)@@ moved from @@LinkUpload()@@.%0a* Add [=$[ULby]=] i18n string 'uploaded by'.%0a* Update documentation.%0a%0a!!! [[#older]] Older versions%0a[[(PmWiki:)ChangeLog Archive]] - changes prior to version 2.3.0.%0a +time=1711024919 diff --git a/wikilib.d/PmWiki.IncludeOtherPages b/wikilib.d/PmWiki.IncludeOtherPages index 7b258f6a..15ecaa21 100644 --- a/wikilib.d/PmWiki.IncludeOtherPages +++ b/wikilib.d/PmWiki.IncludeOtherPages @@ -1,9 +1,9 @@ -version=pmwiki-2.3.2 ordered=1 urlencoded=1 +version=pmwiki-2.3.31 ordered=1 urlencoded=1 author=Petko charset=UTF-8 -csum= (-6) +csum=rm ominous line (-385) name=PmWiki.IncludeOtherPages -rev=140 +rev=141 targets=PmWiki.IncludeOtherPages,PmWiki.Links,PmWiki.WikiGroup,PmWiki.PageTextVariables,PmWiki.IncludeOtherPages-Talk,Cookbook.IncludeSection,PmWiki.LayoutVariables,Site.PageListTemplates,PmWiki.BasicVariables,PmWiki.PagelistVariables,PmWiki.WikiStyles,PmWiki.ConditionalMarkup,PmWiki.PageVariables,Cookbook.IncludeUrl,PmWiki.WikiAdministrator,PmWiki.PageLists -text=(:Summary: Include contents from other PmWiki pages:)%0a(:Audience: authors (intermediate) :)%0aThe %25pmhlt%25[@(:include:)@] directive makes it possible to insert (or [[Wikipedia:Transclusion|"transclude"]]) the contents of other pages into the current wiki page. All of the include directives below perform a straight text inclusion. In particular, any page [[links]] in the included text are assumed to link to pages in the current [[(wiki) group]] if not otherwise qualified.%0a%0a!! Syntax%0aThe basic syntax is%0a* %25pmhlt%25[@(:include PageName:)@] \\%0awith pagename includes the full page from the same group.%0a* %25pmhlt%25[@{Group/PageName$:PTVar}@]\\%0a[[#includeptv|includes]] a [[PageTextVariables|named variable]] from a page, [[(Wiki)Group]] and PageName are options%0a%0aThe full syntax is%0a* @@%25pmhlt%25'''[=(:=]include'''@@%0a [[#includefullname|FullName]]#[[#includeanchor|fromanchor]]#[[#includeanchor|toanchor]] \%0a [[#includelines|lines]]=''12..34'' \%0a [[#includeself|self]]=''0'' \%0a [[#includebasepage|basepage]]=''abc'' \%0a [[#includevariable|variable]]=''value'' \%0a @@''':)'''@@\\%0a includes a page according to the parameters supplied. Parameters are optional.%0a[[#firstanchor]]%0a%0a!! Parameters%0aThe directive can have multiple Name parameters with or without anchors, and multiple [[#includevariable|template variable]] parameters.%0a%0a[[#includefullname]]%0a!!! Named pages%0a%25pmhlt%25[@(:include PageName:)%0a(:include Group.PageName:)%0a(:include Page1 Page2 Group1.Page3 Group2.Page4:)@]%0aIncludes the entire text of another page into the current page. Multiple pages may be specified, but only the first available is included.%0a%0a[[#errormessage]]%0aYou can use the above feature to ''display an error message if an include fails''. Create a page, eg. Site.IncludeFailed containing the error message. You can use any page name. Then, in your include markup, append this page at the end of the page list:%0a %25pmhlt%25[@(:include Page1 Page2 Page3 Site.IncludeFailed:)@]%0aA slightly more complex approach is outlined at [[PmWiki:IncludeOtherPages-Talk|the talk page]].%0a%0a[[#includeanchor]]%0a!!! #From#To anchors%0a|| width=*%0a||%25pmhlt%25[@(:include PageName#from#to:)@] ||include lines from ''`PageName'' between the %25pmhlt%25[@[[#from]]@] and [@[[#to]]@] [[Links#anchors|anchors]]%0a||%25pmhlt%25[@(:include PageName#from#:)@] ||include all lines after %25pmhlt%25[@[[#from]]@] to the end of the page%0a||%25pmhlt%25[@(:include PageName##to:)@] ||include all lines from the start of the page to %25pmhlt%25[@[[#to]]@]%0a||%25pmhlt%25[@(:include PageName#from:)@] ||include everything between %25pmhlt%25[@[[#from]]@] and the next anchor%0a||%25pmhlt%25[@(:include PageName#:)@] ||include everything from the top of the page to the first anchor%0a%25note%25 Note: do not put whitespace between "#from" "#to"%0a%0a%25note%25 Note: text on the same line as a closing anchor but preceding the closing anchor will '''NOT''' be included in the text. Example Below:%0a%25pmhlt%25%25pmhlt%25[@[[#start]] some text on the first line%0asome text on the last line [[#end]]@]%0a%25note%25The above, when included via %25pmhlt%25[@(:include PageName#start:)@] will have the text on the first line but not the text on the last line.%0a%0a%25pmhlt%25[@(:include Page1 Page2 #from#to:)@]%0a-> Include from the first available of Page1, Page2 between the %25pmhlt%25[@[[#from]]@] and [@[[#to]]@] %0a\\%0a%25note%25 Note: put whitespace between "Page2" and "#from#to". The same anchors "#from#to" should be in both pages. If proper anchors are missing in the first available of Page1, Page2 the whole contents of the page is included.\\%0aThis does not seem to work in 2.2 betas. See Cookbook:IncludeSection for a fix.%0a%0a%25pmhlt%25[@(:include Page1#from1#to1 Page2#from2#to2:)@]%0a-> Include the first from the first available of Page1 (between the %25pmhlt%25[@[[#from1]]@] and [@[[#to1]]@]) or Page2 (between the [@[[#from2]]@] and [@[[#to2]]@] ) %0a%0a%25green%25Note%25%25: Previous versions of PmWiki allowed whitespace between %25pmhlt%25[@#from@] and [@#to@] anchors even though it was not designed to. Newer versions do not allow whitespace anymore. To re-enable this "exploited misbehavior" put this into your config.php or farmconfig.php%0a%0a-> %25hlt php%25[@Markup('includeanchors', '%3cinclude', '/(\\(:include.*?#\\w+)\\s+(#\\w+)/', '$1$2');@]%0a%0a[[#includelines]]%0a!!! Lines=from..to%0a%25pmhlt%25[@(:include PageName lines=10:)@]%0a%25pmhlt%25[@(:include PageName lines=5..10:)@]%0a%25pmhlt%25[@(:include PageName lines=5..:)@]%0a-> Include the first 10 lines, lines 5-10, or lines 5 and up from ''`PageName''. A "line" in this context refers to a line of source. ''Thus a line may be a paragraph that wraps over several lines on the screen, or a completely blank line.''%0a%0a%25pmhlt%25[@(:include Page1 Page2 Page3 lines=1..5:)@]%0a-> Include the first five lines from the first available of Page1, Page2, or Page3. (To include lines from a list of pages, use a separate include for each.)%0a%0a[[#includeself]]%0a!!! Self=%0a%25pmhlt%25[@(:include PageName self=0:)@]%0a-> The parameter @@self@@ can be @@0@@ or @@1@@. It tells the include directive if it is allowed to include the current page. This is useful if PageName is a variable like %25pmhlt%25[@{$Name}@] and you want to prevent the directive from including the current page.%0a%0a[[#includeptv]]%0a!!! [[Page text variables]]%0a%25pmhlt%25[@{Group/PageName$:Var}@]%0a-> Includes definition list values from an (optional) page as [[page text variables]]. These are defined using %0a** definition list %25pmhlt%25"[@:item:description@]" %0a** simple colon delimiter %25pmhlt%25"[@item:description@]" %0a** special markup %25pmhlt%25"[@(:item:description:)@]"%0a%0a[[#includebasepage]]%0a!!! Basepage=%0a%0a%25pmhlt%25[@(:include PageName basepage=BasePageName:)@]%0a-> Include PageName, but treat all relative links and page variables on ''PageName`'' as relative to ''BasePageName''.%0aIf @@basepage=@@ is provided all relative links and page variables are interpreted relative to basepage.%0aSo, if one creates %25pmhlt%25[@TemplateName@] as%0a-> %25pmhlt%25[@Name: {$:Name}%0aAddress: {$:Address}@]%0athen the directive%0a-> %25pmhlt%25[@(:include TemplateName basepage=PageName:)@]%0awill retrieve the contents of %25pmhlt%25[@TemplateName@], treating any page variables and links as being relative to [@PageName@]. %0aIn particular, the values for %25pmhlt%25[@{$:Name}@] and [@{$:Address}@] will be taken from [@PageName@], but things like [@{$Title}@] and [@{$LastModifiedBy}@] would also work here.%0a%0a!!!! Basepage usage%0aThe primary purpose of basepage is to allow the inclusion of pages in a way that mimics the 2.1.x behavior where page variables %0aand links are interpreted relative to the currently displayed page.%0aThis is done with:%0a-> %25pmhlt%25[@(:include SomeOtherPage basepage='' :)@]%0a -or-%0a-> %25pmhlt%25[@(:include SomeOtherPage basepage={*$FullName} :)@]%0a%0aIt also allows [=GroupHeader and GroupFooter=] to have their page variables and links be relative to the currently displayed page %0a(instead of [=GroupHeader and GroupFooter=]):%0a>>pre pmhlt%3c%3c%0a ## PmWiki default $GroupHeaderFmt setting%0a $GroupHeaderFmt = %0a [='(:include {$Group}.GroupHeader self=0 basepage={*$FullName}:)(:nl:)';=]%0a>>%3c%3c%0a%0aOtherwise, using {$Name} inside of a [=GroupHeader=] would display '[=GroupHeader=]' and not the name of the currently displayed page.%0a%0aThe basepage= parameter is general enough that it can also be used as a templating engine, so that%0awe can grab a template page containing variables that are then filled in with values from another page:%0a->%25pmhlt%25[@(:include TemplatePage basepage=DataPage :)@]%0a%0aAnd, of course, a single TemplatePage can actually contain multiple templates delimited by anchors, so that we end up with a syntax eerily similar'^[[#footnote|#]]^' to pagelist-templates:%0a>>pre pmhlt%3c%3c%0a [@(:include TemplatePage#abc basepage=DataPage :)@]%0a>>%3c%3c%0a%0aSo then [=TemplatePage=] can use a syntax like:%0a>>pre pmhlt%3c%3c%0a [@%0a [[#abc]]%0a ...template stuff here...%0a [[#abcend]]%0a @]%0a>>%3c%3c%0a%0aand it's possible to display [=TemplatePage=] as a template without it being interpreted... same as we do for [[Site.PageListTemplates]].%0a%0a%0a-%3c [[#footnote]] [- '^[1]^'Okay, maybe it's not so eerie, given that the pagelist template code actually uses the same function as %25pmhlt%25[@(:include:)@] to grab its templates. But it's still a useful parallel. -]%0a%0a[[#includevariable]]%0a!!! Specifying variables as parameters: Use sections as templates%0aYou can also specify variable values inline with the include statement, and refer to the variables in the template using the %25pmhlt%25[@{$$variable1}@] format:%0a-> %25pmhlt%25[@(:include TemplatePage variable1="value" variable2="value2":)@]%0a%0aThis assumes that a site has $EnableRelativePageVars enabled, which is recommended in PmWiki 2.2.0 -- but was disabled by default in version 2.2.8 and earlier.%0a%0aFor example, on my included page ("template") I might have this:%0a%0a(:markup class=horiz:)%0a[[#ivars]]%0aHi, {$$Name}, how are you today?%0a[[#ivarsend]]%0a(:markupend:)%0a%0aThen, including that section above (that section is available via the section %25pmhlt%25[@{$FullName}#ivars@]) you get this type of behavior:%0a%0a(:markup class=horiz:)%0a(:include {$FullName}#ivars Name=Sam:)%0a(:markupend:)%0a%0aIf a value contains spaces, quote it:%0a%0a(:markup class=horiz:)%0a(:include {$FullName}#ivars Name="my friend":)%0a(:markupend:)%0a%0a''See also $EnableUndefinedTemplateVars.''%0a%0a!!!Specific markup%0a%25pmhlt%25[@(:nl:)@] acts like a new line in the ''markup'', only if there isn't one already.%0a%0aThe purpose of %25pmhlt%25[@(:nl:)@] is to be able to write things like "[@(:include Page1:)(:nl:)(:include Page2:)@]" which guarantees that the first line of Page2 is treated as a separate line from the last line of Page1, but without inadvertently generating a blank line between them.%0a%0aSee [[http://thread.gmane.org/gmane.comp.web.wiki.pmwiki.user/15031/focus=15079 | this thread]] and [[http://thread.gmane.org/gmane.comp.web.wiki.pmwiki.user/58609/focus=58633/|this thread]] for more info.%0a%0a%25pmhlt%25[@(:nl:)@] is not intended to put a newline character in the output!%0a%0a!! Parameter References%0a%0aAny parameters supplied to an include statement (whether they are keywords or not) are accessible inside the included page as a special %25pmhlt%25[@{$$...}@] variable of the same name. This feature can be used to provide extra information to use when displaying the included page.%0a%0a!! Notes%0a* You can also say %25pmhlt%25[@(:include My/Page#myanchor lines=4:)@] which starts from, and includes, the line with the anchor [@[[#myanchor]]@] for four lines.%0a%0a!!! Styling Note%0aBy default, Included pages or lines cannot be distinguished from other text on the page. To provide a visual indication that this text is special, you can apply [[PmWiki/Wiki Styles]]. For example:%0a%0a(:markup:)%0a%25define=leftborder border-left="2px solid #88f" margin-left="2px" padding="1px 0 3px 10px"%25%0aWhat is PmWiki?%0a>>leftborder%3c%3c (:include PmWiki.PmWiki lines=1..4:) %0a>>%3c%3c%0a''Have a very nice day!''%0a(:markupend:)%0a%0a!!! Notes about use with [[conditional markup]]%0aThe %25pmhlt%25[@(:include ...:)@] markup is processed after conditional markup is evaluated.\\%0aTherefor you can include a page or page section as part of a condition, like%0a->%25pmhlt%25[@(:if some condition:)(:include SomePage#section:)(:if:) @] %0aBut [@(:include SomePage#section:)@] doesn't look to see if [@[[#section]]@] is part of a conditional, like %0a->%25pmhlt%25[@(:if some condition:)[[#section]]...[[#sectionend]](:ifend:)@]%0a%25pmhlt%25[@(:include SomePage#section:)@] will ignore such a condition. %0a%0aWhen [[Conditional Markup|testing variables]] in included pages the context of the page (source or target) can be useful.%0aSee [[PmWiki/PageVariables#specialreferences|special references]] for details.%0a%0a----%0a%0a!! See Also%0a* [[PmWiki/Page text variables]] {PmWiki/PageTextVariables$:Summary}%0a* [[Cookbook:IncludeUrl]] {Cookbook.IncludeUrl$:Summary}%0a%0a!! FAQ%0a>>faq%3c%3c [[#faq]]%0a%0aQ: [[#maxincludes]] What's the maximum number of includes that can exist in a page? %0a-> My site seems to stop including after 48 includes. ($MaxIncludes)%0a%0aA: By default, PmWiki places a limit of 50 include directives for any given page, to prevent runaway infinite loops and other situations that might eat up server resources. (Two of these are GroupHeader and GroupFooter.) The limit can be modified by the [[wiki administrator]] via the $MaxIncludes variable.%0a%0aQ: Is there any way to include from a group of pages without specifying by exact name, e.g. between Anchor X and Y from all pages named IFClass-* ?%0aA: This can be achieved using [[page lists]].%0a%0a%0aQ: There appears to be a viewing issue when the included page contains the [=(:title:)=] directive.%0aA: In a default installation, the ''last'' title in the page overrides previous ones so you can place your [=(:title :)=] directive at the bottom of the page, after any includes. See also $EnablePageTitlePriority.%0a%0aQ: How to test to see if the page is part of another page?%0aA: (:markup:)%0a(:if ! name {$FullName}:) %0a%25comment%25 name of this page is not the same as the page this text was sourced from%0a->[[{$FullName}#anchor | more ...]]%0a(:ifend:)%0a(:markupend:)%0a%0aQ: Is there any way to include (chapters of) pages which are protected (authuser.php)?%0a%0aA: You can achieve this the other way around: have the public sections in a public page (passwdread=@nopass or @_site_read) and include those into both the protected page, and the public page.%0a%0aA: Note that it is '''strongly recommended to NOT''' hide sensitive content inside a [[conditional( markup)]] in an unprotected page.%0a -time=1647491419 +text=(:Summary: Include contents from other PmWiki pages:)%0a(:Audience: authors (intermediate) :)%0aThe %25pmhlt%25[@(:include:)@] directive makes it possible to insert (or [[Wikipedia:Transclusion|"transclude"]]) the contents of other pages into the current wiki page. All of the include directives below perform a straight text inclusion. In particular, any page [[links]] in the included text are assumed to link to pages in the current [[(wiki) group]] if not otherwise qualified.%0a%0a!! Syntax%0aThe basic syntax is%0a* %25pmhlt%25[@(:include PageName:)@] \\%0awith pagename includes the full page from the same group.%0a* %25pmhlt%25[@{Group/PageName$:PTVar}@]\\%0a[[#includeptv|includes]] a [[PageTextVariables|named variable]] from a page, [[(Wiki)Group]] and PageName are options%0a%0aThe full syntax is%0a* @@%25pmhlt%25'''[=(:=]include'''@@%0a [[#includefullname|FullName]]#[[#includeanchor|fromanchor]]#[[#includeanchor|toanchor]] \%0a [[#includelines|lines]]=''12..34'' \%0a [[#includeself|self]]=''0'' \%0a [[#includebasepage|basepage]]=''abc'' \%0a [[#includevariable|variable]]=''value'' \%0a @@''':)'''@@\\%0a includes a page according to the parameters supplied. Parameters are optional.%0a[[#firstanchor]]%0a%0a!! Parameters%0aThe directive can have multiple Name parameters with or without anchors, and multiple [[#includevariable|template variable]] parameters.%0a%0a[[#includefullname]]%0a!!! Named pages%0a%25pmhlt%25[@(:include PageName:)%0a(:include Group.PageName:)%0a(:include Page1 Page2 Group1.Page3 Group2.Page4:)@]%0aIncludes the entire text of another page into the current page. Multiple pages may be specified, but only the first available is included.%0a%0a[[#errormessage]]%0aYou can use the above feature to ''display an error message if an include fails''. Create a page, eg. Site.IncludeFailed containing the error message. You can use any page name. Then, in your include markup, append this page at the end of the page list:%0a %25pmhlt%25[@(:include Page1 Page2 Page3 Site.IncludeFailed:)@]%0aA slightly more complex approach is outlined at [[PmWiki:IncludeOtherPages-Talk|the talk page]].%0a%0a[[#includeanchor]]%0a!!! #From#To anchors%0a|| width=*%0a||%25pmhlt%25[@(:include PageName#from#to:)@] ||include lines from ''`PageName'' between the %25pmhlt%25[@[[#from]]@] and [@[[#to]]@] [[Links#anchors|anchors]]%0a||%25pmhlt%25[@(:include PageName#from#:)@] ||include all lines after %25pmhlt%25[@[[#from]]@] to the end of the page%0a||%25pmhlt%25[@(:include PageName##to:)@] ||include all lines from the start of the page to %25pmhlt%25[@[[#to]]@]%0a||%25pmhlt%25[@(:include PageName#from:)@] ||include everything between %25pmhlt%25[@[[#from]]@] and the next anchor%0a||%25pmhlt%25[@(:include PageName#:)@] ||include everything from the top of the page to the first anchor%0a%25note%25 Note: do not put whitespace between "#from" "#to"%0a%0a%25note%25 Note: text on the same line as a closing anchor but preceding the closing anchor will '''NOT''' be included in the text. Example Below:%0a%25pmhlt%25%25pmhlt%25[@[[#start]] some text on the first line%0asome text on the last line [[#end]]@]%0a%25note%25The above, when included via %25pmhlt%25[@(:include PageName#start:)@] will have the text on the first line but not the text on the last line.%0a%0a%25pmhlt%25[@(:include Page1 Page2 #from#to:)@]%0a-> Include from the first available of Page1, Page2 between the %25pmhlt%25[@[[#from]]@] and [@[[#to]]@] %0a\\%0a%25note%25 Note: put whitespace between "Page2" and "#from#to". The same anchors "#from#to" should be in both pages. If proper anchors are missing in the first available of Page1, Page2 the whole contents of the page is included.\\%0aThis does not seem to work in 2.2 betas. See Cookbook:IncludeSection for a fix.%0a%0a%25pmhlt%25[@(:include Page1#from1#to1 Page2#from2#to2:)@]%0a-> Include the first from the first available of Page1 (between the %25pmhlt%25[@[[#from1]]@] and [@[[#to1]]@]) or Page2 (between the [@[[#from2]]@] and [@[[#to2]]@] ) %0a%0a[[#includelines]]%0a!!! Lines=from..to%0a%25pmhlt%25[@(:include PageName lines=10:)@]%0a%25pmhlt%25[@(:include PageName lines=5..10:)@]%0a%25pmhlt%25[@(:include PageName lines=5..:)@]%0a-> Include the first 10 lines, lines 5-10, or lines 5 and up from ''`PageName''. A "line" in this context refers to a line of source. ''Thus a line may be a paragraph that wraps over several lines on the screen, or a completely blank line.''%0a%0a%25pmhlt%25[@(:include Page1 Page2 Page3 lines=1..5:)@]%0a-> Include the first five lines from the first available of Page1, Page2, or Page3. (To include lines from a list of pages, use a separate include for each.)%0a%0a[[#includeself]]%0a!!! Self=%0a%25pmhlt%25[@(:include PageName self=0:)@]%0a-> The parameter @@self@@ can be @@0@@ or @@1@@. It tells the include directive if it is allowed to include the current page. This is useful if PageName is a variable like %25pmhlt%25[@{$Name}@] and you want to prevent the directive from including the current page.%0a%0a[[#includeptv]]%0a!!! [[Page text variables]]%0a%25pmhlt%25[@{Group/PageName$:Var}@]%0a-> Includes definition list values from an (optional) page as [[page text variables]]. These are defined using %0a** definition list %25pmhlt%25"[@:item:description@]" %0a** simple colon delimiter %25pmhlt%25"[@item:description@]" %0a** special markup %25pmhlt%25"[@(:item:description:)@]"%0a%0a[[#includebasepage]]%0a!!! Basepage=%0a%0a%25pmhlt%25[@(:include PageName basepage=BasePageName:)@]%0a-> Include PageName, but treat all relative links and page variables on ''PageName`'' as relative to ''BasePageName''.%0aIf @@basepage=@@ is provided all relative links and page variables are interpreted relative to basepage.%0aSo, if one creates %25pmhlt%25[@TemplateName@] as%0a-> %25pmhlt%25[@Name: {$:Name}%0aAddress: {$:Address}@]%0athen the directive%0a-> %25pmhlt%25[@(:include TemplateName basepage=PageName:)@]%0awill retrieve the contents of %25pmhlt%25[@TemplateName@], treating any page variables and links as being relative to [@PageName@]. %0aIn particular, the values for %25pmhlt%25[@{$:Name}@] and [@{$:Address}@] will be taken from [@PageName@], but things like [@{$Title}@] and [@{$LastModifiedBy}@] would also work here.%0a%0a!!!! Basepage usage%0aThe primary purpose of basepage is to allow the inclusion of pages in a way that mimics the 2.1.x behavior where page variables %0aand links are interpreted relative to the currently displayed page.%0aThis is done with:%0a-> %25pmhlt%25[@(:include SomeOtherPage basepage='' :)@]%0a -or-%0a-> %25pmhlt%25[@(:include SomeOtherPage basepage={*$FullName} :)@]%0a%0aIt also allows [=GroupHeader and GroupFooter=] to have their page variables and links be relative to the currently displayed page %0a(instead of [=GroupHeader and GroupFooter=]):%0a>>pre pmhlt%3c%3c%0a ## PmWiki default $GroupHeaderFmt setting%0a $GroupHeaderFmt = %0a [='(:include {$Group}.GroupHeader self=0 basepage={*$FullName}:)(:nl:)';=]%0a>>%3c%3c%0a%0aOtherwise, using {$Name} inside of a [=GroupHeader=] would display '[=GroupHeader=]' and not the name of the currently displayed page.%0a%0aThe basepage= parameter is general enough that it can also be used as a templating engine, so that%0awe can grab a template page containing variables that are then filled in with values from another page:%0a->%25pmhlt%25[@(:include TemplatePage basepage=DataPage :)@]%0a%0aAnd, of course, a single TemplatePage can actually contain multiple templates delimited by anchors, so that we end up with a syntax eerily similar'^[[#footnote|#]]^' to pagelist-templates:%0a>>pre pmhlt%3c%3c%0a [@(:include TemplatePage#abc basepage=DataPage :)@]%0a>>%3c%3c%0a%0aSo then [=TemplatePage=] can use a syntax like:%0a>>pre pmhlt%3c%3c%0a [@%0a [[#abc]]%0a ...template stuff here...%0a [[#abcend]]%0a @]%0a>>%3c%3c%0a%0aand it's possible to display [=TemplatePage=] as a template without it being interpreted... same as we do for [[Site.PageListTemplates]].%0a%0a%0a-%3c [[#footnote]] [- '^[1]^'Okay, maybe it's not so eerie, given that the pagelist template code actually uses the same function as %25pmhlt%25[@(:include:)@] to grab its templates. But it's still a useful parallel. -]%0a%0a[[#includevariable]]%0a!!! Specifying variables as parameters: Use sections as templates%0aYou can also specify variable values inline with the include statement, and refer to the variables in the template using the %25pmhlt%25[@{$$variable1}@] format:%0a-> %25pmhlt%25[@(:include TemplatePage variable1="value" variable2="value2":)@]%0a%0aThis assumes that a site has $EnableRelativePageVars enabled, which is recommended in PmWiki 2.2.0 -- but was disabled by default in version 2.2.8 and earlier.%0a%0aFor example, on my included page ("template") I might have this:%0a%0a(:markup class=horiz:)%0a[[#ivars]]%0aHi, {$$Name}, how are you today?%0a[[#ivarsend]]%0a(:markupend:)%0a%0aThen, including that section above (that section is available via the section %25pmhlt%25[@{$FullName}#ivars@]) you get this type of behavior:%0a%0a(:markup class=horiz:)%0a(:include {$FullName}#ivars Name=Sam:)%0a(:markupend:)%0a%0aIf a value contains spaces, quote it:%0a%0a(:markup class=horiz:)%0a(:include {$FullName}#ivars Name="my friend":)%0a(:markupend:)%0a%0a''See also $EnableUndefinedTemplateVars.''%0a%0a!!!Specific markup%0a%25pmhlt%25[@(:nl:)@] acts like a new line in the ''markup'', only if there isn't one already.%0a%0aThe purpose of %25pmhlt%25[@(:nl:)@] is to be able to write things like "[@(:include Page1:)(:nl:)(:include Page2:)@]" which guarantees that the first line of Page2 is treated as a separate line from the last line of Page1, but without inadvertently generating a blank line between them.%0a%0aSee [[http://thread.gmane.org/gmane.comp.web.wiki.pmwiki.user/15031/focus=15079 | this thread]] and [[http://thread.gmane.org/gmane.comp.web.wiki.pmwiki.user/58609/focus=58633/|this thread]] for more info.%0a%0a%25pmhlt%25[@(:nl:)@] is not intended to put a newline character in the output!%0a%0a!! Parameter References%0a%0aAny parameters supplied to an include statement (whether they are keywords or not) are accessible inside the included page as a special %25pmhlt%25[@{$$...}@] variable of the same name. This feature can be used to provide extra information to use when displaying the included page.%0a%0a!! Notes%0a* You can also say %25pmhlt%25[@(:include My/Page#myanchor lines=4:)@] which starts from, and includes, the line with the anchor [@[[#myanchor]]@] for four lines.%0a%0a!!! Styling Note%0aBy default, Included pages or lines cannot be distinguished from other text on the page. To provide a visual indication that this text is special, you can apply [[PmWiki/Wiki Styles]]. For example:%0a%0a(:markup:)%0a%25define=leftborder border-left="2px solid #88f" margin-left="2px" padding="1px 0 3px 10px"%25%0aWhat is PmWiki?%0a>>leftborder%3c%3c (:include PmWiki.PmWiki lines=1..4:) %0a>>%3c%3c%0a''Have a very nice day!''%0a(:markupend:)%0a%0a!!! Notes about use with [[conditional markup]]%0aThe %25pmhlt%25[@(:include ...:)@] markup is processed after conditional markup is evaluated.\\%0aTherefor you can include a page or page section as part of a condition, like%0a->%25pmhlt%25[@(:if some condition:)(:include SomePage#section:)(:if:) @] %0aBut [@(:include SomePage#section:)@] doesn't look to see if [@[[#section]]@] is part of a conditional, like %0a->%25pmhlt%25[@(:if some condition:)[[#section]]...[[#sectionend]](:ifend:)@]%0a%25pmhlt%25[@(:include SomePage#section:)@] will ignore such a condition. %0a%0aWhen [[Conditional Markup|testing variables]] in included pages the context of the page (source or target) can be useful.%0aSee [[PmWiki/PageVariables#specialreferences|special references]] for details.%0a%0a----%0a%0a!! See Also%0a* [[PmWiki/Page text variables]] {PmWiki/PageTextVariables$:Summary}%0a* [[Cookbook:IncludeUrl]] {Cookbook.IncludeUrl$:Summary}%0a%0a!! FAQ%0a>>faq%3c%3c [[#faq]]%0a%0aQ: [[#maxincludes]] What's the maximum number of includes that can exist in a page? %0a-> My site seems to stop including after 48 includes. ($MaxIncludes)%0a%0aA: By default, PmWiki places a limit of 50 include directives for any given page, to prevent runaway infinite loops and other situations that might eat up server resources. (Two of these are GroupHeader and GroupFooter.) The limit can be modified by the [[wiki administrator]] via the $MaxIncludes variable.%0a%0aQ: Is there any way to include from a group of pages without specifying by exact name, e.g. between Anchor X and Y from all pages named IFClass-* ?%0aA: This can be achieved using [[page lists]].%0a%0a%0aQ: There appears to be a viewing issue when the included page contains the [=(:title:)=] directive.%0aA: In a default installation, the ''last'' title in the page overrides previous ones so you can place your [=(:title :)=] directive at the bottom of the page, after any includes. See also $EnablePageTitlePriority.%0a%0aQ: How to test to see if the page is part of another page?%0aA: (:markup:)%0a(:if ! name {$FullName}:) %0a%25comment%25 name of this page is not the same as the page this text was sourced from%0a->[[{$FullName}#anchor | more ...]]%0a(:ifend:)%0a(:markupend:)%0a%0aQ: Is there any way to include (chapters of) pages which are protected (authuser.php)?%0a%0aA: You can achieve this the other way around: have the public sections in a public page (passwdread=@nopass or @_site_read) and include those into both the protected page, and the public page.%0a%0aA: Note that it is '''strongly recommended to NOT''' hide sensitive content inside a [[conditional( markup)]] in an unprotected page.%0a +time=1710285009 -- cgit v1.2.3