commit 3281ec97b6c959eef4aee8593b1f58a12dbbc56e from: jrmu date: Mon Mar 06 05:00:29 2023 UTC Daily backup commit - e5ab0cb86ff8d86b4660e1abd44f68dee46da31b commit + 3281ec97b6c959eef4aee8593b1f58a12dbbc56e blob - 60facf6cc040c1dc859e0cd9d527344e5d6ef653 blob + baa229b42576ffa4ae53c7a26b15db613fe07c4a --- pub/pmwiki-utils.js +++ pub/pmwiki-utils.js @@ -1,8 +1,8 @@ /* JavaScript utilities for PmWiki - (c) 2009-2020 Petko Yotov www.pmwiki.org/petko + (c) 2009-2022 Petko Yotov www.pmwiki.org/petko based on PmWiki addons DeObMail, AutoTOC and Ape - licensed GNU GPLv2 or any more recent version. + licensed GNU GPLv2 or any more recent version released by the FSF. libsortable() "Sortable tables" adapted for PmWiki from a Public Domain event listener by github.com/tofsjonas @@ -16,12 +16,22 @@ function dqs(str) { return document.querySelector(str); } function dqsa(str) { return document.querySelectorAll(str); } function tap(q, fn) { aE(q, 'click', fn); }; - function adata(el, x) { return el.getAttribute("data-"+x); } - function sdata(el, x, val) { el.setAttribute("data-"+x, val); } - function pf(x) {return parseFloat(x);} + function pf(x) {var y = parseFloat(x); return isNaN(y)? 0:y; } + function zpad(n) {return (n<10)?"0"+n : n; } + function adjbb(el, html) { el.insertAdjacentHTML('beforebegin', html); } + function adjbe(el, html) { el.insertAdjacentHTML('beforeend', html); } + function adjab(el, html) { el.insertAdjacentHTML('afterbegin', html); } + function adjae(el, html) { el.insertAdjacentHTML('afterend', html); } + function getLS(key, parse) { + var x = window.localStorage.getItem(key)|| null; + return parse ? JSON.parse(x) : x;} + function setLS(key, value) { + if (typeof value == 'object') value = JSON.stringify(value); + window.localStorage.setItem(key, value);} + function PHSC(x) { return x.replace(/[&]/g, '&').replace(/[<]/g, '<').replace(/[>]/g, '>'); } - var __script__ = dqs('script[src*="pmwiki-utils.js"]'); - var wikitext = document.getElementById('wikitext'); + var __script__, wikitext; + var log = console.log; function PmXMail() { var els = document.querySelectorAll('span._pmXmail'); @@ -47,12 +57,7 @@ function is_toc_heading(el) { if(el.offsetParent === null) {return false;} // hidden - if(el.className.match(/\bnotoc\b/)) {return false;} // %notoc% - var p = el.parentNode; - while(p && p !== wikitext) { // >>notoc<<, (:markup:) - if(p.className.match(/\b(notoc|markup2)\b/)) {return false;} - if(p.parentNode) p = p.parentNode; - } + if(el.closest('.notoc,.markup2')) {return false;} return true; } function posy(el) { @@ -86,14 +91,8 @@ } return false; } - - function repeat(x, times) { - var y = ''; - for(var i=0; i' + txt + '
\n'; - if(dtoc.EnableBacklinks) hc[0].insertAdjacentHTML('beforeend', ' '); + html += '' + txt + '\n'; + if(dtoc.EnableBacklinks) + adjbe(hc[0], ' '); } @@ -203,10 +205,10 @@ if(!tocdiv) { var wrap = "
"; if(dtoc.ParentElement && dqs(dtoc.ParentElement)) { - dqs(dtoc.ParentElement).insertAdjacentHTML('afterbegin', wrap); + adjab(dqs(dtoc.ParentElement), wrap); } else { - hcache[0][0].insertAdjacentHTML('beforebegin', wrap); + adjbb(hcache[0][0], wrap); } tocdiv = dqs('.PmTOCdiv'); @@ -217,9 +219,9 @@ tocdiv.innerHTML = html; - if(window.localStorage.getItem('closeTOC')) { dqs('#PmTOCchk').checked = true; } + if(getLS('closeTOC')) { dqs('#PmTOCchk').checked = true; } aE('#PmTOCchk', 'change', function(e){ - window.localStorage.setItem('closeTOC', this.checked ? "close" : ''); + setLS('closeTOC', this.checked ? "close" : ''); }); var hh = location.hash; @@ -273,7 +275,7 @@ } function makesortable() { - if(! pf(adata(__script__, 'sortable'))) return; + if(! pf(__script__.dataset.sortable)) return; var tables = dqsa('table.sortable,table.sortable-footer'); for(var i=0; i'+hlvar+''; + } + } } } + } + + var Now, ltmode, daymonth, pagename; + function fmtLocalTime(stamp) { + var d = new Date(stamp*1000); + var tooltip = PHSC(d.toLocaleString()); + if(ltmode == 2) + return [tooltip]; + if(Now-d < 24*3600000) + return [zpad(d.getHours()) + ':'+ zpad(d.getMinutes()), tooltip]; + var D = zpad(d.getDate()), M = zpad(d.getMonth()+1); + var thedate = daymonth.replace(/%d/, D).replace(/%m/, M); + if(Now-d < 334*24*3600000) return [thedate, tooltip]; + return [thedate + '/' + d.getFullYear(), tooltip]; + } + + function localTimes() { + ltmode = pf(__script__.dataset.localtimes); + if(! ltmode) return; + if(ltmode>=11) { + var days = Math.floor(ltmode/10); + ltmode = ltmode%10; + } + else var days = 3; + Now = new Date(); + pagename = __script__.dataset.fullname; + var seenstamp = getLS('seenstamp', true); + if(!seenstamp) seenstamp = {}; + var previous = seenstamp[pagename]; + var times = dqsa('time[datetime]'); + + daymonth = new Date(2021, 11, 26, 17) + .toLocaleDateString().match(/26.*12/)? '%d/%m': '%m/%d'; + + var h72 = Now.getTime()/1000-days*24*3600; + + for(var i=0; i \. \. \. /)) { + var x = fmtLocalTime(stamp); + times[i].innerHTML = x[0]; + times[i].title = x[1] ? x[1]: itemdate.textContent; + continue; + } + var link = li.querySelector('a'); + if(link.className.match(/createlinktext|wikilink|selflink/)) { + var diff = link.href + '?action=diff#diff' + stamp; + if(stamp >= h72) { + var h = link.href + '?action=diff&fmt=rclist'; + adjbe(li, ' +'); + } + } + // recent uploads, other? we want to know when the link becomes "visited" + else diff = link.href + '#diff' + stamp; + times[i].innerHTML = ''+times[i].innerHTML+''; + } + + var difflinks = dqsa('a[href*="#diff"]'), diffcnt = 0; + for(var i=0; iprevious) par.classList.add('rcnew'); + } + if(!diffcnt) return; + var pagetitle = dqs('#wikititle h1, h1.pagetitle'); + if(pagetitle) { + var time = zpad(Now.getHours()) + ':'+ zpad(Now.getMinutes()); + adjbe(pagetitle, ' '+time+''); + tap('.rcreload', function(){location.reload();}); + } + aE('.rcnew', 'mouseup', function(e){ + if(e.which == 2) this.classList.remove('rcnew'); + }); + tap('.rcplus', function(e){ + var plus = this; + plus.style.display = 'none'; + var basehref = plus.dataset.url.replace(/&fmt=rclist/, '#diff') + .replace(/[&]/g, '&'); + var fmt = '

%t %s

\n'; + fetch(plus.dataset.url) + .then(function(resp){return resp.text();}) + .then(function(text){ + var lines = text.split(/\n/g); + var out = ''; + for(var i=0; i summary { + cursor: pointer; +} +details > summary:hover { + color: navy; +} select, textarea, input { font-size: 16px; /*disable zoom-in on some phones*/ @@ -269,6 +280,7 @@ div.imgonly img, div.imgcaption img:first-child { vert .frame { border:1px solid #cccccc; padding:4px; background-color:#f9f9f9; } .lfloat { float:left; margin-right:7px; } .rfloat { float:right; margin-left:7px; } +.clearboth { clear: both; } /* stdmarkup.php */ table.markup { border:2px dotted #ccf; width:100%; } @@ -302,6 +314,10 @@ div.faqtoc div.faq p.question * { display:inline; } .diffmarkup { font-size:14px; } .diffmarkup del { background:#ff9; text-decoration: none; } .diffmarkup ins { background:#9f9; text-decoration: none; } +.rcplus { cursor:pointer; opacity:.3; font-weight:bold; padding: 0 .3em; } +.rcplus:hover {color: white; background: blue; opacity: 1;} +.rcreload { opacity:0.2; font-size: .9rem; cursor: pointer; } +.rcnew {background-color: #ffa;} /* urlapprove.php */ .apprlink { font-size:smaller; } @@ -323,8 +339,14 @@ td.middle, th.middle { vertical-align: middle;} .noPmTOC {display:none;} .PmTOCdiv { display: inline-block; font-size: 13px; overflow: auto; max-height: 500px;} -.PmTOCdiv a { text-decoration: none;} -.back-arrow {font-size: .9em; text-decoration: none;} +.PmTOCdiv a { text-decoration: none; display: block; line-height: 1; margin: .4em 0;} +.PmTOCdiv a.pmtoc-indent1 { margin-left: 1em; } +.PmTOCdiv a.pmtoc-indent2 { margin-left: 2em; } +.PmTOCdiv a.pmtoc-indent3 { margin-left: 3em; } +.PmTOCdiv a.pmtoc-indent4 { margin-left: 4em; } +.PmTOCdiv a.pmtoc-indent5 { margin-left: 5em; } +.PmTOCdiv a.pmtoc-indent6 { margin-left: 6em; } +.back-arrow {font-size: .8rem; text-decoration: none; vertical-align: text-top;} #PmTOCchk + label {cursor: pointer;} #PmTOCchk {display: none;} #PmTOCchk:not(:checked) + label > .pmtoc-show {display: none;} @@ -494,7 +516,6 @@ table.sortable th.dir-d::after { margin-left:0; margin-right: 40px; } - ul, ol { padding: 0 0 0 40px; } dd { margin-left: 40px; } table.horiz td.markup1, table.horiz td.markup2 { blob - 3f761276718f129d9672b9b1263908f594a02cb2 blob + fd18f5826de10eaab6e1524b0d04227a31f2e2b5 --- pub/skins/pmwiki/pmwiki.tmpl +++ pub/skins/pmwiki/pmwiki.tmpl @@ -46,7 +46,7 @@ $[Print] - $[Recent Changes] - $[Search] -
All content is under the IRCNow License. $[Page last modified on {$LastModified}]
+
$[Page last modified on {$LastModified}]
blob - 399b473332d9f376c2daecb81b404332fc5ca921 blob + 90c6643faa12c7641e907bc632298e7d7914228a --- pub/skins/pmwiki-responsive/skin.css +++ pub/skins/pmwiki-responsive/skin.css @@ -1,6 +1,6 @@ /*********************************************************************** ** skin.css -** Copyright 2016-2020 Petko Yotov www.pmwiki.org/petko +** Copyright 2016-2022 Petko Yotov www.pmwiki.org/petko ** ** Partially based on pmwiki.css: ** Copyright 2004-2006 Patrick R. Michaud pmichaud@pobox.com @@ -210,7 +210,7 @@ h6 { font-size:15px; } .wikiaction { margin-top:4px; margin-bottom:4px; } /* These control the fixed-width text elements of the page */ -pre, code { font-size:14px; } +pre, code { font-size: .93333em; } /*14px didn't scale down in smaller text*/ pre, code, .diffmarkup { font-family:'Lucida Console','Andale Mono','Courier New',Courier,monospace; } pre { line-height: 18px; } pre code, code code, pre pre { font-size:100%; } @@ -231,9 +231,14 @@ dd { margin-left: 15px; } ul, ol { - margin: 0; - padding: 0 0 0 20px; + margin: 0; +} +details > summary { + cursor: pointer; } +details > summary:hover { + color: navy; +} select, textarea, input { font-size: 16px; /*disable zoom-in on some phones*/ @@ -269,6 +274,7 @@ div.imgonly img, div.imgcaption img:first-child { vert .frame { border:1px solid #cccccc; padding:4px; background-color:#f9f9f9; } .lfloat { float:left; margin-right:7px; } .rfloat { float:right; margin-left:7px; } +.clearboth { clear: both; } /* stdmarkup.php */ table.markup { border:2px dotted #ccf; width:100%; } @@ -302,6 +308,10 @@ div.faqtoc div.faq p.question * { display:inline; } .diffmarkup { font-size:14px; } .diffmarkup del { background:#ff9; text-decoration: none; } .diffmarkup ins { background:#9f9; text-decoration: none; } +.rcplus { cursor:pointer; opacity:.3; font-weight:bold; padding: 0 .3em; } +.rcplus:hover {color: white; background: blue; opacity: 1;} +.rcreload { opacity:0.2; font-size: .9rem; cursor: pointer; } +.rcnew {background-color: #ffa;} /* urlapprove.php */ .apprlink { font-size:smaller; } @@ -323,8 +333,14 @@ td.middle, th.middle { vertical-align: middle;} .noPmTOC {display:none;} .PmTOCdiv { display: inline-block; font-size: 13px; overflow: auto; max-height: 500px;} -.PmTOCdiv a { text-decoration: none;} -.back-arrow {font-size: .9em; text-decoration: none;} +.PmTOCdiv a { text-decoration: none; display: block; line-height: 1; margin: .4em 0;} +.PmTOCdiv a.pmtoc-indent1 { margin-left: 1em; } +.PmTOCdiv a.pmtoc-indent2 { margin-left: 2em; } +.PmTOCdiv a.pmtoc-indent3 { margin-left: 3em; } +.PmTOCdiv a.pmtoc-indent4 { margin-left: 4em; } +.PmTOCdiv a.pmtoc-indent5 { margin-left: 5em; } +.PmTOCdiv a.pmtoc-indent6 { margin-left: 6em; } +.back-arrow {font-size: .8rem; text-decoration: none; vertical-align: text-top;} #PmTOCchk + label {cursor: pointer;} #PmTOCchk {display: none;} #PmTOCchk:not(:checked) + label > .pmtoc-show {display: none;} @@ -494,7 +510,6 @@ table.sortable th.dir-d::after { margin-left:0; margin-right: 40px; } - ul, ol { padding: 0 0 0 40px; } dd { margin-left: 40px; } table.horiz td.markup1, table.horiz td.markup2 { blob - bdb388b809c945ff1cbebe47baf372060d09bf5c blob + 5688264740cd33bd651aafa3f648d4d5cd519c95 --- pub/skins/pmwiki-responsive/skin.php +++ pub/skins/pmwiki-responsive/skin.php @@ -38,7 +38,7 @@ function MarkupKeepTrackAnchors($m) { } # in HTML5 "clear" is a style not an attribute -Markup('[[<<]]','inline','/\\[\\[<<\\]\\]/',"
"); +Markup('[[<<]]','inline','/\\[\\[<<\\]\\]/',"
"); # Allow skin header and footer to be written # in a wiki page, and use defaults otherwise @@ -64,7 +64,7 @@ SDVA($HideTemplateSections, array( function SkinFmt($pagename, $args) { global $WrapSkinSections, $HideTemplateSections, $TmplDisplay; - $args = preg_split('!\\s+!', $args, null, PREG_SPLIT_NO_EMPTY); + $args = preg_split('!\\s+!', $args, -1, PREG_SPLIT_NO_EMPTY); $section = array_shift($args); $hidesection = $HideTemplateSections[$section]; blob - 27018324e44da9231a64a2c76ec58677ced9f6b8 blob + 596fd4d6c6a213a32d387ed069e869c86de70a20 --- pub/skins/pmwiki-responsive/skin.tmpl +++ pub/skins/pmwiki-responsive/skin.tmpl @@ -74,7 +74,7 @@ $[Recent Changes] - $[Search] -
All content is under the IRCNow License. $[Page last modified on {$LastModified}]
+
$[Page last modified on {$LastModified}]
blob - e4eee0b6dbcf299b1e4c09935107b3a2e85d254c blob + 6164520a4fe947085a2a7eb85fd0ea07a607b573 --- pub/skins/print/print.tmpl +++ pub/skins/print/print.tmpl @@ -14,7 +14,7 @@
$[Retrieved from {$PageUrl}]
-
All content is under the IRCNow License. $[Page last modified on {$LastModified}]
+
$[Page last modified on {$LastModified}]
blob - 28d9eb8f984d3104af4d4055e89c4173b3150c4e blob + 4ab13cfd54a804c884292dbbe6bad5e7ee5c30ec --- scripts/author.php +++ scripts/author.php @@ -1,5 +1,5 @@ "[[~$Author]] $CurrentTime", + '/(? "[[~$Author]] $time", '/(? "[[~$Author]]", )); } blob - 8f03bd05fa4c988ef00149f8d33abc07f1cc6ede blob + 0f1aebf244840bb756270ae02a3dd4a7551f5cb7 --- scripts/authuser.php +++ scripts/authuser.php @@ -1,5 +1,5 @@ $v) $auth[$k] = (array)$v; $authid = ''; @@ -70,13 +76,20 @@ function AuthUserId($pagename, $id, $pw=NULL) { } } + $authlist = array(); if (func_num_args()==2) $authid = $id; else foreach($AuthUserFunctions as $k => $fn) if (@$auth[$k] && $fn($pagename, $id, $pw, $auth[$k], $authlist)) { $authid = $id; break; } - if (!$authid) { $GLOBALS['InvalidLogin'] = 1; return; } + if (!$authid) { $GLOBALS['InvalidLogin'] = 1; if ($flf) $flf($id, 1); return; } + if ($mff && ! $mff($id, $pw)) { + if ($flf) $flf($id, 1); + return; + } + + if (!isset($AuthId)) $AuthId = $authid; $authlist["id:$authid"] = 1; $authlist["id:-$authid"] = -1; @@ -86,7 +99,7 @@ function AuthUserId($pagename, $id, $pw=NULL) { $authlist[$g] = 1; foreach(preg_grep('/^@/', array_keys($auth)) as $g) # useless? PITS:01201 if (in_array($authid, $auth[$g])) $authlist[$g] = 1; - if ($auth['htgroup']) { + if (@$auth['htgroup']) { foreach(AuthUserHtGroup($pagename, $id, $pw, $auth['htgroup']) as $g) $authlist["@$g"] = 1; } @@ -145,7 +158,7 @@ function AuthUserLDAP($pagename, $id, $pw, $pwlist) { list($z, $url, $path) = $match; $ds = ldap_connect($url); ldap_set_option($ds, LDAP_OPT_PROTOCOL_VERSION, 3); - if(isset($AuthLDAPReferrals)) # *NOT* IsEnabled + if (isset($AuthLDAPReferrals)) # *NOT* IsEnabled ldap_set_option($ds, LDAP_OPT_REFERRALS, $AuthLDAPReferrals); ## For Active Directory, don't specify a path and we simply ## attempt to bind with the username and password directly blob - ef0c9904ccb018e484d5cbd985a89b44c76d28e4 blob + 55c17e53917b6b2744d38d2b4adf6ff7d7759d76 --- scripts/blocklist.php +++ scripts/blocklist.php @@ -1,5 +1,5 @@ = 10) { -# SDVA($BlocklistDownload['SiteAdmin.Blocklist-Chongqed'], array( -# 'url' => 'http://blacklist.chongqed.org/', -# 'format' => 'regex')); SDVA($BlocklistDownload['SiteAdmin.Blocklist-MoinMaster'], array( 'url' => 'http://moinmo.in/BadContent?action=raw', 'format' => 'regex')); blob - 314bb4f708d3f8abc3fea40c657516ceaa649018 blob + 67fd5a3e1fc2e00c2abadaa707b332c3c8df449a --- scripts/diag.php +++ scripts/diag.php @@ -16,7 +16,7 @@ if ($action=='diag') { @ini_set('track_errors','1'); @ini_set('display_errors', '1'); - @session_start(); + pm_session_start(); header('Content-type: text/plain'); print_r($GLOBALS); exit(); @@ -80,18 +80,20 @@ function StopWatchHTML($pagename, $print = 0) { - skip non-php files and directories * 2019-11-28: Added to scripts/diag.php by Petko */ -SDV($HandleActions['recipecheck'], 'HandleRecipeCheckCore'); -SDV($HandleAuth['recipecheck'], 'admin'); -SDV($ActionTitleFmt['recipecheck'], '| $[Recipe Check]'); +if($action=='recipecheck') { + SDV($HandleActions['recipecheck'], 'HandleRecipeCheckCore'); + SDV($HandleAuth['recipecheck'], 'admin'); + SDV($ActionTitleFmt['recipecheck'], '| $[Recipe Check]'); -SDV($WikiStyleApply['tr'], 'tr'); -SDV($HTMLStylesFmt['recipecheck'], ' - table.recipecheck tr.ok { color:black; background-color:#ccffcc; } - table.recipecheck tr.check { color:black; background-color:#ffffcc; } - table.recipecheck { border:1px solid #cccccc; padding:4px; } -'); + SDV($WikiStyleApply['tr'], 'tr'); + SDV($HTMLStylesFmt['recipecheck'], ' + table.recipecheck tr.ok { color:black; background-color:#ccffcc; } + table.recipecheck tr.check { color:black; background-color:#ffffcc; } + table.recipecheck { border:1px solid #cccccc; padding:4px; } + '); -SDV($RecipeListUrl, 'http://www.pmwiki.org/pmwiki/recipelist'); + SDV($RecipeListUrl, 'http://www.pmwiki.org/pmwiki/recipelist'); +} function HandleRecipeCheckCore($pagename, $auth = 'admin') { global $RecipeListUrl, $Version, $RecipeInfo, blob - 0bd388210745817a462ce302b34509f4d79f5a42 blob + 66be36386359c1884bcea6f305571bd3f8b354be --- scripts/draft.php +++ scripts/draft.php @@ -1,5 +1,5 @@ "%0a@]%0a%0aThe final result should look like this:%0a%0a[@%0a_adsp._domainkey 86400 IN TXT "dkim=discardable;"%0amail._domainkey 86400 IN TXT "k=rsa; t=s; p=MIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQCmseF9Dm8Dx1LtmLMD56d628JBNaQus8aEcdYYzvBVQ4rhetZzv/ZMafjTEf2RLoOQ+pb7pqL4G86lCZSF+Eeu2ODWQQGYqGVV0xUK5QJSnsGF5UKKscrxmTHSPPtoAQJt25fxNd3PtvH2ZonAGkZkntk+u6Wn5xxlI9hMOVxLUwIDAQAB"%0a@]%0a -time=1631203235 +text=(:title DomainKeys Identified Mail:)%0a%0a!! Introduction%0a%0aDomainKeys Identified Mail (DKIM) is used to detect if an e-mail is spoofed (forged).%0aIt's used to prevent spam and phishing. Signing your mail with DKIM will help%0adetect spam that pretends to come from your domain. It also ensures that your%0aletters pass spam filter checks. Otherwise, letters you send may not end up in the%0ainbox.%0a%0aAn email is signed with a private key. This allows the receiver to check if the email%0acomes from the domain it claims to be from. The receiver looks up the sender's%0apublic key in the domain's DNS record. A valid signature guarantees that the sending%0amail server has access to the private key and that the email body has not been%0atampered with during transit.%0a%0aDKIM, SPF, and DMARC are designed to work together.%0a%0a!! DKIM Header%0a%0aIn our setup, the mail server will sign the message with its private key. Here%0ais what the DKIM header looks like:%0a%0a[@%0aDKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; s=mail; bh=gVJEBqfjoVwtQhV%0a vV3FHh0UQBW0m9unTpuaaGORFGKI=; h=subject:date:from;%0a d=example.com; b=Jv/9zpB2AJGosO4/uYlZxFEm1UFOTy56JBi/nhsjg%0a Am5Qe+rkuKYru5mSqvP01ii/sQRI4exNbG/S8ihdcEXsr5fr8yK4IvLkY8jO5O0xMhblyS%0a PbFGMw7SW2AwLWu95OyHK5teZPzE/SS5U39Zlqs7tS1m8iZo2tPBa70t9204na8/eOT6N7%0a 8IzNIfRHJfF4dNGVX61t9xknkcJrJdC6npO0l4MVTky66safTbcCjlM6JihbUd5j4uOU5I%0a WREE02CLQKWg5c/UnjQQ96Dt308f2RvxeWA6P8hxsjD/FLDIR2U1ZEQyo7k03KCJbdRVw8%0a IHJTdENGGL3p7aM1v8wdg==%0a@]%0a%0a|| border=1 width=100%25 class="sortable simpletable"%0a||! Tag ||! Indicates ||! Example ||%0a|| v || version || v=1 ||%0a|| a || algorithm || a=rsa-sha256 ||%0a|| d || domain || d=example.com ||%0a|| s || selector || s=mail ||%0a|| c || canonicalization algorithm || c=simple/simple ||%0a|| h || header fields || h=subject:date:from ||%0a|| bh || body hash || bh=gVJEBqfjoVwtQhVvV3FHh0UQBW0m9unTpuaaGORFGKI= ||%0a|| b || signature || b=Jv/9zpB2AJGosO4/uYlZxFEm1UFOTy56JBi/nhsjgAm5Qe+rku\\%0aKYru5mSqvP01ii/sQRI4exNbG/S8ihdcEXsr5fr8yK4IvLkY8j\\%0aO5O0xMhblySPbFGMw7SW2AwLWu95OyHK5teZPzE/SS5U39Zlqs\\%0a7tS1m8iZo2tPBa70t9204na8/eOT6N78IzNIfRHJfF4dNGVX61\\%0at9xknkcJrJdC6npO0l4MVTky66safTbcCjlM6JihbUd5j4uOU5\\%0aIWREE02CLQKWg5c/UnjQQ96Dt308f2RvxeWA6P8hxsjD/FLDIR\\%0a2U1ZEQyo7k03KCJbdRVw8IHJTdENGGL3p7aM1v8wdg== ||%0a%0a''Tip'': Many mail clients let you view the mail headers in the email you receive. If you%0adisplay all headers, you can see the DKIM header.%0a%0aA receiving SMTP server will perform a DNS lookup based on the domain name and selector. In the example above, it will look up the TXT record of mail._domainkey.example.com.%0aThis TXT record returned should look like below:%0a%0a[@%0a"k=rsa; t=s; p=MIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQDDmzRmJRQxLEuyYiyMg4suA2Sy%0aMwR5MGHpP9diNT1hRiwUd/mZp1ro7kIDTKS8ttkI6z6eTRW9e9dDOxzSxNuXmume60Cjbu08gOyhPG3%0aGfWdg7QkdN6kR4V75MFlw624VY35DaXBvnlTJTgRg/EW72O1DiYVThkyCgpSYS8nmEQIDAQAB"%0a@]%0a%0a!! Security Notes%0a%0aDKIM-signatures can be used to prove that a mail server sent a letter.%0a%0aNote that DKIM does not provide end-to-end integrity. For this, both sender and receiver will need to use [[PGP/intro|PGP]].%0a%0a!! OpenSMTPd and DKIM%0a%0aFor OpenSMTPd to sign its mail with DKIM, you will need to create a public and private%0aDKIM key:%0a%0a[@%0a$ doas useradd -s /sbin/nologin -d /var/empty -g _dkimsign -G _smtpd _dkimsign%0a$ openssl genrsa -out private.key 1024%0a$ openssl rsa -in private.key -pubout -out public.key%0a$ chmod og-rwx private.key%0a$ chmod og-wx public.key%0a$ chmod u-w public.key private.key%0a$ doas mkdir /etc/dkim%0a$ doas mv private.key public.key /etc/dkim/%0a$ doas chown -R _smtpd:_dovecot /etc/dkim/%0a@]%0a%0aWe then create a DKIM record by taking the public key, removing the first and last%0aline, then joining all the lines together:%0a%0a[@%0a$ doas cat /etc/dkim/public.key | awk '/-----/{if (NR!=1)print "";next}{printf $0}' -%0a@]%0a%0aRunning this command on public.key should produce text like the following:%0a%0a[@%0aMIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQCmseF9Dm8Dx1LtmLMD56d628JBNaQus8aEcdYYzvBVQ4rhetZzv/ZMafjTEf2RLoOQ+pb7pqL4G86lCZSF+Eeu2ODWQQGYqGVV0xUK5QJSnsGF5UKKscrxmTHSPPtoAQJt25fxNd3PtvH2ZonAGkZkntk+u6Wn5xxlI9hMOVxLUwIDAQAB%0a@]%0a%0aThis key should go into the DKIM DNS records:%0a%0a[@%0a_adsp._domainkey 86400 IN TXT "dkim=discardable;"%0amail._domainkey 86400 IN TXT "k=rsa; t=s; p=%3cpublic key>"%0a@]%0a%0aThe final result should look like this:%0a%0a[@%0a_adsp._domainkey 86400 IN TXT "dkim=discardable;"%0amail._domainkey 86400 IN TXT "k=rsa; t=s; p=MIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQCmseF9Dm8Dx1LtmLMD56d628JBNaQus8aEcdYYzvBVQ4rhetZzv/ZMafjTEf2RLoOQ+pb7pqL4G86lCZSF+Eeu2ODWQQGYqGVV0xUK5QJSnsGF5UKKscrxmTHSPPtoAQJt25fxNd3PtvH2ZonAGkZkntk+u6Wn5xxlI9hMOVxLUwIDAQAB"%0a@]%0a +time=1678078118 title=DomainKeys Identified Mail +author:1678078118=jrmu +csum:1678078118=Moved to /etc/dkim/ to fix permissions bugs +diff:1678078118:1631203235:=82,84c82,84%0a%3c $ doas mkdir /etc/dkim%0a%3c $ doas mv private.key public.key /etc/dkim/%0a%3c $ doas chown -R _smtpd:_dovecot /etc/dkim/%0a---%0a> $ doas mkdir /etc/mail/dkim%0a> $ doas mv private.key public.key /etc/mail/dkim/%0a> $ doas chown -R _smtpd:_dovecot /etc/mail/dkim/%0a91c91%0a%3c $ doas cat /etc/dkim/public.key | awk '/-----/{if (NR!=1)print "";next}{printf $0}' -%0a---%0a> $ doas cat /etc/mail/dkim/public.key | awk '/-----/{if (NR!=1)print "";next}{printf $0}' -%0a +host:1678078118=38.87.162.154 author:1631203235=jrmu diff:1631203235:1624860938:=75a76%0a> $ doas groupadd -v _dkimsign%0a host:1631203235=125.231.60.101 blob - 77318bbf696d97cd62cdb709d51e6ff17ec4d497 blob + 78176d8f6eb3cd9e58a670aaa8116c6b6b973732 --- wiki.d/DNS.Mail +++ wiki.d/DNS.Mail @@ -1,16 +1,20 @@ -version=pmwiki-2.2.130 ordered=1 urlencoded=1 +version=pmwiki-2.3.20 ordered=1 urlencoded=1 agent=w3m/0.5.3+git20210102 author=jrmu charset=UTF-8 -csum= +csum=Moved to /etc/dkim/ to fix permissions bugs ctime=1621335466 -host=38.81.163.143 +host=38.87.162.154 name=DNS.Mail -rev=14 +rev=15 targets=Nsd.Configure,Dns.Overview,Dns.FQDN,DNS.SOA,DNS.SPF,DNS.DMARC,DNS.DKIM,DNS.Dnswl -text=(:title DNS for Mail:)%0a%0aRunning a mail server requires a proper DNS records. %0a%0a!! Before you begin%0a%0aThis guide assumes that you have already set up a properly functioning name server using%0a[[nsd/configure|nsd]]. If you have not already, you will want to read up on [[dns/overview|basic DNS concepts]] and [[nsd/configure|set up your name server]].%0a%0a!! Adding to the zone file%0a%0aFor mail, you will need to add DNS records. Let's take a look at a sample zone file%0acontaining only what is needed to handle mail:%0a%0a$ORIGIN and Start of Authority (SOA) record:%0a%0a[@%0a$ORIGIN example.com.%0aexample.com. 3600 SOA ns1.example.com. admin.example.com. (%0a 2021050302 ; serial YYYYMMDDnn%0a 1800 ; refresh%0a 3600 ; retry%0a 86400 ; expire%0a 3600 ) ; minimum TTL%0a@]%0a%0aHere we define the $ORIGIN to be example.com. The $ORIGIN will be appended to every record to produce a [[Dns/FQDN|fully qualified domain name]]. Make sure to read up on [[Dns/FQDN|FQDN]] if you do not understand what that means.%0a%0aThe [[DNS/SOA|Start of Authority record]] says that the serial number was last updated on May 3rd, 2021; that the refresh interval is 1800 seconds, the retry interval is 3600 seconds, the record expires after 1 day, and the minimum time to live is 3600 seconds.%0a%0a[@%0a 3600 IN MX 10 mail%0a 3600 IN A 38.81.163.143%0a 3600 IN AAAA 2602:fccf:1:143::%0a 3600 IN NS ns1%0a 3600 IN NS ns2%0amail 3600 IN A 38.81.163.143%0a 3600 IN AAAA 2602:fccf:1:143::%0apop 3600 IN A 38.81.163.143%0a 3600 IN AAAA 2602:fccf:1:143::%0aimap 3600 IN A 38.81.163.143%0a 3600 IN AAAA 2602:fccf:1:143::%0asmtp 3600 IN A 38.81.163.143%0a 3600 IN AAAA 2602:fccf:1:143::%0a@]%0a%0aWhen there is no name for the record, it just takes on the value of $ORIGIN: example.com.%0a%0aLine 1 defines the mail exchange (MX) record for example.com. When another mail server sends your server mail, it will perform two DNS queries. First, it asks what your MX record is for example.com:%0a%0a[@%0a$ dig +short -t mx example.com%0a10 mail.example.com.%0a@]%0a%0aHere, the MX record for example.com is mail.example.com with a value of 10. This means%0athat mail.example.com is the actual mail server that will handle mail.%0a%0aOnce an MX record is returned, the mail server will find the A/AAAA record for that mail server:%0a%0a[@%0a$ dig +short -t a mail.example.com%0a38.81.163.143%0a@]%0a%0aNormally, a domain will have multiple MX records so that if one mail server goes offline, another can continue serving mail. Most mail servers will choose the MX record with the lowest value to deliver to first.%0a%0a!! [[DNS/SPF|SPF record]]%0a%0aYou'll want to add a TXT record in your domain's [[DNS/SPF|DNS zone for SPF]]:%0a%0a[@%0a 3600 IN TXT "v=spf1 mx -all"%0a@]%0a%0aThis simple SPF record allows any mail exchange (MX) server for the domain to send mail, but no others.%0a%0a!! [[DNS/DMARC|DMARC records]]%0a%0a[@%0a_dmarc 3600 IN TXT "v=DMARC1;p=none;pct=0;fo=1;rua=mailto:postmaster@example.com;ruf=mailto:postmaster@example.com"%0a@]%0a%0aThis record will provide you with reports for DKIM/SPF but will not filter any mail. It's useful for diagnosing problems with your configuration.%0a%0a!! DKIM records%0a%0aYou will need to follow the instructions for creating a proper [[DNS/DKIM|DKIM record]]:%0a%0aFirst, you will need to create a public and private DKIM key:%0a%0a[@%0a$ doas groupadd -v _dkimsign%0a$ doas useradd -s /sbin/nologin -d /var/empty -g _dkimsign -G _smtpd _dkimsign%0a$ openssl genrsa -out private.key 1024%0a$ openssl rsa -in private.key -pubout -out public.key%0a$ chmod og-rwx private.key%0a$ chmod og-wx public.key%0a$ chmod u-w public.key private.key%0a$ doas mkdir /etc/mail/dkim%0a$ doas mv private.key public.key /etc/mail/dkim/%0a$ doas chown -R _smtpd:_dovecot /etc/mail/dkim/%0a@]%0a%0aWe then create a DKIM record by taking the public key, removing the first and last%0aline, then joining all the lines together:%0a%0a[@%0a$ doas cat /etc/mail/dkim/public.key | awk '/-----/{if (NR!=1)print "";next}{printf $0}' -%0a@]%0a%0aRunning this command on public.key should produce text like the following:%0a%0a[@%0aMIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQCmseF9Dm8Dx1LtmLMD56d628JBNaQus8aEcdYYzvBVQ4rhetZzv/ZMafjTEf2RLoOQ+pb7pqL4G86lCZSF+Eeu2ODWQQGYqGVV0xUK5QJSnsGF5UKKscrxmTHSPPtoAQJt25fxNd3PtvH2ZonAGkZkntk+u6Wn5xxlI9hMOVxLUwIDAQAB%0a@]%0a%0aThis key should go into the DKIM DNS records to replace %3cpublic key>:%0a%0a[@%0a_adsp._domainkey 86400 IN TXT "dkim=discardable;"%0amail._domainkey 86400 IN TXT "k=rsa; t=s; p=%3cpublic key>"%0a@]%0a%0aThe final result should look like this:%0a%0a[@%0a_adsp._domainkey 86400 IN TXT "dkim=discardable;"%0amail._domainkey 86400 IN TXT "k=rsa; t=s; p=8AMIIBCgKCAQEAyBhtr90v64hQTfw1sUtFPg5bYXF/SxUTNMziGJMql81av47DG+cDEPmQW0XN8+Tb8yIwenh01hZ5Xh1gjWg1v8OIrnErf3482B8XRZykHJQUdjcALnZ9gGZ9CnzAhIC3TsAnTDSHdgk3c0oqJeilriW0EIAkV2+x1jWlPunGJgJT/bSc2rzZsZv2gZmrrR+2f4aK7xTamAyFUl+cSP/kcoHbEmvXEOtqTQZTTDhxM6BKELUO0xBBhlrsq8C3q92OqZtwflK+IbJDyQPndORMR7R4itIj6O+LMFlYziPitM4egw3KADLZSlycJuTLkhCG5b/3VHFy+uUn3kQc+/s17QIDAQAB"%0a@]%0a%0a!! Whitelists%0a%0a[[DNS/dnswl|dnswl]] is a DNS whitelist that is free of charge, so you should sign up for it.%0a -time=1623943290 +text=(:title DNS for Mail:)%0a%0aRunning a mail server requires a proper DNS records. %0a%0a!! Before you begin%0a%0aThis guide assumes that you have already set up a properly functioning name server using%0a[[nsd/configure|nsd]]. If you have not already, you will want to read up on [[dns/overview|basic DNS concepts]] and [[nsd/configure|set up your name server]].%0a%0a!! Adding to the zone file%0a%0aFor mail, you will need to add DNS records. Let's take a look at a sample zone file%0acontaining only what is needed to handle mail:%0a%0a$ORIGIN and Start of Authority (SOA) record:%0a%0a[@%0a$ORIGIN example.com.%0aexample.com. 3600 SOA ns1.example.com. admin.example.com. (%0a 2021050302 ; serial YYYYMMDDnn%0a 1800 ; refresh%0a 3600 ; retry%0a 86400 ; expire%0a 3600 ) ; minimum TTL%0a@]%0a%0aHere we define the $ORIGIN to be example.com. The $ORIGIN will be appended to every record to produce a [[Dns/FQDN|fully qualified domain name]]. Make sure to read up on [[Dns/FQDN|FQDN]] if you do not understand what that means.%0a%0aThe [[DNS/SOA|Start of Authority record]] says that the serial number was last updated on May 3rd, 2021; that the refresh interval is 1800 seconds, the retry interval is 3600 seconds, the record expires after 1 day, and the minimum time to live is 3600 seconds.%0a%0a[@%0a 3600 IN MX 10 mail%0a 3600 IN A 38.81.163.143%0a 3600 IN AAAA 2602:fccf:1:143::%0a 3600 IN NS ns1%0a 3600 IN NS ns2%0amail 3600 IN A 38.81.163.143%0a 3600 IN AAAA 2602:fccf:1:143::%0apop 3600 IN A 38.81.163.143%0a 3600 IN AAAA 2602:fccf:1:143::%0aimap 3600 IN A 38.81.163.143%0a 3600 IN AAAA 2602:fccf:1:143::%0asmtp 3600 IN A 38.81.163.143%0a 3600 IN AAAA 2602:fccf:1:143::%0a@]%0a%0aWhen there is no name for the record, it just takes on the value of $ORIGIN: example.com.%0a%0aLine 1 defines the mail exchange (MX) record for example.com. When another mail server sends your server mail, it will perform two DNS queries. First, it asks what your MX record is for example.com:%0a%0a[@%0a$ dig +short -t mx example.com%0a10 mail.example.com.%0a@]%0a%0aHere, the MX record for example.com is mail.example.com with a value of 10. This means%0athat mail.example.com is the actual mail server that will handle mail.%0a%0aOnce an MX record is returned, the mail server will find the A/AAAA record for that mail server:%0a%0a[@%0a$ dig +short -t a mail.example.com%0a38.81.163.143%0a@]%0a%0aNormally, a domain will have multiple MX records so that if one mail server goes offline, another can continue serving mail. Most mail servers will choose the MX record with the lowest value to deliver to first.%0a%0a!! [[DNS/SPF|SPF record]]%0a%0aYou'll want to add a TXT record in your domain's [[DNS/SPF|DNS zone for SPF]]:%0a%0a[@%0a 3600 IN TXT "v=spf1 mx -all"%0a@]%0a%0aThis simple SPF record allows any mail exchange (MX) server for the domain to send mail, but no others.%0a%0a!! [[DNS/DMARC|DMARC records]]%0a%0a[@%0a_dmarc 3600 IN TXT "v=DMARC1;p=none;pct=0;fo=1;rua=mailto:postmaster@example.com;ruf=mailto:postmaster@example.com"%0a@]%0a%0aThis record will provide you with reports for DKIM/SPF but will not filter any mail. It's useful for diagnosing problems with your configuration.%0a%0a!! DKIM records%0a%0aYou will need to follow the instructions for creating a proper [[DNS/DKIM|DKIM record]]:%0a%0aFirst, you will need to create a public and private DKIM key:%0a%0a[@%0a$ doas groupadd -v _dkimsign%0a$ doas useradd -s /sbin/nologin -d /var/empty -g _dkimsign -G _smtpd _dkimsign%0a$ openssl genrsa -out private.key 1024%0a$ openssl rsa -in private.key -pubout -out public.key%0a$ chmod og-rwx private.key%0a$ chmod og-wx public.key%0a$ chmod u-w public.key private.key%0a$ doas mkdir /etc/dkim%0a$ doas mv private.key public.key /etc/dkim/%0a$ doas chown -R _smtpd:_dovecot /etc/dkim/%0a@]%0a%0aWe then create a DKIM record by taking the public key, removing the first and last%0aline, then joining all the lines together:%0a%0a[@%0a$ doas cat /etc/dkim/public.key | awk '/-----/{if (NR!=1)print "";next}{printf $0}' -%0a@]%0a%0aRunning this command on public.key should produce text like the following:%0a%0a[@%0aMIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQCmseF9Dm8Dx1LtmLMD56d628JBNaQus8aEcdYYzvBVQ4rhetZzv/ZMafjTEf2RLoOQ+pb7pqL4G86lCZSF+Eeu2ODWQQGYqGVV0xUK5QJSnsGF5UKKscrxmTHSPPtoAQJt25fxNd3PtvH2ZonAGkZkntk+u6Wn5xxlI9hMOVxLUwIDAQAB%0a@]%0a%0aThis key should go into the DKIM DNS records to replace %3cpublic key>:%0a%0a[@%0a_adsp._domainkey 86400 IN TXT "dkim=discardable;"%0amail._domainkey 86400 IN TXT "k=rsa; t=s; p=%3cpublic key>"%0a@]%0a%0aThe final result should look like this:%0a%0a[@%0a_adsp._domainkey 86400 IN TXT "dkim=discardable;"%0amail._domainkey 86400 IN TXT "k=rsa; t=s; p=8AMIIBCgKCAQEAyBhtr90v64hQTfw1sUtFPg5bYXF/SxUTNMziGJMql81av47DG+cDEPmQW0XN8+Tb8yIwenh01hZ5Xh1gjWg1v8OIrnErf3482B8XRZykHJQUdjcALnZ9gGZ9CnzAhIC3TsAnTDSHdgk3c0oqJeilriW0EIAkV2+x1jWlPunGJgJT/bSc2rzZsZv2gZmrrR+2f4aK7xTamAyFUl+cSP/kcoHbEmvXEOtqTQZTTDhxM6BKELUO0xBBhlrsq8C3q92OqZtwflK+IbJDyQPndORMR7R4itIj6O+LMFlYziPitM4egw3KADLZSlycJuTLkhCG5b/3VHFy+uUn3kQc+/s17QIDAQAB"%0a@]%0a%0a!! Whitelists%0a%0a[[DNS/dnswl|dnswl]] is a DNS whitelist that is free of charge, so you should sign up for it.%0a +time=1678078240 title=DNS for Mail +author:1678078240=jrmu +csum:1678078240=Moved to /etc/dkim/ to fix permissions bugs +diff:1678078240:1623943290:=100,102c100,102%0a%3c $ doas mkdir /etc/dkim%0a%3c $ doas mv private.key public.key /etc/dkim/%0a%3c $ doas chown -R _smtpd:_dovecot /etc/dkim/%0a---%0a> $ doas mkdir /etc/mail/dkim%0a> $ doas mv private.key public.key /etc/mail/dkim/%0a> $ doas chown -R _smtpd:_dovecot /etc/mail/dkim/%0a109c109%0a%3c $ doas cat /etc/dkim/public.key | awk '/-----/{if (NR!=1)print "";next}{printf $0}' -%0a---%0a> $ doas cat /etc/mail/dkim/public.key | awk '/-----/{if (NR!=1)print "";next}{printf $0}' -%0a +host:1678078240=38.87.162.154 author:1623943290=jrmu diff:1623943290:1622989290:=94c94%0a%3c $ doas useradd -s /sbin/nologin -d /var/empty -g _dkimsign -G _smtpd _dkimsign%0a---%0a> $ doas useradd -s /sbin/nologin -d /var/empty -g _dkimsign -G _mail _dkimsign%0a102c102%0a%3c $ doas chown -R _smtpd:_dovecot /etc/mail/dkim/%0a---%0a> $ doas chown -R _dkimsign:_dkimsign /etc/mail/dkim/%0a host:1623943290=38.81.163.143 blob - f178b3a216669b36263d70f5e4bb0c40b0db0313 blob + 5ac385e043083281e5cd663ea3d02953df8e6e8b --- wiki.d/DNS.RecentChanges +++ wiki.d/DNS.RecentChanges @@ -1,9 +1,9 @@ -version=pmwiki-2.2.130 ordered=1 urlencoded=1 -agent=Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:109.0) Gecko/20100101 Firefox/109.0 +version=pmwiki-2.3.20 ordered=1 urlencoded=1 +agent=w3m/0.5.3+git20210102 charset=UTF-8 ctime=1621335466 -host=75.158.138.249 +host=38.87.162.154 name=DNS.RecentChanges -rev=77 -text=* [[DNS/Ipv4rDNS]] . . . February 01, 2023, at 08:31 PM by [[~izzyb]]: [=added note to clarify what address needs to be specified.=]%0a* [[DNS/DMARC]] . . . November 22, 2021, at 10:52 PM by [[~Hawk]]: [==]%0a* [[DNS/DKIM]] . . . September 09, 2021, at 04:00 PM by [[~jrmu]]: [==]%0a* [[DNS/Ipv6rDNS]] . . . August 23, 2021, at 11:55 AM by [[~jrmu]]: [==]%0a* [[DNS/RDNS]] . . . August 22, 2021, at 11:20 PM by [[~jrmu]]: [==]%0a* [[DNS/Mail]] . . . June 17, 2021, at 03:21 PM by [[~jrmu]]: [==]%0a* [[DNS/Dnswl]] . . . June 04, 2021, at 11:11 AM by [[~jrmu]]: [==]%0a* [[DNS/SPF]] . . . June 03, 2021, at 01:27 PM by [[~jrmu]]: [==]%0a -time=1675283484 +rev=79 +text=* [[DNS/Mail]] . . . @2023-03-06T04:50:40Z by [[~jrmu]]: [=Moved to /etc/dkim/ to fix permissions bugs=]%0a* [[DNS/DKIM]] . . . @2023-03-06T04:48:38Z by [[~jrmu]]: [=Moved to /etc/dkim/ to fix permissions bugs=]%0a* [[DNS/Ipv4rDNS]] . . . February 01, 2023, at 08:31 PM by [[~izzyb]]: [=added note to clarify what address needs to be specified.=]%0a* [[DNS/DMARC]] . . . November 22, 2021, at 10:52 PM by [[~Hawk]]: [==]%0a* [[DNS/Ipv6rDNS]] . . . August 23, 2021, at 11:55 AM by [[~jrmu]]: [==]%0a* [[DNS/RDNS]] . . . August 22, 2021, at 11:20 PM by [[~jrmu]]: [==]%0a* [[DNS/Dnswl]] . . . June 04, 2021, at 11:11 AM by [[~jrmu]]: [==]%0a* [[DNS/SPF]] . . . June 03, 2021, at 01:27 PM by [[~jrmu]]: [==]%0a +time=1678078240 blob - 7c6bd22c01ee86a191e1c4af4008384d70664f9f blob + 5e318adb6c9d3b71448d3fa1612f80049e99110e --- wiki.d/Openbsd.Ngircd +++ wiki.d/Openbsd.Ngircd @@ -1,16 +1,22 @@ -version=pmwiki-2.2.130 ordered=1 urlencoded=1 -agent=Mozilla/5.0 (Windows NT 10.0; rv:105.0) Gecko/20100101 Firefox/105.0 -author=fossdev +version=pmwiki-2.3.20 ordered=1 urlencoded=1 +agent=Mozilla/5.0 (X11; OpenBSD amd64; rv:102.0) Gecko/20100101 Firefox/102.0 +author=mkf charset=UTF-8 -csum=Edit +csum= ctime=1612974683 -host=2405:201:a40c:a132:4223:43ff:fec0:1a01 -name=Openbsd.Install -rev=121 +host=198.251.81.133 +name=Openbsd.Ngircd +rev=123 targets=Irc.Guide,IP.Myaddress,Ddos.Intro,Chroot.Intro,Netcat.Irc,Hopm.Install,Ngircd.Ssl,Password.Management,Dns.Vhost,Ngircd.Link,Syslogd.Configure,Openbsd.Rcctl,Anope.Install,Acopm.Install -text=(:title Ngircd Install Guide:)%0a%0aIn this guide, we'll setup [[https://ngircd.barton.de/documentation.php.en|ngircd]], a free, portable, lightweight IRC server.%0a%0a!!Overview%0a%0angircd is an [[Irc/Guide|IRC]] server. It helps IRC clients send messages to one another.%0a%0aAdvantages:%0a%0a# The source code is written in modern, portable C.%0a# The code compiles easily on all BSDs, Linux, and other platforms.%0a# The code is easy to fork to add new features such as spam filters%0a# The server has a very simple, easy-to-understand configuration%0a# Documentation is short and easy to understand%0a# The server is a clean implementation which was written from scratch%0a# The lead developer po||ux actively hangs out on the IRC server barton.ngircd.de on #ngircd%0a%0a!! Docs and references%0a%0aBefore installation, please consult:%0a%0a# The [[https://ngircd.barton.de/documentation.php.en|Official ngIRCd documentation]] %0a# After installation, see also /usr/local/share/doc/ngircd/ for local documentation%0a# Consult the man pages:%0a # @@$ man 5 ngircd.conf@@%0a # @@$ man 8 ngircd@@%0a%0a!! Installation%0a%0a!!! Installing from OpenBSD packages%0a%0a[@%0a$ doas pkg_add ngircd%0a@]%0a%0aCopy the sample configuration file:%0a%0a[@%0a$ doas cp /usr/local/share/examples/ngircd/sample-ngircd.conf /etc/ngircd/ngircd.conf%0a@]%0a%0angIRCd v26.1 provided by OpenBSD 7.1 ports does not have ident support. On a production server, ident support is essential, so we will need to compile from source (described below). You will want to do this after installing from packages, so that rc.d scripts are created automatically.%0a%0a!!! Building from source%0a%0a'''Note''': Before building from source, make sure you have ngircd package installed using the instructions from above.%0a%0aDownload the IRC server, extract the code, and build it:%0a%0a[@ %0a$ ftp https://ircnow.org/software/ircnowd.tgz%0a$ tar xvzf ircnowd.tgz%0a$ cd ircnowd/%0a$ sh build.sh %0a@]%0a%0a!! Configuring ngircd%0a%0aEdit @@/etc/ngircd/ngircd.conf@@ as root:%0a%0a'''Note''': Lines that begin with # or ; are comments and will be ignored. You will need to remove # or ; to uncomment.%0a%0aTypically, ";" precedes a line of code that has been commented, while a "#" precedes an actual note that should not be uncommented.%0a%0a!!! Global Block%0a%0a[@%0a[Global]%0a Name = irc.example.com%0a AdminInfo1 = Example Network%0a AdminInfo2 = Planet Earth%0a AdminEMail = admin@example.com%0a HelpFile = /usr/local/share/doc/ngircd/Commands.txt%0a Info = irc.example.com%0a@]%0a%0a* Name: Use your server's domain name.%0a* Info: Use your server's domain name.%0a%0a[@%0a Listen = 127.0.0.1,::1,192.168.1.1,2001:db8::%0a@]%0a%0aProvide every single IP address you want ngircd to listen on. This includes localhost (127.0.0.1 and ::1), and [[IP/Myaddress|our public IPv4 and IPv6 addresses]]. Keep 127.0.0.1 and ::1 untouched, but replace 192.168.1.1 and 2001:db8:: with your real public IPs. If you are hosting a public service, avoid listing IPs that are not DDoS-filtered. IRC servers are heavily [[ddos/intro|DDoSed]] and using an unfiltered IP may get you nullrouted.%0a%0a'''Note''': if you do not uncomment this line, you will listen to all IPs by default, which is probably a mistake.%0a%0a[@%0a MotdFile = /etc/ngircd/ngircd.motd%0a ;MotdPhrase = "Hello world!"%0a Network = ExampleNet%0a ;Password = abc%0a@]%0a%0a* Network: Your network name; this usually contains no periods.%0a%0aKeep the MotdPhrase and Password commented out. First, we will be using a MotdFile instead. Secondly, we do not want a global password for a public server.%0a%0a[@%0a PidFile = /var/run/ngircd/ngircd.pid%0a@]%0a%0aThe Pid file is where ngircd writes its process ID.%0a%0a[@%0a Ports = 6660, 6661, 6662, 6663, 6664, 6665, 6666, 6667, 6668, 6669, 7000, 16667%0a ServerGID = _ngircd%0a ServerUID = _ngircd%0a@]%0a%0aIt's recommended to provide ports besides the standard 6667 to allow users to bypass network firewalls. %0a%0a'''NOTE''': Make sure to set the ServerUID and ServerGID to _ngircd. Otherwise, it runs as the user nobody by default.%0a%0a!!! Limits Block%0a%0a[@%0a[Limits]%0a MaxConnectionsIP = 0%0a MaxJoins = 300%0a MaxNickLength = 16%0a MaxListSize = 3000%0a PingTimeout = 300%0a PongTimeout = 300%0a@]%0a%0aWe allow unlimited connections per IP and handle abuse with other techniques.%0a%0aMaxNickLength: '''must''' be identical for all servers on the network. On IRCNow, MaxNickLength is [@16@].%0a%0a!!! Options Block%0a%0a[@%0a[Options]%0a AllowRemoteOper = yes%0a ChrootDir = /var/ngircd%0a ;CloakHost = %25x%0a CloakHostModeX = %25x%0a CloakHostSalt = abcdefghijklmnopqrstuvwxyz%0a DefaultUserModes = ix%0a DNS = yes%0a Ident = yes%0a@]%0a%0aWe will turn on AllowRemoteOpers so that GLINEs function properly.%0a%0aWe want to [[Chroot.Intro|chroot]] to /var/ngircd to prevent a security compromise. %0a%0aWe will cloak the host using a unique salt; contact another sysadmin for the exact salt. If not linking to another network, you can leave it commented to use a random salt each time it runs, or you can generate your own random salt.%0a%0aWe use CloakHostModeX so that users are cloaked when mode +x is set. Users can then turn off mode x in order to remove the cloak (to show a custom hostmask). If we had used CloakHost instead, uncloaking a user would not be possible.%0a%0aUser mode +i keeps the user invisible so that /whois does not show all channels a user has joined. This helps reduce stalking and harassment.%0a%0aWe want to perform DNS lookups when a client connects so that we can validate a user's hostmask. We also want to perform IDENT lookups.%0a%0a[@%0a NoticeBeforeRegistration = yes%0a OperCanUseMode = yes%0a OperChanPAutoOp = no %0a PAM = no%0a RequireAuthPing = yes%0a SyslogFacility = daemon%0a@]%0a%0aReceiving a notice before registration can help with debugging with [[netcat/irc|netcat]]. It is also necessary for [[hopm/install|hopm]].%0a%0aOperCanUseMode will allow opers the ability to use mode commands when needed. '''Opers should use this power sparingly''', generally only if the channel owner is unable to moderate his channel.%0a%0aOperChanPAutoOp should be set to no so that opers are not automatically op'd in every channel they join. Opers should not interfere with normal channel operation.%0a%0aSet PAM to no because enabling PAM on OpenBSD causes issues.%0a%0aWe set RequireAuthPing to yes because it may help reduce spam.%0a%0aWe're going to log using syslog (see below) to log events.%0a%0a!!! SSL block%0a%0a[@ %0a;[SSL]%0a@]%0a%0a'''This entire block should be commented'''. When you are ready to set up [[ngircd/ssl|SSL/TLS encryption]], un-comment the entire block.%0a%0a'''WARNING''': Do not send passwords or sensitive data over this server until SSL is set up.%0a%0a!!! Operator Block%0a%0aCreate one Operator block for each operator on the server:%0a%0a[@%0a[Operator]%0a Name = username%0a Password = password%0a ;Mask = *!ident@somewhere.example.com%0a@]%0a%0aPlease use a [[password/management|long, random string]] for your password.%0a%0aIf you uncomment Mask, your hostmask must match the operator hostmask in order for the /OPER command to work. If the hostmask differs by even a single character, then your /OPER command will be rejected. It's best to leave Mask commented out until you are familiar with ngircd.%0a%0aOnce your configuration is tested and stable, you can uncomment Mask and have it match your [[dns/vhost|vhost]]. However, please be aware that this will make it impossible to become IRC Operator if you connect from a different IP address.%0a%0a!!! Server Block%0a%0a[@%0a;[Server]%0a@]%0a%0aThe server block is used to connect to other servers to form a network. You can have multiple server blocks. For now, leave it commented out until you are ready to [[ngircd/link|link ngircd]].%0a%0aYou are now finished editing ngircd.conf, so we turn to edit other files.%0a%0a!! MOTD file%0a%0aCreate the Message of the Day in /etc/ngircd/ngircd.motd. Here is a suggested template:%0a%0a[@%0aIRCNow - The Users' Network%0a%0aIRCNow is the network of the user, by the user, for the user.%0a%0a * No porn / illegal drugs / threats of violence%0a * No slander / libel / gambling%0a * No spam, illegal cracking, or DDoS%0a * No copyright infrigement%0a%0aYou must agree to our terms of service and our privacy policy %0ato use this network:%0a%0ahttps://wiki.ircnow.org/index.php?n=Terms.Terms%0a%0aOnly 5 connections per IP address. If you need help, please speak with staff on #help.%0a@]%0a%0a!! Configuring [[syslogd/configure|syslog]]%0a%0aAll log messages from ngircd should go to [@ /var/log/ngircd.log @]. Insert these three lines starting at line 3 (at the top) in [@/etc/syslog.conf@]:%0a%0a[@%0a!!ngircd%0a*.* /var/log/ngircd.log%0a!*%0a@]%0a%0aThis directs all logs from ngircd to go straight to /var/log/ngircd.log.%0a%0aSyslogd expects all logfiles to already exist with the correct permissions. So, we will create the file /var/log/ngircd.log and restart syslogd:%0a%0a[@%0a$ doas touch /var/log/ngircd.log%0a$ doas rcctl restart syslogd%0a@]%0a%0a!! Chroot%0a%0aWe need to set up the [[chroot/intro|chroot]] for ngircd. Let's copy the files into the chroot:%0a%0a[@%0a$ doas mkdir /var/ngircd/etc/%0a$ doas cp /etc/resolv.conf /var/ngircd/etc/%0a$ doas cp -R /etc/ngircd /var/ngircd/etc/%0a$ doas chown -R _ngircd:_ngircd /var/ngircd/%0a$ doas rm -r /etc/ngircd%0a$ doas ln -s /var/ngircd/etc/ngircd /etc/ngircd%0a$ doas mkdir -p /var/ngircd/usr/local/share/doc/%0a$ doas cp -R /usr/local/share/doc/ngircd/ /var/ngircd/usr/local/share/doc/%0a$ doas chown -R _ngircd:_ngircd /var/ngircd/usr/local/share/doc/ngircd/%0a@]%0a%0aThis will create a symlink so that only one set of configuration files needs to be maintained inside and outside of the chroot. Otherwise, ngircd will require two sets of configuration files, one inside and the other outside of the chroot.%0a%0a!! Automation%0a%0aTo automatically restart ngIRCd if it was terminated unexpectedly, create a script in /usr/local/libexec/ngircd/restart.sh:%0a%0a[@%0a$ doas mkdir -p /usr/local/libexec/ngircd/%0a$ doas touch /usr/local/libexec/ngircd/restart.sh%0a$ doas chmod +x /usr/local/libexec/ngircd/restart.sh%0a@]%0a%0aEdit @@/usr/local/libexec/ngircd/restart.sh@@:%0a%0a[@%0a#!/bin/sh%0a%0aSERVICE_NAME="ngircd"%0aSERVICE_USER="_ngircd"%0aSERVICE_PID="/var/ngircd/var/run/ngircd/ngircd.pid"%0a%0aif ! pgrep -u $SERVICE_USER -x "$SERVICE_NAME" > /dev/null%0athen%0a if [ -f $SERVICE_PID ]; then%0a rm -f $SERVICE_PID%0a rcctl -d restart $SERVICE_NAME%0a fi%0afi%0a@]%0a%0aAdd this as a cronjob:%0a%0a[@%0a$ doas crontab -e%0a%0a*/5 * * * * /usr/local/libexec/ngircd/restart.sh > /dev/null 2>&1%0a@]%0a%0aFor the solution to work, make sure you have enabled the use of pid files in /etc/ngircd/ngircd.conf:%0a%0a[@%0aPidFile = /var/run/ngircd/ngircd.pid%0a@]%0a%0a!! Starting ngircd%0a%0aTo start ngircd via [[openbsd/rcctl|rcctl]]:%0a%0a[@%0adoas rcctl enable ngircd%0adoas rcctl start ngircd%0a@]%0a%0aNext, use your IRC client to connect to the server. Join a few channels and chat inside. You will need to invite your friends, since a new IRC server will have no other users on it.%0a%0a!! Troubleshooting%0a%0aIf you run into any errors, you can test to see if your configuration file has errors:%0a%0a[@%0a$ doas ngircd -t%0a@]%0a%0aTo run ngircd in debug mode:%0a%0a[@%0a$ doas ngircd -n%0a@]%0a%0aCheck [@ /var/log/ngircd.log @] to see if ngircd is listening on the correct IP addresses and ports. Connect to those ports using your IRC client to verify that the server is working as intended.%0a%0aRemember, if you are connecting using port 6667 without SSL, any eavesdropper can read all your text, including your passwords. '''Don't send any sensitive information until you have upgraded to [[ngircd/ssl|SSL]].'''%0a%0a!! Reloading and Restarting ngIRCd%0a%0aAfter you edit [@ /etc/ngircd/ngircd.conf @] for a running ngircd server, you will need to reload the configuration file:%0a%0a[@%0a$ doas rcctl reload ngircd%0a@]%0a%0aAlternatively, you can run:%0a%0a[@%0a$ doas pkill -HUP ngircd%0a@]%0a%0a'''Reloading''' a configuration file will '''not''' disconnect any active connections. So, try to reload the configuration where possible '''instead of restarting the service'''.%0a%0aTo restart the ircd:%0a%0a[@%0a$ doas rcctl restart ngircd%0a@]%0a%0a'''WARNING''': '''Restarting''' the ircd '''will''' disconnect all existing connections. So, try to restart ngircd only when absolutely necessary.%0a%0a'''WARNING''': ngircd appears to have a bug where the ircd will crash if you reload the configuration file while a message is being sent. Be careful to avoid reloading configuration files when many users are chatting.%0a%0a!! See Also%0a%0a# Configure [[ngircd/ssl|SSL]] for ngircd to ensure secure connections%0a# [[ngircd/link|Link your ngircd]] with another server to create a network%0a# Install [[anope/install|anope]] to provide services%0a# Configure [[hopm/install|hopm]], an open proxy monitor to stop spammers.%0a# Configure [[acopm/install|acopm]], a minimalist open proxy monitor to stop spammers.%0a -time=1667565713 +text=(:title Ngircd Install Guide:)%0a%0aIn this guide, we'll setup [[https://ngircd.barton.de/documentation.php.en|ngircd]], a free, portable, lightweight IRC server.%0a%0a!!Overview%0a%0angircd is an [[Irc/Guide|IRC]] server. It helps IRC clients send messages to one another.%0a%0aAdvantages:%0a%0a# The source code is written in modern, portable C.%0a# The code compiles easily on all BSDs, Linux, and other platforms.%0a# The code is easy to fork to add new features such as spam filters%0a# The server has a very simple, easy-to-understand configuration%0a# Documentation is short and easy to understand%0a# The server is a clean implementation which was written from scratch%0a# The lead developer po||ux actively hangs out on the IRC server barton.ngircd.de on #ngircd%0a%0a!! Docs and references%0a%0aBefore installation, please consult:%0a%0a# The [[https://ngircd.barton.de/documentation.php.en|Official ngIRCd documentation]] %0a# After installation, see also /usr/local/share/doc/ngircd/ for local documentation%0a# Consult the man pages:%0a # @@$ man 5 ngircd.conf@@%0a # @@$ man 8 ngircd@@%0a%0a!! Installation%0a%0a!!! Installing from OpenBSD packages%0a%0a[@%0a$ doas pkg_add ngircd%0a@]%0a%0aCopy the sample configuration file:%0a%0a[@%0a$ doas cp /usr/local/share/examples/ngircd/sample-ngircd.conf /etc/ngircd/ngircd.conf%0a@]%0a%0angIRCd v26.1 provided by OpenBSD 7.1 ports does not have ident support. On a production server, ident support is essential, so we will need to compile from source (described below). You will want to do this after installing from packages, so that rc.d scripts are created automatically.%0a%0a!!! Building from source%0a%0a'''Note''': Before building from source, make sure you have ngircd package installed using the instructions from above.%0a%0aDownload the IRC server, extract the code, and build it:%0a%0a[@%0a$ ftp https://ircnow.org/software/ircnowd.tgz%0a$ tar xvzf ircnowd.tgz%0a$ cd ircnowd/%0a$ sh build.sh %0a@]%0a%0a!! Configuring ngircd%0a%0aEdit @@/etc/ngircd/ngircd.conf@@ as root:%0a%0a'''Note''': Lines that begin with # or ; are comments and will be ignored. You will need to remove # or ; to uncomment.%0a%0aTypically, ";" precedes a line of code that has been commented, while a "#" precedes an actual note that should not be uncommented.%0a%0a!!! Global Block%0a%0a[@%0a[Global]%0a Name = irc.example.com%0a AdminInfo1 = Example Network%0a AdminInfo2 = Planet Earth%0a AdminEMail = admin@example.com%0a HelpFile = /usr/local/share/doc/ngircd/Commands.txt%0a Info = irc.example.com%0a@]%0a%0a* Name: Use your server's domain name.%0a* Info: Use your server's domain name.%0a%0a[@%0a Listen = 127.0.0.1,::1,192.168.1.1,2001:db8::%0a@]%0a%0aProvide every single IP address you want ngircd to listen on. This includes localhost (127.0.0.1 and ::1), and [[IP/Myaddress|our public IPv4 and IPv6 addresses]]. Keep 127.0.0.1 and ::1 untouched, but replace 192.168.1.1 and 2001:db8:: with your real public IPs. If you are hosting a public service, avoid listing IPs that are not DDoS-filtered. IRC servers are heavily [[ddos/intro|DDoSed]] and using an unfiltered IP may get you nullrouted.%0a%0a'''Note''': if you do not uncomment this line, you will listen to all IPs by default, which is probably a mistake.%0a%0a[@%0a MotdFile = /etc/ngircd/ngircd.motd%0a ;MotdPhrase = "Hello world!"%0a Network = ExampleNet%0a ;Password = abc%0a@]%0a%0a* Network: Your network name; this usually contains no periods.%0a%0aKeep the MotdPhrase and Password commented out. First, we will be using a MotdFile instead. Secondly, we do not want a global password for a public server.%0a%0a[@%0a PidFile = /var/run/ngircd/ngircd.pid%0a@]%0a%0aThe Pid file is where ngircd writes its process ID.%0a%0a[@%0a Ports = 6660, 6661, 6662, 6663, 6664, 6665, 6666, 6667, 6668, 6669, 7000, 16667%0a ServerGID = _ngircd%0a ServerUID = _ngircd%0a@]%0a%0aIt's recommended to provide ports besides the standard 6667 to allow users to bypass network firewalls. %0a%0a'''NOTE''': Make sure to set the ServerUID and ServerGID to _ngircd. Otherwise, it runs as the user nobody by default.%0a%0a!!! Limits Block%0a%0a[@%0a[Limits]%0a MaxConnectionsIP = 0%0a MaxJoins = 300%0a MaxNickLength = 16%0a MaxListSize = 3000%0a PingTimeout = 300%0a PongTimeout = 300%0a@]%0a%0aWe allow unlimited connections per IP and handle abuse with other techniques.%0a%0aMaxNickLength: '''must''' be identical for all servers on the network. On IRCNow, MaxNickLength is [@16@].%0a%0a!!! Options Block%0a%0a[@%0a[Options]%0a AllowRemoteOper = yes%0a ChrootDir = /var/ngircd%0a ;CloakHost = %25x%0a CloakHostModeX = %25x%0a CloakHostSalt = abcdefghijklmnopqrstuvwxyz%0a DefaultUserModes = ix%0a DNS = yes%0a Ident = yes%0a@]%0a%0aWe will turn on AllowRemoteOpers so that GLINEs function properly.%0a%0aWe want to [[Chroot.Intro|chroot]] to /var/ngircd to prevent a security compromise. %0a%0aWe will cloak the host using a unique salt; contact another sysadmin for the exact salt. If not linking to another network, you can leave it commented to use a random salt each time it runs, or you can generate your own random salt.%0a%0aWe use CloakHostModeX so that users are cloaked when mode +x is set. Users can then turn off mode x in order to remove the cloak (to show a custom hostmask). If we had used CloakHost instead, uncloaking a user would not be possible.%0a%0aUser mode +i keeps the user invisible so that /whois does not show all channels a user has joined. This helps reduce stalking and harassment.%0a%0aWe want to perform DNS lookups when a client connects so that we can validate a user's hostmask. We also want to perform IDENT lookups.%0a%0a[@%0a NoticeBeforeRegistration = yes%0a OperCanUseMode = yes%0a OperChanPAutoOp = no %0a PAM = no%0a RequireAuthPing = yes%0a SyslogFacility = daemon%0a@]%0a%0aReceiving a notice before registration can help with debugging with [[netcat/irc|netcat]]. It is also necessary for [[hopm/install|hopm]].%0a%0aOperCanUseMode will allow opers the ability to use mode commands when needed. '''Opers should use this power sparingly''', generally only if the channel owner is unable to moderate his channel.%0a%0aOperChanPAutoOp should be set to no so that opers are not automatically op'd in every channel they join. Opers should not interfere with normal channel operation.%0a%0aSet PAM to no because enabling PAM on OpenBSD causes issues.%0a%0aWe set RequireAuthPing to yes because it may help reduce spam.%0a%0aWe're going to log using syslog (see below) to log events.%0a%0a!!! SSL block%0a%0a[@%0a;[SSL]%0a@]%0a%0a'''This entire block should be commented'''. When you are ready to set up [[ngircd/ssl|SSL/TLS encryption]], un-comment the entire block.%0a%0a'''WARNING''': Do not send passwords or sensitive data over this server until SSL is set up.%0a%0a!!! Operator Block%0a%0aCreate one Operator block for each operator on the server:%0a%0a[@%0a[Operator]%0a Name = username%0a Password = password%0a ;Mask = *!ident@somewhere.example.com%0a@]%0a%0aPlease use a [[password/management|long, random string]] for your password.%0a%0aIf you uncomment Mask, your hostmask must match the operator hostmask in order for the /OPER command to work. If the hostmask differs by even a single character, then your /OPER command will be rejected. It's best to leave Mask commented out until you are familiar with ngircd.%0a%0aOnce your configuration is tested and stable, you can uncomment Mask and have it match your [[dns/vhost|vhost]]. However, please be aware that this will make it impossible to become IRC Operator if you connect from a different IP address.%0a%0a!!! Server Block%0a%0a[@%0a;[Server]%0a@]%0a%0aThe server block is used to connect to other servers to form a network. You can have multiple server blocks. For now, leave it commented out until you are ready to [[ngircd/link|link ngircd]].%0a%0aYou are now finished editing ngircd.conf, so we turn to edit other files.%0a%0a!! MOTD file%0a%0aCreate the Message of the Day in /etc/ngircd/ngircd.motd. Here is a suggested template:%0a%0a[@%0aIRCNow - The Users' Network%0a%0aIRCNow is the network of the user, by the user, for the user.%0a%0a * No porn / illegal drugs / threats of violence%0a * No slander / libel / gambling%0a * No spam, illegal cracking, or DDoS%0a * No copyright infrigement%0a%0aYou must agree to our terms of service and our privacy policy %0ato use this network:%0a%0ahttps://wiki.ircnow.org/index.php?n=Terms.Terms%0a%0aOnly 5 connections per IP address. If you need help, please speak with staff on #help.%0a@]%0a%0a!! Configuring [[syslogd/configure|syslog]]%0a%0aAll log messages from ngircd should go to [@ /var/log/ngircd.log @]. Insert these three lines starting at line 3 (at the top) in [@/etc/syslog.conf@]:%0a%0a[@%0a!!ngircd%0a*.* /var/log/ngircd.log%0a!*%0a@]%0a%0aThis directs all logs from ngircd to go straight to /var/log/ngircd.log.%0a%0aSyslogd expects all logfiles to already exist with the correct permissions. So, we will create the file /var/log/ngircd.log and restart syslogd:%0a%0a[@%0a$ doas touch /var/log/ngircd.log%0a$ doas rcctl restart syslogd%0a@]%0a%0a!! Chroot%0a%0aWe need to set up the [[chroot/intro|chroot]] for ngircd. Let's copy the files into the chroot:%0a%0a[@%0a$ doas mkdir /var/ngircd/etc/%0a$ doas cp /etc/resolv.conf /var/ngircd/etc/%0a$ doas cp -R /etc/ngircd /var/ngircd/etc/%0a$ doas chown -R _ngircd:_ngircd /var/ngircd/%0a$ doas rm -r /etc/ngircd%0a$ doas ln -s /var/ngircd/etc/ngircd /etc/ngircd%0a$ doas mkdir -p /var/ngircd/usr/local/share/doc/%0a$ doas cp -R /usr/local/share/doc/ngircd/ /var/ngircd/usr/local/share/doc/%0a$ doas chown -R _ngircd:_ngircd /var/ngircd/usr/local/share/doc/ngircd/%0a@]%0a%0aThis will create a symlink so that only one set of configuration files needs to be maintained inside and outside of the chroot. Otherwise, ngircd will require two sets of configuration files, one inside and the other outside of the chroot.%0a%0a!! Automation%0a%0aTo automatically restart ngIRCd if it was terminated unexpectedly, create a script in /usr/local/libexec/ngircd/restart.sh:%0a%0a[@%0a$ doas mkdir -p /usr/local/libexec/ngircd/%0a$ doas touch /usr/local/libexec/ngircd/restart.sh%0a$ doas chmod +x /usr/local/libexec/ngircd/restart.sh%0a@]%0a%0aEdit @@/usr/local/libexec/ngircd/restart.sh@@:%0a%0a[@%0a#!/bin/sh%0a%0aSERVICE_NAME="ngircd"%0aSERVICE_USER="_ngircd"%0aSERVICE_PID="/var/ngircd/var/run/ngircd/ngircd.pid"%0a%0aif ! pgrep -u $SERVICE_USER -x "$SERVICE_NAME" > /dev/null%0athen%0a if [ -f $SERVICE_PID ]; then%0a rm -f $SERVICE_PID%0a rcctl -d restart $SERVICE_NAME%0a fi%0afi%0a@]%0a%0aAdd this as a cronjob:%0a%0a[@%0a$ doas crontab -e%0a%0a*/5 * * * * /usr/local/libexec/ngircd/restart.sh > /dev/null 2>&1%0a@]%0a%0aFor the solution to work, make sure you have enabled the use of pid files in /etc/ngircd/ngircd.conf:%0a%0a[@%0aPidFile = /var/run/ngircd/ngircd.pid%0a@]%0a%0a!! Starting ngircd%0a%0aTo start ngircd via [[openbsd/rcctl|rcctl]]:%0a%0a[@%0adoas rcctl enable ngircd%0adoas rcctl start ngircd%0a@]%0a%0aNext, use your IRC client to connect to the server. Join a few channels and chat inside. You will need to invite your friends, since a new IRC server will have no other users on it.%0a%0a!! Troubleshooting%0a%0aIf you run into any errors, you can test to see if your configuration file has errors:%0a%0a[@%0a$ doas ngircd -t%0a@]%0a%0aTo run ngircd in debug mode:%0a%0a[@%0a$ doas ngircd -n%0a@]%0a%0aCheck [@ /var/log/ngircd.log @] to see if ngircd is listening on the correct IP addresses and ports. Connect to those ports using your IRC client to verify that the server is working as intended.%0a%0aRemember, if you are connecting using port 6667 without SSL, any eavesdropper can read all your text, including your passwords. '''Don't send any sensitive information until you have upgraded to [[ngircd/ssl|SSL]].'''%0a%0a!! Reloading and Restarting ngIRCd%0a%0aAfter you edit [@ /etc/ngircd/ngircd.conf @] for a running ngircd server, you will need to reload the configuration file:%0a%0a[@%0a$ doas rcctl reload ngircd%0a@]%0a%0aAlternatively, you can run:%0a%0a[@%0a$ doas pkill -HUP ngircd%0a@]%0a%0a'''Reloading''' a configuration file will '''not''' disconnect any active connections. So, try to reload the configuration where possible '''instead of restarting the service'''.%0a%0aTo restart the ircd:%0a%0a[@%0a$ doas rcctl restart ngircd%0a@]%0a%0a'''WARNING''': '''Restarting''' the ircd '''will''' disconnect all existing connections. So, try to restart ngircd only when absolutely necessary.%0a%0a'''WARNING''': ngircd appears to have a bug where the ircd will crash if you reload the configuration file while a message is being sent. Be careful to avoid reloading configuration files when many users are chatting.%0a%0a!! See Also%0a%0a# Configure [[ngircd/ssl|SSL]] for ngircd to ensure secure connections%0a# [[ngircd/link|Link your ngircd]] with another server to create a network%0a# Install [[anope/install|anope]] to provide services%0a# Configure [[hopm/install|hopm]], an open proxy monitor to stop spammers.%0a# Configure [[acopm/install|acopm]], a minimalist open proxy monitor to stop spammers.%0a +time=1678040259 title=Ngircd Install Guide +author:1678040259=mkf +diff:1678040259:1678040136:=181c181%0a%3c [@%0a---%0a> [@ %0a +host:1678040259=198.251.81.133 +author:1678040136=mkf +diff:1678040136:1667565713:=51c51%0a%3c [@%0a---%0a> [@ %0a +host:1678040136=198.251.81.133 author:1667565713=fossdev csum:1667565713=Edit diff:1667565713:1659546979:= blob - 2453e87f0d98ae532ffab3827b06dd52e8a854fb blob + e0801330ca7799d1ae8dfb672128028c53413c04 --- wiki.d/Openbsd.RecentChanges +++ wiki.d/Openbsd.RecentChanges @@ -1,9 +1,9 @@ -version=pmwiki-2.2.130 ordered=1 urlencoded=1 -agent=Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/92.0.4515.131 Safari/537.36 +version=pmwiki-2.3.20 ordered=1 urlencoded=1 +agent=Mozilla/5.0 (X11; OpenBSD amd64; rv:102.0) Gecko/20100101 Firefox/102.0 charset=UTF-8 ctime=1596189997 -host=2001:bc8:1830:1533::12 +host=198.251.81.133 name=Openbsd.RecentChanges -rev=1933 -text=* [[Openbsd/OpenTracker]] . . . March 03, 2023, at 04:37 PM by [[~baytuch]]: [==]%0a* [[Openbsd/Gotweb]] . . . February 26, 2023, at 05:04 PM by [[~fossdev]]: [==]%0a* [[Openbsd/Plermoa]] . . . February 16, 2023, at 04:52 AM by [[~Yonle]]: [=Redirect=]%0a* [[Openbsd/Pleroma]] . . . February 12, 2023, at 02:49 AM by [[~Yonle]]: [=Oops=]%0a* [[Openbsd/Akkoma]] . . . February 12, 2023, at 02:48 AM by [[~Yonle]]: [=Oof=]%0a* [[Openbsd/Mlmmj]] . . . February 08, 2023, at 02:50 AM by [[~Yonle]]: [==]%0a* [[Openbsd/Mosh]] . . . February 07, 2023, at 11:30 AM by [[~Yonle]]: [==]%0a* [[Openbsd/Passwords]] . . . February 03, 2023, at 07:49 PM by [[~izzyb]]: [==]%0a* [[Openbsd/Biboumi]] . . . January 20, 2023, at 08:11 PM by [[~mkf]]: [==]%0a* [[Openbsd/Unrealircd]] . . . January 20, 2023, at 07:27 PM by [[~mkf]]: [==]%0a* [[Openbsd/Vipw]] . . . January 18, 2023, at 11:01 PM by [[~zen]]: [=added two spaces=]%0a* [[Openbsd/Loginconf]] . . . January 18, 2023, at 10:48 PM by [[~zen]]: [=OpenBSD FAQ link refenrece=]%0a* [[Openbsd/Singleuser]] . . . January 18, 2023, at 10:26 PM by [[~zen]]: [=changed the link reference=]%0a* [[Openbsd/Dump]] . . . January 10, 2023, at 04:48 PM by [[~mkf]]: [=add -u, improve dump-ssh funcationality.=]%0a* [[Openbsd/Quota]] . . . December 29, 2022, at 06:51 PM by [[~mkf]]: [==]%0a* [[Openbsd/Minetest]] . . . December 26, 2022, at 07:23 PM by [[~miniontoby]]: [=Added more ways to install=]%0a* [[Openbsd/Honk]] . . . December 17, 2022, at 08:45 AM by [[~Yonle]]: [==]%0a* [[Openbsd/Icecast]] . . . November 17, 2022, at 11:35 AM by [[~Yonle]]: [==]%0a* [[Openbsd/Geomyidae]] . . . September 10, 2022, at 02:31 AM by [[~akoizumi]]: [==]%0a* [[Openbsd/INN]] . . . September 10, 2022, at 02:23 AM by [[~akoizumi]]: [=Fix some types=]%0a* [[Openbsd/VsFTP]] . . . August 10, 2022, at 03:18 PM by [[~mkf]]: [=snipped unneeded output=]%0a* [[Openbsd/Apmd]] . . . July 03, 2022, at 11:36 AM by [[~mkf]]: [==]%0a* [[Openbsd/Pkg]] . . . June 12, 2022, at 12:32 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Intro]] . . . June 09, 2022, at 07:53 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Bsdrd]] . . . June 09, 2022, at 07:17 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Sysupgrade71]] . . . June 05, 2022, at 11:49 PM by [[~jrmu]]: [==]%0a* [[Openbsd/Growfs]] . . . June 01, 2022, at 12:34 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Nsd]] . . . May 10, 2022, at 12:33 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Ports]] . . . May 09, 2022, at 05:54 AM by [[~mkf]]: [==]%0a* [[Openbsd/Rcctl]] . . . May 09, 2022, at 05:53 AM by [[~mkf]]: [==]%0a* [[Openbsd/Upgrade71]] . . . May 03, 2022, at 06:36 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Install71]] . . . April 24, 2022, at 09:55 PM by [[~jrmu]]: [==]%0a* [[Openbsd/Botnow]] . . . April 24, 2022, at 06:14 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Gopher]] . . . April 20, 2022, at 08:29 PM by [[~jrmu]]: [==]%0a* [[Openbsd/Adduser]] . . . April 20, 2022, at 08:07 PM by [[~jrmu]]: [==]%0a* [[Openbsd/Ntpd]] . . . April 20, 2022, at 06:16 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Vmmlinux]] . . . April 20, 2022, at 05:33 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Iked]] . . . April 20, 2022, at 05:16 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Team]] . . . April 20, 2022, at 04:54 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Announce]] . . . April 19, 2022, at 04:14 PM by [[~jrmu]]: [==]%0a* [[Openbsd/Install70]] . . . April 19, 2022, at 06:52 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Upgrade70]] . . . April 19, 2022, at 06:49 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Censord]] . . . April 05, 2022, at 06:16 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Hopm]] . . . April 05, 2022, at 06:09 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Dns]] . . . April 05, 2022, at 05:24 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Psybnc]] . . . March 30, 2022, at 09:56 PM by [[~jrmu]]: [==]%0a* [[Openbsd/Ddos]] . . . March 24, 2022, at 04:22 PM by [[~jrmu]]: [==]%0a* [[Openbsd/IRCBridge]] . . . February 28, 2022, at 02:59 AM by [[~suzerain]]: [==]%0a* [[Openbsd/Wesnothd]] . . . February 21, 2022, at 06:28 AM by [[~mkf]]: [=Wesnothd=]%0a* [[Openbsd/Xonotic]] . . . February 20, 2022, at 07:43 AM by [[~mkf]]: [=A xonotic server has apperad! pt.2=]%0a* [[Openbsd/Police]] . . . February 10, 2022, at 07:36 PM by [[~jrmu]]: [==]%0a* [[Openbsd/Tcpip]] . . . January 24, 2022, at 05:45 PM by [[~jrmu]]: [==]%0a* [[Openbsd/U9fs]] . . . January 16, 2022, at 06:23 PM by [[~mkf]]: [==]%0a* [[Openbsd/Locale]] . . . January 12, 2022, at 01:23 PM by [[~baytuch]]: [==]%0a* [[Openbsd/Openbsd]] . . . January 12, 2022, at 01:19 PM by [[~baytuch]]: [==]%0a* [[Openbsd/BBB]] . . . January 03, 2022, at 12:06 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Sftp]] . . . December 30, 2021, at 06:01 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Uim]] . . . December 26, 2021, at 01:45 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Wifi]] . . . December 22, 2021, at 02:59 PM by [[~jrmu]]: [==]%0a* [[Openbsd/Recordaudio]] . . . December 22, 2021, at 01:24 PM by [[~jrmu]]: [==]%0a* [[Openbsd/Training]] . . . November 16, 2021, at 03:30 PM by [[~Hawk]]: [==]%0a* [[Openbsd/Got]] . . . November 07, 2021, at 03:16 PM by [[~jrmu]]: [==]%0a* [[Openbsd/Drawtermssh]] . . . November 04, 2021, at 03:54 PM by [[~meeekeeef]]: [=ssh bad >:[=]%0a* [[Openbsd/Sysupgrade70]] . . . October 15, 2021, at 11:02 AM by [[~mkf]]: [=humans are easily confused.=]%0a* [[Openbsd/Ilines]] . . . October 15, 2021, at 02:36 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Pmwiki]] . . . October 14, 2021, at 02:14 PM by [[~miniontoby]]: [=added credits =]%0a* [[Openbsd/Install69]] . . . September 27, 2021, at 05:59 PM by [[~jrmu]]: [==]%0a* [[Openbsd/PFStable]] . . . September 24, 2021, at 03:28 PM by [[~miniontoby]]: [==]%0a* [[Openbsd/Mailopenproxy]] . . . August 25, 2021, at 08:19 PM by [[~mkf]]: [==]%0a* [[Openbsd/Two-FactorAuth]] . . . August 23, 2021, at 07:39 PM by [[~mkf]]: [=login.db compiling is no longer recommended.=]%0a* [[Openbsd/Npppd]] . . . August 21, 2021, at 01:43 PM by [[~mkf]]: [==]%0a* [[Openbsd/FilePermissions]] . . . August 20, 2021, at 02:20 AM by [[~Nate S]]: [==]%0a* [[Openbsd/Gophernicus]] . . . August 15, 2021, at 02:06 AM by [[~mkf]]: [==]%0a* [[Openbsd/Openhttpd]] . . . August 13, 2021, at 07:29 AM by [[~jrmu]]: [==]%0a* [[Openbsd/ZNCModules]] . . . August 11, 2021, at 03:06 PM by [[~wiz]]: [==]%0a* [[Openbsd/Bitlbee]] . . . August 10, 2021, at 12:03 PM by [[~mkf]]: [==]%0a* [[Openbsd/Pppoe]] . . . August 10, 2021, at 11:56 AM by [[~mkf]]: [==]%0a* [[Openbsd/Sshkeys]] . . . August 09, 2021, at 04:42 PM by [[~jrmu]]: [==]%0a* [[Openbsd/Squirrelmail]] . . . August 06, 2021, at 10:32 AM by [[~baytuch]]: [==]%0a* [[Openbsd/Dnszones]] . . . August 03, 2021, at 09:26 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Matterbridge]] . . . August 02, 2021, at 12:33 PM by [[~mkf]]: [==]%0a* [[Openbsd/Vhost]] . . . August 02, 2021, at 02:32 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Chroot]] . . . July 31, 2021, at 02:47 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Vmmuser]] . . . July 29, 2021, at 05:31 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Vmminstall]] . . . July 29, 2021, at 05:28 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Vmm]] . . . July 29, 2021, at 05:24 AM by [[~jrmu]]: [==]%0a* [[Openbsd/ZNCAdmin]] . . . July 28, 2021, at 06:14 AM by [[~jrmu]]: [==]%0a* [[Openbsd/ZNCSupport]] . . . July 28, 2021, at 06:14 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Php]] . . . July 27, 2021, at 02:53 PM by [[~jrmu]]: [==]%0a* [[Openbsd/Dig]] . . . July 25, 2021, at 06:50 AM by [[~jrmu]]: [==]%0a* [[Openbsd/RDNS]] . . . July 23, 2021, at 06:44 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Sic]] . . . July 21, 2021, at 05:57 PM by [[~mkf]]: [=first edit.=]%0a* [[Openbsd/Openrsync]] . . . July 18, 2021, at 02:01 PM by [[~jrmu]]: [==]%0a* [[Openbsd/Znc]] . . . July 16, 2021, at 10:43 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Staticnet]] . . . July 12, 2021, at 05:48 PM by [[~jrmu]]: [==]%0a* [[Openbsd/Dovecot]] . . . July 12, 2021, at 02:58 PM by [[~jrmu]]: [==]%0a* [[Openbsd/Relayd]] . . . July 12, 2021, at 02:45 PM by [[~jrmu]]: [==]%0a* [[Openbsd/Spf]] . . . July 12, 2021, at 03:08 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Eggdrop]] . . . July 02, 2021, at 03:20 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Newdisk]] . . . June 29, 2021, at 03:23 PM by [[~jrmu]]: [==]%0a* [[Openbsd/Ed]] . . . June 28, 2021, at 04:04 PM by [[~mkf]]: [==]%0a* [[Openbsd/Unbound]] . . . June 27, 2021, at 12:12 PM by [[~jrmu]]: [==]%0a* [[Openbsd/Dkimproxy]] . . . June 25, 2021, at 12:56 PM by [[~jrmu]]: [==]%0a* [[Openbsd/Sysupgrade69]] . . . June 25, 2021, at 05:46 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Opensmtpd]] . . . June 23, 2021, at 02:21 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Ngircd]] . . . June 23, 2021, at 02:21 AM by [[~jrmu]]: [==]%0a* [[Openbsd/NgircdLink]] . . . June 22, 2021, at 07:50 PM by [[~mkf]]: [=delete=]%0a* [[Openbsd/Doas]] . . . June 13, 2021, at 01:19 PM by [[~jrmu]]: [==]%0a* [[Openbsd/Shell]] . . . June 11, 2021, at 09:36 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Books]] . . . June 06, 2021, at 12:46 PM by [[~jrmu]]: [==]%0a* [[Openbsd/Pfa]] . . . June 06, 2021, at 03:49 AM by [[~navic]]: [==]%0a* [[Openbsd/Wordpress]] . . . June 04, 2021, at 04:55 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Anope]] . . . May 31, 2021, at 10:24 AM by [[~miniontoby]]: [=cp=]%0a* [[Openbsd/ACKFlood]] . . . May 29, 2021, at 06:20 AM by [[~mkf]]: [==]%0a* [[Openbsd/SSDP]] . . . May 29, 2021, at 06:18 AM by [[~mkf]]: [==]%0a* [[Openbsd/Anycast]] . . . May 29, 2021, at 06:01 AM by [[~mkf]]: [==]%0a* [[Openbsd/Dmarc]] . . . May 21, 2021, at 09:22 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Disklabel]] . . . May 17, 2021, at 03:33 AM by [[~bejelentkezni]]: [==]%0a* [[Openbsd/Fdisk]] . . . May 17, 2021, at 03:27 AM by [[~bejelentkezni]]: [==]%0a* [[Openbsd/Security]] . . . May 14, 2021, at 03:14 AM by [[~caesar]]: [==]%0a* [[Openbsd/Hopm-Arthur]] . . . May 07, 2021, at 12:28 PM by [[~Arthur]]: [==]%0a* [[Openbsd/Syspatch]] . . . February 14, 2021, at 11:00 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Netadmin]] . . . February 14, 2021, at 10:56 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Leafnode]] . . . February 12, 2021, at 01:40 PM by [[~chewy]]: [==]%0a* [[Openbsd/Pylink]] . . . February 08, 2021, at 08:33 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Stable]] . . . February 02, 2021, at 02:25 PM by [[~jrmu]]: [==]%0a* [[Openbsd/Base64]] . . . February 02, 2021, at 06:37 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Unboundadblock]] . . . February 02, 2021, at 04:29 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Pfbadhost]] . . . February 02, 2021, at 04:29 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Wraith]] . . . February 02, 2021, at 04:22 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Delphinusdnsd]] . . . February 02, 2021, at 01:51 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Abuse]] . . . January 31, 2021, at 05:33 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Phishing]] . . . January 31, 2021, at 05:02 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Audit]] . . . January 31, 2021, at 04:46 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Ongoing]] . . . January 31, 2021, at 01:19 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Httpopenproxy]] . . . January 29, 2021, at 11:01 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Zncadmin]] . . . January 29, 2021, at 10:00 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Rbldns]] . . . January 29, 2021, at 05:45 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Setuid]] . . . January 28, 2021, at 06:53 AM by [[~jrmu]]: [==]%0a* [[Openbsd/PFTesting]] . . . January 25, 2021, at 03:28 PM by [[~jrmu]]: [==]%0a* [[Openbsd/ZNCDaily]] . . . January 25, 2021, at 11:35 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Irssi]] . . . January 25, 2021, at 07:08 AM by [[~jrmu]]: [==]%0a* [[Openbsd/XTerm]] . . . January 17, 2021, at 01:48 PM by [[~miniontoby]]: [=copyright=]%0a* [[Openbsd/Slrn]] . . . January 12, 2021, at 02:40 PM by [[~Noxturnix]]: [==]%0a* [[Openbsd/Netcat]] . . . January 09, 2021, at 02:20 PM by [[~jrmu]]: [==]%0a* [[Openbsd/Perl]] . . . January 09, 2021, at 01:52 PM by [[~jrmu]]: [==]%0a* [[Openbsd/Backup]] . . . January 03, 2021, at 01:46 PM by [[~jrmu]]: [==]%0a* [[Openbsd/Backups]] . . . January 02, 2021, at 11:44 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Sshbackdoor]] . . . December 30, 2020, at 12:14 PM by [[~jrmu]]: [==]%0a* [[Openbsd/Pf-bnc]] . . . December 29, 2020, at 06:30 PM by [[~jrmu]]: [==]%0a* [[Openbsd/Tcltls]] . . . December 29, 2020, at 09:53 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Amplification]] . . . December 19, 2020, at 05:42 AM by [[~jrmu]]: [==]%0a* [[Openbsd/UDPFlood]] . . . December 18, 2020, at 10:39 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Tcpdump]] . . . December 18, 2020, at 09:12 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Tcpackflood]] . . . December 17, 2020, at 10:36 AM by [[~jrmu]]: [==]%0a* [[Openbsd/RSTFlood]] . . . December 17, 2020, at 10:34 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Tcpresetflood]] . . . December 17, 2020, at 10:34 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Ssdp]] . . . December 15, 2020, at 12:59 PM by [[~jrmu]]: [==]%0a* [[Openbsd/Pf]] . . . December 13, 2020, at 12:03 PM by [[~jrmu]]: [==]%0a* [[Openbsd/Upgrade68]] . . . December 13, 2020, at 11:12 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Install68]] . . . December 13, 2020, at 10:13 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Upgrade67]] . . . December 13, 2020, at 04:02 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Sysupgrade68]] . . . December 11, 2020, at 10:27 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Dokuwiki]] . . . December 10, 2020, at 02:23 PM by [[~miniontoby]]: [=code blocks fixed=]%0a* [[Openbsd/Acme-client]] . . . December 09, 2020, at 06:47 PM by [[~miniontoby]]: [=fixed troubleshooting links=]%0a* [[Openbsd/Install67]] . . . December 06, 2020, at 11:03 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Buyvm]] . . . December 06, 2020, at 02:42 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Install]] . . . December 04, 2020, at 04:15 PM by [[~jrmu]]: [==]%0a* [[Openbsd/Oidentd]] . . . November 30, 2020, at 11:42 PM by [[~jrmu]]: [==]%0a* [[Openbsd/Checklist]] . . . November 20, 2020, at 12:44 AM by [[~gry]]: [=+=]%0a* [[Openbsd/Acopm]] . . . November 04, 2020, at 03:32 PM by [[~jrmu]]: [==]%0a* [[Openbsd/Achurch]] . . . November 04, 2020, at 02:25 PM by [[~jrmu]]: [==]%0a* [[Openbsd/Vi]] . . . November 04, 2020, at 12:51 PM by [[~jrmu]]: [==]%0a* [[Openbsd/Sudo]] . . . November 04, 2020, at 12:38 PM by [[~jrmu]]: [==]%0a* [[Openbsd/Easyapp]] . . . September 29, 2020, at 12:13 PM by [[~jrmu]]: [==]%0a* [[Openbsd/Cgit]] . . . September 01, 2020, at 05:51 PM by [[~baytuch]]: [==]%0a* [[Openbsd/Bchs]] . . . August 20, 2020, at 07:11 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Fdm]] . . . August 18, 2020, at 10:06 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Opensmtpd-2]] . . . August 18, 2020, at 09:59 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Opensmtpd-relay]] . . . August 18, 2020, at 09:56 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Identd]] . . . August 18, 2020, at 09:39 AM by [[~jrmu]]: [==]%0a* [[Openbsd/IPv6]] . . . August 12, 2020, at 02:21 PM by [[~jrmu]]: [==]%0a* [[Openbsd/Oscommerce]] . . . August 12, 2020, at 10:00 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Ping]] . . . August 12, 2020, at 08:34 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Sockets]] . . . August 12, 2020, at 07:16 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Guides]] . . . August 10, 2020, at 03:42 AM by [[~jrmu]]: [==]%0a -time=1677861462 +rev=1935 +text=* [[Openbsd/Ngircd]] . . . @2023-03-05T18:17:39Z by [[~mkf]]: [==]%0a* [[Openbsd/OpenTracker]] . . . March 03, 2023, at 04:37 PM by [[~baytuch]]: [==]%0a* [[Openbsd/Gotweb]] . . . February 26, 2023, at 05:04 PM by [[~fossdev]]: [==]%0a* [[Openbsd/Plermoa]] . . . February 16, 2023, at 04:52 AM by [[~Yonle]]: [=Redirect=]%0a* [[Openbsd/Pleroma]] . . . February 12, 2023, at 02:49 AM by [[~Yonle]]: [=Oops=]%0a* [[Openbsd/Akkoma]] . . . February 12, 2023, at 02:48 AM by [[~Yonle]]: [=Oof=]%0a* [[Openbsd/Mlmmj]] . . . February 08, 2023, at 02:50 AM by [[~Yonle]]: [==]%0a* [[Openbsd/Mosh]] . . . February 07, 2023, at 11:30 AM by [[~Yonle]]: [==]%0a* [[Openbsd/Passwords]] . . . February 03, 2023, at 07:49 PM by [[~izzyb]]: [==]%0a* [[Openbsd/Biboumi]] . . . January 20, 2023, at 08:11 PM by [[~mkf]]: [==]%0a* [[Openbsd/Unrealircd]] . . . January 20, 2023, at 07:27 PM by [[~mkf]]: [==]%0a* [[Openbsd/Vipw]] . . . January 18, 2023, at 11:01 PM by [[~zen]]: [=added two spaces=]%0a* [[Openbsd/Loginconf]] . . . January 18, 2023, at 10:48 PM by [[~zen]]: [=OpenBSD FAQ link refenrece=]%0a* [[Openbsd/Singleuser]] . . . January 18, 2023, at 10:26 PM by [[~zen]]: [=changed the link reference=]%0a* [[Openbsd/Dump]] . . . January 10, 2023, at 04:48 PM by [[~mkf]]: [=add -u, improve dump-ssh funcationality.=]%0a* [[Openbsd/Quota]] . . . December 29, 2022, at 06:51 PM by [[~mkf]]: [==]%0a* [[Openbsd/Minetest]] . . . December 26, 2022, at 07:23 PM by [[~miniontoby]]: [=Added more ways to install=]%0a* [[Openbsd/Honk]] . . . December 17, 2022, at 08:45 AM by [[~Yonle]]: [==]%0a* [[Openbsd/Icecast]] . . . November 17, 2022, at 11:35 AM by [[~Yonle]]: [==]%0a* [[Openbsd/Geomyidae]] . . . September 10, 2022, at 02:31 AM by [[~akoizumi]]: [==]%0a* [[Openbsd/INN]] . . . September 10, 2022, at 02:23 AM by [[~akoizumi]]: [=Fix some types=]%0a* [[Openbsd/VsFTP]] . . . August 10, 2022, at 03:18 PM by [[~mkf]]: [=snipped unneeded output=]%0a* [[Openbsd/Apmd]] . . . July 03, 2022, at 11:36 AM by [[~mkf]]: [==]%0a* [[Openbsd/Pkg]] . . . June 12, 2022, at 12:32 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Intro]] . . . June 09, 2022, at 07:53 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Bsdrd]] . . . June 09, 2022, at 07:17 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Sysupgrade71]] . . . June 05, 2022, at 11:49 PM by [[~jrmu]]: [==]%0a* [[Openbsd/Growfs]] . . . June 01, 2022, at 12:34 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Nsd]] . . . May 10, 2022, at 12:33 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Ports]] . . . May 09, 2022, at 05:54 AM by [[~mkf]]: [==]%0a* [[Openbsd/Rcctl]] . . . May 09, 2022, at 05:53 AM by [[~mkf]]: [==]%0a* [[Openbsd/Upgrade71]] . . . May 03, 2022, at 06:36 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Install71]] . . . April 24, 2022, at 09:55 PM by [[~jrmu]]: [==]%0a* [[Openbsd/Botnow]] . . . April 24, 2022, at 06:14 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Gopher]] . . . April 20, 2022, at 08:29 PM by [[~jrmu]]: [==]%0a* [[Openbsd/Adduser]] . . . April 20, 2022, at 08:07 PM by [[~jrmu]]: [==]%0a* [[Openbsd/Ntpd]] . . . April 20, 2022, at 06:16 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Vmmlinux]] . . . April 20, 2022, at 05:33 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Iked]] . . . April 20, 2022, at 05:16 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Team]] . . . April 20, 2022, at 04:54 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Announce]] . . . April 19, 2022, at 04:14 PM by [[~jrmu]]: [==]%0a* [[Openbsd/Install70]] . . . April 19, 2022, at 06:52 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Upgrade70]] . . . April 19, 2022, at 06:49 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Censord]] . . . April 05, 2022, at 06:16 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Hopm]] . . . April 05, 2022, at 06:09 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Dns]] . . . April 05, 2022, at 05:24 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Psybnc]] . . . March 30, 2022, at 09:56 PM by [[~jrmu]]: [==]%0a* [[Openbsd/Ddos]] . . . March 24, 2022, at 04:22 PM by [[~jrmu]]: [==]%0a* [[Openbsd/IRCBridge]] . . . February 28, 2022, at 02:59 AM by [[~suzerain]]: [==]%0a* [[Openbsd/Wesnothd]] . . . February 21, 2022, at 06:28 AM by [[~mkf]]: [=Wesnothd=]%0a* [[Openbsd/Xonotic]] . . . February 20, 2022, at 07:43 AM by [[~mkf]]: [=A xonotic server has apperad! pt.2=]%0a* [[Openbsd/Police]] . . . February 10, 2022, at 07:36 PM by [[~jrmu]]: [==]%0a* [[Openbsd/Tcpip]] . . . January 24, 2022, at 05:45 PM by [[~jrmu]]: [==]%0a* [[Openbsd/U9fs]] . . . January 16, 2022, at 06:23 PM by [[~mkf]]: [==]%0a* [[Openbsd/Locale]] . . . January 12, 2022, at 01:23 PM by [[~baytuch]]: [==]%0a* [[Openbsd/Openbsd]] . . . January 12, 2022, at 01:19 PM by [[~baytuch]]: [==]%0a* [[Openbsd/BBB]] . . . January 03, 2022, at 12:06 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Sftp]] . . . December 30, 2021, at 06:01 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Uim]] . . . December 26, 2021, at 01:45 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Wifi]] . . . December 22, 2021, at 02:59 PM by [[~jrmu]]: [==]%0a* [[Openbsd/Recordaudio]] . . . December 22, 2021, at 01:24 PM by [[~jrmu]]: [==]%0a* [[Openbsd/Training]] . . . November 16, 2021, at 03:30 PM by [[~Hawk]]: [==]%0a* [[Openbsd/Got]] . . . November 07, 2021, at 03:16 PM by [[~jrmu]]: [==]%0a* [[Openbsd/Drawtermssh]] . . . November 04, 2021, at 03:54 PM by [[~meeekeeef]]: [=ssh bad >:[=]%0a* [[Openbsd/Sysupgrade70]] . . . October 15, 2021, at 11:02 AM by [[~mkf]]: [=humans are easily confused.=]%0a* [[Openbsd/Ilines]] . . . October 15, 2021, at 02:36 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Pmwiki]] . . . October 14, 2021, at 02:14 PM by [[~miniontoby]]: [=added credits =]%0a* [[Openbsd/Install69]] . . . September 27, 2021, at 05:59 PM by [[~jrmu]]: [==]%0a* [[Openbsd/PFStable]] . . . September 24, 2021, at 03:28 PM by [[~miniontoby]]: [==]%0a* [[Openbsd/Mailopenproxy]] . . . August 25, 2021, at 08:19 PM by [[~mkf]]: [==]%0a* [[Openbsd/Two-FactorAuth]] . . . August 23, 2021, at 07:39 PM by [[~mkf]]: [=login.db compiling is no longer recommended.=]%0a* [[Openbsd/Npppd]] . . . August 21, 2021, at 01:43 PM by [[~mkf]]: [==]%0a* [[Openbsd/FilePermissions]] . . . August 20, 2021, at 02:20 AM by [[~Nate S]]: [==]%0a* [[Openbsd/Gophernicus]] . . . August 15, 2021, at 02:06 AM by [[~mkf]]: [==]%0a* [[Openbsd/Openhttpd]] . . . August 13, 2021, at 07:29 AM by [[~jrmu]]: [==]%0a* [[Openbsd/ZNCModules]] . . . August 11, 2021, at 03:06 PM by [[~wiz]]: [==]%0a* [[Openbsd/Bitlbee]] . . . August 10, 2021, at 12:03 PM by [[~mkf]]: [==]%0a* [[Openbsd/Pppoe]] . . . August 10, 2021, at 11:56 AM by [[~mkf]]: [==]%0a* [[Openbsd/Sshkeys]] . . . August 09, 2021, at 04:42 PM by [[~jrmu]]: [==]%0a* [[Openbsd/Squirrelmail]] . . . August 06, 2021, at 10:32 AM by [[~baytuch]]: [==]%0a* [[Openbsd/Dnszones]] . . . August 03, 2021, at 09:26 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Matterbridge]] . . . August 02, 2021, at 12:33 PM by [[~mkf]]: [==]%0a* [[Openbsd/Vhost]] . . . August 02, 2021, at 02:32 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Chroot]] . . . July 31, 2021, at 02:47 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Vmmuser]] . . . July 29, 2021, at 05:31 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Vmminstall]] . . . July 29, 2021, at 05:28 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Vmm]] . . . July 29, 2021, at 05:24 AM by [[~jrmu]]: [==]%0a* [[Openbsd/ZNCAdmin]] . . . July 28, 2021, at 06:14 AM by [[~jrmu]]: [==]%0a* [[Openbsd/ZNCSupport]] . . . July 28, 2021, at 06:14 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Php]] . . . July 27, 2021, at 02:53 PM by [[~jrmu]]: [==]%0a* [[Openbsd/Dig]] . . . July 25, 2021, at 06:50 AM by [[~jrmu]]: [==]%0a* [[Openbsd/RDNS]] . . . July 23, 2021, at 06:44 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Sic]] . . . July 21, 2021, at 05:57 PM by [[~mkf]]: [=first edit.=]%0a* [[Openbsd/Openrsync]] . . . July 18, 2021, at 02:01 PM by [[~jrmu]]: [==]%0a* [[Openbsd/Znc]] . . . July 16, 2021, at 10:43 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Staticnet]] . . . July 12, 2021, at 05:48 PM by [[~jrmu]]: [==]%0a* [[Openbsd/Dovecot]] . . . July 12, 2021, at 02:58 PM by [[~jrmu]]: [==]%0a* [[Openbsd/Relayd]] . . . July 12, 2021, at 02:45 PM by [[~jrmu]]: [==]%0a* [[Openbsd/Spf]] . . . July 12, 2021, at 03:08 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Eggdrop]] . . . July 02, 2021, at 03:20 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Newdisk]] . . . June 29, 2021, at 03:23 PM by [[~jrmu]]: [==]%0a* [[Openbsd/Ed]] . . . June 28, 2021, at 04:04 PM by [[~mkf]]: [==]%0a* [[Openbsd/Unbound]] . . . June 27, 2021, at 12:12 PM by [[~jrmu]]: [==]%0a* [[Openbsd/Dkimproxy]] . . . June 25, 2021, at 12:56 PM by [[~jrmu]]: [==]%0a* [[Openbsd/Sysupgrade69]] . . . June 25, 2021, at 05:46 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Opensmtpd]] . . . June 23, 2021, at 02:21 AM by [[~jrmu]]: [==]%0a* [[Openbsd/NgircdLink]] . . . June 22, 2021, at 07:50 PM by [[~mkf]]: [=delete=]%0a* [[Openbsd/Doas]] . . . June 13, 2021, at 01:19 PM by [[~jrmu]]: [==]%0a* [[Openbsd/Shell]] . . . June 11, 2021, at 09:36 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Books]] . . . June 06, 2021, at 12:46 PM by [[~jrmu]]: [==]%0a* [[Openbsd/Pfa]] . . . June 06, 2021, at 03:49 AM by [[~navic]]: [==]%0a* [[Openbsd/Wordpress]] . . . June 04, 2021, at 04:55 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Anope]] . . . May 31, 2021, at 10:24 AM by [[~miniontoby]]: [=cp=]%0a* [[Openbsd/ACKFlood]] . . . May 29, 2021, at 06:20 AM by [[~mkf]]: [==]%0a* [[Openbsd/SSDP]] . . . May 29, 2021, at 06:18 AM by [[~mkf]]: [==]%0a* [[Openbsd/Anycast]] . . . May 29, 2021, at 06:01 AM by [[~mkf]]: [==]%0a* [[Openbsd/Dmarc]] . . . May 21, 2021, at 09:22 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Disklabel]] . . . May 17, 2021, at 03:33 AM by [[~bejelentkezni]]: [==]%0a* [[Openbsd/Fdisk]] . . . May 17, 2021, at 03:27 AM by [[~bejelentkezni]]: [==]%0a* [[Openbsd/Security]] . . . May 14, 2021, at 03:14 AM by [[~caesar]]: [==]%0a* [[Openbsd/Hopm-Arthur]] . . . May 07, 2021, at 12:28 PM by [[~Arthur]]: [==]%0a* [[Openbsd/Syspatch]] . . . February 14, 2021, at 11:00 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Netadmin]] . . . February 14, 2021, at 10:56 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Leafnode]] . . . February 12, 2021, at 01:40 PM by [[~chewy]]: [==]%0a* [[Openbsd/Pylink]] . . . February 08, 2021, at 08:33 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Stable]] . . . February 02, 2021, at 02:25 PM by [[~jrmu]]: [==]%0a* [[Openbsd/Base64]] . . . February 02, 2021, at 06:37 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Unboundadblock]] . . . February 02, 2021, at 04:29 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Pfbadhost]] . . . February 02, 2021, at 04:29 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Wraith]] . . . February 02, 2021, at 04:22 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Delphinusdnsd]] . . . February 02, 2021, at 01:51 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Abuse]] . . . January 31, 2021, at 05:33 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Phishing]] . . . January 31, 2021, at 05:02 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Audit]] . . . January 31, 2021, at 04:46 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Ongoing]] . . . January 31, 2021, at 01:19 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Httpopenproxy]] . . . January 29, 2021, at 11:01 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Zncadmin]] . . . January 29, 2021, at 10:00 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Rbldns]] . . . January 29, 2021, at 05:45 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Setuid]] . . . January 28, 2021, at 06:53 AM by [[~jrmu]]: [==]%0a* [[Openbsd/PFTesting]] . . . January 25, 2021, at 03:28 PM by [[~jrmu]]: [==]%0a* [[Openbsd/ZNCDaily]] . . . January 25, 2021, at 11:35 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Irssi]] . . . January 25, 2021, at 07:08 AM by [[~jrmu]]: [==]%0a* [[Openbsd/XTerm]] . . . January 17, 2021, at 01:48 PM by [[~miniontoby]]: [=copyright=]%0a* [[Openbsd/Slrn]] . . . January 12, 2021, at 02:40 PM by [[~Noxturnix]]: [==]%0a* [[Openbsd/Netcat]] . . . January 09, 2021, at 02:20 PM by [[~jrmu]]: [==]%0a* [[Openbsd/Perl]] . . . January 09, 2021, at 01:52 PM by [[~jrmu]]: [==]%0a* [[Openbsd/Backup]] . . . January 03, 2021, at 01:46 PM by [[~jrmu]]: [==]%0a* [[Openbsd/Backups]] . . . January 02, 2021, at 11:44 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Sshbackdoor]] . . . December 30, 2020, at 12:14 PM by [[~jrmu]]: [==]%0a* [[Openbsd/Pf-bnc]] . . . December 29, 2020, at 06:30 PM by [[~jrmu]]: [==]%0a* [[Openbsd/Tcltls]] . . . December 29, 2020, at 09:53 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Amplification]] . . . December 19, 2020, at 05:42 AM by [[~jrmu]]: [==]%0a* [[Openbsd/UDPFlood]] . . . December 18, 2020, at 10:39 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Tcpdump]] . . . December 18, 2020, at 09:12 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Tcpackflood]] . . . December 17, 2020, at 10:36 AM by [[~jrmu]]: [==]%0a* [[Openbsd/RSTFlood]] . . . December 17, 2020, at 10:34 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Tcpresetflood]] . . . December 17, 2020, at 10:34 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Ssdp]] . . . December 15, 2020, at 12:59 PM by [[~jrmu]]: [==]%0a* [[Openbsd/Pf]] . . . December 13, 2020, at 12:03 PM by [[~jrmu]]: [==]%0a* [[Openbsd/Upgrade68]] . . . December 13, 2020, at 11:12 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Install68]] . . . December 13, 2020, at 10:13 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Upgrade67]] . . . December 13, 2020, at 04:02 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Sysupgrade68]] . . . December 11, 2020, at 10:27 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Dokuwiki]] . . . December 10, 2020, at 02:23 PM by [[~miniontoby]]: [=code blocks fixed=]%0a* [[Openbsd/Acme-client]] . . . December 09, 2020, at 06:47 PM by [[~miniontoby]]: [=fixed troubleshooting links=]%0a* [[Openbsd/Install67]] . . . December 06, 2020, at 11:03 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Buyvm]] . . . December 06, 2020, at 02:42 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Install]] . . . December 04, 2020, at 04:15 PM by [[~jrmu]]: [==]%0a* [[Openbsd/Oidentd]] . . . November 30, 2020, at 11:42 PM by [[~jrmu]]: [==]%0a* [[Openbsd/Checklist]] . . . November 20, 2020, at 12:44 AM by [[~gry]]: [=+=]%0a* [[Openbsd/Acopm]] . . . November 04, 2020, at 03:32 PM by [[~jrmu]]: [==]%0a* [[Openbsd/Achurch]] . . . November 04, 2020, at 02:25 PM by [[~jrmu]]: [==]%0a* [[Openbsd/Vi]] . . . November 04, 2020, at 12:51 PM by [[~jrmu]]: [==]%0a* [[Openbsd/Sudo]] . . . November 04, 2020, at 12:38 PM by [[~jrmu]]: [==]%0a* [[Openbsd/Easyapp]] . . . September 29, 2020, at 12:13 PM by [[~jrmu]]: [==]%0a* [[Openbsd/Cgit]] . . . September 01, 2020, at 05:51 PM by [[~baytuch]]: [==]%0a* [[Openbsd/Bchs]] . . . August 20, 2020, at 07:11 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Fdm]] . . . August 18, 2020, at 10:06 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Opensmtpd-2]] . . . August 18, 2020, at 09:59 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Opensmtpd-relay]] . . . August 18, 2020, at 09:56 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Identd]] . . . August 18, 2020, at 09:39 AM by [[~jrmu]]: [==]%0a* [[Openbsd/IPv6]] . . . August 12, 2020, at 02:21 PM by [[~jrmu]]: [==]%0a* [[Openbsd/Oscommerce]] . . . August 12, 2020, at 10:00 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Ping]] . . . August 12, 2020, at 08:34 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Sockets]] . . . August 12, 2020, at 07:16 AM by [[~jrmu]]: [==]%0a* [[Openbsd/Guides]] . . . August 10, 2020, at 03:42 AM by [[~jrmu]]: [==]%0a +time=1678040259 blob - 067e346bda21a211adcff0013264743f6b4c0152 blob + d74d11e4fd015f674fa82b9dd39a36891c2aeb89 --- wiki.d/Opensmtpd.Configure +++ wiki.d/Opensmtpd.Configure @@ -1,15 +1,19 @@ -version=pmwiki-2.2.130 ordered=1 urlencoded=1 -agent=Mozilla/5.0 (X11; OpenBSD amd64; rv:68.0) Gecko/20100101 Firefox/68.0 SeaMonkey/2.53.14 -author=mkf +version=pmwiki-2.3.20 ordered=1 urlencoded=1 +agent=w3m/0.5.3+git20210102 +author=jrmu charset=UTF-8 -csum=mention root mail +csum=Moved to /etc/dkim/ to fix permissions bugs ctime=1621253792 -host=198.251.81.133 +host=38.87.162.154 name=Opensmtpd.Configure -rev=51 +rev=52 targets=Dns.Overview,Nsd.Configure,DNS.Mail,Acme-client.Configure,Opensmtpd.Openrelay,Dovecot.Install,DNS.DKIM,Opensmtpd.Troubleshoot -text=Let's set up a mail server with dkim signing and basic spam checks:%0a%0a!! Before we begin%0a%0aRead the the man pages for [[https://man.openbsd.org/smtpd|opensmtpd]], [[https://man.openbsd.org/smtpd.conf|smtpd.conf]], and [[https://man.openbsd.org/smtpctl|smtpctl]]. %0a%0aRead the [[https://github.com/poolpOrg/OpenSMTPD-book|free OpenSMTPd book]] by the%0aauthor of OpenSMTPd%0a%0a!! DNS%0a%0aRunning a mail server requires proper DNS records. If you have not already, you will%0awant to read up on [[dns/overview|DNS]] and [[nsd/configure|set up your name server]].%0a%0aYou will need to [[DNS/Mail|add proper DNS records]] to your domain and make sure they work.%0a%0a!! Install%0a%0aOpensmtpd is part of OpenBSD base, but we will also want to install some%0aopensmtpd-related packages and dovecot:%0a%0a[@%0a$ doas pkg_add opensmtpd-extras opensmtpd-filter-dkimsign-- dovecot%0a@]%0a%0a!! Configuration%0a%0a!!! TLS%0a%0aYou will want to use [[acme-client/configure|acme-client]] to request a TLS public cert and private key%0ain @@/etc/ssl/@@.%0a%0aNext, we'll create our smtpd configuration file in @@/etc/mail/smtpd.conf@@:%0a%0a[@%0a# PKI for TLS%0apki example.com cert "/etc/ssl/example.com.fullchain.pem"%0apki example.com key "/etc/ssl/private/example.com.key"%0a@]%0a%0aThis defines our public and private key pair for TLS encryption.%0a%0a!!! Tables%0a%0aNext, we define 5 tables:%0a%0a[@%0a# tables setup%0atable domains file:/etc/mail/domains%0atable passwd passwd:/etc/mail/passwd%0atable virtuals file:/etc/mail/virtuals%0atable hosts file:/etc/mail/hosts%0atable users file:/etc/mail/users%0a@]%0a%0aThe domains table contains a list of domains that our mail server should %0areceive mail on.%0a%0aThe passwd table contains a colon-separated list of username/password/disk quota%0aentries.%0a%0aThe virtuals file shows which virtual user should handle whose mail. They are written as @@key: value@@ pairs.%0aSee [[https://man.openbsd.org/aliases|aliases(5)]] for more information.%0a%0aThe hosts file contains a list of trusted sending hosts.%0a%0aThe users file contains a list of valid sending users.%0a%0aAll of these tables will be explained further in the following sections.%0a%0a!!! Dealing with Spam%0a%0a[@%0a# Blocks junk mail%0afilter check_rdns phase connect match !rdns junk%0afilter check_fcrdns phase connect match !fcrdns junk%0afilter "dkimsign" proc-exec "filter-dkimsign -d example.com -s mail -k /etc/mail/dkim/private.key" user _smtpd group _smtpd%0a@]%0a%0aThe first filter will check if the sender has an rdns entry. If not, the mail%0awill be labeled as junk.%0a%0aThe second filter will check if the sender's forward and reverse dns entry match. If%0anot, the mail will be labeled as junk.%0a%0aThe third filter will sign any email with the DKIM private key.%0a%0a# -d specifies the domain name to sign for; you must replace example.com with your real domain.%0a# -s specifies the selector (in this case mail).%0a# -k specifies the path of the private key.%0a# user and group both specify _smtpd, the user and group that does the signing%0a%0a!!! Macros%0a%0aA macro defines a variable that will be replaced with a block of text:%0a%0a[@%0a# macros%0aipv4 = "192.168.0.1"%0aipv6 = "2001:db8::"%0acheck = "pki example.com mask-src filter { check_rdns check_fcrdns } hostname example.com"%0aauthcheck = "pki example.com auth %3cpasswd> mask-src senders %3cusers> filter { check_rdns check_fcrdns dkimsign } hostname example.com"%0a@]%0a%0aLines 2 and 3 define the IPv4 and IPv6 addresses used for sending and receiving mail.%0a%0aLine 4 tells opensmtpd to use the public/private keys we defined earlier for @@example.com@@. We mask the sender's source (the '''from''' part of the @@Received@@ header). We also apply two filters to check for proper forward and reverse confirmed DNS entries. Finally, we indicate that the sending hostname must be example.com instead of the default server name.%0a%0aLine 5 is identical to line 4 except it requires authentication with the password file and it checks if the sender is allowed.%0a%0a!!! Listeners%0a%0aThe listeners tell us what network interfaces, IP addresses, and ports to listen on.%0a%0a[@%0a# listeners%0alisten on socket filter "dkimsign"%0alisten on lo0 filter "dkimsign"%0alisten on $ipv4 port 25 tls $check%0alisten on $ipv6 port 25 tls $check%0alisten on $ipv4 port 465 smtps $authcheck%0alisten on $ipv6 port 465 smtps $authcheck%0alisten on $ipv4 port 587 tls-require $authcheck%0alisten on $ipv6 port 587 tls-require $authcheck%0a@]%0a%0aLine 2 tells smtpd to listen to the UNIX domain socket and to DKIM sign all %0aemails. Line 3 tells us to listen to the loopback interface and also%0asign all emails.%0a%0aLines 4-5 tells smtpd to listen on the IPv4 and IPv6 address on port 25, to provide%0aTLS if supported but to offer plaintext as a fallback. Only basic checking is done.%0a%0aLines 6-7 tells smtpd to listen on the IPv4 and IPv6 address on port 465, for SMTPS.%0aTLS encryption is required and authentication checking is forced because this socket%0acan be used for sending mail to other servers. We want to avoid an%0a[[opensmtpd/openrelay|open mail relay]].%0a%0aLines 8-9 is similar except it's for port 587, which is the SMTP submission port.%0a%0a!!! Rules%0a%0aNext we define the actions that opensmtpd can take and how to decide which%0aaction to follow:%0a%0a[@%0a# rules%0aaction "lmtp" lmtp "/var/dovecot/lmtp" rcpt-to virtual %3cvirtuals>%0aaction "outbound" relay src $ipv4%0a%0amatch from any for domain %3cdomains> action "lmtp"%0amatch from local for any action "outbound"%0amatch from src %3chosts> for any action "outbound"%0amatch auth from any for any action "outbound"%0a@]%0a%0aIn line 2, we define the action "lmtp": we pass the mail to dovecot to handle using the Local Mail Transfer Protocol (LMTP). The actual recipient will be translated using the virtuals table.%0a%0aIn line 3, we define the action "outbound": we relay (send) the email out.%0a%0aLine 4 defines our first matching rule: any email headed for one of our domains should be handed over to lmtp (handed over to dovecot).%0a%0aLine 5 defines our second matching rule: any email from a local IP address or queue can relay (send) without authentication.%0a%0aLine 6 defines our third matching rule: any email from our trusted @@/etc/mail/hosts@@ file will automatically be relayed (sent) without authentication.%0a%0aLine 7 defines our last matching rule: any email that has been properly authenticated will be relayed (sent).%0a%0a!!! Complete configuration file%0a%0aHere is the entire configuration file in @@/etc/mail/smtpd.conf@@:%0a%0a[@%0a# PKI for TLS%0apki example.com cert "/etc/ssl/example.com.fullchain.pem"%0apki example.com key "/etc/ssl/private/example.com.key"%0a%0a# tables setup%0atable domains file:/etc/mail/domains%0atable passwd passwd:/etc/mail/passwd%0atable virtuals file:/etc/mail/virtuals%0atable hosts file:/etc/mail/hosts%0atable users file:/etc/mail/users%0a%0a# Blocks junk mail%0afilter check_rdns phase connect match !rdns junk%0afilter check_fcrdns phase connect match !fcrdns junk%0afilter "dkimsign" proc-exec "filter-dkimsign -d example.com -s mail -k /etc/mail/dkim/private.key" user _smtpd group _smtpd%0a%0a# macros%0aipv4 = "192.168.0.1"%0aipv6 = "2001:db8::"%0acheck = "pki example.com mask-src filter { check_rdns check_fcrdns } hostname example.com"%0aauthcheck = "pki example.com auth %3cpasswd> mask-src senders %3cusers> filter { check_rdns check_fcrdns dkimsign } hostname example.com"%0a%0a# listeners%0alisten on socket filter "dkimsign"%0alisten on lo0 filter "dkimsign"%0alisten on $ipv4 port 25 tls $check%0alisten on $ipv6 port 25 tls $check%0alisten on $ipv4 port 465 smtps $authcheck%0alisten on $ipv6 port 465 smtps $authcheck%0alisten on $ipv4 port 587 tls-require $authcheck%0alisten on $ipv6 port 587 tls-require $authcheck%0a%0a# rules%0aaction "lmtp" lmtp "/var/dovecot/lmtp" rcpt-to virtual %3cvirtuals>%0aaction "outbound" relay src $ipv4%0a%0amatch from any for domain %3cdomains> action "lmtp"%0amatch from local for any action "outbound"%0amatch from src %3chosts> for any action "outbound"%0amatch auth from any for any action "outbound"%0a@]%0a%0a!! Configuring Virtual Users%0a%0aA single user vmail will receive mail for all virtual users:%0a%0a[@%0a$ doas useradd -m -g =uid -c "Virtual Mail" -d /var/vmail -s /sbin/nologin vmail%0a@]%0a%0a/var/vmail will be used to store virtual users' maildir folders. It will be managed by dovecot, which receives mail via LMTP.%0a%0a!! Adding users%0a%0aCreate a new file @@/etc/mail/virtuals@@ and add these lines:%0a%0a[@%0aroot admin@example.com%0aadmin@example.com vmail%0ausername@example.com vmail%0a@]%0a%0aNow, any mail sent to root will get forwarded to admin@example.com.%0a%0aThis is recommended to do so, as daily(8) and other programs will send mails to root. check the mail account linked to root account often!%0a%0aYou can optionally add one line for each user to provide aliases.%0a%0aFor each new user account, you will want to create a new line.%0a%0aYou'll also need to create one line for each user in @@/etc/mail/users@@:%0a%0a[@%0aadmin@example.com: admin@example.com%0ausername@example.com: username@example.com%0a@]%0a%0aA whitelist of known good senders goes into @@/etc/mail/hosts@@:%0a%0a[@%0alocalhost%0a127.0.0.1%0a192.168.1.1%0a2001:db8::%0a@]%0a%0aReplace IP addresses 192.168.1.1 and 2001:db8:: with your server's real IP addresses.%0a%0aIn @@/etc/mail/mailname@@, put in the name you want to use for your mail server. This%0ais very important for passing anti-spam checks:%0a%0a[@%0aexample.com%0a@]%0a%0aThe list of domains this mail server can receive emails for will go inside @@/etc/mail/domains@@:%0a%0a[@%0aexample.com%0amail.example.com%0a@]%0a%0aIn @@/etc/mail/passwd@@, we have a list of colon-separated user credentials:%0a%0a[@%0aadmin@example.com:$2b$10$h5itbhzs73T4jsHAj9YX6Tf63yRatAquGBxoCX67wyekhCH4ZqioD6lKh::::::userdb_quota_rule=*:storage=1G%0ausername@example.com:$2b$10$h5itbhzs73T4jsHAj9YX6Tf63yRatAquGBxoCX67wyekhCH4ZqioD6lKh::::::userdb_quota_rule=*:storage=1G%0a@]%0a%0aEach field is separated with a colon.%0a%0aThe first field tells you the username. Note that usernames include a domain -- this is because you might host mail for multiple domains. So, when logging in to the mail server, your mail client must be of the format username@example.com.%0a%0aThe second field is the password hash. To generate a hash, you can run encrypt:%0a%0a[@%0a$ encrypt%0a@]%0a%0aType your password, then press @@enter@@. Type @@ctrl+d@@ to quit.%0a%0a@@smtpctl encrypt@@ also does the same thing:%0a%0a[@%0a$ smtpctl encrypt%0a@]%0a%0a'''WARNING''': Special characters like $, when used in passwords, may cause issues with your mail client or with opensmtpd. To be safe, you might want to use only alphanumeric characters for your password. You can increase the length of the password for more security.%0a%0aThe last field sets how much data storage each user is allowed. The default here is 1 gigabyte.%0a%0a!!! File Permissions%0a%0aMake sure to set the proper permissions:%0a%0a[@%0a$ doas chown -R _smtpd:_dovecot /etc/mail/%0a$ doas chmod -R o-rx /etc/mail/%0a@]%0a%0a!! IMAP and POP3 via dovecot%0a%0aTo finish the setup, we need to [[dovecot/install|install and configure dovecot]].%0a%0a!! DKIM signing%0a%0aWe will need to set up [[DNS/DKIM|dkim]] to have the mail properly signed.%0a%0a!! Troubleshooting%0a%0aOpenSMTPD may end up in an inconsistent state. This can happen due to a misconfiguration. One symptom is you see this error:%0a%0asmtpd[]: pony express: smtpd: socket: Too many open files%0a%0aTo fix this, you can delete all the temporary files inside OpenSMTPD.%0a%0a'''WARNING''': this will delete any messages in the queue:%0a%0a[@%0a$ doas rcctl stop smtpd%0a$ doas rm -r /var/spool/smtpd/queue/*%0a$ doas rm -r /var/spool/smtpd/offline/*%0a@]%0a%0aAt times, opensmtpd may be unable to connect because outgoing packets are being filtered. For example, suppose you are trying to send a letter to yahoo, but you get errors similar to following, showing a connection timeout:%0a%0a[@%0asmtpd[]: smtp-out: Enabling route [] %3c-> 67.195.204.77 (mtaproxy1.free.mail.vip.bf1.yahoo.com)%0asmtpd[]: smtp-out: Enabling route [] %3c-> 67.195.228.106 (mtaproxy2.free.mail.vip.gq1.yahoo.com)%0asmtpd[]: mta error reason=Connection timeout%0asmtpd[]: smtp-out: Disabling route [] %3c-> 104.47.55.33 (104.47.55.33) for 15s%0a@]%0a%0aAn easy way to test if your packets are being filtered is:%0a%0a[@%0a$ dig -t mx yahoo.com%0a;; ANSWER SECTION:%0ayahoo.com. 395 IN MX 1 mta6.am0.yahoodns.net.%0ayahoo.com. 395 IN MX 1 mta5.am0.yahoodns.net.%0ayahoo.com. 395 IN MX 1 mta7.am0.yahoodns.net.%0a$ nc mta5.am0.yahoodns.net 25%0a@]%0a%0aIf you get no response, then outgoing packets to port 25 are being blocked (often due to firewalls by your VPS provider to block spam). If mail is working, you should see a 220 reply:%0a%0a[@%0a$ nc mta5.am0.yahoodns.net 25%0a220 mtaproxy511.free.mail.ne1.yahoo.com ESMTP ready%0a@]%0a%0aIt is also possible that TLS is being dropped by the firewall. You can test using openssl:%0a%0a[@%0a$ openssl s_client -starttls smtp -connect mta5.am0.yahoodns.net:25%0aCONNECTED(00000003)%0adepth=2 C = US, O = DigiCert Inc, OU = www.digicert.com, CN = DigiCert High Assurance EV Root CA%0averify return:1%0adepth=1 C = US, O = DigiCert Inc, OU = www.digicert.com, CN = DigiCert SHA2 High Assurance Server CA%0averify return:1%0adepth=0 C = US, ST = California, L = Sunnyvale, O = Oath Inc, CN = *.am0.yahoodns.net%0a...%0a250 STARTTLS%0a@]%0a%0aYou should see the entire SSL cert plus 250 STARTTLS reply. If you see the response hang at any point (eg, it returns CONNECTED(00000003) and nothing else), then TLS on port 25 is being filtered.%0a%0aIf you see this warning message in /var/log/maillog:%0a%0a[@%0aDec 6 03:44:17 smtpd[]: info: OpenSMTPD 6.7.0 starting %0aDec 6 03:44:17 smtpd[]: pony express: smtpd: socket: Too many open files %0aDec 6 03:44:17 smtpd[]: warn: lost child: pony express exited abnormally %0a@]%0a%0aThis is due to having too many IP addresses that opensmtpd tries to bind to. This happens when you have a rule that says @@listen on egress@@:%0a%0a[@%0alisten on egress port 25 tls pki fruit.ircnow.org mask-src filter { check_rdns check_fcrdns }%0alisten on egress port 587 tls-require pki fruit.ircnow.org auth %3cpasswd> mask-src filter { check_rdns check_fcrdns }%0a@]%0a%0aThese two lines mean that opensmtpd will listen to '''all''' available ip addresses, including the hundreds of IPv6 addresses you may have in @@/etc/hostname.vio0@@ and @@ifconfig vio0@@. To fix this, you must specify the IP addresses you want to listen to:%0a%0a[@%0aipv4 = "38.81.163.143"%0aipv6 = "2602:fccf:1:143::"%0acheck = "pki example.com filter { check_rdns check_fcrdns } hostname example.com"%0aauthcheck = "pki example.com auth %3cpasswd> filter { check_rdns check_fcrdns dkimsign } hostname example.com"%0a%0a# listeners%0alisten on socket filter "dkimsign"%0alisten on lo0 filter "dkimsign"%0alisten on $ipv4 port 25 tls $check%0alisten on $ipv6 port 25 tls $check%0alisten on $ipv4 port 465 smtps $authcheck%0alisten on $ipv6 port 465 smtps $authcheck%0alisten on $ipv4 port 587 tls-require $authcheck%0alisten on $ipv6 port 587 tls-require $authcheck%0a@]%0a%0a!!! Open Mail Relay%0a%0aIf all your email is being marked as spam, check @@/var/log/maillog@@ . If you see a message like the following:%0a[@%0aJan 8 11:00:29 smtpd[39035]: 83bd6b3b1669649f mta delivery evpid=a8d16cd2144222fa from=%3cspammer@example.com> to=%3cvictim@example.com> rcpt=%3c-> source="192.168.0.1" relay="10.0.0.1 (10.0.0.1)" delay=16h2s result="TempFail" stat="451 4.7.650 The mail server [192.168.0.1] has been temporarily rate limited due to IP reputation. For e-mail delivery information, see https://postmaster.example.com (S843)"%0a@]%0aThen your server is being exploited as an [[opensmtpd/openrelay|open mail relay]]! Please follow the guide to fix it.%0a%0a!! [[opensmtpd/troubleshoot|Troubleshooting OpenSMTPd]]%0a -time=1672417020 +text=Let's set up a mail server with dkim signing and basic spam checks:%0a%0a!! Before we begin%0a%0aRead the the man pages for [[https://man.openbsd.org/smtpd|opensmtpd]], [[https://man.openbsd.org/smtpd.conf|smtpd.conf]], and [[https://man.openbsd.org/smtpctl|smtpctl]]. %0a%0aRead the [[https://github.com/poolpOrg/OpenSMTPD-book|free OpenSMTPd book]] by the%0aauthor of OpenSMTPd%0a%0a!! DNS%0a%0aRunning a mail server requires proper DNS records. If you have not already, you will%0awant to read up on [[dns/overview|DNS]] and [[nsd/configure|set up your name server]].%0a%0aYou will need to [[DNS/Mail|add proper DNS records]] to your domain and make sure they work.%0a%0a!! Install%0a%0aOpensmtpd is part of OpenBSD base, but we will also want to install some%0aopensmtpd-related packages and dovecot:%0a%0a[@%0a$ doas pkg_add opensmtpd-extras opensmtpd-filter-dkimsign-- dovecot%0a@]%0a%0a!! Configuration%0a%0a!!! TLS%0a%0aYou will want to use [[acme-client/configure|acme-client]] to request a TLS public cert and private key%0ain @@/etc/ssl/@@.%0a%0aNext, we'll create our smtpd configuration file in @@/etc/mail/smtpd.conf@@:%0a%0a[@%0a# PKI for TLS%0apki example.com cert "/etc/ssl/example.com.fullchain.pem"%0apki example.com key "/etc/ssl/private/example.com.key"%0a@]%0a%0aThis defines our public and private key pair for TLS encryption.%0a%0a!!! Tables%0a%0aNext, we define 5 tables:%0a%0a[@%0a# tables setup%0atable domains file:/etc/mail/domains%0atable passwd passwd:/etc/mail/passwd%0atable virtuals file:/etc/mail/virtuals%0atable hosts file:/etc/mail/hosts%0atable users file:/etc/mail/users%0a@]%0a%0aThe domains table contains a list of domains that our mail server should %0areceive mail on.%0a%0aThe passwd table contains a colon-separated list of username/password/disk quota%0aentries.%0a%0aThe virtuals file shows which virtual user should handle whose mail. They are written as @@key: value@@ pairs.%0aSee [[https://man.openbsd.org/aliases|aliases(5)]] for more information.%0a%0aThe hosts file contains a list of trusted sending hosts.%0a%0aThe users file contains a list of valid sending users.%0a%0aAll of these tables will be explained further in the following sections.%0a%0a!!! Dealing with Spam%0a%0a[@%0a# Blocks junk mail%0afilter check_rdns phase connect match !rdns junk%0afilter check_fcrdns phase connect match !fcrdns junk%0afilter "dkimsign" proc-exec "filter-dkimsign -d example.com -s mail -k /etc/dkim/private.key" user _smtpd group _smtpd%0a@]%0a%0aThe first filter will check if the sender has an rdns entry. If not, the mail%0awill be labeled as junk.%0a%0aThe second filter will check if the sender's forward and reverse dns entry match. If%0anot, the mail will be labeled as junk.%0a%0aThe third filter will sign any email with the DKIM private key.%0a%0a# -d specifies the domain name to sign for; you must replace example.com with your real domain.%0a# -s specifies the selector (in this case mail).%0a# -k specifies the path of the private key.%0a# user and group both specify _smtpd, the user and group that does the signing%0a%0a!!! Macros%0a%0aA macro defines a variable that will be replaced with a block of text:%0a%0a[@%0a# macros%0aipv4 = "192.168.0.1"%0aipv6 = "2001:db8::"%0acheck = "pki example.com mask-src filter { check_rdns check_fcrdns } hostname example.com"%0aauthcheck = "pki example.com auth %3cpasswd> mask-src senders %3cusers> filter { check_rdns check_fcrdns dkimsign } hostname example.com"%0a@]%0a%0aLines 2 and 3 define the IPv4 and IPv6 addresses used for sending and receiving mail.%0a%0aLine 4 tells opensmtpd to use the public/private keys we defined earlier for @@example.com@@. We mask the sender's source (the '''from''' part of the @@Received@@ header). We also apply two filters to check for proper forward and reverse confirmed DNS entries. Finally, we indicate that the sending hostname must be example.com instead of the default server name.%0a%0aLine 5 is identical to line 4 except it requires authentication with the password file and it checks if the sender is allowed.%0a%0a!!! Listeners%0a%0aThe listeners tell us what network interfaces, IP addresses, and ports to listen on.%0a%0a[@%0a# listeners%0alisten on socket filter "dkimsign"%0alisten on lo0 filter "dkimsign"%0alisten on $ipv4 port 25 tls $check%0alisten on $ipv6 port 25 tls $check%0alisten on $ipv4 port 465 smtps $authcheck%0alisten on $ipv6 port 465 smtps $authcheck%0alisten on $ipv4 port 587 tls-require $authcheck%0alisten on $ipv6 port 587 tls-require $authcheck%0a@]%0a%0aLine 2 tells smtpd to listen to the UNIX domain socket and to DKIM sign all %0aemails. Line 3 tells us to listen to the loopback interface and also%0asign all emails.%0a%0aLines 4-5 tells smtpd to listen on the IPv4 and IPv6 address on port 25, to provide%0aTLS if supported but to offer plaintext as a fallback. Only basic checking is done.%0a%0aLines 6-7 tells smtpd to listen on the IPv4 and IPv6 address on port 465, for SMTPS.%0aTLS encryption is required and authentication checking is forced because this socket%0acan be used for sending mail to other servers. We want to avoid an%0a[[opensmtpd/openrelay|open mail relay]].%0a%0aLines 8-9 is similar except it's for port 587, which is the SMTP submission port.%0a%0a!!! Rules%0a%0aNext we define the actions that opensmtpd can take and how to decide which%0aaction to follow:%0a%0a[@%0a# rules%0aaction "lmtp" lmtp "/var/dovecot/lmtp" rcpt-to virtual %3cvirtuals>%0aaction "outbound" relay src $ipv4%0a%0amatch from any for domain %3cdomains> action "lmtp"%0amatch from local for any action "outbound"%0amatch from src %3chosts> for any action "outbound"%0amatch auth from any for any action "outbound"%0a@]%0a%0aIn line 2, we define the action "lmtp": we pass the mail to dovecot to handle using the Local Mail Transfer Protocol (LMTP). The actual recipient will be translated using the virtuals table.%0a%0aIn line 3, we define the action "outbound": we relay (send) the email out.%0a%0aLine 4 defines our first matching rule: any email headed for one of our domains should be handed over to lmtp (handed over to dovecot).%0a%0aLine 5 defines our second matching rule: any email from a local IP address or queue can relay (send) without authentication.%0a%0aLine 6 defines our third matching rule: any email from our trusted @@/etc/mail/hosts@@ file will automatically be relayed (sent) without authentication.%0a%0aLine 7 defines our last matching rule: any email that has been properly authenticated will be relayed (sent).%0a%0a!!! Complete configuration file%0a%0aHere is the entire configuration file in @@/etc/mail/smtpd.conf@@:%0a%0a[@%0a# PKI for TLS%0apki example.com cert "/etc/ssl/example.com.fullchain.pem"%0apki example.com key "/etc/ssl/private/example.com.key"%0a%0a# tables setup%0atable domains file:/etc/mail/domains%0atable passwd passwd:/etc/mail/passwd%0atable virtuals file:/etc/mail/virtuals%0atable hosts file:/etc/mail/hosts%0atable users file:/etc/mail/users%0a%0a# Blocks junk mail%0afilter check_rdns phase connect match !rdns junk%0afilter check_fcrdns phase connect match !fcrdns junk%0afilter "dkimsign" proc-exec "filter-dkimsign -d example.com -s mail -k /etc/dkim/private.key" user _smtpd group _smtpd%0a%0a# macros%0aipv4 = "192.168.0.1"%0aipv6 = "2001:db8::"%0acheck = "pki example.com mask-src filter { check_rdns check_fcrdns } hostname example.com"%0aauthcheck = "pki example.com auth %3cpasswd> mask-src senders %3cusers> filter { check_rdns check_fcrdns dkimsign } hostname example.com"%0a%0a# listeners%0alisten on socket filter "dkimsign"%0alisten on lo0 filter "dkimsign"%0alisten on $ipv4 port 25 tls $check%0alisten on $ipv6 port 25 tls $check%0alisten on $ipv4 port 465 smtps $authcheck%0alisten on $ipv6 port 465 smtps $authcheck%0alisten on $ipv4 port 587 tls-require $authcheck%0alisten on $ipv6 port 587 tls-require $authcheck%0a%0a# rules%0aaction "lmtp" lmtp "/var/dovecot/lmtp" rcpt-to virtual %3cvirtuals>%0aaction "outbound" relay src $ipv4%0a%0amatch from any for domain %3cdomains> action "lmtp"%0amatch from local for any action "outbound"%0amatch from src %3chosts> for any action "outbound"%0amatch auth from any for any action "outbound"%0a@]%0a%0a!! Configuring Virtual Users%0a%0aA single user vmail will receive mail for all virtual users:%0a%0a[@%0a$ doas useradd -m -g =uid -c "Virtual Mail" -d /var/vmail -s /sbin/nologin vmail%0a@]%0a%0a/var/vmail will be used to store virtual users' maildir folders. It will be managed by dovecot, which receives mail via LMTP.%0a%0a!! Adding users%0a%0aCreate a new file @@/etc/mail/virtuals@@ and add these lines:%0a%0a[@%0aroot admin@example.com%0aadmin@example.com vmail%0ausername@example.com vmail%0a@]%0a%0aNow, any mail sent to root will get forwarded to admin@example.com.%0a%0aThis is recommended to do so, as daily(8) and other programs will send mails to root. check the mail account linked to root account often!%0a%0aYou can optionally add one line for each user to provide aliases.%0a%0aFor each new user account, you will want to create a new line.%0a%0aYou'll also need to create one line for each user in @@/etc/mail/users@@:%0a%0a[@%0aadmin@example.com: admin@example.com%0ausername@example.com: username@example.com%0a@]%0a%0aA whitelist of known good senders goes into @@/etc/mail/hosts@@:%0a%0a[@%0alocalhost%0a127.0.0.1%0a192.168.1.1%0a2001:db8::%0a@]%0a%0aReplace IP addresses 192.168.1.1 and 2001:db8:: with your server's real IP addresses.%0a%0aIn @@/etc/mail/mailname@@, put in the name you want to use for your mail server. This%0ais very important for passing anti-spam checks:%0a%0a[@%0aexample.com%0a@]%0a%0aThe list of domains this mail server can receive emails for will go inside @@/etc/mail/domains@@:%0a%0a[@%0aexample.com%0amail.example.com%0a@]%0a%0aIn @@/etc/mail/passwd@@, we have a list of colon-separated user credentials:%0a%0a[@%0aadmin@example.com:$2b$10$h5itbhzs73T4jsHAj9YX6Tf63yRatAquGBxoCX67wyekhCH4ZqioD6lKh::::::userdb_quota_rule=*:storage=1G%0ausername@example.com:$2b$10$h5itbhzs73T4jsHAj9YX6Tf63yRatAquGBxoCX67wyekhCH4ZqioD6lKh::::::userdb_quota_rule=*:storage=1G%0a@]%0a%0aEach field is separated with a colon.%0a%0aThe first field tells you the username. Note that usernames include a domain -- this is because you might host mail for multiple domains. So, when logging in to the mail server, your mail client must be of the format username@example.com.%0a%0aThe second field is the password hash. To generate a hash, you can run encrypt:%0a%0a[@%0a$ encrypt%0a@]%0a%0aType your password, then press @@enter@@. Type @@ctrl+d@@ to quit.%0a%0a@@smtpctl encrypt@@ also does the same thing:%0a%0a[@%0a$ smtpctl encrypt%0a@]%0a%0a'''WARNING''': Special characters like $, when used in passwords, may cause issues with your mail client or with opensmtpd. To be safe, you might want to use only alphanumeric characters for your password. You can increase the length of the password for more security.%0a%0aThe last field sets how much data storage each user is allowed. The default here is 1 gigabyte.%0a%0a!!! File Permissions%0a%0aMake sure to set the proper permissions:%0a%0a[@%0a$ doas chown -R _smtpd:_dovecot /etc/dkim/%0a$ doas chmod -R o-rx /etc/{dkim,mail}/%0a@]%0a%0a!! IMAP and POP3 via dovecot%0a%0aTo finish the setup, we need to [[dovecot/install|install and configure dovecot]].%0a%0a!! DKIM signing%0a%0aWe will need to set up [[DNS/DKIM|dkim]] to have the mail properly signed.%0a%0a!! Troubleshooting%0a%0aOpenSMTPD may end up in an inconsistent state. This can happen due to a misconfiguration. One symptom is you see this error:%0a%0asmtpd[]: pony express: smtpd: socket: Too many open files%0a%0aTo fix this, you can delete all the temporary files inside OpenSMTPD.%0a%0a'''WARNING''': this will delete any messages in the queue:%0a%0a[@%0a$ doas rcctl stop smtpd%0a$ doas rm -r /var/spool/smtpd/queue/*%0a$ doas rm -r /var/spool/smtpd/offline/*%0a@]%0a%0aAt times, opensmtpd may be unable to connect because outgoing packets are being filtered. For example, suppose you are trying to send a letter to yahoo, but you get errors similar to following, showing a connection timeout:%0a%0a[@%0asmtpd[]: smtp-out: Enabling route [] %3c-> 67.195.204.77 (mtaproxy1.free.mail.vip.bf1.yahoo.com)%0asmtpd[]: smtp-out: Enabling route [] %3c-> 67.195.228.106 (mtaproxy2.free.mail.vip.gq1.yahoo.com)%0asmtpd[]: mta error reason=Connection timeout%0asmtpd[]: smtp-out: Disabling route [] %3c-> 104.47.55.33 (104.47.55.33) for 15s%0a@]%0a%0aAn easy way to test if your packets are being filtered is:%0a%0a[@%0a$ dig -t mx yahoo.com%0a;; ANSWER SECTION:%0ayahoo.com. 395 IN MX 1 mta6.am0.yahoodns.net.%0ayahoo.com. 395 IN MX 1 mta5.am0.yahoodns.net.%0ayahoo.com. 395 IN MX 1 mta7.am0.yahoodns.net.%0a$ nc mta5.am0.yahoodns.net 25%0a@]%0a%0aIf you get no response, then outgoing packets to port 25 are being blocked (often due to firewalls by your VPS provider to block spam). If mail is working, you should see a 220 reply:%0a%0a[@%0a$ nc mta5.am0.yahoodns.net 25%0a220 mtaproxy511.free.mail.ne1.yahoo.com ESMTP ready%0a@]%0a%0aIt is also possible that TLS is being dropped by the firewall. You can test using openssl:%0a%0a[@%0a$ openssl s_client -starttls smtp -connect mta5.am0.yahoodns.net:25%0aCONNECTED(00000003)%0adepth=2 C = US, O = DigiCert Inc, OU = www.digicert.com, CN = DigiCert High Assurance EV Root CA%0averify return:1%0adepth=1 C = US, O = DigiCert Inc, OU = www.digicert.com, CN = DigiCert SHA2 High Assurance Server CA%0averify return:1%0adepth=0 C = US, ST = California, L = Sunnyvale, O = Oath Inc, CN = *.am0.yahoodns.net%0a...%0a250 STARTTLS%0a@]%0a%0aYou should see the entire SSL cert plus 250 STARTTLS reply. If you see the response hang at any point (eg, it returns CONNECTED(00000003) and nothing else), then TLS on port 25 is being filtered.%0a%0aIf you see this warning message in /var/log/maillog:%0a%0a[@%0aDec 6 03:44:17 smtpd[]: info: OpenSMTPD 6.7.0 starting %0aDec 6 03:44:17 smtpd[]: pony express: smtpd: socket: Too many open files %0aDec 6 03:44:17 smtpd[]: warn: lost child: pony express exited abnormally %0a@]%0a%0aThis is due to having too many IP addresses that opensmtpd tries to bind to. This happens when you have a rule that says @@listen on egress@@:%0a%0a[@%0alisten on egress port 25 tls pki fruit.ircnow.org mask-src filter { check_rdns check_fcrdns }%0alisten on egress port 587 tls-require pki fruit.ircnow.org auth %3cpasswd> mask-src filter { check_rdns check_fcrdns }%0a@]%0a%0aThese two lines mean that opensmtpd will listen to '''all''' available ip addresses, including the hundreds of IPv6 addresses you may have in @@/etc/hostname.vio0@@ and @@ifconfig vio0@@. To fix this, you must specify the IP addresses you want to listen to:%0a%0a[@%0aipv4 = "38.81.163.143"%0aipv6 = "2602:fccf:1:143::"%0acheck = "pki example.com filter { check_rdns check_fcrdns } hostname example.com"%0aauthcheck = "pki example.com auth %3cpasswd> filter { check_rdns check_fcrdns dkimsign } hostname example.com"%0a%0a# listeners%0alisten on socket filter "dkimsign"%0alisten on lo0 filter "dkimsign"%0alisten on $ipv4 port 25 tls $check%0alisten on $ipv6 port 25 tls $check%0alisten on $ipv4 port 465 smtps $authcheck%0alisten on $ipv6 port 465 smtps $authcheck%0alisten on $ipv4 port 587 tls-require $authcheck%0alisten on $ipv6 port 587 tls-require $authcheck%0a@]%0a%0a!!! Open Mail Relay%0a%0aIf all your email is being marked as spam, check @@/var/log/maillog@@ . If you see a message like the following:%0a[@%0aJan 8 11:00:29 smtpd[39035]: 83bd6b3b1669649f mta delivery evpid=a8d16cd2144222fa from=%3cspammer@example.com> to=%3cvictim@example.com> rcpt=%3c-> source="192.168.0.1" relay="10.0.0.1 (10.0.0.1)" delay=16h2s result="TempFail" stat="451 4.7.650 The mail server [192.168.0.1] has been temporarily rate limited due to IP reputation. For e-mail delivery information, see https://postmaster.example.com (S843)"%0a@]%0aThen your server is being exploited as an [[opensmtpd/openrelay|open mail relay]]! Please follow the guide to fix it.%0a%0a!! [[opensmtpd/troubleshoot|Troubleshooting OpenSMTPd]]%0a +time=1678077572 +author:1678077572=jrmu +csum:1678077572=Moved to /etc/dkim/ to fix permissions bugs +diff:1678077572:1672417020:=77c77%0a%3c filter "dkimsign" proc-exec "filter-dkimsign -d example.com -s mail -k /etc/dkim/private.key" user _smtpd group _smtpd%0a---%0a> filter "dkimsign" proc-exec "filter-dkimsign -d example.com -s mail -k /etc/mail/dkim/private.key" user _smtpd group _smtpd%0a188,189c188,189%0a%3c filter "dkimsign" proc-exec "filter-dkimsign -d example.com -s mail -k /etc/dkim/private.key" user _smtpd group _smtpd%0a%3c %0a---%0a> filter "dkimsign" proc-exec "filter-dkimsign -d example.com -s mail -k /etc/mail/dkim/private.key" user _smtpd group _smtpd%0a> %0a310,311c310,311%0a%3c $ doas chown -R _smtpd:_dovecot /etc/dkim/%0a%3c $ doas chmod -R o-rx /etc/{dkim,mail}/%0a---%0a> $ doas chown -R _smtpd:_dovecot /etc/mail/%0a> $ doas chmod -R o-rx /etc/mail/%0a +host:1678077572=38.87.162.154 author:1672417020=mkf csum:1672417020=mention root mail diff:1672417020:1667566017:=237,238d236%0a%3c %0a%3c This is recommended to do so, as daily(8) and other programs will send mails to root. check the mail account linked to root account often!%0a blob - 0c12a69317acf529d61877e117c40f3f73bac9d1 blob + ae18f54024c69be665d7a37768fb983a2cccf167 --- wiki.d/Opensmtpd.RecentChanges +++ wiki.d/Opensmtpd.RecentChanges @@ -1,9 +1,9 @@ -version=pmwiki-2.2.130 ordered=1 urlencoded=1 -agent=Mozilla/5.0 (X11; OpenBSD amd64; rv:68.0) Gecko/20100101 Firefox/68.0 SeaMonkey/2.53.14 +version=pmwiki-2.3.20 ordered=1 urlencoded=1 +agent=w3m/0.5.3+git20210102 charset=UTF-8 ctime=1621253792 -host=198.251.81.133 +host=38.87.162.154 name=Opensmtpd.RecentChanges -rev=75 -text=* [[Opensmtpd/Configure]] . . . December 30, 2022, at 04:17 PM by [[~mkf]]: [=mention root mail=]%0a* [[Opensmtpd/Troubleshoot]] . . . July 20, 2022, at 03:58 PM by [[~jlj]]: [=Added notes about how I resolved the first two errors, on nastycode=]%0a* [[Opensmtpd/Test]] . . . July 03, 2022, at 11:13 AM by [[~mkf]]: [==]%0a* [[Opensmtpd/Openrelay]] . . . November 11, 2021, at 10:37 AM by [[~mkf]]: [==]%0a -time=1672417020 +rev=76 +text=* [[Opensmtpd/Configure]] . . . @2023-03-06T04:39:32Z by [[~jrmu]]: [=Moved to /etc/dkim/ to fix permissions bugs=]%0a* [[Opensmtpd/Troubleshoot]] . . . July 20, 2022, at 03:58 PM by [[~jlj]]: [=Added notes about how I resolved the first two errors, on nastycode=]%0a* [[Opensmtpd/Test]] . . . July 03, 2022, at 11:13 AM by [[~mkf]]: [==]%0a* [[Opensmtpd/Openrelay]] . . . November 11, 2021, at 10:37 AM by [[~mkf]]: [==]%0a +time=1678077572 blob - 1584c0503783b8225bfa13d2264fedf13bc4c30e blob + 76c922c8b2683b955ab6217e03c13c0204767294 --- wiki.d/Site.AllRecentChanges +++ wiki.d/Site.AllRecentChanges @@ -1,11 +1,11 @@ -version=pmwiki-2.2.130 ordered=1 urlencoded=1 -agent=Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/92.0.4515.131 Safari/537.36 +version=pmwiki-2.3.20 ordered=1 urlencoded=1 +agent=w3m/0.5.3+git20210102 charset=UTF-8 ctime=1596101899 -host=2001:bc8:1830:1533::12 +host=38.87.162.154 name=Site.AllRecentChanges -rev=11448 -text=* [[Openbsd.OpenTracker]] . . . March 03, 2023, at 04:37 PM by [[~baytuch]]: [==]%0a* [[SiteAdmin.AuthUser]] . . . March 03, 2023, at 05:31 AM by [[~jrmu]]: [==]%0a* [[Almanack.Almanack]] . . . March 02, 2023, at 05:10 AM by [[~jrmu]]: [==]%0a* [[Ircnow.Roadmap]] . . . March 02, 2023, at 05:10 AM by [[~jrmu]]: [==]%0a* [[Ircnow.Roadmap2023]] . . . March 02, 2023, at 05:07 AM by [[~jrmu]]: [==]%0a* [[Oidentd.ZNC]] . . . February 28, 2023, at 02:34 AM by [[~jrmu]]: [==]%0a* [[Oidentd.Changeident]] . . . February 28, 2023, at 02:33 AM by [[~jrmu]]: [=This was suggested by another author, but because the solution is not permanent, we move it to a sep=]%0a* [[Acme-client.Configure]] . . . February 26, 2023, at 10:06 PM by [[~jrmu]]: [=Revert as I'm not sure if /etc/daily.local is better=]%0a* [[Ircnow.Servers]] . . . February 26, 2023, at 05:42 PM by [[~Yonle]]: [=No.=]%0a* [[Stagit.Install]] . . . February 26, 2023, at 05:24 PM by [[~fossdev]]: [==]%0a* [[Openbsd.Gotweb]] . . . February 26, 2023, at 05:04 PM by [[~fossdev]]: [==]%0a* [[Got.Repo]] . . . February 26, 2023, at 05:02 PM by [[~fossdev]]: [==]%0a* [[Oidentd.Install]] . . . February 26, 2023, at 01:59 AM by [[~jrmu]]: [=Revert erroneous change=]%0a* [[Ircnow.Explorer]] . . . February 26, 2023, at 01:35 AM by [[~jrmu]]: [==]%0a* [[Ircnow.Codeforce]] . . . February 26, 2023, at 01:03 AM by [[~jrmu]]: [==]%0a* [[Donations.Donations]] . . . February 25, 2023, at 08:36 PM by [[~jrmu]]: [==]%0a* [[Main.HomePage]] . . . February 25, 2023, at 05:39 AM by [[~jrmu]]: [==]%0a* [[Vps.Vps]] . . . February 25, 2023, at 12:31 AM by [[~jrmu]]: [==]%0a* [[Botnow.Install]] . . . February 24, 2023, at 11:24 PM by [[~Naglfar]]: [=Add a list with new parameters=]%0a* [[Hardware.Ps2]] . . . February 24, 2023, at 04:26 PM by [[~mkf]]: [==]%0a* [[Bouncer.Bouncer]] . . . February 22, 2023, at 02:06 PM by [[~Yonle]]: [==]%0a* [[Ircnow.Minutemin]] . . . February 18, 2023, at 05:41 AM by [[~jrmu]]: [==]%0a* [[Ircnow.SSHFingerprints]] . . . February 17, 2023, at 05:39 PM by [[~jrmu]]: [==]%0a* [[Baytuch.Bio]] . . . February 17, 2023, at 12:00 PM by [[~baytuch]]: [==]%0a* [[Openhttpd.Configure]] . . . February 17, 2023, at 11:39 AM by [[~baytuch]]: [==]%0a* [[Openbsd.Plermoa]] . . . February 16, 2023, at 04:52 AM by [[~Yonle]]: [=Redirect=]%0a* [[Openbsd.Pleroma]] . . . February 12, 2023, at 02:49 AM by [[~Yonle]]: [=Oops=]%0a* [[Openbsd.Akkoma]] . . . February 12, 2023, at 02:48 AM by [[~Yonle]]: [=Oof=]%0a* [[Akkoma.Install]] . . . February 09, 2023, at 12:49 PM by [[~Yonle]]: [==]%0a* [[Google.Sins]] . . . February 08, 2023, at 05:13 AM by [[~Yonle]]: [==]%0a* [[Debate.Googledanger]] . . . February 08, 2023, at 05:01 AM by [[~Yonle]]: [==]%0a* [[Debate.Outreachkids]] . . . February 08, 2023, at 04:34 AM by [[~Yonle]]: [==]%0a* [[Openbsd.Mlmmj]] . . . February 08, 2023, at 02:50 AM by [[~Yonle]]: [==]%0a* [[Openbsd.Mosh]] . . . February 07, 2023, at 11:30 AM by [[~Yonle]]: [==]%0a* [[Shelllabs.Reading]] . . . February 07, 2023, at 02:06 AM by [[~jrmu]]: [==]%0a* [[Squirrelmail.Install]] . . . February 06, 2023, at 09:24 PM by [[~Naglfar]]: [=Add snapshot download reference=]%0a* [[Route.Usage]] . . . February 06, 2023, at 02:38 PM by [[~mkf]]: [==]%0a* [[Mkf.Wikiv1]] . . . February 06, 2023, at 02:31 PM by [[~mkf]]: [==]%0a* [[Psybnc.Install]] . . . February 06, 2023, at 02:31 PM by [[~mkf]]: [==]%0a* [[Debate.Openweb]] . . . February 06, 2023, at 02:15 PM by [[~Yonle]]: [==]%0a* [[Debate.Youtubedanger]] . . . February 06, 2023, at 02:10 PM by [[~Yonle]]: [==]%0a* [[Debate.Providers]] . . . February 06, 2023, at 01:41 PM by [[~Yonle]]: [==]%0a* [[Paster.Install]] . . . February 06, 2023, at 10:22 AM by [[~mkf]]: [==]%0a* [[Anope.Install]] . . . February 06, 2023, at 09:46 AM by [[~mkf]]: [==]%0a* [[9.Drawterm]] . . . February 05, 2023, at 09:18 PM by [[~mkf]]: [==]%0a* [[Znc.Chroot]] . . . February 04, 2023, at 04:45 PM by [[~Francis]]: [==]%0a* [[Password.Hashes]] . . . February 04, 2023, at 07:27 AM by [[~izzyb]]: [=formatting fixes=]%0a* [[Chess.Chessgogi]] . . . February 04, 2023, at 03:49 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Passwords]] . . . February 03, 2023, at 07:49 PM by [[~izzyb]]: [==]%0a* [[Password.Management]] . . . February 03, 2023, at 07:44 PM by [[~izzyb]]: [==]%0a* [[DNS.Ipv4rDNS]] . . . February 01, 2023, at 08:31 PM by [[~izzyb]]: [=added note to clarify what address needs to be specified.=]%0a* [[Dovecot.SharedMailboxes]] . . . January 31, 2023, at 08:29 PM by [[~izzyb]]: [==]%0a* [[Dovecot.SharedFolders]] . . . January 31, 2023, at 06:03 AM by [[~izzyb]]: [=renaming to sharedMailboxes=]%0a* [[Soju.Install]] . . . January 24, 2023, at 11:29 AM by [[~mkf]]: [=minor changes on style=]%0a* [[Lilywhitebot.Install]] . . . January 24, 2023, at 11:23 AM by [[~mkf]]: [==]%0a* [[SendMoneyToSplinter0616Outlook.Com]] . . . January 24, 2023, at 11:19 AM by [[~mkf]]: [==]%0a* [[9.9gridchan]] . . . January 22, 2023, at 07:01 AM by [[~jrmu]]: [==]%0a* [[Ircnow.Milestones]] . . . January 21, 2023, at 03:59 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Biboumi]] . . . January 20, 2023, at 08:11 PM by [[~mkf]]: [==]%0a* [[Biboumi.Install]] . . . January 20, 2023, at 08:10 PM by [[~mkf]]: [==]%0a* [[Texlive.Install]] . . . January 20, 2023, at 08:05 PM by [[~mkf]]: [==]%0a* [[Rcctl.Rcctl]] . . . January 20, 2023, at 08:00 PM by [[~mkf]]: [==]%0a* [[Vmm.Configure]] . . . January 20, 2023, at 07:59 PM by [[~mkf]]: [==]%0a* [[Hopm.Install]] . . . January 20, 2023, at 07:32 PM by [[~mkf]]: [==]%0a* [[Openbsd.Unrealircd]] . . . January 20, 2023, at 07:27 PM by [[~mkf]]: [==]%0a* [[Unrealircd.Install]] . . . January 20, 2023, at 07:24 PM by [[~mkf]]: [==]%0a* [[Pleroma.Install]] . . . January 20, 2023, at 07:18 PM by [[~mkf]]: [==]%0a* [[Gomuks.Install]] . . . January 20, 2023, at 07:08 PM by [[~mkf]]: [==]%0a* [[Gotweb.Install]] . . . January 20, 2023, at 07:02 PM by [[~mkf]]: [==]%0a* [[Webnews.Install]] . . . January 20, 2023, at 06:57 PM by [[~mkf]]: [==]%0a* [[Php.Install]] . . . January 20, 2023, at 06:52 PM by [[~mkf]]: [==]%0a* [[Mlmmj.Install]] . . . January 20, 2023, at 06:48 PM by [[~mkf]]: [==]%0a* [[Fiche.Install]] . . . January 20, 2023, at 06:44 PM by [[~mkf]]: [==]%0a* [[Prosody.Install]] . . . January 20, 2023, at 06:42 PM by [[~mkf]]: [==]%0a* [[Bitlbee.Install]] . . . January 20, 2023, at 06:36 PM by [[~mkf]]: [==]%0a* [[TigerVNC.Install]] . . . January 20, 2023, at 06:30 PM by [[~mkf]]: [==]%0a* [[NodeJS.Install]] . . . January 20, 2023, at 06:27 PM by [[~mkf]]: [==]%0a* [[Pmwiki.Install]] . . . January 20, 2023, at 06:19 PM by [[~mkf]]: [==]%0a* [[Xfce.Install]] . . . January 20, 2023, at 06:17 PM by [[~mkf]]: [==]%0a* [[Ngircd.Install]] . . . January 20, 2023, at 06:08 PM by [[~mkf]]: [==]%0a* [[Openbsd.Vipw]] . . . January 18, 2023, at 11:01 PM by [[~zen]]: [=added two spaces=]%0a* [[Grep.Usage]] . . . January 18, 2023, at 10:54 PM by [[~zen]]: [==]%0a* [[Openbsd.Loginconf]] . . . January 18, 2023, at 10:48 PM by [[~zen]]: [=OpenBSD FAQ link refenrece=]%0a* [[Openbsd.Singleuser]] . . . January 18, 2023, at 10:26 PM by [[~zen]]: [=changed the link reference=]%0a* [[Ssh.Fingerprints]] . . . January 14, 2023, at 04:31 PM by [[~izzyb]]: [=added link to ircnow network ssh fingerprints as example.=]%0a* [[Team.Networks]] . . . January 12, 2023, at 06:36 PM by [[~kilroy]]: [=Updated Sturtz IRC=]%0a* [[Openbsd.Dump]] . . . January 10, 2023, at 04:48 PM by [[~mkf]]: [=add -u, improve dump-ssh funcationality.=]%0a* [[Znc.Install]] . . . January 07, 2023, at 11:58 PM by [[~jrmu]]: [==]%0a* [[Jrmu.Bio]] . . . January 05, 2023, at 07:23 PM by [[~jrmu]]: [==]%0a* [[Rspamd.Configure]] . . . January 03, 2023, at 04:55 PM by [[~mkf]]: [==]%0a* [[Eggdrop191.Install]] . . . December 31, 2022, at 05:29 PM by [[~Yonle]]: [==]%0a* [[Dovecot.Pigeonhole]] . . . December 30, 2022, at 04:24 PM by [[~mkf]]: [=style 2=]%0a* [[Opensmtpd.Configure]] . . . December 30, 2022, at 04:17 PM by [[~mkf]]: [=mention root mail=]%0a* [[Openbsd.Quota]] . . . December 29, 2022, at 06:51 PM by [[~mkf]]: [==]%0a* [[Minutemin.Bootcamp]] . . . December 29, 2022, at 04:38 PM by [[~mkf]]: [==]%0a* [[Profiles.Miniontoby]] . . . December 26, 2022, at 07:26 PM by [[~miniontoby]]: [=Created=]%0a* [[Minetest.Minetest]] . . . December 26, 2022, at 07:25 PM by [[~miniontoby]]: [=Added building guide link=]%0a* [[Openbsd.Minetest]] . . . December 26, 2022, at 07:23 PM by [[~miniontoby]]: [=Added more ways to install=]%0a* [[Splinter0616Outlook.Com]] . . . December 25, 2022, at 02:37 AM by [[~SplinTer]]: [==]%0a* [[Ngircd.Oper]] . . . December 25, 2022, at 12:03 AM by [[~forero]]: [==]%0a* [[Profiles.Yonle]] . . . December 24, 2022, at 03:29 PM by [[~Yonle]]: [==]%0a* [[Openbsd.Honk]] . . . December 17, 2022, at 08:45 AM by [[~Yonle]]: [==]%0a* [[Yonle.Bio]] . . . December 13, 2022, at 05:18 PM by [[~Yonle]]: [==]%0a* [[Camping.Gear]] . . . December 12, 2022, at 04:39 AM by [[~jrmu]]: [==]%0a* [[Vhost.Vhost]] . . . December 12, 2022, at 03:36 AM by [[~xfnw]]: [==]%0a* [[Vhost.Ircnow]] . . . December 12, 2022, at 03:13 AM by [[~xfnw]]: [=ircfree.com is not an ircnow domain=]%0a* [[Shelllabs.Openaccess]] . . . December 08, 2022, at 10:02 PM by [[~redrum88]]: [==]%0a* [[I2Pd.Install]] . . . December 07, 2022, at 01:16 AM by [[~Yonle]]: [=Again not 7070=]%0a* [[I2Pd.Tunnels]] . . . December 06, 2022, at 02:52 PM by [[~Yonle]]: [=There we go. =]%0a* [[I2pd.Tunnels]] . . . December 06, 2022, at 02:45 PM by [[~Yonle]]: [==]%0a* [[Unbound.Configure]] . . . December 04, 2022, at 03:59 AM by [[~Yonle]]: [==]%0a* [[Profiles.Xfnw]] . . . November 28, 2022, at 10:38 PM by [[~xfnw]]: [=add pgp keys=]%0a* [[Unwind.Configure]] . . . November 26, 2022, at 09:23 PM by [[~akoizumi]]: [=add unwind=]%0a* [[Openbsd.Icecast]] . . . November 17, 2022, at 11:35 AM by [[~Yonle]]: [==]%0a* [[Debian.Install]] . . . November 13, 2022, at 11:43 AM by [[~suzerain]]: [=writing=]%0a* [[Lemon.Lemon]] . . . November 10, 2022, at 01:48 PM by [[~mkf]]: [==]%0a* [[Bouncer.JmIRC]] . . . November 04, 2022, at 06:18 PM by [[~baytuch]]: [=Added screenshots about setup=]%0a* [[Ambassador.Ilines]] . . . October 22, 2022, at 04:40 AM by [[~jrmu]]: [==]%0a* [[Bouncer.XChat]] . . . October 16, 2022, at 11:09 PM by [[~xfnw]]: [=XChat is unmaintained=]%0a* [[Eggdrop.VHost]] . . . October 02, 2022, at 01:05 PM by [[~sulieztya]]: [==]%0a* [[Eggdrop.VhostTCL]] . . . October 02, 2022, at 07:06 AM by [[~sulieztya]]: [==]%0a* [[Eggdrop.BotZNC]] . . . October 02, 2022, at 01:29 AM by [[~sulieztya]]: [==]%0a* [[Shelllabs.Intro]] . . . September 28, 2022, at 06:53 PM by [[~jrmu]]: [==]%0a* [[He.IPv6Certification]] . . . September 16, 2022, at 05:32 PM by [[~xfnw]]: [=create page=]%0a* [[Shelllabs.Education]] . . . September 14, 2022, at 07:30 PM by [[~jrmu]]: [==]%0a* [[About.AboutUs]] . . . September 13, 2022, at 06:42 PM by [[~zleap]]: [==]%0a* [[Site.SideBar]] . . . September 13, 2022, at 06:21 PM by [[~jrmu]]: [==]%0a* [[LegalAndSafety.LegalAndSafety]] . . . September 13, 2022, at 05:19 PM by [[~zleap]]: [==]%0a* [[LegalAndSafety.LegalAmpSafety]] . . . September 13, 2022, at 05:17 PM by [[~zleap]]: [==]%0a* [[LegalAmpSafety.Subheading]] . . . September 13, 2022, at 05:15 PM by [[~zleap]]: [==]%0a* [[Acmesh.Configure]] . . . September 11, 2022, at 06:03 PM by [[~akoizumi]]: [=Added acme.sh (currently a WIP)=]%0a* [[Dehydrated.Configure]] . . . September 11, 2022, at 02:52 PM by [[~akoizumi]]: [=Add dehydrated=]%0a* [[Profiles.Izzyb]] . . . September 11, 2022, at 06:28 AM by [[~izzyb]]: [==]%0a* [[Site.EditForm]] . . . September 11, 2022, at 06:22 AM by [[~izzyb]]: [=Make Author none editable field=]%0a* [[Netcat.Irc]] . . . September 11, 2022, at 04:21 AM by [[~izzyb]]: [=Removed info about PASS - moving to different doc as per jrmu request=]%0a* [[Openbsd.Geomyidae]] . . . September 10, 2022, at 02:31 AM by [[~akoizumi]]: [==]%0a* [[Openbsd.INN]] . . . September 10, 2022, at 02:23 AM by [[~akoizumi]]: [=Fix some types=]%0a* [[Ngircd.Loginconf]] . . . September 10, 2022, at 01:51 AM by [[~jrmu]]: [==]%0a* [[Heading.Subheading]] . . . September 07, 2022, at 07:23 PM by [[~zleap]]: [==]%0a* [[Eggdrop193.Install]] . . . September 07, 2022, at 04:48 PM by [[~jrmu]]: [==]%0a* [[Letsencrypt.Expired]] . . . September 06, 2022, at 12:00 AM by [[~xfnw]]: [=be less misleading about Let's Encrypt's reasoning for keeping the expired chain=]%0a* [[Ircnow.Pioneer]] . . . August 14, 2022, at 05:06 AM by [[~jrmu]]: [==]%0a* [[Openbsd.VsFTP]] . . . August 10, 2022, at 03:18 PM by [[~mkf]]: [=snipped unneeded output=]%0a* [[C.Scanf]] . . . August 10, 2022, at 09:51 AM by [[~mkf]]: [==]%0a* [[Vmm.Install]] . . . August 10, 2022, at 08:05 AM by [[~miniontoby]]: [=coconut to host=]%0a* [[Orange.CertsReissue]] . . . August 08, 2022, at 05:35 AM by [[~baytuch]]: [==]%0a* [[Team.Security]] . . . August 08, 2022, at 12:53 AM by [[~jrmu]]: [==]%0a* [[Netcat.Usage]] . . . August 04, 2022, at 01:12 AM by [[~tiramisu]]: [==]%0a* [[Freedom.Universal]] . . . August 03, 2022, at 06:33 PM by [[~jrmu]]: [==]%0a* [[Pgp.Upload]] . . . August 01, 2022, at 01:21 PM by [[~jan6]]: [=keys.openpgp.org uses a superior implementation, less vulnerable to various issues=]%0a* [[Lemon.Packages]] . . . July 30, 2022, at 07:52 PM by [[~mkf]]: [==]%0a* [[Netizen.Ellisisland]] . . . July 27, 2022, at 07:05 PM by [[~jrmu]]: [==]%0a* [[Ircnow.Newdeal]] . . . July 27, 2022, at 06:55 PM by [[~jrmu]]: [==]%0a* [[Ircnow.Daughtersofliberty]] . . . July 27, 2022, at 06:45 PM by [[~jrmu]]: [==]%0a* [[Ircnow.Womenstem]] . . . July 21, 2022, at 05:59 PM by [[~jrmu]]: [==]%0a* [[Eggdrop.RC]] . . . July 20, 2022, at 06:55 PM by [[~baytuch]]: [==]%0a* [[Opensmtpd.Troubleshoot]] . . . July 20, 2022, at 03:58 PM by [[~jlj]]: [=Added notes about how I resolved the first two errors, on nastycode=]%0a* [[Eggdrop.Nickserv]] . . . July 19, 2022, at 10:05 AM by [[~baytuch]]: [==]%0a* [[Chroot.Intro]] . . . July 18, 2022, at 04:23 PM by [[~mkf]]: [==]%0a* [[Ircnow.Media]] . . . July 15, 2022, at 05:54 AM by [[~jrmu]]: [==]%0a* [[Iked.Linuxstrongswan]] . . . July 03, 2022, at 11:29 PM by [[~jrmu]]: [==]%0a* [[Acme-client.AutoRenew]] . . . July 03, 2022, at 11:50 AM by [[~mkf]]: [==]%0a* [[Openbsd.Apmd]] . . . July 03, 2022, at 11:36 AM by [[~mkf]]: [==]%0a* [[Opensmtpd.Test]] . . . July 03, 2022, at 11:13 AM by [[~mkf]]: [==]%0a* [[Ircnow.Roadmap2022]] . . . July 03, 2022, at 11:04 AM by [[~mkf]]: [==]%0a* [[Iked.Android]] . . . July 01, 2022, at 12:14 AM by [[~jrmu]]: [==]%0a* [[Vpn.Myipaddress]] . . . June 30, 2022, at 09:51 PM by [[~jrmu]]: [==]%0a* [[Olympics.Games]] . . . June 27, 2022, at 10:42 PM by [[~jrmu]]: [==]%0a* [[Iked.Configure]] . . . June 25, 2022, at 02:28 PM by [[~jrmu]]: [==]%0a* [[Unbound.Blacklists]] . . . June 25, 2022, at 06:02 AM by [[~jrmu]]: [==]%0a* [[Iked.Linux]] . . . June 23, 2022, at 07:10 AM by [[~jrmu]]: [==]%0a* [[Vpn.Vpn]] . . . June 23, 2022, at 06:42 AM by [[~jrmu]]: [==]%0a* [[Ircnow.Nsf]] . . . June 20, 2022, at 05:05 PM by [[~jrmu]]: [==]%0a* [[Debate.Debate]] . . . June 19, 2022, at 04:12 PM by [[~jrmu]]: [==]%0a* [[Ircnow.Metrics]] . . . June 19, 2022, at 04:12 PM by [[~jrmu]]: [==]%0a* [[Nsd.Masterslave]] . . . June 19, 2022, at 06:34 AM by [[~jrmu]]: [==]%0a* [[Dns.Overview]] . . . June 19, 2022, at 05:45 AM by [[~jrmu]]: [==]%0a* [[Dns.Records]] . . . June 19, 2022, at 05:44 AM by [[~jrmu]]: [==]%0a* [[Syspatch.Syspatch]] . . . June 17, 2022, at 06:24 AM by [[~jrmu]]: [==]%0a* [[Tmux.Config]] . . . June 14, 2022, at 12:34 AM by [[~jrmu]]: [==]%0a* [[Vmm.Alpine]] . . . June 13, 2022, at 05:42 PM by [[~fossdev]]: [==]%0a* [[Team.Announce]] . . . June 13, 2022, at 03:52 PM by [[~jrmu]]: [==]%0a* [[Vmm.Arch]] . . . June 12, 2022, at 04:11 PM by [[~g1n]]: [=Added article about Arch Linux setup on VMM=]%0a* [[Znc.Patch]] . . . June 12, 2022, at 12:48 AM by [[~jrmu]]: [==]%0a* [[Unveil.Intro]] . . . June 12, 2022, at 12:40 AM by [[~jrmu]]: [==]%0a* [[Pledge.Intro]] . . . June 12, 2022, at 12:39 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Pkg]] . . . June 12, 2022, at 12:32 AM by [[~jrmu]]: [==]%0a* [[Doas.Configure]] . . . June 09, 2022, at 07:56 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Intro]] . . . June 09, 2022, at 07:53 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Bsdrd]] . . . June 09, 2022, at 07:17 AM by [[~jrmu]]: [==]%0a* [[Vnc.Vnc]] . . . June 08, 2022, at 04:04 PM by [[~miniontoby]]: [=Added RealVNC Viewer to the list (might need some more extra stuff, but yeah its fine)=]%0a* [[Unix101.Unix101]] . . . June 07, 2022, at 03:12 PM by [[~jrmu]]: [==]%0a* [[Openbsd.Sysupgrade71]] . . . June 05, 2022, at 11:49 PM by [[~jrmu]]: [==]%0a* [[Openbsd.Growfs]] . . . June 01, 2022, at 12:34 AM by [[~jrmu]]: [==]%0a* [[Team.Welcome]] . . . May 31, 2022, at 10:20 PM by [[~jrmu]]: [==]%0a* [[Hostnameif.Static-v2]] . . . May 23, 2022, at 06:29 AM by [[~theguest]]: [==]%0a* [[Hostnameif.Static]] . . . May 23, 2022, at 05:01 AM by [[~theguest]]: [==]%0a* [[Ircnow.Team]] . . . May 12, 2022, at 03:44 PM by [[~jrmu]]: [==]%0a* [[Grape.Minetest]] . . . May 10, 2022, at 10:48 AM by [[~baytuch]]: [==]%0a* [[Irc.Emoji]] . . . May 10, 2022, at 10:23 AM by [[~baytuch]]: [==]%0a* [[Openbsd.Nsd]] . . . May 10, 2022, at 12:33 AM by [[~jrmu]]: [==]%0a* [[Opsofliberty.Bootcamp]] . . . May 09, 2022, at 08:38 AM by [[~mkf]]: [==]%0a* [[Openbsd.Ports]] . . . May 09, 2022, at 05:54 AM by [[~mkf]]: [==]%0a* [[Openbsd.Rcctl]] . . . May 09, 2022, at 05:53 AM by [[~mkf]]: [==]%0a* [[Ngircd.Ssl]] . . . May 08, 2022, at 03:30 PM by [[~miniontoby]]: [=fixed the text=]%0a* [[Openbsd.Upgrade71]] . . . May 03, 2022, at 06:36 AM by [[~jrmu]]: [==]%0a* [[Codeforce.Training]] . . . May 03, 2022, at 03:02 AM by [[~jrmu]]: [==]%0a* [[Civics.Intro]] . . . May 03, 2022, at 01:06 AM by [[~jrmu]]: [==]%0a* [[OpenBSD.EdgeRouter-Lite]] . . . April 28, 2022, at 02:50 PM by [[~pufferf]]: [==]%0a* [[Math.Reading]] . . . April 27, 2022, at 08:23 PM by [[~jrmu]]: [==]%0a* [[Openbsd.Install71]] . . . April 24, 2022, at 09:55 PM by [[~jrmu]]: [==]%0a* [[Openbsd.Botnow]] . . . April 24, 2022, at 06:14 AM by [[~jrmu]]: [==]%0a* [[Buyvm.Ipv6]] . . . April 24, 2022, at 06:10 AM by [[~jrmu]]: [==]%0a* [[Eggdrop.Rss]] . . . April 23, 2022, at 04:20 PM by [[~jrmu]]: [==]%0a* [[Team.Testing]] . . . April 20, 2022, at 09:45 PM by [[~jrmu]]: [==]%0a* [[Dns.Registrars]] . . . April 20, 2022, at 09:30 PM by [[~jrmu]]: [==]%0a* [[Hosting.Providers]] . . . April 20, 2022, at 08:52 PM by [[~jrmu]]: [==]%0a* [[Openbsd.Gopher]] . . . April 20, 2022, at 08:29 PM by [[~jrmu]]: [==]%0a* [[Openbsd.Adduser]] . . . April 20, 2022, at 08:07 PM by [[~jrmu]]: [==]%0a* [[Signify.Verify]] . . . April 20, 2022, at 06:24 PM by [[~jrmu]]: [==]%0a* [[Almanack.Route]] . . . April 20, 2022, at 06:23 AM by [[~jrmu]]: [==]%0a* [[Ntpd.Configure]] . . . April 20, 2022, at 06:17 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Ntpd]] . . . April 20, 2022, at 06:16 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Vmmlinux]] . . . April 20, 2022, at 05:33 AM by [[~jrmu]]: [==]%0a* [[Vmm.Linux]] . . . April 20, 2022, at 05:33 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Iked]] . . . April 20, 2022, at 05:16 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Team]] . . . April 20, 2022, at 04:54 AM by [[~jrmu]]: [==]%0a* [[Ircnow.Networks]] . . . April 19, 2022, at 04:22 PM by [[~jrmu]]: [==]%0a* [[Openbsd.Announce]] . . . April 19, 2022, at 04:14 PM by [[~jrmu]]: [==]%0a* [[Ircnow.Ally]] . . . April 19, 2022, at 04:11 PM by [[~jrmu]]: [==]%0a* [[Openhttpd.Chroot]] . . . April 19, 2022, at 04:05 PM by [[~jrmu]]: [==]%0a* [[Openbsd.Install70]] . . . April 19, 2022, at 06:52 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Upgrade70]] . . . April 19, 2022, at 06:49 AM by [[~jrmu]]: [==]%0a* [[CodeForce.Bootcamp]] . . . April 19, 2022, at 06:29 AM by [[~jrmu]]: [==]%0a* [[Perl101.Perl101]] . . . April 19, 2022, at 06:15 AM by [[~jrmu]]: [==]%0a* [[Vmm.Vmm]] . . . April 15, 2022, at 12:20 PM by [[~Naglfar]]: [=Update: report from PiRATA=]%0a* [[Ngircd.Link]] . . . April 07, 2022, at 06:52 AM by [[~jrmu]]: [==]%0a* [[Minutemin.Minutemin]] . . . April 06, 2022, at 02:55 AM by [[~jrmu]]: [==]%0a* [[Openhttpd.CGI]] . . . April 05, 2022, at 04:22 PM by [[~gtlsgamr]]: [==]%0a* [[Openbsd.Censord]] . . . April 05, 2022, at 06:16 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Hopm]] . . . April 05, 2022, at 06:09 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Dns]] . . . April 05, 2022, at 05:24 AM by [[~jrmu]]: [==]%0a* [[Debate.Zncflaws]] . . . April 05, 2022, at 05:18 AM by [[~jrmu]]: [==]%0a* [[Debate.Debiandanger]] . . . April 04, 2022, at 04:30 AM by [[~jrmu]]: [==]%0a* [[Openhttpd.Tls]] . . . April 04, 2022, at 04:25 AM by [[~jrmu]]: [==]%0a* [[Openhttpd.Website]] . . . April 03, 2022, at 11:03 PM by [[~jrmu]]: [==]%0a* [[Soju.Guide]] . . . April 02, 2022, at 03:46 PM by [[~Yonle]]: [==]%0a* [[Nitter.Install]] . . . April 02, 2022, at 01:08 AM by [[~fallback]]: [=first nitter install page=]%0a* [[Debiankaios.Bio]] . . . April 01, 2022, at 05:10 PM by [[~debiankaios]]: [==]%0a* [[Openbsd.Psybnc]] . . . March 30, 2022, at 09:56 PM by [[~jrmu]]: [==]%0a* [[Sshd.Disablepassword]] . . . March 30, 2022, at 08:27 PM by [[~xfnw]]: [=undo accidental revert=]%0a* [[Tor.Irc]] . . . March 30, 2022, at 12:40 PM by [[~m16]]: [==]%0a* [[Chess.Reading]] . . . March 29, 2022, at 10:02 PM by [[~jrmu]]: [==]%0a* [[Linux.Reading]] . . . March 29, 2022, at 03:31 PM by [[~jrmu]]: [==]%0a* [[Unix.Reading]] . . . March 28, 2022, at 03:24 PM by [[~jrmu]]: [==]%0a* [[Irc.Services]] . . . March 25, 2022, at 04:29 AM by [[~jrmu]]: [==]%0a* [[Syslogd.Configure]] . . . March 25, 2022, at 04:07 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Ddos]] . . . March 24, 2022, at 04:22 PM by [[~jrmu]]: [==]%0a* [[Ddos.Intro]] . . . March 24, 2022, at 04:22 PM by [[~jrmu]]: [==]%0a* [[Bouncer.ZNC]] . . . March 19, 2022, at 07:31 AM by [[~fallback]]: [==]%0a* [[ISCABBS.DownloadingAndInstalling]] . . . March 15, 2022, at 10:42 PM by [[~Mandarax]]: [==]%0a* [[ISCABBS.ISCABBS]] . . . March 15, 2022, at 09:24 PM by [[~Mandarax]]: [==]%0a* [[Unix.History]] . . . March 14, 2022, at 06:07 PM by [[~jrmu]]: [==]%0a* [[Unix.Exhibit]] . . . March 13, 2022, at 11:37 PM by [[~jrmu]]: [==]%0a* [[Debate.Dogfooding]] . . . March 10, 2022, at 05:14 AM by [[~jrmu]]: [==]%0a* [[Irc.Easy]] . . . March 05, 2022, at 08:56 PM by [[~jrmu]]: [==]%0a* [[Doxing.Defense]] . . . March 05, 2022, at 08:54 PM by [[~jrmu]]: [==]%0a* [[Mlmmj-archivist.Install]] . . . March 03, 2022, at 05:26 AM by [[~error]]: [==]%0a* [[Openbsd.IRCBridge]] . . . February 28, 2022, at 02:59 AM by [[~suzerain]]: [==]%0a* [[Unix101.Vi]] . . . February 27, 2022, at 08:16 PM by [[~jrmu]]: [==]%0a* [[Vi.Intro]] . . . February 27, 2022, at 04:16 PM by [[~Limits]]: [=Add Introduction to Vi=]%0a* [[Irc201.Irc201]] . . . February 27, 2022, at 04:21 AM by [[~suzerain]]: [==]%0a* [[9.Ideas]] . . . February 23, 2022, at 05:19 PM by [[~mkf]]: [==]%0a* [[Main.WikiSandbox]] . . . February 22, 2022, at 11:05 PM by [[~mkf]]: [==]%0a* [[Openhttpd.Perl]] . . . February 21, 2022, at 07:18 AM by [[~Naglfar]]: [==]%0a* [[Openbsd.Wesnothd]] . . . February 21, 2022, at 06:28 AM by [[~mkf]]: [=Wesnothd=]%0a* [[9.Audio]] . . . February 20, 2022, at 08:07 PM by [[~jrmu]]: [==]%0a* [[Cloud9p.Roadmap]] . . . February 20, 2022, at 06:54 PM by [[~xfnw]]: [==]%0a* [[Openbsd.Xonotic]] . . . February 20, 2022, at 07:43 AM by [[~mkf]]: [=A xonotic server has apperad! pt.2=]%0a* [[Bouncer.Irssi]] . . . February 16, 2022, at 06:26 PM by [[~izzyb]]: [=clarified wording in example=]%0a* [[PuTTY.PuTTYgen]] . . . February 16, 2022, at 05:24 AM by [[~jrmu]]: [==]%0a* [[Rcd.Configure]] . . . February 15, 2022, at 04:46 PM by [[~xfnw]]: [=fix title formatting=]%0a* [[Debate.Ircnowd]] . . . February 14, 2022, at 06:24 PM by [[~jrmu]]: [==]%0a* [[Stopm.Stopm]] . . . February 14, 2022, at 06:16 PM by [[~jrmu]]: [==]%0a* [[Police.Fingerprints]] . . . February 12, 2022, at 02:09 PM by [[~xfnw]]: [=ip addresses should be sorted with sort -V=]%0a* [[Openbsd.Police]] . . . February 10, 2022, at 07:36 PM by [[~jrmu]]: [==]%0a* [[Dns.Dns]] . . . February 10, 2022, at 07:39 AM by [[~nixdork]]: [=Fix typo=]%0a* [[Dns.BindResolver]] . . . February 10, 2022, at 07:30 AM by [[~nixdork]]: [=First draft of bind resolver howto=]%0a* [[Botnow.SqliteViews]] . . . February 10, 2022, at 02:00 AM by [[~xfnw]]: [==]%0a* [[Relayd.TLSMulti]] . . . February 08, 2022, at 06:45 AM by [[~Naglfar]]: [=Fix listening port for https=]%0a* [[Relayd.Acceleration]] . . . February 08, 2022, at 06:27 AM by [[~Naglfar]]: [=Fix: https forwarding port=]%0a* [[AncientWisdom.Bio]] . . . February 07, 2022, at 01:18 PM by [[~AncientWisdom]]: [==]%0a* [[Minutemin.Questions]] . . . February 05, 2022, at 09:16 AM by [[~jrmu]]: [==]%0a* [[Minutemin.Server]] . . . February 05, 2022, at 08:14 AM by [[~jrmu]]: [==]%0a* [[Vmm.SlackwareIso]] . . . February 03, 2022, at 10:53 PM by [[~Naglfar]]: [=Slackware 15.0 x86 stable is released=]%0a* [[Vmctl.Usage]] . . . February 03, 2022, at 06:24 PM by [[~miniontoby]]: [=fixed attachment=]%0a* [[Duplicity.Usage]] . . . February 02, 2022, at 10:31 AM by [[~jrmu]]: [==]%0a* [[Openssl.Encryptfile]] . . . February 02, 2022, at 09:29 AM by [[~jrmu]]: [==]%0a* [[Bots.Basicbot]] . . . January 31, 2022, at 08:54 PM by [[~izzyb]]: [==]%0a* [[Dovecot.Install]] . . . January 29, 2022, at 09:35 PM by [[~forero]]: [=comment out=]%0a* [[Openrsync.Usage]] . . . January 29, 2022, at 09:04 AM by [[~Naglfar]]: [=update from rsync to openrsync=]%0a* [[Openbsd.Tcpip]] . . . January 24, 2022, at 05:45 PM by [[~jrmu]]: [==]%0a* [[Synclient.Configure]] . . . January 24, 2022, at 06:02 AM by [[~jrmu]]: [==]%0a* [[Crontab.Edit]] . . . January 23, 2022, at 05:46 PM by [[~mkf]]: [==]%0a* [[9.Install]] . . . January 22, 2022, at 06:57 AM by [[~mkf]]: [==]%0a* [[Asterisk.Install]] . . . January 19, 2022, at 05:34 AM by [[~jrmu]]: [==]%0a* [[9.Rcpu]] . . . January 17, 2022, at 10:19 PM by [[~jrmu]]: [==]%0a* [[9.9p]] . . . January 17, 2022, at 08:47 PM by [[~mkf]]: [==]%0a* [[9.Ndb]] . . . January 16, 2022, at 06:46 PM by [[~mkf]]: [==]%0a* [[Openbsd.U9fs]] . . . January 16, 2022, at 06:23 PM by [[~mkf]]: [==]%0a* [[Dns.FQDN]] . . . January 15, 2022, at 10:16 PM by [[~jrmu]]: [==]%0a* [[Pgp.Create]] . . . January 14, 2022, at 09:14 AM by [[~baytuch]]: [==]%0a* [[Nsd.DNSSec]] . . . January 14, 2022, at 02:53 AM by [[~pyr3x]]: [==]%0a* [[Openbsd.Locale]] . . . January 12, 2022, at 01:23 PM by [[~baytuch]]: [==]%0a* [[Openbsd.Openbsd]] . . . January 12, 2022, at 01:19 PM by [[~baytuch]]: [==]%0a* [[Ksh.Autocomplete]] . . . January 11, 2022, at 01:44 PM by [[~miniontoby]]: [=updated url=]%0a* [[Gpg.Verify]] . . . January 08, 2022, at 09:48 PM by [[~Naglfar]]: [=Add description=]%0a* [[Mlmmj.Archive]] . . . January 06, 2022, at 10:52 PM by [[~Hawk]]: [==]%0a* [[9.Hostowner]] . . . January 06, 2022, at 11:29 AM by [[~mkf]]: [==]%0a* [[Ircnow.Dogfood]] . . . January 06, 2022, at 08:48 AM by [[~jrmu]]: [==]%0a* [[9.Authsrv]] . . . January 05, 2022, at 04:59 AM by [[~mkf]]: [=hmm=]%0a* [[9.Chording]] . . . January 03, 2022, at 02:40 PM by [[~jrmu]]: [==]%0a* [[Ircnow.Status]] . . . January 03, 2022, at 06:06 AM by [[~jrmu]]: [==]%0a* [[Openbsd.BBB]] . . . January 03, 2022, at 12:06 AM by [[~jrmu]]: [==]%0a* [[Got.Server]] . . . January 02, 2022, at 05:42 PM by [[~jrmu]]: [==]%0a* [[Census.Census]] . . . January 02, 2022, at 11:27 AM by [[~jrmu]]: [==]%0a* [[Bncnow.Bncnow]] . . . January 02, 2022, at 11:18 AM by [[~jrmu]]: [==]%0a* [[Ircnow.Projects]] . . . January 02, 2022, at 11:09 AM by [[~jrmu]]: [==]%0a* [[Ircfs.Intro]] . . . January 02, 2022, at 10:49 AM by [[~jrmu]]: [==]%0a* [[Ircnowd.Ircnowd]] . . . January 02, 2022, at 06:32 AM by [[~jrmu]]: [==]%0a* [[Marketing.Marketing]] . . . January 02, 2022, at 06:20 AM by [[~jrmu]]: [==]%0a* [[Ircnow.Sonsofliberty]] . . . January 02, 2022, at 06:06 AM by [[~jrmu]]: [==]%0a* [[Pkgadd.CheckUpdates]] . . . January 01, 2022, at 04:29 AM by [[~pyr3x]]: [==]%0a* [[Ircnow.Roadmap2021]] . . . December 30, 2021, at 06:31 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Sftp]] . . . December 30, 2021, at 06:01 AM by [[~jrmu]]: [==]%0a* [[Sftp.Chroot]] . . . December 30, 2021, at 06:01 AM by [[~jrmu]]: [==]%0a* [[Ircnow.Status2022]] . . . December 30, 2021, at 05:35 AM by [[~jrmu]]: [==]%0a* [[Eggdrop.UTF8]] . . . December 28, 2021, at 08:21 PM by [[~jrmu]]: [==]%0a* [[Openbsd.Uim]] . . . December 26, 2021, at 01:45 AM by [[~jrmu]]: [==]%0a* [[Sshwifty.Install]] . . . December 23, 2021, at 02:49 PM by [[~miniontoby]]: [=created=]%0a* [[Nsd.Zone]] . . . December 23, 2021, at 10:33 AM by [[~jrmu]]: [==]%0a* [[Openhttpd.Hosting]] . . . December 23, 2021, at 03:06 AM by [[~jrmu]]: [==]%0a* [[OpenSSH.RSAkeys]] . . . December 22, 2021, at 03:18 PM by [[~miniontoby]]: [==]%0a* [[Openbsd.Wifi]] . . . December 22, 2021, at 02:59 PM by [[~jrmu]]: [==]%0a* [[Openbsd.Recordaudio]] . . . December 22, 2021, at 01:24 PM by [[~jrmu]]: [==]%0a* [[9.9]] . . . December 22, 2021, at 11:30 AM by [[~xfnw]]: [=fix some grammatical errors=]%0a* [[Parec.Record]] . . . December 22, 2021, at 07:02 AM by [[~jrmu]]: [==]%0a* [[Sox.Concat]] . . . December 22, 2021, at 07:01 AM by [[~jrmu]]: [==]%0a* [[Ffmpeg.Recordscreen]] . . . December 22, 2021, at 07:00 AM by [[~jrmu]]: [==]%0a* [[JuiceSSH.Connect]] . . . December 20, 2021, at 01:03 PM by [[~jrmu]]: [==]%0a* [[Marketing.Memes]] . . . December 20, 2021, at 12:55 PM by [[~jrmu]]: [==]%0a* [[9.Independent]] . . . December 20, 2021, at 12:47 PM by [[~jrmu]]: [==]%0a* [[MacScreenSharing.Connect]] . . . December 20, 2021, at 11:57 AM by [[~jrmu]]: [==]%0a* [[9.Partdisk]] . . . December 20, 2021, at 11:39 AM by [[~jrmu]]: [==]%0a* [[Got.Usage]] . . . December 17, 2021, at 04:44 PM by [[~jrmu]]: [==]%0a* [[Irc.Federation]] . . . December 17, 2021, at 02:03 PM by [[~jrmu]]: [==]%0a* [[Irc.Chanop]] . . . December 14, 2021, at 04:58 AM by [[~mkf]]: [==]%0a* [[9.Todo]] . . . December 03, 2021, at 07:52 PM by [[~mkf]]: [==]%0a* [[Pylink.Chroot]] . . . December 02, 2021, at 02:03 PM by [[~jrmu]]: [==]%0a* [[Pylink.Install]] . . . December 02, 2021, at 02:02 PM by [[~jrmu]]: [==]%0a* [[Jrmu.Marriage]] . . . December 02, 2021, at 06:09 AM by [[~jrmu]]: [==]%0a* [[Hosting.Hosting]] . . . December 01, 2021, at 02:01 PM by [[~jrmu]]: [==]%0a* [[Mc.Usage]] . . . November 29, 2021, at 07:53 PM by [[~mkf]]: [==]%0a* [[PuTTY.Connect]] . . . November 29, 2021, at 12:13 PM by [[~jrmu]]: [==]%0a* [[Email.Email]] . . . November 29, 2021, at 04:19 AM by [[~mkf]]: [==]%0a* [[Texlive.Sinhala]] . . . November 28, 2021, at 06:35 AM by [[~jrmu]]: [==]%0a* [[MailWindows.Connect]] . . . November 27, 2021, at 03:12 PM by [[~jrmu]]: [==]%0a* [[Gajim.Biboumi]] . . . November 27, 2021, at 01:02 PM by [[~jrmu]]: [==]%0a* [[Xmpp.Xmpp]] . . . November 27, 2021, at 12:33 PM by [[~jrmu]]: [==]%0a* [[Mcabber.Connect]] . . . November 26, 2021, at 01:38 PM by [[~jrmu]]: [==]%0a* [[ChatSecure.Connect]] . . . November 26, 2021, at 11:36 AM by [[~jrmu]]: [==]%0a* [[9.9pfs]] . . . November 24, 2021, at 02:00 PM by [[~mkf]]: [==]%0a* [[Vmm.DebianInstall]] . . . November 24, 2021, at 11:44 AM by [[~nicoz]]: [==]%0a* [[Siskin.Connect]] . . . November 23, 2021, at 04:38 PM by [[~jrmu]]: [==]%0a* [[Dino.Connect]] . . . November 23, 2021, at 02:10 PM by [[~mkf]]: [==]%0a* [[Monal.Connect]] . . . November 23, 2021, at 10:32 AM by [[~jrmu]]: [==]%0a* [[Xabber.Connect]] . . . November 23, 2021, at 10:20 AM by [[~jrmu]]: [==]%0a* [[DNS.DMARC]] . . . November 22, 2021, at 10:52 PM by [[~Hawk]]: [==]%0a* [[StorkIM.Connect]] . . . November 21, 2021, at 05:03 AM by [[~jrmu]]: [==]%0a* [[Conversations.Connect]] . . . November 20, 2021, at 05:37 PM by [[~jrmu]]: [==]%0a* [[Yaxim.Connect]] . . . November 20, 2021, at 05:09 PM by [[~jrmu]]: [==]%0a* [[Adium.Connect]] . . . November 20, 2021, at 07:32 AM by [[~jrmu]]: [==]%0a* [[Vmm.AlmaLinux]] . . . November 20, 2021, at 06:47 AM by [[~dodocrypto]]: [==]%0a* [[Vmm.DebianIso]] . . . November 19, 2021, at 09:35 PM by [[~nicoz]]: [==]%0a* [[Psi.Connect]] . . . November 17, 2021, at 03:23 PM by [[~jrmu]]: [==]%0a* [[Pidgin.Connect]] . . . November 17, 2021, at 10:18 AM by [[~jrmu]]: [==]%0a* [[Gajim.Connect]] . . . November 17, 2021, at 08:01 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Training]] . . . November 16, 2021, at 03:30 PM by [[~Hawk]]: [==]%0a* [[Opera.Connect]] . . . November 16, 2021, at 12:12 AM by [[~wiz]]: [==]%0a* [[0dev.0dev]] . . . November 12, 2021, at 03:00 AM by [[~dodocrypto]]: [==]%0a* [[Vmm.RockyLinux]] . . . November 11, 2021, at 10:51 AM by [[~dodocrypto]]: [==]%0a* [[Opensmtpd.Openrelay]] . . . November 11, 2021, at 10:37 AM by [[~mkf]]: [==]%0a* [[Sandbox.0dev]] . . . November 11, 2021, at 01:45 AM by [[~dodocrypto]]: [==]%0a* [[Nsd.Configure]] . . . November 10, 2021, at 11:58 AM by [[~Hawk]]: [==]%0a* [[Got.Mirror]] . . . November 07, 2021, at 05:22 PM by [[~jrmu]]: [==]%0a* [[Vpn.OpenIKED]] . . . November 07, 2021, at 03:45 PM by [[~gloNO]]: [==]%0a* [[Openbsd.Got]] . . . November 07, 2021, at 03:16 PM by [[~jrmu]]: [==]%0a* [[Ircnow.Opsofliberty]] . . . November 06, 2021, at 05:15 PM by [[~jrmu]]: [==]%0a* [[Emacs.Emacs]] . . . November 06, 2021, at 04:39 PM by [[~LohanG]]: [==]%0a* [[ZNC.Support]] . . . November 06, 2021, at 03:53 PM by [[~LohanG]]: [=added libera=]%0a* [[Vmm.Plan9]] . . . November 05, 2021, at 09:31 PM by [[~mkf]]: [=???=]%0a* [[9.Stone]] . . . November 04, 2021, at 04:09 PM by [[~meeekeeef]]: [==]%0a* [[9.Zuke]] . . . November 04, 2021, at 04:01 PM by [[~meeekeeef]]: [==]%0a* [[Openbsd.Drawtermssh]] . . . November 04, 2021, at 03:54 PM by [[~meeekeeef]]: [=ssh bad >:[=]%0a* [[Netcat.Http]] . . . November 03, 2021, at 02:30 PM by [[~jrmu]]: [==]%0a* [[Telnet.Http]] . . . November 03, 2021, at 02:18 PM by [[~jrmu]]: [==]%0a* [[Znc.Relayd]] . . . November 03, 2021, at 10:18 AM by [[~jrmu]]: [==]%0a* [[ZNC.Admin]] . . . November 02, 2021, at 05:44 PM by [[~jrmu]]: [==]%0a* [[Znc.Debug]] . . . November 02, 2021, at 03:23 PM by [[~jrmu]]: [==]%0a* [[Znc.Usage]] . . . November 02, 2021, at 03:09 PM by [[~jrmu]]: [==]%0a* [[Ambassador.Markets]] . . . November 02, 2021, at 01:29 PM by [[~jrmu]]: [==]%0a* [[Almanack.Rewrite]] . . . October 31, 2021, at 10:30 PM by [[~hydragyrum]]: [==]%0a* [[9.Sysupdate]] . . . October 31, 2021, at 10:21 PM by [[~meeekeeef]]: [==]%0a* [[Debian.Debian]] . . . October 31, 2021, at 12:34 PM by [[~monaco]]: [==]%0a* [[Ircnow.Victorycpus]] . . . October 30, 2021, at 08:17 AM by [[~jrmu]]: [==]%0a* [[Gnus.Connect]] . . . October 30, 2021, at 01:32 AM by [[~hydragyrum]]: [==]%0a* [[Ircnow.Settler]] . . . October 29, 2021, at 04:03 PM by [[~jrmu]]: [==]%0a* [[Debian.Nginxphpfpm]] . . . October 29, 2021, at 12:26 PM by [[~monaco]]: [==]%0a* [[Debian.Nginx]] . . . October 29, 2021, at 12:18 PM by [[~monaco]]: [==]%0a* [[Vmm.Homerouter]] . . . October 26, 2021, at 05:08 PM by [[~jrmu]]: [==]%0a* [[9.Netcat]] . . . October 25, 2021, at 03:40 PM by [[~jrmu]]: [==]%0a* [[9.Plan9ini]] . . . October 24, 2021, at 04:30 PM by [[~jrmu]]: [==]%0a* [[Iked.Newconfig]] . . . October 24, 2021, at 03:49 PM by [[~tool]]: [==]%0a* [[Lua.Minetest-1]] . . . October 24, 2021, at 10:30 AM by [[~debiankaios]]: [==]%0a* [[9.Links]] . . . October 24, 2021, at 06:29 AM by [[~mkf]]: [==]%0a* [[9.Keybindings]] . . . October 24, 2021, at 06:15 AM by [[~mkf]]: [=heheheheheh=]%0a* [[Xdefaults.Configure]] . . . October 23, 2021, at 02:40 PM by [[~jrmu]]: [==]%0a* [[TigerVNC.SSH]] . . . October 23, 2021, at 11:56 AM by [[~Hawk]]: [==]%0a* [[Rio.Customize]] . . . October 22, 2021, at 09:22 AM by [[~jrmu]]: [==]%0a* [[9.Ssh]] . . . October 22, 2021, at 12:54 AM by [[~jrmu]]: [==]%0a* [[Vmm.Devuan4Iso]] . . . October 21, 2021, at 04:29 PM by [[~debiankaios]]: [=changed beowulf_3.1.1 to chimaera_4.0.0=]%0a* [[9.101]] . . . October 20, 2021, at 04:53 PM by [[~jrmu]]: [==]%0a* [[Fvwm.Configure]] . . . October 18, 2021, at 10:20 AM by [[~jrmu]]: [==]%0a* [[KISSmo.KISSmo]] . . . October 18, 2021, at 09:58 AM by [[~monaco]]: [==]%0a* [[KISSmo.Download]] . . . October 18, 2021, at 09:53 AM by [[~monaco]]: [==]%0a* [[KISSmo.About]] . . . October 18, 2021, at 09:52 AM by [[~monaco]]: [==]%0a* [[KISSmo.Install]] . . . October 18, 2021, at 09:44 AM by [[~monaco]]: [==]%0a* [[Cvs.Repo]] . . . October 17, 2021, at 08:32 AM by [[~jrmu]]: [==]%0a* [[Cvs.Anoncvs]] . . . October 17, 2021, at 04:00 AM by [[~jrmu]]: [==]%0a* [[Cvs.Commit]] . . . October 17, 2021, at 03:58 AM by [[~jrmu]]: [==]%0a* [[Cvs.Cvsweb]] . . . October 17, 2021, at 03:28 AM by [[~jrmu]]: [==]%0a* [[9.Cvsfs]] . . . October 15, 2021, at 12:58 PM by [[~mkf]]: [==]%0a* [[Openbsd.Sysupgrade70]] . . . October 15, 2021, at 11:02 AM by [[~mkf]]: [=humans are easily confused.=]%0a* [[Openbsd.Ilines]] . . . October 15, 2021, at 02:36 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Pmwiki]] . . . October 14, 2021, at 02:14 PM by [[~miniontoby]]: [=added credits =]%0a* [[Vmm.Devuan-ISO]] . . . October 14, 2021, at 09:50 AM by [[~siva]]: [==]%0a* [[Vmm.Devuan-Simple]] . . . October 14, 2021, at 09:48 AM by [[~siva]]: [=Tutorial Created=]%0a* [[Cvs.Intro]] . . . October 13, 2021, at 03:49 PM by [[~jrmu]]: [==]%0a* [[Synapse.Install]] . . . October 12, 2021, at 02:49 PM by [[~miniontoby]]: [=Created=]%0a* [[Ircnow.Oper]] . . . October 12, 2021, at 03:02 AM by [[~jrmu]]: [==]%0a* [[Terms.Privacy]] . . . October 11, 2021, at 11:48 AM by [[~jrmu]]: [==]%0a* [[Ircnow.Diversity]] . . . October 09, 2021, at 02:56 AM by [[~jrmu]]: [==]%0a* [[Ircnow.Linux]] . . . October 08, 2021, at 04:51 AM by [[~jrmu]]: [==]%0a* [[OpenBSD.ResetPassword]] . . . October 07, 2021, at 03:56 AM by [[~jrmu]]: [==]%0a* [[Terms.Vps]] . . . October 06, 2021, at 12:30 AM by [[~jrmu]]: [==]%0a* [[9.JSDrawterm]] . . . September 30, 2021, at 06:06 PM by [[~jrmu]]: [==]%0a* [[9.Fonts]] . . . September 28, 2021, at 05:13 PM by [[~jrmu]]: [==]%0a* [[Openbsd.Install69]] . . . September 27, 2021, at 05:59 PM by [[~jrmu]]: [==]%0a* [[Cvs.Guide]] . . . September 26, 2021, at 02:28 PM by [[~Miniontoby]]: [==]%0a* [[Openbsd.PFStable]] . . . September 24, 2021, at 03:28 PM by [[~miniontoby]]: [==]%0a* [[License.IrcnowV2]] . . . September 21, 2021, at 03:53 AM by [[~jrmu]]: [==]%0a* [[Dhcpd.Configure]] . . . September 15, 2021, at 04:02 PM by [[~jrmu]]: [==]%0a* [[Vmm.Router]] . . . September 14, 2021, at 12:11 PM by [[~jrmu]]: [==]%0a* [[Weechat.Relay]] . . . September 11, 2021, at 05:46 PM by [[~mkf]]: [==]%0a* [[Gry.Bio]] . . . September 11, 2021, at 02:49 AM by [[~jrmu]]: [==]%0a* [[Hopm.Telnet]] . . . September 10, 2021, at 06:13 AM by [[~mkf]]: [==]%0a* [[Wraith.Chroot]] . . . September 10, 2021, at 06:11 AM by [[~mkf]]: [==]%0a* [[Mutt.Connect]] . . . September 10, 2021, at 06:01 AM by [[~mkf]]: [=6.8 -> 6.9=]%0a* [[DNS.DKIM]] . . . September 09, 2021, at 04:00 PM by [[~jrmu]]: [==]%0a* [[ZNC.Skins]] . . . September 06, 2021, at 07:58 AM by [[~mkf]]: [="Huh, pmwiki has a bug." no numbered list if use monospaced text. :(=]%0a* [[Seamonkey.Connect]] . . . August 28, 2021, at 01:05 PM by [[~mkf]]: [==]%0a* [[Debate.Wikistyle]] . . . August 27, 2021, at 03:29 PM by [[~mkf]]: [==]%0a* [[Email.EmailAndroidEmailApp]] . . . August 27, 2021, at 02:37 PM by [[~mkf]]: [==]%0a* [[Tmux.Shortcuts]] . . . August 27, 2021, at 12:56 PM by [[~mkf]]: [==]%0a* [[Vmm.Haiku]] . . . August 27, 2021, at 12:53 PM by [[~mkf]]: [==]%0a* [[Openbsd.Mailopenproxy]] . . . August 25, 2021, at 08:19 PM by [[~mkf]]: [==]%0a* [[Openbsd.Two-FactorAuth]] . . . August 23, 2021, at 07:39 PM by [[~mkf]]: [=login.db compiling is no longer recommended.=]%0a* [[Vmm.DragonflyBSD]] . . . August 23, 2021, at 07:31 PM by [[~mkf]]: [=logs=]%0a* [[Vmm.NetBSD]] . . . August 23, 2021, at 07:01 PM by [[~mkf]]: [=better logs?=]%0a* [[Mariadb.Install]] . . . August 23, 2021, at 04:42 PM by [[~wiz]]: [==]%0a* [[DNS.Ipv6rDNS]] . . . August 23, 2021, at 11:55 AM by [[~jrmu]]: [==]%0a* [[Pipes.Redirection]] . . . August 23, 2021, at 03:50 AM by [[~jrmu]]: [==]%0a* [[Ksh.Redirection]] . . . August 23, 2021, at 03:50 AM by [[~jrmu]]: [==]%0a* [[DNS.RDNS]] . . . August 22, 2021, at 11:20 PM by [[~jrmu]]: [==]%0a* [[Rbldnsd.Install]] . . . August 22, 2021, at 07:58 PM by [[~mkf]]: [=wiki-ish.=]%0a* [[Netcat.Smtp]] . . . August 22, 2021, at 06:58 PM by [[~mkf]]: [=byebye=]%0a* [[Vmm.UbuntuIso]] . . . August 22, 2021, at 06:40 AM by [[~jrmu]]: [==]%0a* [[Vmm.DevuanIso]] . . . August 22, 2021, at 05:44 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Npppd]] . . . August 21, 2021, at 01:43 PM by [[~mkf]]: [==]%0a* [[Shell.Shell]] . . . August 21, 2021, at 11:42 AM by [[~jrmu]]: [==]%0a* [[Tls.CA]] . . . August 21, 2021, at 11:10 AM by [[~jrmu]]: [==]%0a* [[Openssl.Imap]] . . . August 21, 2021, at 04:05 AM by [[~AncientWisdom]]: [==]%0a* [[Openbsd.FilePermissions]] . . . August 20, 2021, at 02:20 AM by [[~Nate S]]: [==]%0a* [[Ircnow.Todo]] . . . August 17, 2021, at 08:41 AM by [[~mkf]]: [==]%0a* [[Vmm.GuixIso]] . . . August 16, 2021, at 05:12 PM by [[~jrmu]]: [==]%0a* [[Vmm.VoidIso]] . . . August 16, 2021, at 06:19 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Gophernicus]] . . . August 15, 2021, at 02:06 AM by [[~mkf]]: [==]%0a* [[Gazette.Gazette]] . . . August 15, 2021, at 01:14 AM by [[~mkf]]: [=a bit polishing=]%0a* [[EmailTray.Connect]] . . . August 15, 2021, at 12:11 AM by [[~mkf]]: [==]%0a* [[Bouncer.Konversation]] . . . August 14, 2021, at 02:46 PM by [[~mkf]]: [==]%0a* [[Squirrelmail.Connect]] . . . August 14, 2021, at 04:47 AM by [[~mkf]]: [==]%0a* [[Termius.Connect]] . . . August 14, 2021, at 04:42 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Openhttpd]] . . . August 13, 2021, at 07:29 AM by [[~jrmu]]: [==]%0a* [[ConnectBot.Keys]] . . . August 12, 2021, at 06:58 AM by [[~jrmu]]: [==]%0a* [[Debate.Monopolydanger]] . . . August 11, 2021, at 07:01 PM by [[~mkf]]: [==]%0a* [[ConnectBot.Connect]] . . . August 11, 2021, at 04:34 PM by [[~jrmu]]: [==]%0a* [[Openbsd.ZNCModules]] . . . August 11, 2021, at 03:06 PM by [[~wiz]]: [==]%0a* [[Termux.Connect]] . . . August 11, 2021, at 05:28 AM by [[~jrmu]]: [==]%0a* [[Web101.Web101]] . . . August 10, 2021, at 04:20 PM by [[~craziness]]: [=started web101=]%0a* [[Openbsd.Bitlbee]] . . . August 10, 2021, at 12:03 PM by [[~mkf]]: [==]%0a* [[Openbsd.Pppoe]] . . . August 10, 2021, at 11:56 AM by [[~mkf]]: [==]%0a* [[Sylpheed.Connect]] . . . August 10, 2021, at 11:50 AM by [[~mkf]]: [=eh, forgot that "[" again=]%0a* [[MacTerminal.Connect]] . . . August 10, 2021, at 10:33 AM by [[~jrmu]]: [==]%0a* [[OpenSSH.Connect]] . . . August 10, 2021, at 10:19 AM by [[~jrmu]]: [==]%0a* [[Fdroid.Install]] . . . August 10, 2021, at 09:05 AM by [[~jrmu]]: [==]%0a* [[Shell.Sshfingerprints]] . . . August 10, 2021, at 08:55 AM by [[~jrmu]]: [==]%0a* [[OpenSSH.Keygen]] . . . August 09, 2021, at 06:27 PM by [[~jrmu]]: [==]%0a* [[Openbsd.Sshkeys]] . . . August 09, 2021, at 04:42 PM by [[~jrmu]]: [==]%0a* [[Vmm.9front]] . . . August 09, 2021, at 06:16 AM by [[~mkf]]: [==]%0a* [[Bouncer.WinIRC]] . . . August 09, 2021, at 06:03 AM by [[~mkf]]: [==]%0a* [[IP.Myaddress]] . . . August 07, 2021, at 05:14 PM by [[~jrmu]]: [==]%0a* [[SerFISH.Connect]] . . . August 06, 2021, at 05:05 PM by [[~jrmu]]: [==]%0a* [[Sshwifty.Connect]] . . . August 06, 2021, at 05:00 PM by [[~jrmu]]: [==]%0a* [[Openbsd.Squirrelmail]] . . . August 06, 2021, at 10:32 AM by [[~baytuch]]: [==]%0a* [[Eggdrop.NickServ]] . . . August 05, 2021, at 07:27 AM by [[~jrmu]]: [==]%0a* [[Medals.Intro]] . . . August 04, 2021, at 08:34 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Dnszones]] . . . August 03, 2021, at 09:26 AM by [[~jrmu]]: [==]%0a* [[Dns.Zonefile]] . . . August 03, 2021, at 09:21 AM by [[~jrmu]]: [==]%0a* [[Irc.Clients]] . . . August 02, 2021, at 02:54 PM by [[~mkf]]: [==]%0a* [[Minutemin.Ifconfig]] . . . August 02, 2021, at 12:59 PM by [[~mkf]]: [==]%0a* [[Openbsd.Matterbridge]] . . . August 02, 2021, at 12:33 PM by [[~mkf]]: [==]%0a* [[Znc.I18n]] . . . August 02, 2021, at 09:12 AM by [[~mkf]]: [==]%0a* [[Almanack.Alt]] . . . August 02, 2021, at 07:52 AM by [[~jrmu]]: [==]%0a* [[Eggdrop.Simple]] . . . August 02, 2021, at 07:49 AM by [[~jrmu]]: [==]%0a* [[Eggdrop.Install]] . . . August 02, 2021, at 05:11 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Vhost]] . . . August 02, 2021, at 02:32 AM by [[~jrmu]]: [==]%0a* [[Ircnow.Hardware]] . . . August 01, 2021, at 01:48 PM by [[~jrmu]]: [==]%0a* [[Thunderirc.Hardware]] . . . August 01, 2021, at 01:47 PM by [[~jrmu]]: [==]%0a* [[Planetofnix.Hardware]] . . . August 01, 2021, at 01:46 PM by [[~jrmu]]: [==]%0a* [[Bsdforall.Hardware]] . . . August 01, 2021, at 01:45 PM by [[~jrmu]]: [==]%0a* [[Oddprotocol.Hardware]] . . . August 01, 2021, at 01:28 PM by [[~jrmu]]: [==]%0a* [[Lecturify.Hardware]] . . . August 01, 2021, at 01:27 PM by [[~jrmu]]: [==]%0a* [[Eggdrop184.Install]] . . . August 01, 2021, at 07:07 AM by [[~jrmu]]: [==]%0a* [[Congress.Procedure]] . . . August 01, 2021, at 06:41 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Chroot]] . . . July 31, 2021, at 02:47 AM by [[~jrmu]]: [==]%0a* [[Syslogd.Remote]] . . . July 30, 2021, at 03:30 PM by [[~jrmu]]: [==]%0a* [[Openbsd.Vmmuser]] . . . July 29, 2021, at 05:31 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Vmminstall]] . . . July 29, 2021, at 05:28 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Vmm]] . . . July 29, 2021, at 05:24 AM by [[~jrmu]]: [==]%0a* [[Openbsd.ZNCAdmin]] . . . July 28, 2021, at 06:14 AM by [[~jrmu]]: [==]%0a* [[Openbsd.ZNCSupport]] . . . July 28, 2021, at 06:14 AM by [[~jrmu]]: [==]%0a* [[ZNC.Troubleshoot]] . . . July 28, 2021, at 06:12 AM by [[~jrmu]]: [==]%0a* [[Znc.Troubleshoot]] . . . July 28, 2021, at 06:11 AM by [[~jrmu]]: [==]%0a* [[Kill.Usage]] . . . July 28, 2021, at 03:42 AM by [[~jrmu]]: [==]%0a* [[Ps.Usage]] . . . July 28, 2021, at 03:42 AM by [[~jrmu]]: [==]%0a* [[Dns.Vhost]] . . . July 28, 2021, at 03:05 AM by [[~jrmu]]: [==]%0a* [[Host.Usage]] . . . July 28, 2021, at 01:57 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Php]] . . . July 27, 2021, at 02:53 PM by [[~jrmu]]: [==]%0a* [[UsersCategoryMirrory.IRCFreeHomesteadVPS]] . . . July 26, 2021, at 06:12 AM by [[~category_mirror]]: [==]%0a* [[Ircnow.PioneerTldr]] . . . July 26, 2021, at 06:04 AM by [[~jrmu]]: [==]%0a* [[UsersCategoryMirrory.Pioneer]] . . . July 26, 2021, at 04:22 AM by [[~category_mirror]]: [==]%0a* [[Openbsd.Dig]] . . . July 25, 2021, at 06:50 AM by [[~jrmu]]: [==]%0a* [[Openbsd.RDNS]] . . . July 23, 2021, at 06:44 AM by [[~jrmu]]: [==]%0a* [[Wordpress.Install]] . . . July 21, 2021, at 06:59 PM by [[~mkf]]: [==]%0a* [[Bouncer.All]] . . . July 21, 2021, at 06:37 PM by [[~mkf]]: [==]%0a* [[Lemon.Todo]] . . . July 21, 2021, at 06:21 PM by [[~mkf]]: [==]%0a* [[Irc.Guide]] . . . July 21, 2021, at 06:02 PM by [[~mkf]]: [=client -> clients=]%0a* [[Openbsd.Sic]] . . . July 21, 2021, at 05:57 PM by [[~mkf]]: [=first edit.=]%0a* [[Minutemin.Progress]] . . . July 21, 2021, at 08:10 AM by [[~jrmu]]: [==]%0a* [[Openssl.Check]] . . . July 20, 2021, at 01:27 PM by [[~jrmu]]: [==]%0a* [[Rsync.Usage]] . . . July 19, 2021, at 02:30 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Openrsync]] . . . July 18, 2021, at 02:01 PM by [[~jrmu]]: [==]%0a* [[Eggdrop.DuckHunt]] . . . July 17, 2021, at 06:34 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Znc]] . . . July 16, 2021, at 10:43 AM by [[~jrmu]]: [==]%0a* [[Netizen.Become]] . . . July 14, 2021, at 09:47 AM by [[~jrmu]]: [==]%0a* [[Freedom.Bearcode]] . . . July 14, 2021, at 09:42 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Staticnet]] . . . July 12, 2021, at 05:48 PM by [[~jrmu]]: [==]%0a* [[Openbsd.Dovecot]] . . . July 12, 2021, at 02:58 PM by [[~jrmu]]: [==]%0a* [[Openbsd.Relayd]] . . . July 12, 2021, at 02:45 PM by [[~jrmu]]: [==]%0a* [[Openbsd.Spf]] . . . July 12, 2021, at 03:08 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Eggdrop]] . . . July 02, 2021, at 03:20 AM by [[~jrmu]]: [==]%0a* [[Openssl.Http]] . . . June 30, 2021, at 04:44 AM by [[~mkf]]: [==]%0a* [[Debate.Oldsoftware]] . . . June 29, 2021, at 03:56 PM by [[~mkf]]: [==]%0a* [[Debate.Xmlflaws]] . . . June 29, 2021, at 03:54 PM by [[~mkf]]: [==]%0a* [[Debate.Wikipediadanger]] . . . June 29, 2021, at 03:51 PM by [[~mkf]]: [==]%0a* [[Debate.DCC]] . . . June 29, 2021, at 03:49 PM by [[~mkf]]: [==]%0a* [[Debate.Matrixflaws]] . . . June 29, 2021, at 03:48 PM by [[~mkf]]: [==]%0a* [[Debate.Webirc]] . . . June 29, 2021, at 03:48 PM by [[~mkf]]: [==]%0a* [[Debate.Nodejstrap]] . . . June 29, 2021, at 03:48 PM by [[~mkf]]: [==]%0a* [[Debate.Ircv3defense]] . . . June 29, 2021, at 03:45 PM by [[~mkf]]: [==]%0a* [[Openbsd.Newdisk]] . . . June 29, 2021, at 03:23 PM by [[~jrmu]]: [==]%0a* [[AndroidEmail.AndroidEmail]] . . . June 29, 2021, at 03:11 PM by [[~jrmu]]: [==]%0a* [[Openbsd.Ed]] . . . June 28, 2021, at 04:04 PM by [[~mkf]]: [==]%0a* [[Openbsd.Unbound]] . . . June 27, 2021, at 12:12 PM by [[~jrmu]]: [==]%0a* [[Freedom.Religion]] . . . June 27, 2021, at 02:02 AM by [[~jrmu]]: [==]%0a* [[Tor.Hidden]] . . . June 26, 2021, at 08:56 PM by [[~mkf]]: [==]%0a* [[Freedom.Union]] . . . June 26, 2021, at 01:01 PM by [[~jrmu]]: [==]%0a* [[Freedom.Firstamendment]] . . . June 26, 2021, at 11:45 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Dkimproxy]] . . . June 25, 2021, at 12:56 PM by [[~jrmu]]: [==]%0a* [[MIF.Test]] . . . June 25, 2021, at 12:42 PM by [[~nsturtz]]: [==]%0a* [[Openbsd.Sysupgrade69]] . . . June 25, 2021, at 05:46 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Opensmtpd]] . . . June 23, 2021, at 02:21 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Ngircd]] . . . June 23, 2021, at 02:21 AM by [[~jrmu]]: [==]%0a* [[Openbsd.NgircdLink]] . . . June 22, 2021, at 07:50 PM by [[~mkf]]: [=delete=]%0a* [[File.File]] . . . June 22, 2021, at 07:43 PM by [[~mkf]]: [=linking=]%0a* [[Debate.Linuxflaws]] . . . June 20, 2021, at 08:03 AM by [[~mkf]]: [=making hyperlinks=]%0a* [[Police.Intro]] . . . June 19, 2021, at 11:42 AM by [[~jrmu]]: [==]%0a* [[Freedom.Destiny]] . . . June 18, 2021, at 05:31 AM by [[~jrmu]]: [==]%0a* [[DNS.Mail]] . . . June 17, 2021, at 03:21 PM by [[~jrmu]]: [==]%0a* [[Openbsd.Doas]] . . . June 13, 2021, at 01:19 PM by [[~jrmu]]: [==]%0a* [[Freedom.Freedom]] . . . June 13, 2021, at 09:13 AM by [[~jrmu]]: [==]%0a* [[Freedom.Press]] . . . June 13, 2021, at 09:12 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Shell]] . . . June 11, 2021, at 09:36 AM by [[~jrmu]]: [==]%0a* [[Ircnow.Constitution]] . . . June 10, 2021, at 03:48 PM by [[~jrmu]]: [==]%0a* [[Netizen.Rights]] . . . June 10, 2021, at 03:21 PM by [[~jrmu]]: [==]%0a* [[IPv4.Overview]] . . . June 10, 2021, at 10:13 AM by [[~jrmu]]: [==]%0a* [[Ksh.Bash]] . . . June 09, 2021, at 11:31 AM by [[~jrmu]]: [==]%0a* [[PowerShell.Connect]] . . . June 09, 2021, at 11:10 AM by [[~jrmu]]: [==]%0a* [[Code.Code]] . . . June 08, 2021, at 05:24 PM by [[~mkf]]: [=better formating=]%0a* [[Grape.DonateUs]] . . . June 06, 2021, at 03:41 PM by [[~fizi]]: [==]%0a* [[Openbsd.Books]] . . . June 06, 2021, at 12:46 PM by [[~jrmu]]: [==]%0a* [[Grape.Grape]] . . . June 06, 2021, at 11:39 AM by [[~fizi]]: [==]%0a* [[Openbsd.Pfa]] . . . June 06, 2021, at 03:49 AM by [[~navic]]: [==]%0a* [[Vmm.Debian]] . . . June 04, 2021, at 07:48 PM by [[~mkf]]: [="LOL"=]%0a* [[DNS.Dnswl]] . . . June 04, 2021, at 11:11 AM by [[~jrmu]]: [==]%0a* [[Netcat.SMTP]] . . . June 04, 2021, at 09:59 AM by [[~jrmu]]: [==]%0a* [[Dkim.Dkimsign]] . . . June 04, 2021, at 09:07 AM by [[~jrmu]]: [==]%0a* [[Tor.Torsocks]] . . . June 04, 2021, at 06:16 AM by [[~jrmu]]: [==]%0a* [[Vpn.VpnIos]] . . . June 04, 2021, at 05:52 AM by [[~jrmu]]: [==]%0a* [[Vpn.VpnMac]] . . . June 04, 2021, at 05:40 AM by [[~jrmu]]: [==]%0a* [[Fdisk.Usage]] . . . June 04, 2021, at 05:04 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Wordpress]] . . . June 04, 2021, at 04:55 AM by [[~jrmu]]: [==]%0a* [[DNS.SPF]] . . . June 03, 2021, at 01:27 PM by [[~jrmu]]: [==]%0a* [[Terms.Terms]] . . . June 02, 2021, at 01:40 PM by [[~jrmu]]: [==]%0a* [[HostServ.Rules]] . . . June 01, 2021, at 08:11 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Anope]] . . . May 31, 2021, at 10:24 AM by [[~miniontoby]]: [=cp=]%0a* [[Openbsd.ACKFlood]] . . . May 29, 2021, at 06:20 AM by [[~mkf]]: [==]%0a* [[Openbsd.SSDP]] . . . May 29, 2021, at 06:18 AM by [[~mkf]]: [==]%0a* [[Openbsd.Anycast]] . . . May 29, 2021, at 06:01 AM by [[~mkf]]: [==]%0a* [[Ambassador.Networks]] . . . May 27, 2021, at 04:05 PM by [[~jrmu]]: [==]%0a* [[Marketing.Rules]] . . . May 26, 2021, at 06:15 AM by [[~jrmu]]: [==]%0a* [[Freenode.Power]] . . . May 26, 2021, at 04:38 AM by [[~jrmu]]: [==]%0a* [[Freenode.Money]] . . . May 25, 2021, at 03:29 PM by [[~jrmu]]: [==]%0a* [[Freenode.Takeover]] . . . May 25, 2021, at 05:28 AM by [[~jrmu]]: [==]%0a* [[Freedom.Freenode]] . . . May 25, 2021, at 01:48 AM by [[~jrmu]]: [==]%0a* [[Bouncer.Atomic]] . . . May 24, 2021, at 03:22 PM by [[~mkf]]: [=spacing=]%0a* [[Minetest.Updating]] . . . May 24, 2021, at 08:10 AM by [[~mkf]]: [=monospaced commands=]%0a* [[Shell.Putty]] . . . May 24, 2021, at 06:16 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Dmarc]] . . . May 21, 2021, at 09:22 AM by [[~jrmu]]: [==]%0a* [[Vmm.Optimize]] . . . May 19, 2021, at 04:04 AM by [[~jrmu]]: [==]%0a* [[Ircnow.Stable]] . . . May 18, 2021, at 10:15 AM by [[~mkf]]: [==]%0a* [[Ircnow.VicePresident]] . . . May 18, 2021, at 08:15 AM by [[~jrmu]]: [==]%0a* [[Ircnow.Sheriff]] . . . May 18, 2021, at 08:00 AM by [[~jrmu]]: [==]%0a* [[Ircnow.Ambassador]] . . . May 18, 2021, at 07:42 AM by [[~jrmu]]: [==]%0a* [[Pf.Guide]] . . . May 17, 2021, at 03:37 AM by [[~bejelentkezni]]: [==]%0a* [[Openbsd.Disklabel]] . . . May 17, 2021, at 03:33 AM by [[~bejelentkezni]]: [==]%0a* [[Openbsd.Fdisk]] . . . May 17, 2021, at 03:27 AM by [[~bejelentkezni]]: [==]%0a* [[NewsNow.Install]] . . . May 16, 2021, at 06:49 AM by [[~mkf]]: [="$"=]%0a* [[Tmux.Share]] . . . May 15, 2021, at 02:27 AM by [[~mistera]]: [==]%0a* [[Openbsd.Security]] . . . May 14, 2021, at 03:14 AM by [[~caesar]]: [==]%0a* [[Bouncer.Vision]] . . . May 13, 2021, at 09:47 AM by [[~mkf]]: [=added home page, removed "..."s=]%0a* [[Minetest.Worldbackup]] . . . May 12, 2021, at 11:02 AM by [[~AES]]: [==]%0a* [[Minetest.Texturestyle]] . . . May 12, 2021, at 11:00 AM by [[~AES]]: [==]%0a* [[Minetest.Serverlocations]] . . . May 12, 2021, at 10:59 AM by [[~AES]]: [==]%0a* [[Minetest.Addingarenas]] . . . May 12, 2021, at 10:58 AM by [[~jrmu]]: [==]%0a* [[Relay.Relay]] . . . May 12, 2021, at 09:10 AM by [[~jrmu]]: [==]%0a* [[Ngircd.Install-bej]] . . . May 11, 2021, at 05:26 AM by [[~bejelentkezni]]: [==]%0a* [[Botnow.Botnow]] . . . May 08, 2021, at 09:44 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Hopm-Arthur]] . . . May 07, 2021, at 12:28 PM by [[~Arthur]]: [==]%0a* [[Znc.Chroot69]] . . . May 06, 2021, at 03:36 AM by [[~bejelentkezni]]: [=back to 6.9 to see real changes=]%0a* [[Dig.Usage]] . . . May 04, 2021, at 02:36 AM by [[~sarah]]: [==]%0a* [[Bgpd.Configure]] . . . May 03, 2021, at 06:26 AM by [[~jrmu]]: [==]%0a* [[Cherry.Cherry]] . . . May 02, 2021, at 01:43 PM by [[~Oz]]: [==]%0a* [[Freedom.Unix]] . . . April 29, 2021, at 03:39 PM by [[~jrmu]]: [==]%0a* [[Pmwiki.Simpleurl]] . . . April 29, 2021, at 02:46 PM by [[~punk]]: [==]%0a* [[Gpl.Flaws]] . . . April 24, 2021, at 04:56 PM by [[~jrmu]]: [==]%0a* [[Iked.Windows]] . . . April 18, 2021, at 07:38 PM by [[~st13g]]: [==]%0a* [[Freedom.Libertyordeath]] . . . April 17, 2021, at 12:35 PM by [[~jrmu]]: [==]%0a* [[Minetest.Economy]] . . . April 15, 2021, at 02:32 PM by [[~jrmu]]: [==]%0a* [[Vim.Vim]] . . . April 11, 2021, at 11:14 PM by [[~monaco]]: [==]%0a* [[Minutemin.Duty]] . . . April 11, 2021, at 04:53 AM by [[~jrmu]]: [==]%0a* [[License.License]] . . . April 04, 2021, at 02:00 AM by [[~jrmu]]: [==]%0a* [[EthicalSource.HolierThanThou]] . . . April 04, 2021, at 01:56 AM by [[~jrmu]]: [==]%0a* [[Jrmu.Rmsboycott]] . . . April 03, 2021, at 01:36 AM by [[~jrmu]]: [==]%0a* [[Jrmu.Libertyordeath]] . . . April 02, 2021, at 12:56 PM by [[~jrmu]]: [==]%0a* [[Fig.Fig]] . . . March 31, 2021, at 10:15 AM by [[~chewy]]: [==]%0a* [[Coconut.Coconut]] . . . March 29, 2021, at 12:28 PM by [[~jrmu]]: [==]%0a* [[Ircnow.CodeForce]] . . . March 29, 2021, at 12:04 PM by [[~jrmu]]: [==]%0a* [[ClawsMail.Connect]] . . . March 29, 2021, at 08:42 AM by [[~miniontoby]]: [==]%0a* [[Freedom.Madeonirc]] . . . March 27, 2021, at 11:48 AM by [[~jrmu]]: [==]%0a* [[Third.Devs]] . . . March 27, 2021, at 11:41 AM by [[~jrmu]]: [==]%0a* [[Minutemin.Code]] . . . March 24, 2021, at 03:26 AM by [[~jrmu]]: [==]%0a* [[Cherry.Todo]] . . . March 23, 2021, at 03:23 PM by [[~Oz]]: [==]%0a* [[Freedom.Independence]] . . . March 22, 2021, at 01:13 PM by [[~wiz]]: [==]%0a* [[Ifconfig.Change]] . . . March 20, 2021, at 11:15 AM by [[~jrmu]]: [==]%0a* [[Marketing.Founders]] . . . March 20, 2021, at 01:40 AM by [[~jrmu]]: [==]%0a* [[NewsNow.Teams]] . . . March 18, 2021, at 09:47 AM by [[~miniontoby]]: [=banana=]%0a* [[NewsNow.NewsNow]] . . . March 17, 2021, at 04:33 PM by [[~miniontoby]]: [=more ways=]%0a* [[Vhost.Freedns]] . . . March 16, 2021, at 12:22 PM by [[~wiz]]: [==]%0a* [[Marketing.Freedom]] . . . March 15, 2021, at 01:30 PM by [[~jrmu]]: [==]%0a* [[Bsd.Labor]] . . . March 15, 2021, at 06:12 AM by [[~jrmu]]: [==]%0a* [[License.Discriminatory]] . . . March 15, 2021, at 06:12 AM by [[~jrmu]]: [==]%0a* [[Bsd.Hope]] . . . March 14, 2021, at 11:05 PM by [[~jrmu]]: [==]%0a* [[License.Publicdomain]] . . . March 14, 2021, at 10:02 AM by [[~jrmu]]: [==]%0a* [[Linux.Flaws]] . . . March 14, 2021, at 05:13 AM by [[~jrmu]]: [==]%0a* [[NewsNow.Browser]] . . . March 12, 2021, at 08:00 AM by [[~miniontoby]]: [==]%0a* [[Abuse.Code]] . . . March 09, 2021, at 03:44 PM by [[~jrmu]]: [==]%0a* [[Congress.Documents]] . . . March 07, 2021, at 04:50 AM by [[~jrmu]]: [==]%0a* [[Ircnow.Goals]] . . . March 06, 2021, at 09:33 AM by [[~jrmu]]: [==]%0a* [[Ircnow.Chatforce]] . . . March 05, 2021, at 02:15 PM by [[~jrmu]]: [==]%0a* [[Shell.Bash]] . . . March 05, 2021, at 10:19 AM by [[~jrmu]]: [==]%0a* [[User.Welcome]] . . . March 05, 2021, at 07:34 AM by [[~jrmu]]: [==]%0a* [[Immigrant.Welcome]] . . . March 05, 2021, at 06:59 AM by [[~jrmu]]: [==]%0a* [[Mail.Openrelay]] . . . March 04, 2021, at 03:20 PM by [[~jrmu]]: [==]%0a* [[Mail.Test]] . . . March 04, 2021, at 03:07 PM by [[~jrmu]]: [==]%0a* [[Minutemin.Game]] . . . March 04, 2021, at 10:16 AM by [[~jrmu]]: [==]%0a* [[Marketing.Recruit]] . . . March 04, 2021, at 09:39 AM by [[~jrmu]]: [==]%0a* [[Ircnow.Howtoask]] . . . March 03, 2021, at 12:35 PM by [[~jrmu]]: [==]%0a* [[Ircnow.Netizen]] . . . February 28, 2021, at 03:18 PM by [[~jrmu]]: [==]%0a* [[Servers.Rights]] . . . February 28, 2021, at 12:37 PM by [[~jrmu]]: [==]%0a* [[Marketing.Enterprise]] . . . February 28, 2021, at 11:52 AM by [[~jrmu]]: [==]%0a* [[Minutemin.Creed]] . . . February 28, 2021, at 03:21 AM by [[~jrmu]]: [==]%0a* [[Ln.Intro]] . . . February 25, 2021, at 12:20 PM by [[~jrmu]]: [==]%0a* [[Leafnode.Install]] . . . February 25, 2021, at 10:56 AM by [[~jrmu]]: [==]%0a* [[Guava.Todo]] . . . February 23, 2021, at 10:47 AM by [[~quofan]]: [==]%0a* [[Relays.Relays]] . . . February 22, 2021, at 04:22 PM by [[~jrmu]]: [==]%0a* [[Jujube.Jujube]] . . . February 21, 2021, at 04:22 PM by [[~fizi]]: [==]%0a* [[PSFTP.Connect]] . . . February 21, 2021, at 03:57 PM by [[~jrmu]]: [==]%0a* [[Outlook.Connect]] . . . February 21, 2021, at 03:23 PM by [[~jrmu]]: [==]%0a* [[AppleMail.Connect]] . . . February 20, 2021, at 04:38 PM by [[~jrmu]]: [==]%0a* [[Thunderbird.Pgp]] . . . February 19, 2021, at 04:44 PM by [[~jrmu]]: [==]%0a* [[License.Ircnow]] . . . February 19, 2021, at 09:45 AM by [[~miniontoby]]: [=2021=]%0a* [[Thunderbird.Connect]] . . . February 19, 2021, at 09:36 AM by [[~jrmu]]: [==]%0a* [[Shell.Mac]] . . . February 19, 2021, at 09:14 AM by [[~jrmu]]: [==]%0a* [[Minutemin.Training]] . . . February 18, 2021, at 06:42 AM by [[~jrmu]]: [==]%0a* [[Freedom.Openforeveryone]] . . . February 16, 2021, at 04:33 AM by [[~jrmu]]: [==]%0a* [[Ircnow.IRCitizen]] . . . February 15, 2021, at 05:32 AM by [[~jrmu]]: [==]%0a* [[IPv6.Overview]] . . . February 14, 2021, at 11:09 AM by [[~jrmu]]: [==]%0a* [[Tcpip.Overview]] . . . February 14, 2021, at 11:02 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Syspatch]] . . . February 14, 2021, at 11:00 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Netadmin]] . . . February 14, 2021, at 10:56 AM by [[~jrmu]]: [==]%0a* [[Marketing.Religion]] . . . February 14, 2021, at 10:37 AM by [[~jrmu]]: [==]%0a* [[Marketing.Independence]] . . . February 13, 2021, at 04:59 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Leafnode]] . . . February 12, 2021, at 01:40 PM by [[~chewy]]: [==]%0a* [[Oidentd.Pylink]] . . . February 12, 2021, at 01:25 PM by [[~jrmu]]: [==]%0a* [[Marketing.Opportunity]] . . . February 11, 2021, at 12:58 PM by [[~jrmu]]: [==]%0a* [[Marketing.Republic]] . . . February 11, 2021, at 06:45 AM by [[~jrmu]]: [==]%0a* [[Achurch.Install]] . . . February 10, 2021, at 04:33 PM by [[~jrmu]]: [==]%0a* [[Openbsd.Pylink]] . . . February 08, 2021, at 08:33 AM by [[~jrmu]]: [==]%0a* [[Ircnow.OpofLiberty]] . . . February 06, 2021, at 12:53 PM by [[~jrmu]]: [==]%0a* [[Ircnow.Allies]] . . . February 06, 2021, at 12:47 PM by [[~jrmu]]: [==]%0a* [[Freedom.Dueprocess]] . . . February 06, 2021, at 12:25 PM by [[~jrmu]]: [==]%0a* [[Freedom.Checks]] . . . February 06, 2021, at 12:21 PM by [[~jrmu]]: [==]%0a* [[Freedom.Rulebylaw]] . . . February 06, 2021, at 12:12 PM by [[~jrmu]]: [==]%0a* [[Freedom.Startupdream]] . . . February 06, 2021, at 12:12 PM by [[~jrmu]]: [==]%0a* [[Freedom.Federation]] . . . February 06, 2021, at 11:44 AM by [[~jrmu]]: [==]%0a* [[Freedom.Selfadmin]] . . . February 06, 2021, at 11:26 AM by [[~jrmu]]: [==]%0a* [[Ircnow.OpsofLiberty]] . . . February 06, 2021, at 02:13 AM by [[~jrmu]]: [==]%0a* [[Freedom.Homestead]] . . . February 05, 2021, at 12:49 PM by [[~jrmu]]: [==]%0a* [[Freedom.Software]] . . . February 05, 2021, at 11:31 AM by [[~jrmu]]: [==]%0a* [[Freedom.Opportunity]] . . . February 05, 2021, at 08:55 AM by [[~jrmu]]: [==]%0a* [[Unix.Workethic]] . . . February 05, 2021, at 08:49 AM by [[~jrmu]]: [==]%0a* [[Unix.Ethic]] . . . February 05, 2021, at 08:48 AM by [[~jrmu]]: [==]%0a* [[Freedom.Privacy]] . . . February 05, 2021, at 07:26 AM by [[~jrmu]]: [==]%0a* [[Debate.Privacy]] . . . February 05, 2021, at 07:05 AM by [[~jrmu]]: [==]%0a* [[Team.Policy]] . . . February 04, 2021, at 04:08 PM by [[~jrmu]]: [==]%0a* [[Freedom.Serversrights]] . . . February 04, 2021, at 02:43 PM by [[~jrmu]]: [==]%0a* [[Freedom.Serverrights]] . . . February 04, 2021, at 02:42 PM by [[~jrmu]]: [==]%0a* [[Freedom.Fork]] . . . February 04, 2021, at 02:39 PM by [[~jrmu]]: [==]%0a* [[Freedom.Lanofopportunity]] . . . February 04, 2021, at 01:24 PM by [[~jrmu]]: [==]%0a* [[Freedom.Opentoall]] . . . February 04, 2021, at 01:17 PM by [[~jrmu]]: [==]%0a* [[Freedom.Refuge]] . . . February 04, 2021, at 09:31 AM by [[~jrmu]]: [==]%0a* [[Dns.Providers]] . . . February 04, 2021, at 04:27 AM by [[~jrmu]]: [==]%0a* [[Guava.Guava]] . . . February 03, 2021, at 02:30 AM by [[~st13g]]: [==]%0a* [[Openbsd.Stable]] . . . February 02, 2021, at 02:25 PM by [[~jrmu]]: [==]%0a* [[Openbsd.Base64]] . . . February 02, 2021, at 06:37 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Unboundadblock]] . . . February 02, 2021, at 04:29 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Pfbadhost]] . . . February 02, 2021, at 04:29 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Wraith]] . . . February 02, 2021, at 04:22 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Delphinusdnsd]] . . . February 02, 2021, at 01:51 AM by [[~jrmu]]: [==]%0a* [[Mango.Mango]] . . . January 31, 2021, at 12:01 PM by [[~nix]]: [==]%0a* [[Openbsd.Abuse]] . . . January 31, 2021, at 05:33 AM by [[~jrmu]]: [==]%0a* [[Freedom.Censorship]] . . . January 31, 2021, at 05:23 AM by [[~jrmu]]: [==]%0a* [[Debate.Firstamendment]] . . . January 31, 2021, at 05:20 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Phishing]] . . . January 31, 2021, at 05:02 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Audit]] . . . January 31, 2021, at 04:46 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Ongoing]] . . . January 31, 2021, at 01:19 AM by [[~jrmu]]: [==]%0a* [[Ircnow.Partners]] . . . January 31, 2021, at 12:32 AM by [[~jrmu]]: [==]%0a* [[Orange.Todo]] . . . January 30, 2021, at 11:31 AM by [[~jrmu]]: [==]%0a* [[Pear.Pear]] . . . January 29, 2021, at 06:09 PM by [[~dennis]]: [==]%0a* [[Openbsd.Httpopenproxy]] . . . January 29, 2021, at 11:01 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Zncadmin]] . . . January 29, 2021, at 10:00 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Rbldns]] . . . January 29, 2021, at 05:45 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Setuid]] . . . January 28, 2021, at 06:53 AM by [[~jrmu]]: [==]%0a* [[Openbsd.PFTesting]] . . . January 25, 2021, at 03:28 PM by [[~jrmu]]: [==]%0a* [[Openbsd.ZNCDaily]] . . . January 25, 2021, at 11:35 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Irssi]] . . . January 25, 2021, at 07:08 AM by [[~jrmu]]: [==]%0a* [[Ircnow.Sysadmins]] . . . January 24, 2021, at 10:36 AM by [[~jrmu]]: [==]%0a* [[Debate.UnixPhilosophy]] . . . January 18, 2021, at 05:05 AM by [[~category_mirror]]: [==]%0a* [[Openbsd.XTerm]] . . . January 17, 2021, at 01:48 PM by [[~miniontoby]]: [=copyright=]%0a* [[UsersCategoryMirrory.Statement]] . . . January 17, 2021, at 02:44 AM by [[~category_mirror]]: [==]%0a* [[Email.Outlook]] . . . January 16, 2021, at 05:13 PM by [[~Zouheir]]: [==]%0a* [[Plum.Todo]] . . . January 16, 2021, at 12:09 AM by [[~st13g]]: [==]%0a* [[Debate.Ipsec]] . . . January 13, 2021, at 10:39 AM by [[~jrmu]]: [==]%0a* [[Plum.Plum]] . . . January 12, 2021, at 03:02 PM by [[~wiz]]: [==]%0a* [[Openbsd.Slrn]] . . . January 12, 2021, at 02:40 PM by [[~Noxturnix]]: [==]%0a* [[OpenBSD.CPAN]] . . . January 12, 2021, at 01:48 PM by [[~Dima]]: [==]%0a* [[Jujube.Todo]] . . . January 11, 2021, at 05:13 PM by [[~fizi]]: [==]%0a* [[Ircnow.Ilines]] . . . January 11, 2021, at 09:55 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Netcat]] . . . January 09, 2021, at 02:20 PM by [[~jrmu]]: [==]%0a* [[OpenBSD.Perl]] . . . January 09, 2021, at 02:04 PM by [[~dima]]: [==]%0a* [[Openbsd.Perl]] . . . January 09, 2021, at 01:52 PM by [[~jrmu]]: [==]%0a* [[Fig.Log]] . . . January 07, 2021, at 11:23 AM by [[~dima]]: [=test=]%0a* [[Fig.Todo]] . . . January 06, 2021, at 01:06 PM by [[~jrmu]]: [==]%0a* [[Grape.Todo]] . . . January 06, 2021, at 01:05 PM by [[~jrmu]]: [==]%0a* [[Pear.Todo]] . . . January 06, 2021, at 01:05 PM by [[~jrmu]]: [==]%0a* [[Jujube.Team]] . . . January 06, 2021, at 01:04 PM by [[~jrmu]]: [==]%0a* [[Mango.Todo]] . . . January 06, 2021, at 01:04 PM by [[~jrmu]]: [==]%0a* [[Ircnow.Censorship]] . . . January 06, 2021, at 03:01 AM by [[~jrmu]]: [==]%0a* [[Ircnow.Pentesters]] . . . January 05, 2021, at 11:17 AM by [[~jrmu]]: [==]%0a* [[Ircnow.Coders]] . . . January 05, 2021, at 11:11 AM by [[~jrmu]]: [==]%0a* [[Banana.Todo]] . . . January 04, 2021, at 09:41 AM by [[~miniontoby]]: [=znc=]%0a* [[Users.CategoryMirrory]] . . . January 04, 2021, at 01:10 AM by [[~category_mirror]]: [==]%0a* [[UsersCategoryMirrory.Test]] . . . January 03, 2021, at 08:17 PM by [[~category_mirrory]]: [==]%0a* [[Users.Categorymirrory]] . . . January 03, 2021, at 08:12 PM by [[~category_mirrory]]: [=wrong caps=]%0a* [[Banana.Banana]] . . . January 03, 2021, at 02:39 PM by [[~miniontoby]]: [==]%0a* [[Orange.Orange]] . . . January 03, 2021, at 02:10 PM by [[~jrmu]]: [==]%0a* [[Openbsd.Backup]] . . . January 03, 2021, at 01:46 PM by [[~jrmu]]: [==]%0a* [[Openbsd.Backups]] . . . January 02, 2021, at 11:44 AM by [[~jrmu]]: [==]%0a* [[Debate.Appledanger]] . . . January 02, 2021, at 01:35 AM by [[~jrmu]]: [==]%0a* [[Grape.Tasks]] . . . January 01, 2021, at 07:52 PM by [[~fizi]]: [==]%0a* [[Ircnow.Helpers]] . . . January 01, 2021, at 04:36 AM by [[~jrmu]]: [==]%0a* [[Ircnow.Finances]] . . . January 01, 2021, at 04:15 AM by [[~jrmu]]: [==]%0a* [[Tutorial.Tutorial]] . . . January 01, 2021, at 03:25 AM by [[~jrmu]]: [==]%0a* [[Ircnow.Testing]] . . . December 30, 2020, at 12:58 PM by [[~jrmu]]: [==]%0a* [[Openbsd.Sshbackdoor]] . . . December 30, 2020, at 12:14 PM by [[~jrmu]]: [==]%0a* [[Mango.Packages]] . . . December 30, 2020, at 10:48 AM by [[~nix]]: [==]%0a* [[Ircnow.Contact]] . . . December 30, 2020, at 03:18 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Pf-bnc]] . . . December 29, 2020, at 06:30 PM by [[~jrmu]]: [==]%0a* [[Ircnow.Partners2]] . . . December 29, 2020, at 02:52 PM by [[~jrmu]]: [==]%0a* [[Openbsd.Tcltls]] . . . December 29, 2020, at 09:53 AM by [[~jrmu]]: [==]%0a* [[Debate.Mozilladanger]] . . . December 27, 2020, at 03:05 AM by [[~jrmu]]: [==]%0a* [[Debate.Controlcomputer]] . . . December 27, 2020, at 03:02 AM by [[~jrmu]]: [==]%0a* [[Debate.Facebookdanger]] . . . December 27, 2020, at 03:01 AM by [[~jrmu]]: [==]%0a* [[Debate.Slackdanger]] . . . December 27, 2020, at 02:56 AM by [[~jrmu]]: [==]%0a* [[Debate.Freespeech]] . . . December 27, 2020, at 02:36 AM by [[~jrmu]]: [==]%0a* [[Debate.Ethicalflaws]] . . . December 27, 2020, at 02:31 AM by [[~jrmu]]: [==]%0a* [[Debate.Hatespeech]] . . . December 27, 2020, at 02:20 AM by [[~jrmu]]: [==]%0a* [[Debate.Monero]] . . . December 27, 2020, at 02:02 AM by [[~jrmu]]: [==]%0a* [[Debate.WhyNotC]] . . . December 26, 2020, at 06:43 PM by [[~searchsocial]]: [==]%0a* [[Debate.Python]] . . . December 26, 2020, at 06:21 PM by [[~jrmu]]: [==]%0a* [[Debate.Cash]] . . . December 26, 2020, at 06:18 PM by [[~jrmu]]: [==]%0a* [[Debate.Uberdanger]] . . . December 26, 2020, at 06:16 PM by [[~jrmu]]: [==]%0a* [[Debate.Microsoftdanger]] . . . December 26, 2020, at 06:15 PM by [[~jrmu]]: [==]%0a* [[Debate.Accessibility]] . . . December 26, 2020, at 06:14 PM by [[~jrmu]]: [==]%0a* [[Debate.Zoomdanger]] . . . December 26, 2020, at 06:08 PM by [[~jrmu]]: [==]%0a* [[Shell.Applications]] . . . December 19, 2020, at 06:21 PM by [[~fizi]]: [==]%0a* [[Third.Dillo]] . . . December 19, 2020, at 01:52 PM by [[~jrmu]]: [==]%0a* [[Third.Basilisk]] . . . December 19, 2020, at 01:38 PM by [[~jrmu]]: [==]%0a* [[Third.Directory]] . . . December 19, 2020, at 01:35 PM by [[~jrmu]]: [==]%0a* [[Guava.Packages]] . . . December 19, 2020, at 06:14 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Amplification]] . . . December 19, 2020, at 05:42 AM by [[~jrmu]]: [==]%0a* [[Openbsd.UDPFlood]] . . . December 18, 2020, at 10:39 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Tcpdump]] . . . December 18, 2020, at 09:12 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Tcpackflood]] . . . December 17, 2020, at 10:36 AM by [[~jrmu]]: [==]%0a* [[Openbsd.RSTFlood]] . . . December 17, 2020, at 10:34 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Tcpresetflood]] . . . December 17, 2020, at 10:34 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Ssdp]] . . . December 15, 2020, at 12:59 PM by [[~jrmu]]: [==]%0a* [[Bouncer.Igloo]] . . . December 14, 2020, at 09:39 AM by [[~Noxturnix]]: [==]%0a* [[Main.Terms]] . . . December 13, 2020, at 01:35 PM by [[~jrmu]]: [==]%0a* [[Openbsd.Pf]] . . . December 13, 2020, at 12:03 PM by [[~jrmu]]: [==]%0a* [[Openbsd.Upgrade68]] . . . December 13, 2020, at 11:12 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Install68]] . . . December 13, 2020, at 10:13 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Upgrade67]] . . . December 13, 2020, at 04:02 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Sysupgrade68]] . . . December 11, 2020, at 10:27 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Dokuwiki]] . . . December 10, 2020, at 02:23 PM by [[~miniontoby]]: [=code blocks fixed=]%0a* [[Openbsd.Acme-client]] . . . December 09, 2020, at 06:47 PM by [[~miniontoby]]: [=fixed troubleshooting links=]%0a* [[Freedom.Christian]] . . . December 08, 2020, at 01:12 AM by [[~jrmu]]: [==]%0a* [[Freedom.Finances]] . . . December 08, 2020, at 01:04 AM by [[~jrmu]]: [==]%0a* [[Shell.Sshkeys]] . . . December 07, 2020, at 10:36 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Install67]] . . . December 06, 2020, at 11:03 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Buyvm]] . . . December 06, 2020, at 02:42 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Install]] . . . December 04, 2020, at 04:15 PM by [[~jrmu]]: [==]%0a* [[Opernbsd.Buyvm]] . . . December 04, 2020, at 12:06 PM by [[~jrmu]]: [==]%0a* [[Bouncer.WeeChat]] . . . December 02, 2020, at 12:43 PM by [[~jrmu]]: [==]%0a* [[Bouncer.SimpleIRC]] . . . December 02, 2020, at 12:31 PM by [[~jrmu]]: [==]%0a* [[Freedom.Militia]] . . . December 02, 2020, at 04:18 AM by [[~jrmu]]: [==]%0a* [[Third.Third]] . . . December 01, 2020, at 01:49 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Oidentd]] . . . November 30, 2020, at 11:42 PM by [[~jrmu]]: [==]%0a* [[Ircnow.Helper]] . . . November 28, 2020, at 02:21 AM by [[~jrmu]]: [==]%0a* [[Bouncer.Hexchat]] . . . November 27, 2020, at 12:52 PM by [[~jrmu]]: [==]%0a* [[Bouncer.IRCCloud]] . . . November 24, 2020, at 11:53 AM by [[~jrmu]]: [==]%0a* [[Bouncer.AdiIRC]] . . . November 24, 2020, at 11:42 AM by [[~jrmu]]: [==]%0a* [[Bouncer.RevolutionIRC]] . . . November 24, 2020, at 11:35 AM by [[~jrmu]]: [==]%0a* [[Bouncer.KiwiIRC]] . . . November 24, 2020, at 11:34 AM by [[~jrmu]]: [==]%0a* [[Bouncer.KVIrc]] . . . November 24, 2020, at 11:33 AM by [[~jrmu]]: [==]%0a* [[Bouncer.IceChat]] . . . November 24, 2020, at 11:27 AM by [[~jrmu]]: [==]%0a* [[Bouncer.IRCCloudiOS]] . . . November 24, 2020, at 11:20 AM by [[~jrmu]]: [==]%0a* [[Bouncer.IRCCloudAndroid]] . . . November 24, 2020, at 11:20 AM by [[~jrmu]]: [==]%0a* [[Bouncer.IRCCloudWeb]] . . . November 24, 2020, at 11:19 AM by [[~jrmu]]: [==]%0a* [[Third.Catalog]] . . . November 23, 2020, at 07:52 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Checklist]] . . . November 20, 2020, at 12:44 AM by [[~gry]]: [=+=]%0a* [[Openbsd.Acopm]] . . . November 04, 2020, at 03:32 PM by [[~jrmu]]: [==]%0a* [[Openbsd.Achurch]] . . . November 04, 2020, at 02:25 PM by [[~jrmu]]: [==]%0a* [[Openbsd.Vi]] . . . November 04, 2020, at 12:51 PM by [[~jrmu]]: [==]%0a* [[Openbsd.Sudo]] . . . November 04, 2020, at 12:38 PM by [[~jrmu]]: [==]%0a* [[Freedom.Denomination]] . . . October 23, 2020, at 09:20 AM by [[~jrmu]]: [==]%0a* [[Vps.Intro]] . . . October 10, 2020, at 08:22 AM by [[~jrmu]]: [==]%0a* [[Ircweb.Ircweb]] . . . October 05, 2020, at 01:10 AM by [[~jrmu]]: [==]%0a* [[Http2irc.Http2irc]] . . . October 05, 2020, at 01:04 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Easyapp]] . . . September 29, 2020, at 12:13 PM by [[~jrmu]]: [==]%0a* [[Orange.Nl]] . . . September 17, 2020, at 08:43 AM by [[~miniontoby]]: [=Dutch correct page=]%0a* [[Grape.Guide]] . . . September 16, 2020, at 08:42 AM by [[~baytuch]]: [==]%0a* [[Orange.Id]] . . . September 08, 2020, at 09:51 AM by [[~gry]]: [=+=]%0a* [[Orange.Ru]] . . . September 07, 2020, at 11:29 PM by [[~gry]]: [=+=]%0a* [[Bouncer.MIRC]] . . . September 06, 2020, at 03:59 AM by [[~jrmu]]: [==]%0a* [[Debate.Bncnow]] . . . September 04, 2020, at 04:36 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Cgit]] . . . September 01, 2020, at 05:51 PM by [[~baytuch]]: [==]%0a* [[Orange.Notes]] . . . August 27, 2020, at 03:38 AM by [[~gry]]: [=expanded=]%0a* [[Shell.ShellSSHKEYS]] . . . August 25, 2020, at 10:00 PM by [[~gry]]: [=permissions added=]%0a* [[Bots.Bots]] . . . August 25, 2020, at 12:02 PM by [[~jrmu]]: [==]%0a* [[Bouncer.Irccloud]] . . . August 24, 2020, at 12:20 PM by [[~jrmu]]: [==]%0a* [[GrapeTeam.Tracker]] . . . August 24, 2020, at 10:16 AM by [[~gry]]: [=+=]%0a* [[GrapeTeam.GrapeTeam]] . . . August 24, 2020, at 10:13 AM by [[~jrmu]]: [==]%0a* [[Ircnow.Course]] . . . August 21, 2020, at 05:01 AM by [[~gry]]: [==]%0a* [[Openbsd.Bchs]] . . . August 20, 2020, at 07:11 AM by [[~jrmu]]: [==]%0a* [[Ircnow.Todo]] . . . August 20, 2020, at 06:48 AM by [[~jrmu]]: on_is_active php_session_active squirrelmailing sqsession_start troubleshooting authentication session_status config_default webmail_access modifications configuration unfortunately accessibility administrator webmail_error compatibility acceleration default_pref organization replacement disposition alternative information sourceforge permissions certificate interactive configuring preferences letsencrypt development compatible javascript configtest connection additional nameserver configured afterwards extracting attempting installing documents complains openhttpd functions localhost opensmtpd challenge supported subdomain receiving databases recommend necessary following languages delimiter directory debugging fusername essential addresses installed chrooted smtphost projects browsers normally location provides tlsmulti 26214400 required remember original security listener optional settings sendmail properly software specific licensed messages brackets instance writable services browsing defaults drawback continue opening control dovecot fastcgi already contact defines example initial unbound folders unusual request plugins general command servers defined private options however records contrib include restart because nologin disable exiting keypair baytuch strings misused charset appears content instead openbsd release sending mt_rand another subject version tarball warning charlie without changes resolve foxtrot uploads written client relayd needed return logout syntax longer cannot latest htdocs braces rather offset typing before themes ircnow frames across making should switch please detect secure invert readme global create update system locale report serial delete femail myname daemon lookup socket number errors trying issues actual stable inline attach master reload touch could color chown check chmod needs first intro shell rcctl php74 mkdir books hosts write above https there false using might every ascii happy delta curly array fatal bravo query where since which setup exist works notes saved files press alpha enter means class block title index chain strip lines known worry based ifend about zones this doas 2001 imap will well page your real acme make sure that aaaa ipv4 does fccf want 1008 2602 than sbin chsh help bind body some copy runs both must logs like when ctrl type echo xvzf find uses html many wiki easy fees more exec text once were have made mime done next move into ipv6 pop3 menu sign quit full motd hide give edit time www ssl etc var 127 day see has 162 bad gpl 451 fix ksh 644 zip its 755 ftp net way crt 634 usr 403 src nsd fpm dns max few db8 143 via by gz 22 cd rx 38 87 mv 80 9 -time=1677861462 +rev=11455 +text=* [[DNS.Mail]] . . . @2023-03-06T04:50:40Z by [[~jrmu]]: [=Moved to /etc/dkim/ to fix permissions bugs=]%0a* [[DNS.DKIM]] . . . @2023-03-06T04:48:38Z by [[~jrmu]]: [=Moved to /etc/dkim/ to fix permissions bugs=]%0a* [[Opensmtpd.Configure]] . . . @2023-03-06T04:39:32Z by [[~jrmu]]: [=Moved to /etc/dkim/ to fix permissions bugs=]%0a* [[9front.Netsurf]] . . . @2023-03-06T03:14:30Z by [[~Yonle]]: [==]%0a* [[Openbsd.Ngircd]] . . . @2023-03-05T18:17:39Z by [[~mkf]]: [==]%0a* [[FreeIRC.About]] . . . March 05, 2023, at 03:51 PM by [[~kilroy]]: [==]%0a* [[Openbsd.OpenTracker]] . . . March 03, 2023, at 04:37 PM by [[~baytuch]]: [==]%0a* [[SiteAdmin.AuthUser]] . . . March 03, 2023, at 05:31 AM by [[~jrmu]]: [==]%0a* [[Almanack.Almanack]] . . . March 02, 2023, at 05:10 AM by [[~jrmu]]: [==]%0a* [[Ircnow.Roadmap]] . . . March 02, 2023, at 05:10 AM by [[~jrmu]]: [==]%0a* [[Ircnow.Roadmap2023]] . . . March 02, 2023, at 05:07 AM by [[~jrmu]]: [==]%0a* [[Oidentd.ZNC]] . . . February 28, 2023, at 02:34 AM by [[~jrmu]]: [==]%0a* [[Oidentd.Changeident]] . . . February 28, 2023, at 02:33 AM by [[~jrmu]]: [=This was suggested by another author, but because the solution is not permanent, we move it to a sep=]%0a* [[Acme-client.Configure]] . . . February 26, 2023, at 10:06 PM by [[~jrmu]]: [=Revert as I'm not sure if /etc/daily.local is better=]%0a* [[Ircnow.Servers]] . . . February 26, 2023, at 05:42 PM by [[~Yonle]]: [=No.=]%0a* [[Stagit.Install]] . . . February 26, 2023, at 05:24 PM by [[~fossdev]]: [==]%0a* [[Openbsd.Gotweb]] . . . February 26, 2023, at 05:04 PM by [[~fossdev]]: [==]%0a* [[Got.Repo]] . . . February 26, 2023, at 05:02 PM by [[~fossdev]]: [==]%0a* [[Oidentd.Install]] . . . February 26, 2023, at 01:59 AM by [[~jrmu]]: [=Revert erroneous change=]%0a* [[Ircnow.Explorer]] . . . February 26, 2023, at 01:35 AM by [[~jrmu]]: [==]%0a* [[Ircnow.Codeforce]] . . . February 26, 2023, at 01:03 AM by [[~jrmu]]: [==]%0a* [[Donations.Donations]] . . . February 25, 2023, at 08:36 PM by [[~jrmu]]: [==]%0a* [[Main.HomePage]] . . . February 25, 2023, at 05:39 AM by [[~jrmu]]: [==]%0a* [[Vps.Vps]] . . . February 25, 2023, at 12:31 AM by [[~jrmu]]: [==]%0a* [[Botnow.Install]] . . . February 24, 2023, at 11:24 PM by [[~Naglfar]]: [=Add a list with new parameters=]%0a* [[Hardware.Ps2]] . . . February 24, 2023, at 04:26 PM by [[~mkf]]: [==]%0a* [[Bouncer.Bouncer]] . . . February 22, 2023, at 02:06 PM by [[~Yonle]]: [==]%0a* [[Ircnow.Minutemin]] . . . February 18, 2023, at 05:41 AM by [[~jrmu]]: [==]%0a* [[Ircnow.SSHFingerprints]] . . . February 17, 2023, at 05:39 PM by [[~jrmu]]: [==]%0a* [[Baytuch.Bio]] . . . February 17, 2023, at 12:00 PM by [[~baytuch]]: [==]%0a* [[Openhttpd.Configure]] . . . February 17, 2023, at 11:39 AM by [[~baytuch]]: [==]%0a* [[Openbsd.Plermoa]] . . . February 16, 2023, at 04:52 AM by [[~Yonle]]: [=Redirect=]%0a* [[Openbsd.Pleroma]] . . . February 12, 2023, at 02:49 AM by [[~Yonle]]: [=Oops=]%0a* [[Openbsd.Akkoma]] . . . February 12, 2023, at 02:48 AM by [[~Yonle]]: [=Oof=]%0a* [[Akkoma.Install]] . . . February 09, 2023, at 12:49 PM by [[~Yonle]]: [==]%0a* [[Google.Sins]] . . . February 08, 2023, at 05:13 AM by [[~Yonle]]: [==]%0a* [[Debate.Googledanger]] . . . February 08, 2023, at 05:01 AM by [[~Yonle]]: [==]%0a* [[Debate.Outreachkids]] . . . February 08, 2023, at 04:34 AM by [[~Yonle]]: [==]%0a* [[Openbsd.Mlmmj]] . . . February 08, 2023, at 02:50 AM by [[~Yonle]]: [==]%0a* [[Openbsd.Mosh]] . . . February 07, 2023, at 11:30 AM by [[~Yonle]]: [==]%0a* [[Shelllabs.Reading]] . . . February 07, 2023, at 02:06 AM by [[~jrmu]]: [==]%0a* [[Squirrelmail.Install]] . . . February 06, 2023, at 09:24 PM by [[~Naglfar]]: [=Add snapshot download reference=]%0a* [[Route.Usage]] . . . February 06, 2023, at 02:38 PM by [[~mkf]]: [==]%0a* [[Mkf.Wikiv1]] . . . February 06, 2023, at 02:31 PM by [[~mkf]]: [==]%0a* [[Psybnc.Install]] . . . February 06, 2023, at 02:31 PM by [[~mkf]]: [==]%0a* [[Debate.Openweb]] . . . February 06, 2023, at 02:15 PM by [[~Yonle]]: [==]%0a* [[Debate.Youtubedanger]] . . . February 06, 2023, at 02:10 PM by [[~Yonle]]: [==]%0a* [[Debate.Providers]] . . . February 06, 2023, at 01:41 PM by [[~Yonle]]: [==]%0a* [[Paster.Install]] . . . February 06, 2023, at 10:22 AM by [[~mkf]]: [==]%0a* [[Anope.Install]] . . . February 06, 2023, at 09:46 AM by [[~mkf]]: [==]%0a* [[9.Drawterm]] . . . February 05, 2023, at 09:18 PM by [[~mkf]]: [==]%0a* [[Znc.Chroot]] . . . February 04, 2023, at 04:45 PM by [[~Francis]]: [==]%0a* [[Password.Hashes]] . . . February 04, 2023, at 07:27 AM by [[~izzyb]]: [=formatting fixes=]%0a* [[Chess.Chessgogi]] . . . February 04, 2023, at 03:49 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Passwords]] . . . February 03, 2023, at 07:49 PM by [[~izzyb]]: [==]%0a* [[Password.Management]] . . . February 03, 2023, at 07:44 PM by [[~izzyb]]: [==]%0a* [[DNS.Ipv4rDNS]] . . . February 01, 2023, at 08:31 PM by [[~izzyb]]: [=added note to clarify what address needs to be specified.=]%0a* [[Dovecot.SharedMailboxes]] . . . January 31, 2023, at 08:29 PM by [[~izzyb]]: [==]%0a* [[Dovecot.SharedFolders]] . . . January 31, 2023, at 06:03 AM by [[~izzyb]]: [=renaming to sharedMailboxes=]%0a* [[Soju.Install]] . . . January 24, 2023, at 11:29 AM by [[~mkf]]: [=minor changes on style=]%0a* [[Lilywhitebot.Install]] . . . January 24, 2023, at 11:23 AM by [[~mkf]]: [==]%0a* [[SendMoneyToSplinter0616Outlook.Com]] . . . January 24, 2023, at 11:19 AM by [[~mkf]]: [==]%0a* [[9.9gridchan]] . . . January 22, 2023, at 07:01 AM by [[~jrmu]]: [==]%0a* [[Ircnow.Milestones]] . . . January 21, 2023, at 03:59 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Biboumi]] . . . January 20, 2023, at 08:11 PM by [[~mkf]]: [==]%0a* [[Biboumi.Install]] . . . January 20, 2023, at 08:10 PM by [[~mkf]]: [==]%0a* [[Texlive.Install]] . . . January 20, 2023, at 08:05 PM by [[~mkf]]: [==]%0a* [[Rcctl.Rcctl]] . . . January 20, 2023, at 08:00 PM by [[~mkf]]: [==]%0a* [[Vmm.Configure]] . . . January 20, 2023, at 07:59 PM by [[~mkf]]: [==]%0a* [[Hopm.Install]] . . . January 20, 2023, at 07:32 PM by [[~mkf]]: [==]%0a* [[Openbsd.Unrealircd]] . . . January 20, 2023, at 07:27 PM by [[~mkf]]: [==]%0a* [[Unrealircd.Install]] . . . January 20, 2023, at 07:24 PM by [[~mkf]]: [==]%0a* [[Pleroma.Install]] . . . January 20, 2023, at 07:18 PM by [[~mkf]]: [==]%0a* [[Gomuks.Install]] . . . January 20, 2023, at 07:08 PM by [[~mkf]]: [==]%0a* [[Gotweb.Install]] . . . January 20, 2023, at 07:02 PM by [[~mkf]]: [==]%0a* [[Webnews.Install]] . . . January 20, 2023, at 06:57 PM by [[~mkf]]: [==]%0a* [[Php.Install]] . . . January 20, 2023, at 06:52 PM by [[~mkf]]: [==]%0a* [[Mlmmj.Install]] . . . January 20, 2023, at 06:48 PM by [[~mkf]]: [==]%0a* [[Fiche.Install]] . . . January 20, 2023, at 06:44 PM by [[~mkf]]: [==]%0a* [[Prosody.Install]] . . . January 20, 2023, at 06:42 PM by [[~mkf]]: [==]%0a* [[Bitlbee.Install]] . . . January 20, 2023, at 06:36 PM by [[~mkf]]: [==]%0a* [[TigerVNC.Install]] . . . January 20, 2023, at 06:30 PM by [[~mkf]]: [==]%0a* [[NodeJS.Install]] . . . January 20, 2023, at 06:27 PM by [[~mkf]]: [==]%0a* [[Pmwiki.Install]] . . . January 20, 2023, at 06:19 PM by [[~mkf]]: [==]%0a* [[Xfce.Install]] . . . January 20, 2023, at 06:17 PM by [[~mkf]]: [==]%0a* [[Ngircd.Install]] . . . January 20, 2023, at 06:08 PM by [[~mkf]]: [==]%0a* [[Openbsd.Vipw]] . . . January 18, 2023, at 11:01 PM by [[~zen]]: [=added two spaces=]%0a* [[Grep.Usage]] . . . January 18, 2023, at 10:54 PM by [[~zen]]: [==]%0a* [[Openbsd.Loginconf]] . . . January 18, 2023, at 10:48 PM by [[~zen]]: [=OpenBSD FAQ link refenrece=]%0a* [[Openbsd.Singleuser]] . . . January 18, 2023, at 10:26 PM by [[~zen]]: [=changed the link reference=]%0a* [[Ssh.Fingerprints]] . . . January 14, 2023, at 04:31 PM by [[~izzyb]]: [=added link to ircnow network ssh fingerprints as example.=]%0a* [[Team.Networks]] . . . January 12, 2023, at 06:36 PM by [[~kilroy]]: [=Updated Sturtz IRC=]%0a* [[Openbsd.Dump]] . . . January 10, 2023, at 04:48 PM by [[~mkf]]: [=add -u, improve dump-ssh funcationality.=]%0a* [[Znc.Install]] . . . January 07, 2023, at 11:58 PM by [[~jrmu]]: [==]%0a* [[Jrmu.Bio]] . . . January 05, 2023, at 07:23 PM by [[~jrmu]]: [==]%0a* [[Rspamd.Configure]] . . . January 03, 2023, at 04:55 PM by [[~mkf]]: [==]%0a* [[Eggdrop191.Install]] . . . December 31, 2022, at 05:29 PM by [[~Yonle]]: [==]%0a* [[Dovecot.Pigeonhole]] . . . December 30, 2022, at 04:24 PM by [[~mkf]]: [=style 2=]%0a* [[Openbsd.Quota]] . . . December 29, 2022, at 06:51 PM by [[~mkf]]: [==]%0a* [[Minutemin.Bootcamp]] . . . December 29, 2022, at 04:38 PM by [[~mkf]]: [==]%0a* [[Profiles.Miniontoby]] . . . December 26, 2022, at 07:26 PM by [[~miniontoby]]: [=Created=]%0a* [[Minetest.Minetest]] . . . December 26, 2022, at 07:25 PM by [[~miniontoby]]: [=Added building guide link=]%0a* [[Openbsd.Minetest]] . . . December 26, 2022, at 07:23 PM by [[~miniontoby]]: [=Added more ways to install=]%0a* [[Splinter0616Outlook.Com]] . . . December 25, 2022, at 02:37 AM by [[~SplinTer]]: [==]%0a* [[Ngircd.Oper]] . . . December 25, 2022, at 12:03 AM by [[~forero]]: [==]%0a* [[Profiles.Yonle]] . . . December 24, 2022, at 03:29 PM by [[~Yonle]]: [==]%0a* [[Openbsd.Honk]] . . . December 17, 2022, at 08:45 AM by [[~Yonle]]: [==]%0a* [[Yonle.Bio]] . . . December 13, 2022, at 05:18 PM by [[~Yonle]]: [==]%0a* [[Camping.Gear]] . . . December 12, 2022, at 04:39 AM by [[~jrmu]]: [==]%0a* [[Vhost.Vhost]] . . . December 12, 2022, at 03:36 AM by [[~xfnw]]: [==]%0a* [[Vhost.Ircnow]] . . . December 12, 2022, at 03:13 AM by [[~xfnw]]: [=ircfree.com is not an ircnow domain=]%0a* [[Shelllabs.Openaccess]] . . . December 08, 2022, at 10:02 PM by [[~redrum88]]: [==]%0a* [[I2Pd.Install]] . . . December 07, 2022, at 01:16 AM by [[~Yonle]]: [=Again not 7070=]%0a* [[I2Pd.Tunnels]] . . . December 06, 2022, at 02:52 PM by [[~Yonle]]: [=There we go. =]%0a* [[I2pd.Tunnels]] . . . December 06, 2022, at 02:45 PM by [[~Yonle]]: [==]%0a* [[Unbound.Configure]] . . . December 04, 2022, at 03:59 AM by [[~Yonle]]: [==]%0a* [[Profiles.Xfnw]] . . . November 28, 2022, at 10:38 PM by [[~xfnw]]: [=add pgp keys=]%0a* [[Unwind.Configure]] . . . November 26, 2022, at 09:23 PM by [[~akoizumi]]: [=add unwind=]%0a* [[Openbsd.Icecast]] . . . November 17, 2022, at 11:35 AM by [[~Yonle]]: [==]%0a* [[Debian.Install]] . . . November 13, 2022, at 11:43 AM by [[~suzerain]]: [=writing=]%0a* [[Lemon.Lemon]] . . . November 10, 2022, at 01:48 PM by [[~mkf]]: [==]%0a* [[Bouncer.JmIRC]] . . . November 04, 2022, at 06:18 PM by [[~baytuch]]: [=Added screenshots about setup=]%0a* [[Ambassador.Ilines]] . . . October 22, 2022, at 04:40 AM by [[~jrmu]]: [==]%0a* [[Bouncer.XChat]] . . . October 16, 2022, at 11:09 PM by [[~xfnw]]: [=XChat is unmaintained=]%0a* [[Eggdrop.VHost]] . . . October 02, 2022, at 01:05 PM by [[~sulieztya]]: [==]%0a* [[Eggdrop.VhostTCL]] . . . October 02, 2022, at 07:06 AM by [[~sulieztya]]: [==]%0a* [[Eggdrop.BotZNC]] . . . October 02, 2022, at 01:29 AM by [[~sulieztya]]: [==]%0a* [[Shelllabs.Intro]] . . . September 28, 2022, at 06:53 PM by [[~jrmu]]: [==]%0a* [[He.IPv6Certification]] . . . September 16, 2022, at 05:32 PM by [[~xfnw]]: [=create page=]%0a* [[Shelllabs.Education]] . . . September 14, 2022, at 07:30 PM by [[~jrmu]]: [==]%0a* [[About.AboutUs]] . . . September 13, 2022, at 06:42 PM by [[~zleap]]: [==]%0a* [[Site.SideBar]] . . . September 13, 2022, at 06:21 PM by [[~jrmu]]: [==]%0a* [[LegalAndSafety.LegalAndSafety]] . . . September 13, 2022, at 05:19 PM by [[~zleap]]: [==]%0a* [[LegalAndSafety.LegalAmpSafety]] . . . September 13, 2022, at 05:17 PM by [[~zleap]]: [==]%0a* [[LegalAmpSafety.Subheading]] . . . September 13, 2022, at 05:15 PM by [[~zleap]]: [==]%0a* [[Acmesh.Configure]] . . . September 11, 2022, at 06:03 PM by [[~akoizumi]]: [=Added acme.sh (currently a WIP)=]%0a* [[Dehydrated.Configure]] . . . September 11, 2022, at 02:52 PM by [[~akoizumi]]: [=Add dehydrated=]%0a* [[Profiles.Izzyb]] . . . September 11, 2022, at 06:28 AM by [[~izzyb]]: [==]%0a* [[Site.EditForm]] . . . September 11, 2022, at 06:22 AM by [[~izzyb]]: [=Make Author none editable field=]%0a* [[Netcat.Irc]] . . . September 11, 2022, at 04:21 AM by [[~izzyb]]: [=Removed info about PASS - moving to different doc as per jrmu request=]%0a* [[Openbsd.Geomyidae]] . . . September 10, 2022, at 02:31 AM by [[~akoizumi]]: [==]%0a* [[Openbsd.INN]] . . . September 10, 2022, at 02:23 AM by [[~akoizumi]]: [=Fix some types=]%0a* [[Ngircd.Loginconf]] . . . September 10, 2022, at 01:51 AM by [[~jrmu]]: [==]%0a* [[Heading.Subheading]] . . . September 07, 2022, at 07:23 PM by [[~zleap]]: [==]%0a* [[Eggdrop193.Install]] . . . September 07, 2022, at 04:48 PM by [[~jrmu]]: [==]%0a* [[Letsencrypt.Expired]] . . . September 06, 2022, at 12:00 AM by [[~xfnw]]: [=be less misleading about Let's Encrypt's reasoning for keeping the expired chain=]%0a* [[Ircnow.Pioneer]] . . . August 14, 2022, at 05:06 AM by [[~jrmu]]: [==]%0a* [[Openbsd.VsFTP]] . . . August 10, 2022, at 03:18 PM by [[~mkf]]: [=snipped unneeded output=]%0a* [[C.Scanf]] . . . August 10, 2022, at 09:51 AM by [[~mkf]]: [==]%0a* [[Vmm.Install]] . . . August 10, 2022, at 08:05 AM by [[~miniontoby]]: [=coconut to host=]%0a* [[Orange.CertsReissue]] . . . August 08, 2022, at 05:35 AM by [[~baytuch]]: [==]%0a* [[Team.Security]] . . . August 08, 2022, at 12:53 AM by [[~jrmu]]: [==]%0a* [[Netcat.Usage]] . . . August 04, 2022, at 01:12 AM by [[~tiramisu]]: [==]%0a* [[Freedom.Universal]] . . . August 03, 2022, at 06:33 PM by [[~jrmu]]: [==]%0a* [[Pgp.Upload]] . . . August 01, 2022, at 01:21 PM by [[~jan6]]: [=keys.openpgp.org uses a superior implementation, less vulnerable to various issues=]%0a* [[Lemon.Packages]] . . . July 30, 2022, at 07:52 PM by [[~mkf]]: [==]%0a* [[Netizen.Ellisisland]] . . . July 27, 2022, at 07:05 PM by [[~jrmu]]: [==]%0a* [[Ircnow.Newdeal]] . . . July 27, 2022, at 06:55 PM by [[~jrmu]]: [==]%0a* [[Ircnow.Daughtersofliberty]] . . . July 27, 2022, at 06:45 PM by [[~jrmu]]: [==]%0a* [[Ircnow.Womenstem]] . . . July 21, 2022, at 05:59 PM by [[~jrmu]]: [==]%0a* [[Eggdrop.RC]] . . . July 20, 2022, at 06:55 PM by [[~baytuch]]: [==]%0a* [[Opensmtpd.Troubleshoot]] . . . July 20, 2022, at 03:58 PM by [[~jlj]]: [=Added notes about how I resolved the first two errors, on nastycode=]%0a* [[Eggdrop.Nickserv]] . . . July 19, 2022, at 10:05 AM by [[~baytuch]]: [==]%0a* [[Chroot.Intro]] . . . July 18, 2022, at 04:23 PM by [[~mkf]]: [==]%0a* [[Ircnow.Media]] . . . July 15, 2022, at 05:54 AM by [[~jrmu]]: [==]%0a* [[Iked.Linuxstrongswan]] . . . July 03, 2022, at 11:29 PM by [[~jrmu]]: [==]%0a* [[Acme-client.AutoRenew]] . . . July 03, 2022, at 11:50 AM by [[~mkf]]: [==]%0a* [[Openbsd.Apmd]] . . . July 03, 2022, at 11:36 AM by [[~mkf]]: [==]%0a* [[Opensmtpd.Test]] . . . July 03, 2022, at 11:13 AM by [[~mkf]]: [==]%0a* [[Ircnow.Roadmap2022]] . . . July 03, 2022, at 11:04 AM by [[~mkf]]: [==]%0a* [[Iked.Android]] . . . July 01, 2022, at 12:14 AM by [[~jrmu]]: [==]%0a* [[Vpn.Myipaddress]] . . . June 30, 2022, at 09:51 PM by [[~jrmu]]: [==]%0a* [[Olympics.Games]] . . . June 27, 2022, at 10:42 PM by [[~jrmu]]: [==]%0a* [[Iked.Configure]] . . . June 25, 2022, at 02:28 PM by [[~jrmu]]: [==]%0a* [[Unbound.Blacklists]] . . . June 25, 2022, at 06:02 AM by [[~jrmu]]: [==]%0a* [[Iked.Linux]] . . . June 23, 2022, at 07:10 AM by [[~jrmu]]: [==]%0a* [[Vpn.Vpn]] . . . June 23, 2022, at 06:42 AM by [[~jrmu]]: [==]%0a* [[Ircnow.Nsf]] . . . June 20, 2022, at 05:05 PM by [[~jrmu]]: [==]%0a* [[Debate.Debate]] . . . June 19, 2022, at 04:12 PM by [[~jrmu]]: [==]%0a* [[Ircnow.Metrics]] . . . June 19, 2022, at 04:12 PM by [[~jrmu]]: [==]%0a* [[Nsd.Masterslave]] . . . June 19, 2022, at 06:34 AM by [[~jrmu]]: [==]%0a* [[Dns.Overview]] . . . June 19, 2022, at 05:45 AM by [[~jrmu]]: [==]%0a* [[Dns.Records]] . . . June 19, 2022, at 05:44 AM by [[~jrmu]]: [==]%0a* [[Syspatch.Syspatch]] . . . June 17, 2022, at 06:24 AM by [[~jrmu]]: [==]%0a* [[Tmux.Config]] . . . June 14, 2022, at 12:34 AM by [[~jrmu]]: [==]%0a* [[Vmm.Alpine]] . . . June 13, 2022, at 05:42 PM by [[~fossdev]]: [==]%0a* [[Team.Announce]] . . . June 13, 2022, at 03:52 PM by [[~jrmu]]: [==]%0a* [[Vmm.Arch]] . . . June 12, 2022, at 04:11 PM by [[~g1n]]: [=Added article about Arch Linux setup on VMM=]%0a* [[Znc.Patch]] . . . June 12, 2022, at 12:48 AM by [[~jrmu]]: [==]%0a* [[Unveil.Intro]] . . . June 12, 2022, at 12:40 AM by [[~jrmu]]: [==]%0a* [[Pledge.Intro]] . . . June 12, 2022, at 12:39 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Pkg]] . . . June 12, 2022, at 12:32 AM by [[~jrmu]]: [==]%0a* [[Doas.Configure]] . . . June 09, 2022, at 07:56 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Intro]] . . . June 09, 2022, at 07:53 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Bsdrd]] . . . June 09, 2022, at 07:17 AM by [[~jrmu]]: [==]%0a* [[Vnc.Vnc]] . . . June 08, 2022, at 04:04 PM by [[~miniontoby]]: [=Added RealVNC Viewer to the list (might need some more extra stuff, but yeah its fine)=]%0a* [[Unix101.Unix101]] . . . June 07, 2022, at 03:12 PM by [[~jrmu]]: [==]%0a* [[Openbsd.Sysupgrade71]] . . . June 05, 2022, at 11:49 PM by [[~jrmu]]: [==]%0a* [[Openbsd.Growfs]] . . . June 01, 2022, at 12:34 AM by [[~jrmu]]: [==]%0a* [[Team.Welcome]] . . . May 31, 2022, at 10:20 PM by [[~jrmu]]: [==]%0a* [[Hostnameif.Static-v2]] . . . May 23, 2022, at 06:29 AM by [[~theguest]]: [==]%0a* [[Hostnameif.Static]] . . . May 23, 2022, at 05:01 AM by [[~theguest]]: [==]%0a* [[Ircnow.Team]] . . . May 12, 2022, at 03:44 PM by [[~jrmu]]: [==]%0a* [[Grape.Minetest]] . . . May 10, 2022, at 10:48 AM by [[~baytuch]]: [==]%0a* [[Irc.Emoji]] . . . May 10, 2022, at 10:23 AM by [[~baytuch]]: [==]%0a* [[Openbsd.Nsd]] . . . May 10, 2022, at 12:33 AM by [[~jrmu]]: [==]%0a* [[Opsofliberty.Bootcamp]] . . . May 09, 2022, at 08:38 AM by [[~mkf]]: [==]%0a* [[Openbsd.Ports]] . . . May 09, 2022, at 05:54 AM by [[~mkf]]: [==]%0a* [[Openbsd.Rcctl]] . . . May 09, 2022, at 05:53 AM by [[~mkf]]: [==]%0a* [[Ngircd.Ssl]] . . . May 08, 2022, at 03:30 PM by [[~miniontoby]]: [=fixed the text=]%0a* [[Openbsd.Upgrade71]] . . . May 03, 2022, at 06:36 AM by [[~jrmu]]: [==]%0a* [[Codeforce.Training]] . . . May 03, 2022, at 03:02 AM by [[~jrmu]]: [==]%0a* [[Civics.Intro]] . . . May 03, 2022, at 01:06 AM by [[~jrmu]]: [==]%0a* [[OpenBSD.EdgeRouter-Lite]] . . . April 28, 2022, at 02:50 PM by [[~pufferf]]: [==]%0a* [[Math.Reading]] . . . April 27, 2022, at 08:23 PM by [[~jrmu]]: [==]%0a* [[Openbsd.Install71]] . . . April 24, 2022, at 09:55 PM by [[~jrmu]]: [==]%0a* [[Openbsd.Botnow]] . . . April 24, 2022, at 06:14 AM by [[~jrmu]]: [==]%0a* [[Buyvm.Ipv6]] . . . April 24, 2022, at 06:10 AM by [[~jrmu]]: [==]%0a* [[Eggdrop.Rss]] . . . April 23, 2022, at 04:20 PM by [[~jrmu]]: [==]%0a* [[Team.Testing]] . . . April 20, 2022, at 09:45 PM by [[~jrmu]]: [==]%0a* [[Dns.Registrars]] . . . April 20, 2022, at 09:30 PM by [[~jrmu]]: [==]%0a* [[Hosting.Providers]] . . . April 20, 2022, at 08:52 PM by [[~jrmu]]: [==]%0a* [[Openbsd.Gopher]] . . . April 20, 2022, at 08:29 PM by [[~jrmu]]: [==]%0a* [[Openbsd.Adduser]] . . . April 20, 2022, at 08:07 PM by [[~jrmu]]: [==]%0a* [[Signify.Verify]] . . . April 20, 2022, at 06:24 PM by [[~jrmu]]: [==]%0a* [[Almanack.Route]] . . . April 20, 2022, at 06:23 AM by [[~jrmu]]: [==]%0a* [[Ntpd.Configure]] . . . April 20, 2022, at 06:17 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Ntpd]] . . . April 20, 2022, at 06:16 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Vmmlinux]] . . . April 20, 2022, at 05:33 AM by [[~jrmu]]: [==]%0a* [[Vmm.Linux]] . . . April 20, 2022, at 05:33 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Iked]] . . . April 20, 2022, at 05:16 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Team]] . . . April 20, 2022, at 04:54 AM by [[~jrmu]]: [==]%0a* [[Ircnow.Networks]] . . . April 19, 2022, at 04:22 PM by [[~jrmu]]: [==]%0a* [[Openbsd.Announce]] . . . April 19, 2022, at 04:14 PM by [[~jrmu]]: [==]%0a* [[Ircnow.Ally]] . . . April 19, 2022, at 04:11 PM by [[~jrmu]]: [==]%0a* [[Openhttpd.Chroot]] . . . April 19, 2022, at 04:05 PM by [[~jrmu]]: [==]%0a* [[Openbsd.Install70]] . . . April 19, 2022, at 06:52 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Upgrade70]] . . . April 19, 2022, at 06:49 AM by [[~jrmu]]: [==]%0a* [[CodeForce.Bootcamp]] . . . April 19, 2022, at 06:29 AM by [[~jrmu]]: [==]%0a* [[Perl101.Perl101]] . . . April 19, 2022, at 06:15 AM by [[~jrmu]]: [==]%0a* [[Vmm.Vmm]] . . . April 15, 2022, at 12:20 PM by [[~Naglfar]]: [=Update: report from PiRATA=]%0a* [[Ngircd.Link]] . . . April 07, 2022, at 06:52 AM by [[~jrmu]]: [==]%0a* [[Minutemin.Minutemin]] . . . April 06, 2022, at 02:55 AM by [[~jrmu]]: [==]%0a* [[Openhttpd.CGI]] . . . April 05, 2022, at 04:22 PM by [[~gtlsgamr]]: [==]%0a* [[Openbsd.Censord]] . . . April 05, 2022, at 06:16 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Hopm]] . . . April 05, 2022, at 06:09 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Dns]] . . . April 05, 2022, at 05:24 AM by [[~jrmu]]: [==]%0a* [[Debate.Zncflaws]] . . . April 05, 2022, at 05:18 AM by [[~jrmu]]: [==]%0a* [[Debate.Debiandanger]] . . . April 04, 2022, at 04:30 AM by [[~jrmu]]: [==]%0a* [[Openhttpd.Tls]] . . . April 04, 2022, at 04:25 AM by [[~jrmu]]: [==]%0a* [[Openhttpd.Website]] . . . April 03, 2022, at 11:03 PM by [[~jrmu]]: [==]%0a* [[Soju.Guide]] . . . April 02, 2022, at 03:46 PM by [[~Yonle]]: [==]%0a* [[Nitter.Install]] . . . April 02, 2022, at 01:08 AM by [[~fallback]]: [=first nitter install page=]%0a* [[Debiankaios.Bio]] . . . April 01, 2022, at 05:10 PM by [[~debiankaios]]: [==]%0a* [[Openbsd.Psybnc]] . . . March 30, 2022, at 09:56 PM by [[~jrmu]]: [==]%0a* [[Sshd.Disablepassword]] . . . March 30, 2022, at 08:27 PM by [[~xfnw]]: [=undo accidental revert=]%0a* [[Tor.Irc]] . . . March 30, 2022, at 12:40 PM by [[~m16]]: [==]%0a* [[Chess.Reading]] . . . March 29, 2022, at 10:02 PM by [[~jrmu]]: [==]%0a* [[Linux.Reading]] . . . March 29, 2022, at 03:31 PM by [[~jrmu]]: [==]%0a* [[Unix.Reading]] . . . March 28, 2022, at 03:24 PM by [[~jrmu]]: [==]%0a* [[Irc.Services]] . . . March 25, 2022, at 04:29 AM by [[~jrmu]]: [==]%0a* [[Syslogd.Configure]] . . . March 25, 2022, at 04:07 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Ddos]] . . . March 24, 2022, at 04:22 PM by [[~jrmu]]: [==]%0a* [[Ddos.Intro]] . . . March 24, 2022, at 04:22 PM by [[~jrmu]]: [==]%0a* [[Bouncer.ZNC]] . . . March 19, 2022, at 07:31 AM by [[~fallback]]: [==]%0a* [[ISCABBS.DownloadingAndInstalling]] . . . March 15, 2022, at 10:42 PM by [[~Mandarax]]: [==]%0a* [[ISCABBS.ISCABBS]] . . . March 15, 2022, at 09:24 PM by [[~Mandarax]]: [==]%0a* [[Unix.History]] . . . March 14, 2022, at 06:07 PM by [[~jrmu]]: [==]%0a* [[Unix.Exhibit]] . . . March 13, 2022, at 11:37 PM by [[~jrmu]]: [==]%0a* [[Debate.Dogfooding]] . . . March 10, 2022, at 05:14 AM by [[~jrmu]]: [==]%0a* [[Irc.Easy]] . . . March 05, 2022, at 08:56 PM by [[~jrmu]]: [==]%0a* [[Doxing.Defense]] . . . March 05, 2022, at 08:54 PM by [[~jrmu]]: [==]%0a* [[Mlmmj-archivist.Install]] . . . March 03, 2022, at 05:26 AM by [[~error]]: [==]%0a* [[Openbsd.IRCBridge]] . . . February 28, 2022, at 02:59 AM by [[~suzerain]]: [==]%0a* [[Unix101.Vi]] . . . February 27, 2022, at 08:16 PM by [[~jrmu]]: [==]%0a* [[Vi.Intro]] . . . February 27, 2022, at 04:16 PM by [[~Limits]]: [=Add Introduction to Vi=]%0a* [[Irc201.Irc201]] . . . February 27, 2022, at 04:21 AM by [[~suzerain]]: [==]%0a* [[9.Ideas]] . . . February 23, 2022, at 05:19 PM by [[~mkf]]: [==]%0a* [[Main.WikiSandbox]] . . . February 22, 2022, at 11:05 PM by [[~mkf]]: [==]%0a* [[Openhttpd.Perl]] . . . February 21, 2022, at 07:18 AM by [[~Naglfar]]: [==]%0a* [[Openbsd.Wesnothd]] . . . February 21, 2022, at 06:28 AM by [[~mkf]]: [=Wesnothd=]%0a* [[9.Audio]] . . . February 20, 2022, at 08:07 PM by [[~jrmu]]: [==]%0a* [[Cloud9p.Roadmap]] . . . February 20, 2022, at 06:54 PM by [[~xfnw]]: [==]%0a* [[Openbsd.Xonotic]] . . . February 20, 2022, at 07:43 AM by [[~mkf]]: [=A xonotic server has apperad! pt.2=]%0a* [[Bouncer.Irssi]] . . . February 16, 2022, at 06:26 PM by [[~izzyb]]: [=clarified wording in example=]%0a* [[PuTTY.PuTTYgen]] . . . February 16, 2022, at 05:24 AM by [[~jrmu]]: [==]%0a* [[Rcd.Configure]] . . . February 15, 2022, at 04:46 PM by [[~xfnw]]: [=fix title formatting=]%0a* [[Debate.Ircnowd]] . . . February 14, 2022, at 06:24 PM by [[~jrmu]]: [==]%0a* [[Stopm.Stopm]] . . . February 14, 2022, at 06:16 PM by [[~jrmu]]: [==]%0a* [[Police.Fingerprints]] . . . February 12, 2022, at 02:09 PM by [[~xfnw]]: [=ip addresses should be sorted with sort -V=]%0a* [[Openbsd.Police]] . . . February 10, 2022, at 07:36 PM by [[~jrmu]]: [==]%0a* [[Dns.Dns]] . . . February 10, 2022, at 07:39 AM by [[~nixdork]]: [=Fix typo=]%0a* [[Dns.BindResolver]] . . . February 10, 2022, at 07:30 AM by [[~nixdork]]: [=First draft of bind resolver howto=]%0a* [[Botnow.SqliteViews]] . . . February 10, 2022, at 02:00 AM by [[~xfnw]]: [==]%0a* [[Relayd.TLSMulti]] . . . February 08, 2022, at 06:45 AM by [[~Naglfar]]: [=Fix listening port for https=]%0a* [[Relayd.Acceleration]] . . . February 08, 2022, at 06:27 AM by [[~Naglfar]]: [=Fix: https forwarding port=]%0a* [[AncientWisdom.Bio]] . . . February 07, 2022, at 01:18 PM by [[~AncientWisdom]]: [==]%0a* [[Minutemin.Questions]] . . . February 05, 2022, at 09:16 AM by [[~jrmu]]: [==]%0a* [[Minutemin.Server]] . . . February 05, 2022, at 08:14 AM by [[~jrmu]]: [==]%0a* [[Vmm.SlackwareIso]] . . . February 03, 2022, at 10:53 PM by [[~Naglfar]]: [=Slackware 15.0 x86 stable is released=]%0a* [[Vmctl.Usage]] . . . February 03, 2022, at 06:24 PM by [[~miniontoby]]: [=fixed attachment=]%0a* [[Duplicity.Usage]] . . . February 02, 2022, at 10:31 AM by [[~jrmu]]: [==]%0a* [[Openssl.Encryptfile]] . . . February 02, 2022, at 09:29 AM by [[~jrmu]]: [==]%0a* [[Bots.Basicbot]] . . . January 31, 2022, at 08:54 PM by [[~izzyb]]: [==]%0a* [[Dovecot.Install]] . . . January 29, 2022, at 09:35 PM by [[~forero]]: [=comment out=]%0a* [[Openrsync.Usage]] . . . January 29, 2022, at 09:04 AM by [[~Naglfar]]: [=update from rsync to openrsync=]%0a* [[Openbsd.Tcpip]] . . . January 24, 2022, at 05:45 PM by [[~jrmu]]: [==]%0a* [[Synclient.Configure]] . . . January 24, 2022, at 06:02 AM by [[~jrmu]]: [==]%0a* [[Crontab.Edit]] . . . January 23, 2022, at 05:46 PM by [[~mkf]]: [==]%0a* [[9.Install]] . . . January 22, 2022, at 06:57 AM by [[~mkf]]: [==]%0a* [[Asterisk.Install]] . . . January 19, 2022, at 05:34 AM by [[~jrmu]]: [==]%0a* [[9.Rcpu]] . . . January 17, 2022, at 10:19 PM by [[~jrmu]]: [==]%0a* [[9.9p]] . . . January 17, 2022, at 08:47 PM by [[~mkf]]: [==]%0a* [[9.Ndb]] . . . January 16, 2022, at 06:46 PM by [[~mkf]]: [==]%0a* [[Openbsd.U9fs]] . . . January 16, 2022, at 06:23 PM by [[~mkf]]: [==]%0a* [[Dns.FQDN]] . . . January 15, 2022, at 10:16 PM by [[~jrmu]]: [==]%0a* [[Pgp.Create]] . . . January 14, 2022, at 09:14 AM by [[~baytuch]]: [==]%0a* [[Nsd.DNSSec]] . . . January 14, 2022, at 02:53 AM by [[~pyr3x]]: [==]%0a* [[Openbsd.Locale]] . . . January 12, 2022, at 01:23 PM by [[~baytuch]]: [==]%0a* [[Openbsd.Openbsd]] . . . January 12, 2022, at 01:19 PM by [[~baytuch]]: [==]%0a* [[Ksh.Autocomplete]] . . . January 11, 2022, at 01:44 PM by [[~miniontoby]]: [=updated url=]%0a* [[Gpg.Verify]] . . . January 08, 2022, at 09:48 PM by [[~Naglfar]]: [=Add description=]%0a* [[Mlmmj.Archive]] . . . January 06, 2022, at 10:52 PM by [[~Hawk]]: [==]%0a* [[9.Hostowner]] . . . January 06, 2022, at 11:29 AM by [[~mkf]]: [==]%0a* [[Ircnow.Dogfood]] . . . January 06, 2022, at 08:48 AM by [[~jrmu]]: [==]%0a* [[9.Authsrv]] . . . January 05, 2022, at 04:59 AM by [[~mkf]]: [=hmm=]%0a* [[9.Chording]] . . . January 03, 2022, at 02:40 PM by [[~jrmu]]: [==]%0a* [[Ircnow.Status]] . . . January 03, 2022, at 06:06 AM by [[~jrmu]]: [==]%0a* [[Openbsd.BBB]] . . . January 03, 2022, at 12:06 AM by [[~jrmu]]: [==]%0a* [[Got.Server]] . . . January 02, 2022, at 05:42 PM by [[~jrmu]]: [==]%0a* [[Census.Census]] . . . January 02, 2022, at 11:27 AM by [[~jrmu]]: [==]%0a* [[Bncnow.Bncnow]] . . . January 02, 2022, at 11:18 AM by [[~jrmu]]: [==]%0a* [[Ircnow.Projects]] . . . January 02, 2022, at 11:09 AM by [[~jrmu]]: [==]%0a* [[Ircfs.Intro]] . . . January 02, 2022, at 10:49 AM by [[~jrmu]]: [==]%0a* [[Ircnowd.Ircnowd]] . . . January 02, 2022, at 06:32 AM by [[~jrmu]]: [==]%0a* [[Marketing.Marketing]] . . . January 02, 2022, at 06:20 AM by [[~jrmu]]: [==]%0a* [[Ircnow.Sonsofliberty]] . . . January 02, 2022, at 06:06 AM by [[~jrmu]]: [==]%0a* [[Pkgadd.CheckUpdates]] . . . January 01, 2022, at 04:29 AM by [[~pyr3x]]: [==]%0a* [[Ircnow.Roadmap2021]] . . . December 30, 2021, at 06:31 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Sftp]] . . . December 30, 2021, at 06:01 AM by [[~jrmu]]: [==]%0a* [[Sftp.Chroot]] . . . December 30, 2021, at 06:01 AM by [[~jrmu]]: [==]%0a* [[Ircnow.Status2022]] . . . December 30, 2021, at 05:35 AM by [[~jrmu]]: [==]%0a* [[Eggdrop.UTF8]] . . . December 28, 2021, at 08:21 PM by [[~jrmu]]: [==]%0a* [[Openbsd.Uim]] . . . December 26, 2021, at 01:45 AM by [[~jrmu]]: [==]%0a* [[Sshwifty.Install]] . . . December 23, 2021, at 02:49 PM by [[~miniontoby]]: [=created=]%0a* [[Nsd.Zone]] . . . December 23, 2021, at 10:33 AM by [[~jrmu]]: [==]%0a* [[Openhttpd.Hosting]] . . . December 23, 2021, at 03:06 AM by [[~jrmu]]: [==]%0a* [[OpenSSH.RSAkeys]] . . . December 22, 2021, at 03:18 PM by [[~miniontoby]]: [==]%0a* [[Openbsd.Wifi]] . . . December 22, 2021, at 02:59 PM by [[~jrmu]]: [==]%0a* [[Openbsd.Recordaudio]] . . . December 22, 2021, at 01:24 PM by [[~jrmu]]: [==]%0a* [[9.9]] . . . December 22, 2021, at 11:30 AM by [[~xfnw]]: [=fix some grammatical errors=]%0a* [[Parec.Record]] . . . December 22, 2021, at 07:02 AM by [[~jrmu]]: [==]%0a* [[Sox.Concat]] . . . December 22, 2021, at 07:01 AM by [[~jrmu]]: [==]%0a* [[Ffmpeg.Recordscreen]] . . . December 22, 2021, at 07:00 AM by [[~jrmu]]: [==]%0a* [[JuiceSSH.Connect]] . . . December 20, 2021, at 01:03 PM by [[~jrmu]]: [==]%0a* [[Marketing.Memes]] . . . December 20, 2021, at 12:55 PM by [[~jrmu]]: [==]%0a* [[9.Independent]] . . . December 20, 2021, at 12:47 PM by [[~jrmu]]: [==]%0a* [[MacScreenSharing.Connect]] . . . December 20, 2021, at 11:57 AM by [[~jrmu]]: [==]%0a* [[9.Partdisk]] . . . December 20, 2021, at 11:39 AM by [[~jrmu]]: [==]%0a* [[Got.Usage]] . . . December 17, 2021, at 04:44 PM by [[~jrmu]]: [==]%0a* [[Irc.Federation]] . . . December 17, 2021, at 02:03 PM by [[~jrmu]]: [==]%0a* [[Irc.Chanop]] . . . December 14, 2021, at 04:58 AM by [[~mkf]]: [==]%0a* [[9.Todo]] . . . December 03, 2021, at 07:52 PM by [[~mkf]]: [==]%0a* [[Pylink.Chroot]] . . . December 02, 2021, at 02:03 PM by [[~jrmu]]: [==]%0a* [[Pylink.Install]] . . . December 02, 2021, at 02:02 PM by [[~jrmu]]: [==]%0a* [[Jrmu.Marriage]] . . . December 02, 2021, at 06:09 AM by [[~jrmu]]: [==]%0a* [[Hosting.Hosting]] . . . December 01, 2021, at 02:01 PM by [[~jrmu]]: [==]%0a* [[Mc.Usage]] . . . November 29, 2021, at 07:53 PM by [[~mkf]]: [==]%0a* [[PuTTY.Connect]] . . . November 29, 2021, at 12:13 PM by [[~jrmu]]: [==]%0a* [[Email.Email]] . . . November 29, 2021, at 04:19 AM by [[~mkf]]: [==]%0a* [[Texlive.Sinhala]] . . . November 28, 2021, at 06:35 AM by [[~jrmu]]: [==]%0a* [[MailWindows.Connect]] . . . November 27, 2021, at 03:12 PM by [[~jrmu]]: [==]%0a* [[Gajim.Biboumi]] . . . November 27, 2021, at 01:02 PM by [[~jrmu]]: [==]%0a* [[Xmpp.Xmpp]] . . . November 27, 2021, at 12:33 PM by [[~jrmu]]: [==]%0a* [[Mcabber.Connect]] . . . November 26, 2021, at 01:38 PM by [[~jrmu]]: [==]%0a* [[ChatSecure.Connect]] . . . November 26, 2021, at 11:36 AM by [[~jrmu]]: [==]%0a* [[9.9pfs]] . . . November 24, 2021, at 02:00 PM by [[~mkf]]: [==]%0a* [[Vmm.DebianInstall]] . . . November 24, 2021, at 11:44 AM by [[~nicoz]]: [==]%0a* [[Siskin.Connect]] . . . November 23, 2021, at 04:38 PM by [[~jrmu]]: [==]%0a* [[Dino.Connect]] . . . November 23, 2021, at 02:10 PM by [[~mkf]]: [==]%0a* [[Monal.Connect]] . . . November 23, 2021, at 10:32 AM by [[~jrmu]]: [==]%0a* [[Xabber.Connect]] . . . November 23, 2021, at 10:20 AM by [[~jrmu]]: [==]%0a* [[DNS.DMARC]] . . . November 22, 2021, at 10:52 PM by [[~Hawk]]: [==]%0a* [[StorkIM.Connect]] . . . November 21, 2021, at 05:03 AM by [[~jrmu]]: [==]%0a* [[Conversations.Connect]] . . . November 20, 2021, at 05:37 PM by [[~jrmu]]: [==]%0a* [[Yaxim.Connect]] . . . November 20, 2021, at 05:09 PM by [[~jrmu]]: [==]%0a* [[Adium.Connect]] . . . November 20, 2021, at 07:32 AM by [[~jrmu]]: [==]%0a* [[Vmm.AlmaLinux]] . . . November 20, 2021, at 06:47 AM by [[~dodocrypto]]: [==]%0a* [[Vmm.DebianIso]] . . . November 19, 2021, at 09:35 PM by [[~nicoz]]: [==]%0a* [[Psi.Connect]] . . . November 17, 2021, at 03:23 PM by [[~jrmu]]: [==]%0a* [[Pidgin.Connect]] . . . November 17, 2021, at 10:18 AM by [[~jrmu]]: [==]%0a* [[Gajim.Connect]] . . . November 17, 2021, at 08:01 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Training]] . . . November 16, 2021, at 03:30 PM by [[~Hawk]]: [==]%0a* [[Opera.Connect]] . . . November 16, 2021, at 12:12 AM by [[~wiz]]: [==]%0a* [[0dev.0dev]] . . . November 12, 2021, at 03:00 AM by [[~dodocrypto]]: [==]%0a* [[Vmm.RockyLinux]] . . . November 11, 2021, at 10:51 AM by [[~dodocrypto]]: [==]%0a* [[Opensmtpd.Openrelay]] . . . November 11, 2021, at 10:37 AM by [[~mkf]]: [==]%0a* [[Sandbox.0dev]] . . . November 11, 2021, at 01:45 AM by [[~dodocrypto]]: [==]%0a* [[Nsd.Configure]] . . . November 10, 2021, at 11:58 AM by [[~Hawk]]: [==]%0a* [[Got.Mirror]] . . . November 07, 2021, at 05:22 PM by [[~jrmu]]: [==]%0a* [[Vpn.OpenIKED]] . . . November 07, 2021, at 03:45 PM by [[~gloNO]]: [==]%0a* [[Openbsd.Got]] . . . November 07, 2021, at 03:16 PM by [[~jrmu]]: [==]%0a* [[Ircnow.Opsofliberty]] . . . November 06, 2021, at 05:15 PM by [[~jrmu]]: [==]%0a* [[Emacs.Emacs]] . . . November 06, 2021, at 04:39 PM by [[~LohanG]]: [==]%0a* [[ZNC.Support]] . . . November 06, 2021, at 03:53 PM by [[~LohanG]]: [=added libera=]%0a* [[Vmm.Plan9]] . . . November 05, 2021, at 09:31 PM by [[~mkf]]: [=???=]%0a* [[9.Stone]] . . . November 04, 2021, at 04:09 PM by [[~meeekeeef]]: [==]%0a* [[9.Zuke]] . . . November 04, 2021, at 04:01 PM by [[~meeekeeef]]: [==]%0a* [[Openbsd.Drawtermssh]] . . . November 04, 2021, at 03:54 PM by [[~meeekeeef]]: [=ssh bad >:[=]%0a* [[Netcat.Http]] . . . November 03, 2021, at 02:30 PM by [[~jrmu]]: [==]%0a* [[Telnet.Http]] . . . November 03, 2021, at 02:18 PM by [[~jrmu]]: [==]%0a* [[Znc.Relayd]] . . . November 03, 2021, at 10:18 AM by [[~jrmu]]: [==]%0a* [[ZNC.Admin]] . . . November 02, 2021, at 05:44 PM by [[~jrmu]]: [==]%0a* [[Znc.Debug]] . . . November 02, 2021, at 03:23 PM by [[~jrmu]]: [==]%0a* [[Znc.Usage]] . . . November 02, 2021, at 03:09 PM by [[~jrmu]]: [==]%0a* [[Ambassador.Markets]] . . . November 02, 2021, at 01:29 PM by [[~jrmu]]: [==]%0a* [[Almanack.Rewrite]] . . . October 31, 2021, at 10:30 PM by [[~hydragyrum]]: [==]%0a* [[9.Sysupdate]] . . . October 31, 2021, at 10:21 PM by [[~meeekeeef]]: [==]%0a* [[Debian.Debian]] . . . October 31, 2021, at 12:34 PM by [[~monaco]]: [==]%0a* [[Ircnow.Victorycpus]] . . . October 30, 2021, at 08:17 AM by [[~jrmu]]: [==]%0a* [[Gnus.Connect]] . . . October 30, 2021, at 01:32 AM by [[~hydragyrum]]: [==]%0a* [[Ircnow.Settler]] . . . October 29, 2021, at 04:03 PM by [[~jrmu]]: [==]%0a* [[Debian.Nginxphpfpm]] . . . October 29, 2021, at 12:26 PM by [[~monaco]]: [==]%0a* [[Debian.Nginx]] . . . October 29, 2021, at 12:18 PM by [[~monaco]]: [==]%0a* [[Vmm.Homerouter]] . . . October 26, 2021, at 05:08 PM by [[~jrmu]]: [==]%0a* [[9.Netcat]] . . . October 25, 2021, at 03:40 PM by [[~jrmu]]: [==]%0a* [[9.Plan9ini]] . . . October 24, 2021, at 04:30 PM by [[~jrmu]]: [==]%0a* [[Iked.Newconfig]] . . . October 24, 2021, at 03:49 PM by [[~tool]]: [==]%0a* [[Lua.Minetest-1]] . . . October 24, 2021, at 10:30 AM by [[~debiankaios]]: [==]%0a* [[9.Links]] . . . October 24, 2021, at 06:29 AM by [[~mkf]]: [==]%0a* [[9.Keybindings]] . . . October 24, 2021, at 06:15 AM by [[~mkf]]: [=heheheheheh=]%0a* [[Xdefaults.Configure]] . . . October 23, 2021, at 02:40 PM by [[~jrmu]]: [==]%0a* [[TigerVNC.SSH]] . . . October 23, 2021, at 11:56 AM by [[~Hawk]]: [==]%0a* [[Rio.Customize]] . . . October 22, 2021, at 09:22 AM by [[~jrmu]]: [==]%0a* [[9.Ssh]] . . . October 22, 2021, at 12:54 AM by [[~jrmu]]: [==]%0a* [[Vmm.Devuan4Iso]] . . . October 21, 2021, at 04:29 PM by [[~debiankaios]]: [=changed beowulf_3.1.1 to chimaera_4.0.0=]%0a* [[9.101]] . . . October 20, 2021, at 04:53 PM by [[~jrmu]]: [==]%0a* [[Fvwm.Configure]] . . . October 18, 2021, at 10:20 AM by [[~jrmu]]: [==]%0a* [[KISSmo.KISSmo]] . . . October 18, 2021, at 09:58 AM by [[~monaco]]: [==]%0a* [[KISSmo.Download]] . . . October 18, 2021, at 09:53 AM by [[~monaco]]: [==]%0a* [[KISSmo.About]] . . . October 18, 2021, at 09:52 AM by [[~monaco]]: [==]%0a* [[KISSmo.Install]] . . . October 18, 2021, at 09:44 AM by [[~monaco]]: [==]%0a* [[Cvs.Repo]] . . . October 17, 2021, at 08:32 AM by [[~jrmu]]: [==]%0a* [[Cvs.Anoncvs]] . . . October 17, 2021, at 04:00 AM by [[~jrmu]]: [==]%0a* [[Cvs.Commit]] . . . October 17, 2021, at 03:58 AM by [[~jrmu]]: [==]%0a* [[Cvs.Cvsweb]] . . . October 17, 2021, at 03:28 AM by [[~jrmu]]: [==]%0a* [[9.Cvsfs]] . . . October 15, 2021, at 12:58 PM by [[~mkf]]: [==]%0a* [[Openbsd.Sysupgrade70]] . . . October 15, 2021, at 11:02 AM by [[~mkf]]: [=humans are easily confused.=]%0a* [[Openbsd.Ilines]] . . . October 15, 2021, at 02:36 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Pmwiki]] . . . October 14, 2021, at 02:14 PM by [[~miniontoby]]: [=added credits =]%0a* [[Vmm.Devuan-ISO]] . . . October 14, 2021, at 09:50 AM by [[~siva]]: [==]%0a* [[Vmm.Devuan-Simple]] . . . October 14, 2021, at 09:48 AM by [[~siva]]: [=Tutorial Created=]%0a* [[Cvs.Intro]] . . . October 13, 2021, at 03:49 PM by [[~jrmu]]: [==]%0a* [[Synapse.Install]] . . . October 12, 2021, at 02:49 PM by [[~miniontoby]]: [=Created=]%0a* [[Ircnow.Oper]] . . . October 12, 2021, at 03:02 AM by [[~jrmu]]: [==]%0a* [[Terms.Privacy]] . . . October 11, 2021, at 11:48 AM by [[~jrmu]]: [==]%0a* [[Ircnow.Diversity]] . . . October 09, 2021, at 02:56 AM by [[~jrmu]]: [==]%0a* [[Ircnow.Linux]] . . . October 08, 2021, at 04:51 AM by [[~jrmu]]: [==]%0a* [[OpenBSD.ResetPassword]] . . . October 07, 2021, at 03:56 AM by [[~jrmu]]: [==]%0a* [[Terms.Vps]] . . . October 06, 2021, at 12:30 AM by [[~jrmu]]: [==]%0a* [[9.JSDrawterm]] . . . September 30, 2021, at 06:06 PM by [[~jrmu]]: [==]%0a* [[9.Fonts]] . . . September 28, 2021, at 05:13 PM by [[~jrmu]]: [==]%0a* [[Openbsd.Install69]] . . . September 27, 2021, at 05:59 PM by [[~jrmu]]: [==]%0a* [[Cvs.Guide]] . . . September 26, 2021, at 02:28 PM by [[~Miniontoby]]: [==]%0a* [[Openbsd.PFStable]] . . . September 24, 2021, at 03:28 PM by [[~miniontoby]]: [==]%0a* [[License.IrcnowV2]] . . . September 21, 2021, at 03:53 AM by [[~jrmu]]: [==]%0a* [[Dhcpd.Configure]] . . . September 15, 2021, at 04:02 PM by [[~jrmu]]: [==]%0a* [[Vmm.Router]] . . . September 14, 2021, at 12:11 PM by [[~jrmu]]: [==]%0a* [[Weechat.Relay]] . . . September 11, 2021, at 05:46 PM by [[~mkf]]: [==]%0a* [[Gry.Bio]] . . . September 11, 2021, at 02:49 AM by [[~jrmu]]: [==]%0a* [[Hopm.Telnet]] . . . September 10, 2021, at 06:13 AM by [[~mkf]]: [==]%0a* [[Wraith.Chroot]] . . . September 10, 2021, at 06:11 AM by [[~mkf]]: [==]%0a* [[Mutt.Connect]] . . . September 10, 2021, at 06:01 AM by [[~mkf]]: [=6.8 -> 6.9=]%0a* [[ZNC.Skins]] . . . September 06, 2021, at 07:58 AM by [[~mkf]]: [="Huh, pmwiki has a bug." no numbered list if use monospaced text. :(=]%0a* [[Seamonkey.Connect]] . . . August 28, 2021, at 01:05 PM by [[~mkf]]: [==]%0a* [[Debate.Wikistyle]] . . . August 27, 2021, at 03:29 PM by [[~mkf]]: [==]%0a* [[Email.EmailAndroidEmailApp]] . . . August 27, 2021, at 02:37 PM by [[~mkf]]: [==]%0a* [[Tmux.Shortcuts]] . . . August 27, 2021, at 12:56 PM by [[~mkf]]: [==]%0a* [[Vmm.Haiku]] . . . August 27, 2021, at 12:53 PM by [[~mkf]]: [==]%0a* [[Openbsd.Mailopenproxy]] . . . August 25, 2021, at 08:19 PM by [[~mkf]]: [==]%0a* [[Openbsd.Two-FactorAuth]] . . . August 23, 2021, at 07:39 PM by [[~mkf]]: [=login.db compiling is no longer recommended.=]%0a* [[Vmm.DragonflyBSD]] . . . August 23, 2021, at 07:31 PM by [[~mkf]]: [=logs=]%0a* [[Vmm.NetBSD]] . . . August 23, 2021, at 07:01 PM by [[~mkf]]: [=better logs?=]%0a* [[Mariadb.Install]] . . . August 23, 2021, at 04:42 PM by [[~wiz]]: [==]%0a* [[DNS.Ipv6rDNS]] . . . August 23, 2021, at 11:55 AM by [[~jrmu]]: [==]%0a* [[Pipes.Redirection]] . . . August 23, 2021, at 03:50 AM by [[~jrmu]]: [==]%0a* [[Ksh.Redirection]] . . . August 23, 2021, at 03:50 AM by [[~jrmu]]: [==]%0a* [[DNS.RDNS]] . . . August 22, 2021, at 11:20 PM by [[~jrmu]]: [==]%0a* [[Rbldnsd.Install]] . . . August 22, 2021, at 07:58 PM by [[~mkf]]: [=wiki-ish.=]%0a* [[Netcat.Smtp]] . . . August 22, 2021, at 06:58 PM by [[~mkf]]: [=byebye=]%0a* [[Vmm.UbuntuIso]] . . . August 22, 2021, at 06:40 AM by [[~jrmu]]: [==]%0a* [[Vmm.DevuanIso]] . . . August 22, 2021, at 05:44 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Npppd]] . . . August 21, 2021, at 01:43 PM by [[~mkf]]: [==]%0a* [[Shell.Shell]] . . . August 21, 2021, at 11:42 AM by [[~jrmu]]: [==]%0a* [[Tls.CA]] . . . August 21, 2021, at 11:10 AM by [[~jrmu]]: [==]%0a* [[Openssl.Imap]] . . . August 21, 2021, at 04:05 AM by [[~AncientWisdom]]: [==]%0a* [[Openbsd.FilePermissions]] . . . August 20, 2021, at 02:20 AM by [[~Nate S]]: [==]%0a* [[Ircnow.Todo]] . . . August 17, 2021, at 08:41 AM by [[~mkf]]: [==]%0a* [[Vmm.GuixIso]] . . . August 16, 2021, at 05:12 PM by [[~jrmu]]: [==]%0a* [[Vmm.VoidIso]] . . . August 16, 2021, at 06:19 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Gophernicus]] . . . August 15, 2021, at 02:06 AM by [[~mkf]]: [==]%0a* [[Gazette.Gazette]] . . . August 15, 2021, at 01:14 AM by [[~mkf]]: [=a bit polishing=]%0a* [[EmailTray.Connect]] . . . August 15, 2021, at 12:11 AM by [[~mkf]]: [==]%0a* [[Bouncer.Konversation]] . . . August 14, 2021, at 02:46 PM by [[~mkf]]: [==]%0a* [[Squirrelmail.Connect]] . . . August 14, 2021, at 04:47 AM by [[~mkf]]: [==]%0a* [[Termius.Connect]] . . . August 14, 2021, at 04:42 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Openhttpd]] . . . August 13, 2021, at 07:29 AM by [[~jrmu]]: [==]%0a* [[ConnectBot.Keys]] . . . August 12, 2021, at 06:58 AM by [[~jrmu]]: [==]%0a* [[Debate.Monopolydanger]] . . . August 11, 2021, at 07:01 PM by [[~mkf]]: [==]%0a* [[ConnectBot.Connect]] . . . August 11, 2021, at 04:34 PM by [[~jrmu]]: [==]%0a* [[Openbsd.ZNCModules]] . . . August 11, 2021, at 03:06 PM by [[~wiz]]: [==]%0a* [[Termux.Connect]] . . . August 11, 2021, at 05:28 AM by [[~jrmu]]: [==]%0a* [[Web101.Web101]] . . . August 10, 2021, at 04:20 PM by [[~craziness]]: [=started web101=]%0a* [[Openbsd.Bitlbee]] . . . August 10, 2021, at 12:03 PM by [[~mkf]]: [==]%0a* [[Openbsd.Pppoe]] . . . August 10, 2021, at 11:56 AM by [[~mkf]]: [==]%0a* [[Sylpheed.Connect]] . . . August 10, 2021, at 11:50 AM by [[~mkf]]: [=eh, forgot that "[" again=]%0a* [[MacTerminal.Connect]] . . . August 10, 2021, at 10:33 AM by [[~jrmu]]: [==]%0a* [[OpenSSH.Connect]] . . . August 10, 2021, at 10:19 AM by [[~jrmu]]: [==]%0a* [[Fdroid.Install]] . . . August 10, 2021, at 09:05 AM by [[~jrmu]]: [==]%0a* [[Shell.Sshfingerprints]] . . . August 10, 2021, at 08:55 AM by [[~jrmu]]: [==]%0a* [[OpenSSH.Keygen]] . . . August 09, 2021, at 06:27 PM by [[~jrmu]]: [==]%0a* [[Openbsd.Sshkeys]] . . . August 09, 2021, at 04:42 PM by [[~jrmu]]: [==]%0a* [[Vmm.9front]] . . . August 09, 2021, at 06:16 AM by [[~mkf]]: [==]%0a* [[Bouncer.WinIRC]] . . . August 09, 2021, at 06:03 AM by [[~mkf]]: [==]%0a* [[IP.Myaddress]] . . . August 07, 2021, at 05:14 PM by [[~jrmu]]: [==]%0a* [[SerFISH.Connect]] . . . August 06, 2021, at 05:05 PM by [[~jrmu]]: [==]%0a* [[Sshwifty.Connect]] . . . August 06, 2021, at 05:00 PM by [[~jrmu]]: [==]%0a* [[Openbsd.Squirrelmail]] . . . August 06, 2021, at 10:32 AM by [[~baytuch]]: [==]%0a* [[Eggdrop.NickServ]] . . . August 05, 2021, at 07:27 AM by [[~jrmu]]: [==]%0a* [[Medals.Intro]] . . . August 04, 2021, at 08:34 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Dnszones]] . . . August 03, 2021, at 09:26 AM by [[~jrmu]]: [==]%0a* [[Dns.Zonefile]] . . . August 03, 2021, at 09:21 AM by [[~jrmu]]: [==]%0a* [[Irc.Clients]] . . . August 02, 2021, at 02:54 PM by [[~mkf]]: [==]%0a* [[Minutemin.Ifconfig]] . . . August 02, 2021, at 12:59 PM by [[~mkf]]: [==]%0a* [[Openbsd.Matterbridge]] . . . August 02, 2021, at 12:33 PM by [[~mkf]]: [==]%0a* [[Znc.I18n]] . . . August 02, 2021, at 09:12 AM by [[~mkf]]: [==]%0a* [[Almanack.Alt]] . . . August 02, 2021, at 07:52 AM by [[~jrmu]]: [==]%0a* [[Eggdrop.Simple]] . . . August 02, 2021, at 07:49 AM by [[~jrmu]]: [==]%0a* [[Eggdrop.Install]] . . . August 02, 2021, at 05:11 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Vhost]] . . . August 02, 2021, at 02:32 AM by [[~jrmu]]: [==]%0a* [[Ircnow.Hardware]] . . . August 01, 2021, at 01:48 PM by [[~jrmu]]: [==]%0a* [[Thunderirc.Hardware]] . . . August 01, 2021, at 01:47 PM by [[~jrmu]]: [==]%0a* [[Planetofnix.Hardware]] . . . August 01, 2021, at 01:46 PM by [[~jrmu]]: [==]%0a* [[Bsdforall.Hardware]] . . . August 01, 2021, at 01:45 PM by [[~jrmu]]: [==]%0a* [[Oddprotocol.Hardware]] . . . August 01, 2021, at 01:28 PM by [[~jrmu]]: [==]%0a* [[Lecturify.Hardware]] . . . August 01, 2021, at 01:27 PM by [[~jrmu]]: [==]%0a* [[Eggdrop184.Install]] . . . August 01, 2021, at 07:07 AM by [[~jrmu]]: [==]%0a* [[Congress.Procedure]] . . . August 01, 2021, at 06:41 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Chroot]] . . . July 31, 2021, at 02:47 AM by [[~jrmu]]: [==]%0a* [[Syslogd.Remote]] . . . July 30, 2021, at 03:30 PM by [[~jrmu]]: [==]%0a* [[Openbsd.Vmmuser]] . . . July 29, 2021, at 05:31 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Vmminstall]] . . . July 29, 2021, at 05:28 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Vmm]] . . . July 29, 2021, at 05:24 AM by [[~jrmu]]: [==]%0a* [[Openbsd.ZNCAdmin]] . . . July 28, 2021, at 06:14 AM by [[~jrmu]]: [==]%0a* [[Openbsd.ZNCSupport]] . . . July 28, 2021, at 06:14 AM by [[~jrmu]]: [==]%0a* [[ZNC.Troubleshoot]] . . . July 28, 2021, at 06:12 AM by [[~jrmu]]: [==]%0a* [[Znc.Troubleshoot]] . . . July 28, 2021, at 06:11 AM by [[~jrmu]]: [==]%0a* [[Kill.Usage]] . . . July 28, 2021, at 03:42 AM by [[~jrmu]]: [==]%0a* [[Ps.Usage]] . . . July 28, 2021, at 03:42 AM by [[~jrmu]]: [==]%0a* [[Dns.Vhost]] . . . July 28, 2021, at 03:05 AM by [[~jrmu]]: [==]%0a* [[Host.Usage]] . . . July 28, 2021, at 01:57 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Php]] . . . July 27, 2021, at 02:53 PM by [[~jrmu]]: [==]%0a* [[UsersCategoryMirrory.IRCFreeHomesteadVPS]] . . . July 26, 2021, at 06:12 AM by [[~category_mirror]]: [==]%0a* [[Ircnow.PioneerTldr]] . . . July 26, 2021, at 06:04 AM by [[~jrmu]]: [==]%0a* [[UsersCategoryMirrory.Pioneer]] . . . July 26, 2021, at 04:22 AM by [[~category_mirror]]: [==]%0a* [[Openbsd.Dig]] . . . July 25, 2021, at 06:50 AM by [[~jrmu]]: [==]%0a* [[Openbsd.RDNS]] . . . July 23, 2021, at 06:44 AM by [[~jrmu]]: [==]%0a* [[Wordpress.Install]] . . . July 21, 2021, at 06:59 PM by [[~mkf]]: [==]%0a* [[Bouncer.All]] . . . July 21, 2021, at 06:37 PM by [[~mkf]]: [==]%0a* [[Lemon.Todo]] . . . July 21, 2021, at 06:21 PM by [[~mkf]]: [==]%0a* [[Irc.Guide]] . . . July 21, 2021, at 06:02 PM by [[~mkf]]: [=client -> clients=]%0a* [[Openbsd.Sic]] . . . July 21, 2021, at 05:57 PM by [[~mkf]]: [=first edit.=]%0a* [[Minutemin.Progress]] . . . July 21, 2021, at 08:10 AM by [[~jrmu]]: [==]%0a* [[Openssl.Check]] . . . July 20, 2021, at 01:27 PM by [[~jrmu]]: [==]%0a* [[Rsync.Usage]] . . . July 19, 2021, at 02:30 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Openrsync]] . . . July 18, 2021, at 02:01 PM by [[~jrmu]]: [==]%0a* [[Eggdrop.DuckHunt]] . . . July 17, 2021, at 06:34 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Znc]] . . . July 16, 2021, at 10:43 AM by [[~jrmu]]: [==]%0a* [[Netizen.Become]] . . . July 14, 2021, at 09:47 AM by [[~jrmu]]: [==]%0a* [[Freedom.Bearcode]] . . . July 14, 2021, at 09:42 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Staticnet]] . . . July 12, 2021, at 05:48 PM by [[~jrmu]]: [==]%0a* [[Openbsd.Dovecot]] . . . July 12, 2021, at 02:58 PM by [[~jrmu]]: [==]%0a* [[Openbsd.Relayd]] . . . July 12, 2021, at 02:45 PM by [[~jrmu]]: [==]%0a* [[Openbsd.Spf]] . . . July 12, 2021, at 03:08 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Eggdrop]] . . . July 02, 2021, at 03:20 AM by [[~jrmu]]: [==]%0a* [[Openssl.Http]] . . . June 30, 2021, at 04:44 AM by [[~mkf]]: [==]%0a* [[Debate.Oldsoftware]] . . . June 29, 2021, at 03:56 PM by [[~mkf]]: [==]%0a* [[Debate.Xmlflaws]] . . . June 29, 2021, at 03:54 PM by [[~mkf]]: [==]%0a* [[Debate.Wikipediadanger]] . . . June 29, 2021, at 03:51 PM by [[~mkf]]: [==]%0a* [[Debate.DCC]] . . . June 29, 2021, at 03:49 PM by [[~mkf]]: [==]%0a* [[Debate.Matrixflaws]] . . . June 29, 2021, at 03:48 PM by [[~mkf]]: [==]%0a* [[Debate.Webirc]] . . . June 29, 2021, at 03:48 PM by [[~mkf]]: [==]%0a* [[Debate.Nodejstrap]] . . . June 29, 2021, at 03:48 PM by [[~mkf]]: [==]%0a* [[Debate.Ircv3defense]] . . . June 29, 2021, at 03:45 PM by [[~mkf]]: [==]%0a* [[Openbsd.Newdisk]] . . . June 29, 2021, at 03:23 PM by [[~jrmu]]: [==]%0a* [[AndroidEmail.AndroidEmail]] . . . June 29, 2021, at 03:11 PM by [[~jrmu]]: [==]%0a* [[Openbsd.Ed]] . . . June 28, 2021, at 04:04 PM by [[~mkf]]: [==]%0a* [[Openbsd.Unbound]] . . . June 27, 2021, at 12:12 PM by [[~jrmu]]: [==]%0a* [[Freedom.Religion]] . . . June 27, 2021, at 02:02 AM by [[~jrmu]]: [==]%0a* [[Tor.Hidden]] . . . June 26, 2021, at 08:56 PM by [[~mkf]]: [==]%0a* [[Freedom.Union]] . . . June 26, 2021, at 01:01 PM by [[~jrmu]]: [==]%0a* [[Freedom.Firstamendment]] . . . June 26, 2021, at 11:45 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Dkimproxy]] . . . June 25, 2021, at 12:56 PM by [[~jrmu]]: [==]%0a* [[MIF.Test]] . . . June 25, 2021, at 12:42 PM by [[~nsturtz]]: [==]%0a* [[Openbsd.Sysupgrade69]] . . . June 25, 2021, at 05:46 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Opensmtpd]] . . . June 23, 2021, at 02:21 AM by [[~jrmu]]: [==]%0a* [[Openbsd.NgircdLink]] . . . June 22, 2021, at 07:50 PM by [[~mkf]]: [=delete=]%0a* [[File.File]] . . . June 22, 2021, at 07:43 PM by [[~mkf]]: [=linking=]%0a* [[Debate.Linuxflaws]] . . . June 20, 2021, at 08:03 AM by [[~mkf]]: [=making hyperlinks=]%0a* [[Police.Intro]] . . . June 19, 2021, at 11:42 AM by [[~jrmu]]: [==]%0a* [[Freedom.Destiny]] . . . June 18, 2021, at 05:31 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Doas]] . . . June 13, 2021, at 01:19 PM by [[~jrmu]]: [==]%0a* [[Freedom.Freedom]] . . . June 13, 2021, at 09:13 AM by [[~jrmu]]: [==]%0a* [[Freedom.Press]] . . . June 13, 2021, at 09:12 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Shell]] . . . June 11, 2021, at 09:36 AM by [[~jrmu]]: [==]%0a* [[Ircnow.Constitution]] . . . June 10, 2021, at 03:48 PM by [[~jrmu]]: [==]%0a* [[Netizen.Rights]] . . . June 10, 2021, at 03:21 PM by [[~jrmu]]: [==]%0a* [[IPv4.Overview]] . . . June 10, 2021, at 10:13 AM by [[~jrmu]]: [==]%0a* [[Ksh.Bash]] . . . June 09, 2021, at 11:31 AM by [[~jrmu]]: [==]%0a* [[PowerShell.Connect]] . . . June 09, 2021, at 11:10 AM by [[~jrmu]]: [==]%0a* [[Code.Code]] . . . June 08, 2021, at 05:24 PM by [[~mkf]]: [=better formating=]%0a* [[Grape.DonateUs]] . . . June 06, 2021, at 03:41 PM by [[~fizi]]: [==]%0a* [[Openbsd.Books]] . . . June 06, 2021, at 12:46 PM by [[~jrmu]]: [==]%0a* [[Grape.Grape]] . . . June 06, 2021, at 11:39 AM by [[~fizi]]: [==]%0a* [[Openbsd.Pfa]] . . . June 06, 2021, at 03:49 AM by [[~navic]]: [==]%0a* [[Vmm.Debian]] . . . June 04, 2021, at 07:48 PM by [[~mkf]]: [="LOL"=]%0a* [[DNS.Dnswl]] . . . June 04, 2021, at 11:11 AM by [[~jrmu]]: [==]%0a* [[Netcat.SMTP]] . . . June 04, 2021, at 09:59 AM by [[~jrmu]]: [==]%0a* [[Dkim.Dkimsign]] . . . June 04, 2021, at 09:07 AM by [[~jrmu]]: [==]%0a* [[Tor.Torsocks]] . . . June 04, 2021, at 06:16 AM by [[~jrmu]]: [==]%0a* [[Vpn.VpnIos]] . . . June 04, 2021, at 05:52 AM by [[~jrmu]]: [==]%0a* [[Vpn.VpnMac]] . . . June 04, 2021, at 05:40 AM by [[~jrmu]]: [==]%0a* [[Fdisk.Usage]] . . . June 04, 2021, at 05:04 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Wordpress]] . . . June 04, 2021, at 04:55 AM by [[~jrmu]]: [==]%0a* [[DNS.SPF]] . . . June 03, 2021, at 01:27 PM by [[~jrmu]]: [==]%0a* [[Terms.Terms]] . . . June 02, 2021, at 01:40 PM by [[~jrmu]]: [==]%0a* [[HostServ.Rules]] . . . June 01, 2021, at 08:11 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Anope]] . . . May 31, 2021, at 10:24 AM by [[~miniontoby]]: [=cp=]%0a* [[Openbsd.ACKFlood]] . . . May 29, 2021, at 06:20 AM by [[~mkf]]: [==]%0a* [[Openbsd.SSDP]] . . . May 29, 2021, at 06:18 AM by [[~mkf]]: [==]%0a* [[Openbsd.Anycast]] . . . May 29, 2021, at 06:01 AM by [[~mkf]]: [==]%0a* [[Ambassador.Networks]] . . . May 27, 2021, at 04:05 PM by [[~jrmu]]: [==]%0a* [[Marketing.Rules]] . . . May 26, 2021, at 06:15 AM by [[~jrmu]]: [==]%0a* [[Freenode.Power]] . . . May 26, 2021, at 04:38 AM by [[~jrmu]]: [==]%0a* [[Freenode.Money]] . . . May 25, 2021, at 03:29 PM by [[~jrmu]]: [==]%0a* [[Freenode.Takeover]] . . . May 25, 2021, at 05:28 AM by [[~jrmu]]: [==]%0a* [[Freedom.Freenode]] . . . May 25, 2021, at 01:48 AM by [[~jrmu]]: [==]%0a* [[Bouncer.Atomic]] . . . May 24, 2021, at 03:22 PM by [[~mkf]]: [=spacing=]%0a* [[Minetest.Updating]] . . . May 24, 2021, at 08:10 AM by [[~mkf]]: [=monospaced commands=]%0a* [[Shell.Putty]] . . . May 24, 2021, at 06:16 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Dmarc]] . . . May 21, 2021, at 09:22 AM by [[~jrmu]]: [==]%0a* [[Vmm.Optimize]] . . . May 19, 2021, at 04:04 AM by [[~jrmu]]: [==]%0a* [[Ircnow.Stable]] . . . May 18, 2021, at 10:15 AM by [[~mkf]]: [==]%0a* [[Ircnow.VicePresident]] . . . May 18, 2021, at 08:15 AM by [[~jrmu]]: [==]%0a* [[Ircnow.Sheriff]] . . . May 18, 2021, at 08:00 AM by [[~jrmu]]: [==]%0a* [[Ircnow.Ambassador]] . . . May 18, 2021, at 07:42 AM by [[~jrmu]]: [==]%0a* [[Pf.Guide]] . . . May 17, 2021, at 03:37 AM by [[~bejelentkezni]]: [==]%0a* [[Openbsd.Disklabel]] . . . May 17, 2021, at 03:33 AM by [[~bejelentkezni]]: [==]%0a* [[Openbsd.Fdisk]] . . . May 17, 2021, at 03:27 AM by [[~bejelentkezni]]: [==]%0a* [[NewsNow.Install]] . . . May 16, 2021, at 06:49 AM by [[~mkf]]: [="$"=]%0a* [[Tmux.Share]] . . . May 15, 2021, at 02:27 AM by [[~mistera]]: [==]%0a* [[Openbsd.Security]] . . . May 14, 2021, at 03:14 AM by [[~caesar]]: [==]%0a* [[Bouncer.Vision]] . . . May 13, 2021, at 09:47 AM by [[~mkf]]: [=added home page, removed "..."s=]%0a* [[Minetest.Worldbackup]] . . . May 12, 2021, at 11:02 AM by [[~AES]]: [==]%0a* [[Minetest.Texturestyle]] . . . May 12, 2021, at 11:00 AM by [[~AES]]: [==]%0a* [[Minetest.Serverlocations]] . . . May 12, 2021, at 10:59 AM by [[~AES]]: [==]%0a* [[Minetest.Addingarenas]] . . . May 12, 2021, at 10:58 AM by [[~jrmu]]: [==]%0a* [[Relay.Relay]] . . . May 12, 2021, at 09:10 AM by [[~jrmu]]: [==]%0a* [[Ngircd.Install-bej]] . . . May 11, 2021, at 05:26 AM by [[~bejelentkezni]]: [==]%0a* [[Botnow.Botnow]] . . . May 08, 2021, at 09:44 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Hopm-Arthur]] . . . May 07, 2021, at 12:28 PM by [[~Arthur]]: [==]%0a* [[Znc.Chroot69]] . . . May 06, 2021, at 03:36 AM by [[~bejelentkezni]]: [=back to 6.9 to see real changes=]%0a* [[Dig.Usage]] . . . May 04, 2021, at 02:36 AM by [[~sarah]]: [==]%0a* [[Bgpd.Configure]] . . . May 03, 2021, at 06:26 AM by [[~jrmu]]: [==]%0a* [[Cherry.Cherry]] . . . May 02, 2021, at 01:43 PM by [[~Oz]]: [==]%0a* [[Freedom.Unix]] . . . April 29, 2021, at 03:39 PM by [[~jrmu]]: [==]%0a* [[Pmwiki.Simpleurl]] . . . April 29, 2021, at 02:46 PM by [[~punk]]: [==]%0a* [[Gpl.Flaws]] . . . April 24, 2021, at 04:56 PM by [[~jrmu]]: [==]%0a* [[Iked.Windows]] . . . April 18, 2021, at 07:38 PM by [[~st13g]]: [==]%0a* [[Freedom.Libertyordeath]] . . . April 17, 2021, at 12:35 PM by [[~jrmu]]: [==]%0a* [[Minetest.Economy]] . . . April 15, 2021, at 02:32 PM by [[~jrmu]]: [==]%0a* [[Vim.Vim]] . . . April 11, 2021, at 11:14 PM by [[~monaco]]: [==]%0a* [[Minutemin.Duty]] . . . April 11, 2021, at 04:53 AM by [[~jrmu]]: [==]%0a* [[License.License]] . . . April 04, 2021, at 02:00 AM by [[~jrmu]]: [==]%0a* [[EthicalSource.HolierThanThou]] . . . April 04, 2021, at 01:56 AM by [[~jrmu]]: [==]%0a* [[Jrmu.Rmsboycott]] . . . April 03, 2021, at 01:36 AM by [[~jrmu]]: [==]%0a* [[Jrmu.Libertyordeath]] . . . April 02, 2021, at 12:56 PM by [[~jrmu]]: [==]%0a* [[Fig.Fig]] . . . March 31, 2021, at 10:15 AM by [[~chewy]]: [==]%0a* [[Coconut.Coconut]] . . . March 29, 2021, at 12:28 PM by [[~jrmu]]: [==]%0a* [[Ircnow.CodeForce]] . . . March 29, 2021, at 12:04 PM by [[~jrmu]]: [==]%0a* [[ClawsMail.Connect]] . . . March 29, 2021, at 08:42 AM by [[~miniontoby]]: [==]%0a* [[Freedom.Madeonirc]] . . . March 27, 2021, at 11:48 AM by [[~jrmu]]: [==]%0a* [[Third.Devs]] . . . March 27, 2021, at 11:41 AM by [[~jrmu]]: [==]%0a* [[Minutemin.Code]] . . . March 24, 2021, at 03:26 AM by [[~jrmu]]: [==]%0a* [[Cherry.Todo]] . . . March 23, 2021, at 03:23 PM by [[~Oz]]: [==]%0a* [[Freedom.Independence]] . . . March 22, 2021, at 01:13 PM by [[~wiz]]: [==]%0a* [[Ifconfig.Change]] . . . March 20, 2021, at 11:15 AM by [[~jrmu]]: [==]%0a* [[Marketing.Founders]] . . . March 20, 2021, at 01:40 AM by [[~jrmu]]: [==]%0a* [[NewsNow.Teams]] . . . March 18, 2021, at 09:47 AM by [[~miniontoby]]: [=banana=]%0a* [[NewsNow.NewsNow]] . . . March 17, 2021, at 04:33 PM by [[~miniontoby]]: [=more ways=]%0a* [[Vhost.Freedns]] . . . March 16, 2021, at 12:22 PM by [[~wiz]]: [==]%0a* [[Marketing.Freedom]] . . . March 15, 2021, at 01:30 PM by [[~jrmu]]: [==]%0a* [[Bsd.Labor]] . . . March 15, 2021, at 06:12 AM by [[~jrmu]]: [==]%0a* [[License.Discriminatory]] . . . March 15, 2021, at 06:12 AM by [[~jrmu]]: [==]%0a* [[Bsd.Hope]] . . . March 14, 2021, at 11:05 PM by [[~jrmu]]: [==]%0a* [[License.Publicdomain]] . . . March 14, 2021, at 10:02 AM by [[~jrmu]]: [==]%0a* [[Linux.Flaws]] . . . March 14, 2021, at 05:13 AM by [[~jrmu]]: [==]%0a* [[NewsNow.Browser]] . . . March 12, 2021, at 08:00 AM by [[~miniontoby]]: [==]%0a* [[Abuse.Code]] . . . March 09, 2021, at 03:44 PM by [[~jrmu]]: [==]%0a* [[Congress.Documents]] . . . March 07, 2021, at 04:50 AM by [[~jrmu]]: [==]%0a* [[Ircnow.Goals]] . . . March 06, 2021, at 09:33 AM by [[~jrmu]]: [==]%0a* [[Ircnow.Chatforce]] . . . March 05, 2021, at 02:15 PM by [[~jrmu]]: [==]%0a* [[Shell.Bash]] . . . March 05, 2021, at 10:19 AM by [[~jrmu]]: [==]%0a* [[User.Welcome]] . . . March 05, 2021, at 07:34 AM by [[~jrmu]]: [==]%0a* [[Immigrant.Welcome]] . . . March 05, 2021, at 06:59 AM by [[~jrmu]]: [==]%0a* [[Mail.Openrelay]] . . . March 04, 2021, at 03:20 PM by [[~jrmu]]: [==]%0a* [[Mail.Test]] . . . March 04, 2021, at 03:07 PM by [[~jrmu]]: [==]%0a* [[Minutemin.Game]] . . . March 04, 2021, at 10:16 AM by [[~jrmu]]: [==]%0a* [[Marketing.Recruit]] . . . March 04, 2021, at 09:39 AM by [[~jrmu]]: [==]%0a* [[Ircnow.Howtoask]] . . . March 03, 2021, at 12:35 PM by [[~jrmu]]: [==]%0a* [[Ircnow.Netizen]] . . . February 28, 2021, at 03:18 PM by [[~jrmu]]: [==]%0a* [[Servers.Rights]] . . . February 28, 2021, at 12:37 PM by [[~jrmu]]: [==]%0a* [[Marketing.Enterprise]] . . . February 28, 2021, at 11:52 AM by [[~jrmu]]: [==]%0a* [[Minutemin.Creed]] . . . February 28, 2021, at 03:21 AM by [[~jrmu]]: [==]%0a* [[Ln.Intro]] . . . February 25, 2021, at 12:20 PM by [[~jrmu]]: [==]%0a* [[Leafnode.Install]] . . . February 25, 2021, at 10:56 AM by [[~jrmu]]: [==]%0a* [[Guava.Todo]] . . . February 23, 2021, at 10:47 AM by [[~quofan]]: [==]%0a* [[Relays.Relays]] . . . February 22, 2021, at 04:22 PM by [[~jrmu]]: [==]%0a* [[Jujube.Jujube]] . . . February 21, 2021, at 04:22 PM by [[~fizi]]: [==]%0a* [[PSFTP.Connect]] . . . February 21, 2021, at 03:57 PM by [[~jrmu]]: [==]%0a* [[Outlook.Connect]] . . . February 21, 2021, at 03:23 PM by [[~jrmu]]: [==]%0a* [[AppleMail.Connect]] . . . February 20, 2021, at 04:38 PM by [[~jrmu]]: [==]%0a* [[Thunderbird.Pgp]] . . . February 19, 2021, at 04:44 PM by [[~jrmu]]: [==]%0a* [[License.Ircnow]] . . . February 19, 2021, at 09:45 AM by [[~miniontoby]]: [=2021=]%0a* [[Thunderbird.Connect]] . . . February 19, 2021, at 09:36 AM by [[~jrmu]]: [==]%0a* [[Shell.Mac]] . . . February 19, 2021, at 09:14 AM by [[~jrmu]]: [==]%0a* [[Minutemin.Training]] . . . February 18, 2021, at 06:42 AM by [[~jrmu]]: [==]%0a* [[Freedom.Openforeveryone]] . . . February 16, 2021, at 04:33 AM by [[~jrmu]]: [==]%0a* [[Ircnow.IRCitizen]] . . . February 15, 2021, at 05:32 AM by [[~jrmu]]: [==]%0a* [[IPv6.Overview]] . . . February 14, 2021, at 11:09 AM by [[~jrmu]]: [==]%0a* [[Tcpip.Overview]] . . . February 14, 2021, at 11:02 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Syspatch]] . . . February 14, 2021, at 11:00 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Netadmin]] . . . February 14, 2021, at 10:56 AM by [[~jrmu]]: [==]%0a* [[Marketing.Religion]] . . . February 14, 2021, at 10:37 AM by [[~jrmu]]: [==]%0a* [[Marketing.Independence]] . . . February 13, 2021, at 04:59 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Leafnode]] . . . February 12, 2021, at 01:40 PM by [[~chewy]]: [==]%0a* [[Oidentd.Pylink]] . . . February 12, 2021, at 01:25 PM by [[~jrmu]]: [==]%0a* [[Marketing.Opportunity]] . . . February 11, 2021, at 12:58 PM by [[~jrmu]]: [==]%0a* [[Marketing.Republic]] . . . February 11, 2021, at 06:45 AM by [[~jrmu]]: [==]%0a* [[Achurch.Install]] . . . February 10, 2021, at 04:33 PM by [[~jrmu]]: [==]%0a* [[Openbsd.Pylink]] . . . February 08, 2021, at 08:33 AM by [[~jrmu]]: [==]%0a* [[Ircnow.OpofLiberty]] . . . February 06, 2021, at 12:53 PM by [[~jrmu]]: [==]%0a* [[Ircnow.Allies]] . . . February 06, 2021, at 12:47 PM by [[~jrmu]]: [==]%0a* [[Freedom.Dueprocess]] . . . February 06, 2021, at 12:25 PM by [[~jrmu]]: [==]%0a* [[Freedom.Checks]] . . . February 06, 2021, at 12:21 PM by [[~jrmu]]: [==]%0a* [[Freedom.Rulebylaw]] . . . February 06, 2021, at 12:12 PM by [[~jrmu]]: [==]%0a* [[Freedom.Startupdream]] . . . February 06, 2021, at 12:12 PM by [[~jrmu]]: [==]%0a* [[Freedom.Federation]] . . . February 06, 2021, at 11:44 AM by [[~jrmu]]: [==]%0a* [[Freedom.Selfadmin]] . . . February 06, 2021, at 11:26 AM by [[~jrmu]]: [==]%0a* [[Ircnow.OpsofLiberty]] . . . February 06, 2021, at 02:13 AM by [[~jrmu]]: [==]%0a* [[Freedom.Homestead]] . . . February 05, 2021, at 12:49 PM by [[~jrmu]]: [==]%0a* [[Freedom.Software]] . . . February 05, 2021, at 11:31 AM by [[~jrmu]]: [==]%0a* [[Freedom.Opportunity]] . . . February 05, 2021, at 08:55 AM by [[~jrmu]]: [==]%0a* [[Unix.Workethic]] . . . February 05, 2021, at 08:49 AM by [[~jrmu]]: [==]%0a* [[Unix.Ethic]] . . . February 05, 2021, at 08:48 AM by [[~jrmu]]: [==]%0a* [[Freedom.Privacy]] . . . February 05, 2021, at 07:26 AM by [[~jrmu]]: [==]%0a* [[Debate.Privacy]] . . . February 05, 2021, at 07:05 AM by [[~jrmu]]: [==]%0a* [[Team.Policy]] . . . February 04, 2021, at 04:08 PM by [[~jrmu]]: [==]%0a* [[Freedom.Serversrights]] . . . February 04, 2021, at 02:43 PM by [[~jrmu]]: [==]%0a* [[Freedom.Serverrights]] . . . February 04, 2021, at 02:42 PM by [[~jrmu]]: [==]%0a* [[Freedom.Fork]] . . . February 04, 2021, at 02:39 PM by [[~jrmu]]: [==]%0a* [[Freedom.Lanofopportunity]] . . . February 04, 2021, at 01:24 PM by [[~jrmu]]: [==]%0a* [[Freedom.Opentoall]] . . . February 04, 2021, at 01:17 PM by [[~jrmu]]: [==]%0a* [[Freedom.Refuge]] . . . February 04, 2021, at 09:31 AM by [[~jrmu]]: [==]%0a* [[Dns.Providers]] . . . February 04, 2021, at 04:27 AM by [[~jrmu]]: [==]%0a* [[Guava.Guava]] . . . February 03, 2021, at 02:30 AM by [[~st13g]]: [==]%0a* [[Openbsd.Stable]] . . . February 02, 2021, at 02:25 PM by [[~jrmu]]: [==]%0a* [[Openbsd.Base64]] . . . February 02, 2021, at 06:37 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Unboundadblock]] . . . February 02, 2021, at 04:29 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Pfbadhost]] . . . February 02, 2021, at 04:29 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Wraith]] . . . February 02, 2021, at 04:22 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Delphinusdnsd]] . . . February 02, 2021, at 01:51 AM by [[~jrmu]]: [==]%0a* [[Mango.Mango]] . . . January 31, 2021, at 12:01 PM by [[~nix]]: [==]%0a* [[Openbsd.Abuse]] . . . January 31, 2021, at 05:33 AM by [[~jrmu]]: [==]%0a* [[Freedom.Censorship]] . . . January 31, 2021, at 05:23 AM by [[~jrmu]]: [==]%0a* [[Debate.Firstamendment]] . . . January 31, 2021, at 05:20 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Phishing]] . . . January 31, 2021, at 05:02 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Audit]] . . . January 31, 2021, at 04:46 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Ongoing]] . . . January 31, 2021, at 01:19 AM by [[~jrmu]]: [==]%0a* [[Ircnow.Partners]] . . . January 31, 2021, at 12:32 AM by [[~jrmu]]: [==]%0a* [[Orange.Todo]] . . . January 30, 2021, at 11:31 AM by [[~jrmu]]: [==]%0a* [[Pear.Pear]] . . . January 29, 2021, at 06:09 PM by [[~dennis]]: [==]%0a* [[Openbsd.Httpopenproxy]] . . . January 29, 2021, at 11:01 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Zncadmin]] . . . January 29, 2021, at 10:00 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Rbldns]] . . . January 29, 2021, at 05:45 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Setuid]] . . . January 28, 2021, at 06:53 AM by [[~jrmu]]: [==]%0a* [[Openbsd.PFTesting]] . . . January 25, 2021, at 03:28 PM by [[~jrmu]]: [==]%0a* [[Openbsd.ZNCDaily]] . . . January 25, 2021, at 11:35 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Irssi]] . . . January 25, 2021, at 07:08 AM by [[~jrmu]]: [==]%0a* [[Ircnow.Sysadmins]] . . . January 24, 2021, at 10:36 AM by [[~jrmu]]: [==]%0a* [[Debate.UnixPhilosophy]] . . . January 18, 2021, at 05:05 AM by [[~category_mirror]]: [==]%0a* [[Openbsd.XTerm]] . . . January 17, 2021, at 01:48 PM by [[~miniontoby]]: [=copyright=]%0a* [[UsersCategoryMirrory.Statement]] . . . January 17, 2021, at 02:44 AM by [[~category_mirror]]: [==]%0a* [[Email.Outlook]] . . . January 16, 2021, at 05:13 PM by [[~Zouheir]]: [==]%0a* [[Plum.Todo]] . . . January 16, 2021, at 12:09 AM by [[~st13g]]: [==]%0a* [[Debate.Ipsec]] . . . January 13, 2021, at 10:39 AM by [[~jrmu]]: [==]%0a* [[Plum.Plum]] . . . January 12, 2021, at 03:02 PM by [[~wiz]]: [==]%0a* [[Openbsd.Slrn]] . . . January 12, 2021, at 02:40 PM by [[~Noxturnix]]: [==]%0a* [[OpenBSD.CPAN]] . . . January 12, 2021, at 01:48 PM by [[~Dima]]: [==]%0a* [[Jujube.Todo]] . . . January 11, 2021, at 05:13 PM by [[~fizi]]: [==]%0a* [[Ircnow.Ilines]] . . . January 11, 2021, at 09:55 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Netcat]] . . . January 09, 2021, at 02:20 PM by [[~jrmu]]: [==]%0a* [[OpenBSD.Perl]] . . . January 09, 2021, at 02:04 PM by [[~dima]]: [==]%0a* [[Openbsd.Perl]] . . . January 09, 2021, at 01:52 PM by [[~jrmu]]: [==]%0a* [[Fig.Log]] . . . January 07, 2021, at 11:23 AM by [[~dima]]: [=test=]%0a* [[Fig.Todo]] . . . January 06, 2021, at 01:06 PM by [[~jrmu]]: [==]%0a* [[Grape.Todo]] . . . January 06, 2021, at 01:05 PM by [[~jrmu]]: [==]%0a* [[Pear.Todo]] . . . January 06, 2021, at 01:05 PM by [[~jrmu]]: [==]%0a* [[Jujube.Team]] . . . January 06, 2021, at 01:04 PM by [[~jrmu]]: [==]%0a* [[Mango.Todo]] . . . January 06, 2021, at 01:04 PM by [[~jrmu]]: [==]%0a* [[Ircnow.Censorship]] . . . January 06, 2021, at 03:01 AM by [[~jrmu]]: [==]%0a* [[Ircnow.Pentesters]] . . . January 05, 2021, at 11:17 AM by [[~jrmu]]: [==]%0a* [[Ircnow.Coders]] . . . January 05, 2021, at 11:11 AM by [[~jrmu]]: [==]%0a* [[Banana.Todo]] . . . January 04, 2021, at 09:41 AM by [[~miniontoby]]: [=znc=]%0a* [[Users.CategoryMirrory]] . . . January 04, 2021, at 01:10 AM by [[~category_mirror]]: [==]%0a* [[UsersCategoryMirrory.Test]] . . . January 03, 2021, at 08:17 PM by [[~category_mirrory]]: [==]%0a* [[Users.Categorymirrory]] . . . January 03, 2021, at 08:12 PM by [[~category_mirrory]]: [=wrong caps=]%0a* [[Banana.Banana]] . . . January 03, 2021, at 02:39 PM by [[~miniontoby]]: [==]%0a* [[Orange.Orange]] . . . January 03, 2021, at 02:10 PM by [[~jrmu]]: [==]%0a* [[Openbsd.Backup]] . . . January 03, 2021, at 01:46 PM by [[~jrmu]]: [==]%0a* [[Openbsd.Backups]] . . . January 02, 2021, at 11:44 AM by [[~jrmu]]: [==]%0a* [[Debate.Appledanger]] . . . January 02, 2021, at 01:35 AM by [[~jrmu]]: [==]%0a* [[Grape.Tasks]] . . . January 01, 2021, at 07:52 PM by [[~fizi]]: [==]%0a* [[Ircnow.Helpers]] . . . January 01, 2021, at 04:36 AM by [[~jrmu]]: [==]%0a* [[Ircnow.Finances]] . . . January 01, 2021, at 04:15 AM by [[~jrmu]]: [==]%0a* [[Tutorial.Tutorial]] . . . January 01, 2021, at 03:25 AM by [[~jrmu]]: [==]%0a* [[Ircnow.Testing]] . . . December 30, 2020, at 12:58 PM by [[~jrmu]]: [==]%0a* [[Openbsd.Sshbackdoor]] . . . December 30, 2020, at 12:14 PM by [[~jrmu]]: [==]%0a* [[Mango.Packages]] . . . December 30, 2020, at 10:48 AM by [[~nix]]: [==]%0a* [[Ircnow.Contact]] . . . December 30, 2020, at 03:18 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Pf-bnc]] . . . December 29, 2020, at 06:30 PM by [[~jrmu]]: [==]%0a* [[Ircnow.Partners2]] . . . December 29, 2020, at 02:52 PM by [[~jrmu]]: [==]%0a* [[Openbsd.Tcltls]] . . . December 29, 2020, at 09:53 AM by [[~jrmu]]: [==]%0a* [[Debate.Mozilladanger]] . . . December 27, 2020, at 03:05 AM by [[~jrmu]]: [==]%0a* [[Debate.Controlcomputer]] . . . December 27, 2020, at 03:02 AM by [[~jrmu]]: [==]%0a* [[Debate.Facebookdanger]] . . . December 27, 2020, at 03:01 AM by [[~jrmu]]: [==]%0a* [[Debate.Slackdanger]] . . . December 27, 2020, at 02:56 AM by [[~jrmu]]: [==]%0a* [[Debate.Freespeech]] . . . December 27, 2020, at 02:36 AM by [[~jrmu]]: [==]%0a* [[Debate.Ethicalflaws]] . . . December 27, 2020, at 02:31 AM by [[~jrmu]]: [==]%0a* [[Debate.Hatespeech]] . . . December 27, 2020, at 02:20 AM by [[~jrmu]]: [==]%0a* [[Debate.Monero]] . . . December 27, 2020, at 02:02 AM by [[~jrmu]]: [==]%0a* [[Debate.WhyNotC]] . . . December 26, 2020, at 06:43 PM by [[~searchsocial]]: [==]%0a* [[Debate.Python]] . . . December 26, 2020, at 06:21 PM by [[~jrmu]]: [==]%0a* [[Debate.Cash]] . . . December 26, 2020, at 06:18 PM by [[~jrmu]]: [==]%0a* [[Debate.Uberdanger]] . . . December 26, 2020, at 06:16 PM by [[~jrmu]]: [==]%0a* [[Debate.Microsoftdanger]] . . . December 26, 2020, at 06:15 PM by [[~jrmu]]: [==]%0a* [[Debate.Accessibility]] . . . December 26, 2020, at 06:14 PM by [[~jrmu]]: [==]%0a* [[Debate.Zoomdanger]] . . . December 26, 2020, at 06:08 PM by [[~jrmu]]: [==]%0a* [[Shell.Applications]] . . . December 19, 2020, at 06:21 PM by [[~fizi]]: [==]%0a* [[Third.Dillo]] . . . December 19, 2020, at 01:52 PM by [[~jrmu]]: [==]%0a* [[Third.Basilisk]] . . . December 19, 2020, at 01:38 PM by [[~jrmu]]: [==]%0a* [[Third.Directory]] . . . December 19, 2020, at 01:35 PM by [[~jrmu]]: [==]%0a* [[Guava.Packages]] . . . December 19, 2020, at 06:14 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Amplification]] . . . December 19, 2020, at 05:42 AM by [[~jrmu]]: [==]%0a* [[Openbsd.UDPFlood]] . . . December 18, 2020, at 10:39 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Tcpdump]] . . . December 18, 2020, at 09:12 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Tcpackflood]] . . . December 17, 2020, at 10:36 AM by [[~jrmu]]: [==]%0a* [[Openbsd.RSTFlood]] . . . December 17, 2020, at 10:34 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Tcpresetflood]] . . . December 17, 2020, at 10:34 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Ssdp]] . . . December 15, 2020, at 12:59 PM by [[~jrmu]]: [==]%0a* [[Bouncer.Igloo]] . . . December 14, 2020, at 09:39 AM by [[~Noxturnix]]: [==]%0a* [[Main.Terms]] . . . December 13, 2020, at 01:35 PM by [[~jrmu]]: [==]%0a* [[Openbsd.Pf]] . . . December 13, 2020, at 12:03 PM by [[~jrmu]]: [==]%0a* [[Openbsd.Upgrade68]] . . . December 13, 2020, at 11:12 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Install68]] . . . December 13, 2020, at 10:13 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Upgrade67]] . . . December 13, 2020, at 04:02 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Sysupgrade68]] . . . December 11, 2020, at 10:27 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Dokuwiki]] . . . December 10, 2020, at 02:23 PM by [[~miniontoby]]: [=code blocks fixed=]%0a* [[Openbsd.Acme-client]] . . . December 09, 2020, at 06:47 PM by [[~miniontoby]]: [=fixed troubleshooting links=]%0a* [[Freedom.Christian]] . . . December 08, 2020, at 01:12 AM by [[~jrmu]]: [==]%0a* [[Freedom.Finances]] . . . December 08, 2020, at 01:04 AM by [[~jrmu]]: [==]%0a* [[Shell.Sshkeys]] . . . December 07, 2020, at 10:36 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Install67]] . . . December 06, 2020, at 11:03 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Buyvm]] . . . December 06, 2020, at 02:42 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Install]] . . . December 04, 2020, at 04:15 PM by [[~jrmu]]: [==]%0a* [[Opernbsd.Buyvm]] . . . December 04, 2020, at 12:06 PM by [[~jrmu]]: [==]%0a* [[Bouncer.WeeChat]] . . . December 02, 2020, at 12:43 PM by [[~jrmu]]: [==]%0a* [[Bouncer.SimpleIRC]] . . . December 02, 2020, at 12:31 PM by [[~jrmu]]: [==]%0a* [[Freedom.Militia]] . . . December 02, 2020, at 04:18 AM by [[~jrmu]]: [==]%0a* [[Third.Third]] . . . December 01, 2020, at 01:49 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Oidentd]] . . . November 30, 2020, at 11:42 PM by [[~jrmu]]: [==]%0a* [[Ircnow.Helper]] . . . November 28, 2020, at 02:21 AM by [[~jrmu]]: [==]%0a* [[Bouncer.Hexchat]] . . . November 27, 2020, at 12:52 PM by [[~jrmu]]: [==]%0a* [[Bouncer.IRCCloud]] . . . November 24, 2020, at 11:53 AM by [[~jrmu]]: [==]%0a* [[Bouncer.AdiIRC]] . . . November 24, 2020, at 11:42 AM by [[~jrmu]]: [==]%0a* [[Bouncer.RevolutionIRC]] . . . November 24, 2020, at 11:35 AM by [[~jrmu]]: [==]%0a* [[Bouncer.KiwiIRC]] . . . November 24, 2020, at 11:34 AM by [[~jrmu]]: [==]%0a* [[Bouncer.KVIrc]] . . . November 24, 2020, at 11:33 AM by [[~jrmu]]: [==]%0a* [[Bouncer.IceChat]] . . . November 24, 2020, at 11:27 AM by [[~jrmu]]: [==]%0a* [[Bouncer.IRCCloudiOS]] . . . November 24, 2020, at 11:20 AM by [[~jrmu]]: [==]%0a* [[Bouncer.IRCCloudAndroid]] . . . November 24, 2020, at 11:20 AM by [[~jrmu]]: [==]%0a* [[Bouncer.IRCCloudWeb]] . . . November 24, 2020, at 11:19 AM by [[~jrmu]]: [==]%0a* [[Third.Catalog]] . . . November 23, 2020, at 07:52 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Checklist]] . . . November 20, 2020, at 12:44 AM by [[~gry]]: [=+=]%0a* [[Openbsd.Acopm]] . . . November 04, 2020, at 03:32 PM by [[~jrmu]]: [==]%0a* [[Openbsd.Achurch]] . . . November 04, 2020, at 02:25 PM by [[~jrmu]]: [==]%0a* [[Openbsd.Vi]] . . . November 04, 2020, at 12:51 PM by [[~jrmu]]: [==]%0a* [[Openbsd.Sudo]] . . . November 04, 2020, at 12:38 PM by [[~jrmu]]: [==]%0a* [[Freedom.Denomination]] . . . October 23, 2020, at 09:20 AM by [[~jrmu]]: [==]%0a* [[Vps.Intro]] . . . October 10, 2020, at 08:22 AM by [[~jrmu]]: [==]%0a* [[Ircweb.Ircweb]] . . . October 05, 2020, at 01:10 AM by [[~jrmu]]: [==]%0a* [[Http2irc.Http2irc]] . . . October 05, 2020, at 01:04 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Easyapp]] . . . September 29, 2020, at 12:13 PM by [[~jrmu]]: [==]%0a* [[Orange.Nl]] . . . September 17, 2020, at 08:43 AM by [[~miniontoby]]: [=Dutch correct page=]%0a* [[Grape.Guide]] . . . September 16, 2020, at 08:42 AM by [[~baytuch]]: [==]%0a* [[Orange.Id]] . . . September 08, 2020, at 09:51 AM by [[~gry]]: [=+=]%0a* [[Orange.Ru]] . . . September 07, 2020, at 11:29 PM by [[~gry]]: [=+=]%0a* [[Bouncer.MIRC]] . . . September 06, 2020, at 03:59 AM by [[~jrmu]]: [==]%0a* [[Debate.Bncnow]] . . . September 04, 2020, at 04:36 AM by [[~jrmu]]: [==]%0a* [[Openbsd.Cgit]] . . . September 01, 2020, at 05:51 PM by [[~baytuch]]: [==]%0a* [[Orange.Notes]] . . . August 27, 2020, at 03:38 AM by [[~gry]]: [=expanded=]%0a* [[Shell.ShellSSHKEYS]] . . . August 25, 2020, at 10:00 PM by [[~gry]]: [=permissions added=]%0a* [[Bots.Bots]] . . . August 25, 2020, at 12:02 PM by [[~jrmu]]: [==]%0a* [[Bouncer.Irccloud]] . . . August 24, 2020, at 12:20 PM by [[~jrmu]]: [==]%0a* [[GrapeTeam.Tracker]] . . . August 24, 2020, at 10:16 AM by [[~gry]]: [=+=]%0a* [[GrapeTeam.GrapeTeam]] . . . August 24, 2020, at 10:13 AM by [[~jrmu]]: [==]%0a* [[Ircnow.Course]] . . . August 21, 2020, at 05:01 AM by [[~gry]]: [==]%0a* [[Openbsd.Bchs]] . . . August 20, 2020, at 07:11 AM by [[~jrmu]]: [==]%0a* [[Ircnow.Todo]] . . . August 20, 2020, at 06:48 AM by [[~jrmu]]: on_is_active php_session_active squirrelmailing sqsession_start troubleshooting authentication session_status config_default webmail_access modifications configuration unfortunately accessibility administrator webmail_error compatibility acceleration default_pref organization replacement disposition alternative information sourceforge permissions certificate interactive configuring preferences letsencrypt development compatible javascript configtest connection additional nameserver configured afterwards extracting attempting installing documents complains openhttpd functions localhost opensmtpd challenge supported subdomain receiving databases recommend necessary following languages delimiter directory debugging fusername essential addresses installed chrooted smtphost projects browsers normally location provides tlsmulti 26214400 required remember original security listener optional settings sendmail properly software specific licensed messages brackets instance writable services browsing defaults drawback continue opening control dovecot fastcgi already contact defines example initial unbound folders unusual request plugins general command servers defined private options however records contrib include restart because nologin disable exiting keypair baytuch strings misused charset appears content instead openbsd release sending mt_rand another subject version tarball warning charlie without changes resolve foxtrot uploads written client relayd needed return logout syntax longer cannot latest htdocs braces rather offset typing before themes ircnow frames across making should switch please detect secure invert readme global create update system locale report serial delete femail myname daemon lookup socket number errors trying issues actual stable inline attach master reload touch could color chown check chmod needs first intro shell rcctl php74 mkdir books hosts write above https there false using might every ascii happy delta curly array fatal bravo query where since which setup exist works notes saved files press alpha enter means class block title index chain strip lines known worry based ifend about zones this doas 2001 imap will well page your real acme make sure that aaaa ipv4 does fccf want 1008 2602 than sbin chsh help bind body some copy runs both must logs like when ctrl type echo xvzf find uses html many wiki easy fees more exec text once were have made mime done next move into ipv6 pop3 menu sign quit full motd hide give edit time www ssl etc var 127 day see has 162 bad gpl 451 fix ksh 644 zip its 755 ftp net way crt 634 usr 403 src nsd fpm dns max few db8 143 via by gz 22 cd rx 38 87 mv 80 9 +time=1678078240 Relayd.TLSMulti:1628325508: Relayd.Acceleration Openhttpd.Hosting Acme-client.Configure Pf.Guide Openssl.Http : troubleshooting acknowledgments configuration acceleration dramatically remote_addr server_port permissions server_addr connections simpletable certificate commentary configured especially consulting forwarding foreground plaintext correctly debugging fullchain openhttpd available forwarded verbosity splitting listening challenge following selective remaining instances directory stacksize newsyslog openfiles service1 service2 searches increase database disabled protocol symlinks starting services tlsmulti sortable requests complete template filtered properly networks rotation addition location listener expanded multiple messages concepts example keypair listens finally backlog running private www6tls warning openbsd respond content produce provide verbose replace hosting devices android earlier maximum inspect enabled another domains openssl syslogd reverse headers td76656 without archive default already missing labeled records address option actual relayd handle relays create nabble wwwtls define packet turned before client please border append serves common public errors either cannot number blocks syntax bottom daemon assume entire typing failed simply sample second notice output https certs class there check rcctl first pfctl width guide login fails queue where names large which value match avoid above ports using based wrong entry lines close title below doesn three users index known third proxy while strip 8020 sure 8001 8002 icmp 4096 have make 2001 need will both that ipv6 them this want acme they ipv4 your edit what sack time doas then must logs html 7691 into send busy wish from real upon look test like stop ones auto when well root load last says also ddos etc 443 crt sub see are any ip4 ios tcp org man cur 96m 128 its won var may nsd set dns how pem 100 dvv 127 168 192 ip6 db8 of n7 by ln= Relayd.Acceleration:1628324627: Pf.Guide Leafnode.Install Tcpip.Sockets Openbsd.Znc Openhttpd.Configure Openhttpd.Hosting Telnet.Http Znc.Chroot Openbsd.Netcat Acme-client.Configure Openssl.Http : troubleshooting acknowledgments eavesdropping configuration dramatically introduction acceleration permissions server_addr connections simpletable server_port remote_addr certificate integration application transparent forwarding encryption webhosting configured foreground indication afterwards especially commentary splitting openhttpd plaintext challenge openfiles forwarded stacksize listening selective necessary directory fullchain providing debugging correctly sometimes following newsyslog verbosity available instances location service1 service2 symlinks protocol possible searches template requests listener filtered bouncers sortable database rotation addition increase messages balancer networks properly features plumbing normally exposing leafnode starting disabled complete private example produce keypair openbsd missing warning running replace address labeled default records openssl sockets install android devices verbose td76656 archiv= blob - 09c5b7e4d55edc4be4be6b9f6c94289863e53894 blob + 646d5f0fdeeb8f77e1d7bfd85569d83ca912cbbc --- wiki.d/SiteAdmin.Blocklist-MoinMaster +++ wiki.d/SiteAdmin.Blocklist-MoinMaster @@ -1,10 +1,10 @@ version=pmwiki-2.2.130 ordered=1 urlencoded=1 -agent=w3m/0.5.3+git20220429 +agent=Mozilla/5.0 (Linux; Android 7.0; MI MAX) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/108.0.0.0 Mobile Safari/537.36 charset=UTF-8 ctime=1596101899 -host=38.87.162.8 +host=2001:448a:1022:2580:19f7:77df:8fc0:8232 name=SiteAdmin.Blocklist-MoinMaster passwdread=@lock -rev=616 +rev=617 text=%0a [@%0a## blocklist-note: NOTE: This page is automatically generated by blocklist.php%0a## blocklist-note: NOTE: Any edits to this page may be lost!%0a## blocklist-url: http://moinmo.in/BadContent?action=raw%0a## blocklist-when: 2020-07-30T09:38:19%0a# blocklist-format: regex%0a#### Unable to download blocklist (allow_url_fopen=)%0a @]%0a -time=1677821463 +time=1677994348 blob - 17abac8aa8ea8cb983380c8099d5ca61dfe467b9 blob + 4a86cd9b58d34b9675cd7e9d4d8f4fa15064c095 --- wiki.d/SiteAdmin.Status +++ wiki.d/SiteAdmin.Status @@ -1,12 +1,12 @@ -version=pmwiki-2.2.130 ordered=1 urlencoded=1 -agent=Mozilla/5.0 (X11; OpenBSD amd64; rv:76.0) Gecko/20100101 Firefox/76.0 +version=pmwiki-2.3.20 ordered=1 urlencoded=1 +agent=Mozilla/5.0 (X11; OpenBSD amd64; rv:68.0) Gecko/20100101 Firefox/68.0 SeaMonkey/2.53.14 author=simon -charset=ISO-8859-1 +charset=UTF-8 csum=Add summary, see how long a summary lasts?! -host=38.81.163.143 +host=198.251.81.133 name=SiteAdmin.Status -rev=25 +rev=26 targets= text=(:Summary: PmWiki version {$Version} (VersionNum={$VersionNum}):)%0a(:comment Any local edits to this page may be lost!:)%0a%0aThis site is running {$Version} (VersionNum={$VersionNum}).%0a -time=1596100312 -updatedto=2002130 +time=1678035288 +updatedto=2003020 blob - ab8771550b9860a198fb2d248702a04a788b35c3 blob + 9aad855d7696be00f081e0009df44817259a7133 --- wikilib.d/Category.GroupFooter +++ wikilib.d/Category.GroupFooter @@ -1,9 +1,9 @@ -version=pmwiki-2.2.105 ordered=1 urlencoded=1 +version=pmwiki-2.3.4 ordered=1 urlencoded=1 author=Petko charset=UTF-8 -csum=add request=1 for the new search on pmwiki.org +csum=You can use category={*$FullName}, see documentation on PageLists (+0) (+77) name=Category.GroupFooter -rev=73 +rev=75 targets= -text=(:Summary:content generated for Category list pages:)%0a----%0a[--'''{*$:Summary}'''--]%0a(:pagelist link={*$FullName} list=normal request=1:)%0a -time=1511113873 +text=(:Summary:Content generated for Category list pages:)%0a----%0a[--'''{*$:Summary}'''--]%0a(:pagelist link={*$FullName} list=normal request=1:)%0a(:comment You can use category={*$FullName}, see documentation on PageLists:) +time=1652600234 blob - d0856628430d270839913705dd9e0b7057bf26b9 blob + 32588e42c2d11ced5086a3adecea4e2a159d2f53 --- wikilib.d/Main.HomePage +++ wikilib.d/Main.HomePage @@ -5,5 +5,5 @@ csum=add summary name=Main.HomePage rev=203 targets=PmWiki.DocumentationIndex,PmWiki.InitialSetupTasks,PmWiki.BasicEditing,Main.WikiSandbox -text=(:Summary:The default home page for the PmWiki distribution:)%0aWelcome to PmWiki!%0a%0aA local copy of PmWiki's%0adocumentation has been installed along with the software,%0aand is available via the [[PmWiki/documentation index]]. %0a%0aTo continue setting up PmWiki, see [[PmWiki/initial setup tasks]].%0a%0aThe [[PmWiki/basic editing]] page describes how to create pages%0ain PmWiki. You can practice editing in the [[wiki sandbox]].%0a%0aMore information about PmWiki is available from [[http://www.pmwiki.org]].%0a +text=(:Summary:The default home page for the PmWiki distribution:)%0aWelcome to PmWiki!%0a%0aA local copy of PmWiki's%0adocumentation has been installed along with the software,%0aand is available via the [[PmWiki/documentation index]]. %0a%0aTo continue setting up PmWiki, see [[PmWiki/initial setup tasks]].%0a%0aThe [[PmWiki/basic editing]] page describes how to create pages%0ain PmWiki. You can practice editing in the [[wiki sandbox]].%0a%0aMore information about PmWiki is available from [[https://www.pmwiki.org]].%0a time=1400472661 blob - 5f2c91afbce8228721d45133566c664435313e30 blob + bd290c609f8867d5a206ab6586e343740fa07f40 --- wikilib.d/PmWiki.AccessKeys +++ wikilib.d/PmWiki.AccessKeys @@ -1,10 +1,10 @@ -version=pmwiki-2.2.85 ordered=1 urlencoded=1 -author=mfwolff +version=pmwiki-2.3.8 ordered=1 urlencoded=1 +author=MFWolff charset=UTF-8 -csum=link to skin 'lean' +csum=another https (+1) ctime=1137027716 name=PmWiki.AccessKeys -rev=110 +rev=112 targets=PmWiki.Drafts,PmWiki.Internationalizations,PmWiki.SitePreferences,Site.Preferences,Skins.Lean,Site.PageActions -text=(:Summary:Access keys are keyboard shortcuts for tasks that would otherwise require a mouse:)%0a(:Audience: visitors (intermediate) :)%0a%0aAccess keys (See also [[Wikipedia:access key]]s) are keyboard shortcuts for tasks that would otherwise require a mouse click. %0aThey are part of markup that may exist on any webpage.%0aOn PmWiki steps have been taken to make it easier to use access keys throughout a site, and to make it possible to adjust key assignments to accommodate different languages and preferences.%0a%0a!! Using access keys in different operating systems and browsers%0aAccess keys require you to hold down two or more keys.%0a* On Windows with Internet Explorer, press ALT + the access key.%0a* With Firefox, press SHIFT + ALT + the access key.%0a* On a Macintosh with Firefox, Omniweb, Internet Explorer, press Ctrl + the access key.%0a** With Safari (Version 4.0.2) press Ctrl + Option + the access key.%0a* With [[http://opera.com/browser/tutorials/nomouse/index.dml#access | Opera]] press Shift+Esc to enter (or exit) access-key mode.%0a* With Konqueror, press Ctrl to enter (or exit) access-key mode.%0a* With Chrome, press SHIFT + ALT + the access key%0a%0aExceptions exist for specific browsers, and specific versions. For example, %0a* Internet Explorer requires that the Enter key be pressed at the end of the sequence for versions 5 and up under Windows, but not under Macintosh (where access keys were not supported until after version 4.5). %0a* Firefox versions 1.5 and earlier simply use Alt, while Firefox version 2.0 uses Shift+Alt. %0a%0aNote, in cases of conflicts between the keyboard shortcuts assigned by browsers and access keys assigned by links and other markup on webpages, many browsers, including Mozilla, Netscape and Internet Explorer, allow access keys to override the browser defaults and require a different sequence to continue using overridden browser assignments (typically, by pressing and releasing the Alt key, instead of holding it down). %0a%0a!! Access key assignments in this PmWiki installation%0aThe following is a list of the currently defined access keys for built-in actions. Remember that the letters identified below must be used together with the combination listed above (depending on your operating system and browser). Note that some actions do not have a corresponding access key by default.%0a%0a|| border=1%0a||!Key Name ||!Key Value ||!Function ||%0a||ak_view || $[ak_view] ||view ||%0a||ak_edit || $[ak_edit] ||edit ||%0a||ak_history || $[ak_history] ||history ||%0a||ak_attach || $[ak_attach] ||attach ||%0a||ak_print || $[ak_print] ||print ||%0a||ak_backlinks || $[ak_backlinks] ||backlinks ||%0a||ak_logout || $[ak_logout] ||logout ||%0a||ak_recentchanges || $[ak_recentchanges] ||recent changes ||%0a||ak_save || $[ak_save] ||save or publish page ||%0a||ak_saveedit || $[ak_saveedit] ||save and keep editing ||%0a||ak_savedraft || $[ak_savedraft] ||save draft ||%0a||ak_preview || $[ak_preview] ||preview page ||%0a||ak_textedit || $[ak_textedit] ||jump to edit textarea || %0a||ak_em || $[ak_em] ||''emphasize'' text ||%0a||ak_strong || $[ak_strong] ||'''strong''' text ||%0aNote: If the 'Key Value' is the same as the 'Key Name', the access key is currently undefined.%0a%0a!! When can these access keys be used%0a* Access keys ak_view, ak_edit, ak_history, ak_attach, ak_print, ak_backlinks, ak_logout and ak_recentchanges can be used all the time%0a* Access keys ak_save, ak_saveedit, ak_savedraft, ak_preview, ak_textedit can only be used in edit mode%0a%0aFollowing table explains which button is activated by which access key. Note that the Cancel button has no access key.%0a|| border=1%0a||!Standard Edit mode ||![[Draft(s)]] Edit mode ||!Used Access Key ||%0a||Save ||Publish ||ak_save ||%0a|| ||Save draft ||ak_savedraft ||%0a||Save and edit ||Save draft and edit ||ak_saveedit ||%0a||Preview ||Preview ||ak_preview ||%0a%0a* Access keys ak_em and ak_strong work only in edit mode '''and''' when the GUIbuttons are enabled in local/config.php.%0a%0a%25audience%25 admins (intermediate)%0a!! [[#customkeys]] Customizing access keys%0aPmWiki uses the same "phrase translation" methods for access key mappings as it does for [[internationalization(s)]]. This makes it possible for administrators, skins, language translators, and visitors to all influence the way that specific keys are mapped to actions.%0a%0aSee [[SitePreferences]] and [[Site.Preferences]] for more information and a template.%0a%0aNote that some skins (e.g., [[Skins:Lean | Lean]]) don't use the translation mechanism. In this case one must edit the template file itself in order to change the access keys.%0a%0aBy convention, the translation phrases for all of the access key actions start with the characters "ak_", so that the page variable "[@$[ak_edit]@]" is replaced by the access key for editing as defined by the current preferences, language, skin default, or site default.%0a%0a!! Implementation of access keys%0aAccess keys are implemented in html as optional parameters that can be added to links and many other types of markup.%0a%0a'''Example:''' [@%3ca href="http://example.com" accesskey="x">Example%3c/a>@] would create a link to example.com that could be triggered by clicking on the linked word "example" or using the access key Akey+x. That same action key link could be created in PmWiki markup by typing [@%25accesskey="x"%25[[http://example.com|Example]]%25%25@], like this: %25accesskey="x"%25[[http://example.com|Example]]%25%25. Try it and see if it works. Note that this AKey+x access key only works this way on this page, because it is simply a shortcut for accessing the link that exists only on this page.%0a%0aThe list of access key assignments in default PmWiki installations generally work throughout a site because links have been created in PmWiki skins and editing screens that incorporate access key parameters using the access key translation phrases. One location where those links can be viewed is [[Site.PageActions]]. That page contains the links that the default PmWiki skin, and many other skins, use to generate links such as "View" "Edit" and "History" that appear on most pages (other than editing screens). Each of the links in that page also has an [@%25accesskey=$[ak_xxx]%25@] declaration in front of it, which enables a specific access key for that link.%0a%0a>>faq%3c%3c [[#faq]]%0a%0aQ: How can I change the keyboard shortcuts for editing and saving a page?%0aA: See [[#customkeys | Customizing access keys]].%0a%0a -time=1459417112 +text=(:Summary:Access keys are keyboard shortcuts for tasks that would otherwise require a mouse:)%0a(:Audience: visitors (intermediate) :)%0a%0aAccess keys (See also [[Wikipedia:access key]]s) are keyboard shortcuts for tasks that would otherwise require a mouse click. %0aThey are part of markup that may exist on any webpage.%0aOn PmWiki steps have been taken to make it easier to use access keys throughout a site, and to make it possible to adjust key assignments to accommodate different languages and preferences.%0a%0a!! Using access keys in different operating systems and browsers%0aAccess keys require you to hold down two or more keys.%0a* On Windows with Internet Explorer, press @@ALT@@ + the access key.%0a* With Firefox, press @@SHIFT + ALT@@ + the access key.%0a* On a Macintosh with Firefox, Omniweb, Internet Explorer, press @@Ctrl@@ + the access key.%0a** With Safari (Version 4.0.2) press @@Ctrl + Option@@ + the access key.%0a* With Konqueror, press @@Ctrl@@ to enter (or exit) access-key mode.%0a* With Chrome, press @@SHIFT + ALT@@ + the access key%0a* [[https://vivaldi.com/blog/access-keys-in-vivaldi/ | access keys in Vivaldi]]%0a%0aExceptions exist for specific browsers, and specific versions. For example, %0a* Internet Explorer requires that the Enter key be pressed at the end of the sequence for versions 5 and up under Windows, but not under Macintosh (where access keys were not supported until after version 4.5). %0a* Firefox versions 1.5 and earlier simply use Alt, while Firefox version 2.0 uses Shift+Alt. %0a%0aNote, in cases of conflicts between the keyboard shortcuts assigned by browsers and access keys assigned by links and other markup on webpages, many browsers, including Mozilla, Netscape and Internet Explorer, allow access keys to override the browser defaults and require a different sequence to continue using overridden browser assignments (typically, by pressing and releasing the Alt key, instead of holding it down). %0a%0a!! Access key assignments in this PmWiki installation%0aThe following is a list of the currently defined access keys for built-in actions. Remember that the letters identified below must be used together with the combination listed above (depending on your operating system and browser). Note that some actions do not have a corresponding access key by default.%0a%0a|| border=1%0a||!Key Name ||!Key Value ||!Function ||%0a||ak_view || $[ak_view] ||view ||%0a||ak_edit || $[ak_edit] ||edit ||%0a||ak_history || $[ak_history] ||history ||%0a||ak_attach || $[ak_attach] ||attach ||%0a||ak_print || $[ak_print] ||print ||%0a||ak_backlinks || $[ak_backlinks] ||backlinks ||%0a||ak_logout || $[ak_logout] ||logout ||%0a||ak_recentchanges || $[ak_recentchanges] ||recent changes ||%0a||ak_save || $[ak_save] ||save or publish page ||%0a||ak_saveedit || $[ak_saveedit] ||save and keep editing ||%0a||ak_savedraft || $[ak_savedraft] ||save draft ||%0a||ak_preview || $[ak_preview] ||preview page ||%0a||ak_textedit || $[ak_textedit] ||jump to edit textarea || %0a||ak_em || $[ak_em] ||''emphasize'' text ||%0a||ak_strong || $[ak_strong] ||'''strong''' text ||%0aNote: If the 'Key Value' is the same as the 'Key Name', the access key is currently undefined.%0a%0a!! When can these access keys be used%0a* Access keys ak_view, ak_edit, ak_history, ak_attach, ak_print, ak_backlinks, ak_logout and ak_recentchanges can be used all the time%0a* Access keys ak_save, ak_saveedit, ak_savedraft, ak_preview, ak_textedit can only be used in edit mode%0a%0aFollowing table explains which button is activated by which access key. Note that the Cancel button has no access key.%0a|| border=1%0a||!Standard Edit mode ||![[Draft(s)]] Edit mode ||!Used Access Key ||%0a||Save ||Publish ||ak_save ||%0a|| ||Save draft ||ak_savedraft ||%0a||Save and edit ||Save draft and edit ||ak_saveedit ||%0a||Preview ||Preview ||ak_preview ||%0a%0a* Access keys ak_em and ak_strong work only in edit mode '''and''' when the GUIbuttons are enabled in @@local/config.php@@.%0a%0a%25audience%25 admins (intermediate)%0a!! [[#customkeys]] Customizing access keys%0aPmWiki uses the same "phrase translation" methods for access key mappings as it does for [[internationalization(s)]]. This makes it possible for administrators, skins, language translators, and visitors to all influence the way that specific keys are mapped to actions.%0a%0aSee [[SitePreferences]] and [[Site.Preferences]] for more information and a template.%0a%0aNote that some skins (e.g., [[Skins:Lean | Lean]]) don't use the translation mechanism. In this case one must edit the template file itself in order to change the access keys.%0a%0aBy convention, the translation phrases for all of the access key actions start with the characters "ak_", so that the page variable "%25pmhlt%25[@$[ak_edit]@]" is replaced by the access key for editing as defined by the current preferences, language, skin default, or site default.%0a%0a!! Implementation of access keys%0aAccess keys are implemented in html as optional parameters that can be added to links and many other types of markup.%0a%0a'''Example:''' %25hlt html%25[@%3ca href="https://example.com" accesskey="x">Example%3c/a>@] would create a link to example.com that could be triggered by clicking on the linked word "example" or using the access key Akey+x. That same action key link could be created in PmWiki markup by typing %25hlt php%25[@%25accesskey="x"%25[[https://example.com|Example]]%25%25@], like this: %25accesskey="x"%25[[https://example.com|Example]]%25%25. Try it and see if it works. Note that this AKey+x access key only works this way on this page, because it is simply a shortcut for accessing the link that exists only on this page.%0a%0aThe list of access key assignments in default PmWiki installations generally work throughout a site because links have been created in PmWiki skins and editing screens that incorporate access key parameters using the access key translation phrases. One location where those links can be viewed is [[Site.PageActions]]. That page contains the links that the default PmWiki skin, and many other skins, use to generate links such as "View" "Edit" and "History" that appear on most pages (other than editing screens). Each of the links in that page also has an [@%25accesskey=$[ak_xxx]%25@] declaration in front of it, which enables a specific access key for that link.%0a%0a>>faq%3c%3c [[#faq]]%0a%0aQ: How can I change the keyboard shortcuts for editing and saving a page?%0aA: See [[#customkeys | Customizing access keys]].%0a%0a +time=1660032794 blob - 1e0825b86db6fafd3d284f9540c51fe6d1628bfa blob + a696cc5b7f2a5626e4b73eb75bf5cfc646a869fb --- wikilib.d/PmWiki.AuthUser +++ wikilib.d/PmWiki.AuthUser @@ -1,9 +1,9 @@ -version=pmwiki-2.2.118 ordered=1 urlencoded=1 -author=Petko +version=pmwiki-2.3.17 ordered=1 urlencoded=1 +author=Gregor charset=UTF-8 -csum=add !! FAQ heading when there are questions and answers +csum= (+47) name=PmWiki.AuthUser -rev=215 -targets=PmWiki.Passwords,PmWiki.ThoughtsOnAccessControl,Cookbook.QuickStartForAuthUser,PmWiki.PathVariables,PmWiki.PasswordsAdmin,SiteAdmin.AuthUser,PmWiki.SecurityVariables,PmWiki.AuthUser,PmWiki.BasicVariables,Cookbook.AuthUserViaMicrosoftLDAP,Cookbook.SessionSecurityAdvice,Cookbook.AuthUser,Cookbook.UserLastAction,PITS.00400,Cookbook.HtpasswdForm,Cookbook.UserAdmin -text=(:Summary:Authorization system that uses usernames and passwords:)%0a(:Audience: administrators (intermediate) :)%0aAuthUser is PmWiki's identity-based authorization system that allows access to pages to be controlled through the use of usernames and passwords. AuthUser can be used in addition to the [[Passwords | password-based]] scheme that is PmWiki's default configuration.%0a%0aAuthUser is a very flexible system for managing access control on pages, but flexibility can also bring complexity and increased maintenance overhead to the wiki administrator. This is why PmWiki defaults to the simpler password-based system. For some thoughts about the relative merits of the two approaches, see [[PmWiki:ThoughtsOnAccessControl]].%0a%0aSee also: [[Cookbook:Quick Start for AuthUser]].%0a%0a!! Activating AuthUser%0aTo activate PmWiki's identity-based system, add the following line%0ato ''local/config.php'':%0a%0a include_once("$FarmD/scripts/authuser.php");%0a%0aEnsure that you have [[PasswordsAdmin | set a site wide admin password]], otherwise you will not be able to edit [[SiteAdmin.AuthUser]].%0a%0a->%25note%25 Note: Older versions of PmWiki (before 2.2.0-beta58) use ''Site.AuthUser''.%0a%0aPmWiki caches some group and page authorization levels when a page is accessed. For this reason, it is better to include @@authuser.php@@ quite early in config.php, notably%0a* after any recipe which inserts some custom writable PageStore class (MySQL, SQLite, Compressed PageStore or other)%0a* and after any internationalization (UTF-8 and XLPage).%0a%0a(If you don't use a custom PageStore class and i18n, include @@authuser.php@@ first thing in @@config.php@@.)%0a%0aAll other recipes should be included after these.%0a%0a!! Creating user accounts%0aMost of AuthUser's configuration is performed via the [[SiteAdmin.AuthUser]] page. To change the AuthUser configuration, simply edit this page like any other wiki page (you'll typically need to use the site's admin password for this).%0a%0aTo create a login account, simply add lines to SiteAdmin.AuthUser that look like:%0a%0a username: [=(:=]encrypt ''password'':)%0a%0aFor example, to create a login account for "alice" with a password of "restaurant", enter:%0a%0a alice: [=(:=]encrypt restaurant:)%0a%0aWhen the page is saved, the "@@[=(:=]encrypt restaurant:)@@" part of the text will be replaced by an encrypted form of the password "restaurant". This encryption is done so that someone looking at the SiteAdmin.AuthUser page cannot easily determine the passwords stored in the page. %0a%0aTo change or reset an account's password, simply replace the encrypted string with another @@[=(:=]encrypt:)@@ directive.%0a%0a%25note%25 The password cannot contain spaces, tabs, new lines, columns ":" and equals "="; on some systems it should contain at least 4 characters. Usernames and passwords are case sensitive, eg. "User" is not the same as "user".%0a%0a!! Controlling access to pages by login%0a%0aPages and groups can be protected based on login account by using "passwords" of the form [@id:username@] in the password fields of [@?action=attr@] (see [[PmWiki.Passwords]]). For example, to restrict a page to being edited by Alice, one would set the password to "[@id:alice@]".%0a%0aIt's possible to use multiple "id:" declarations and passwords in the [@?action=attr@] form, thus the following setting would allow access to Alice, Carol, and anyone who knows the password "quick":%0a%0a quick id:alice,carol%0a%0aTo allow access to anyone who has successfully logged in, use "[@id:*@]".%0a%0aOne can also perform site-wide restrictions based on identity in the $DefaultPasswords array (in local/config.php): e.g.%0a%0a # require valid login before viewing pages%0a $DefaultPasswords['read'] = 'id:*';%0a # Alice and carol may edit%0a $DefaultPasswords['edit'] = 'id:alice,carol';%0a # All admins and Fred may edit%0a $DefaultPasswords['edit'] = array('@admins', 'id:Fred');%0a%0aYou can change the $DefaultPasswords array in local customization files such as:%0a* local/config.php (for entire wiki)%0a* farmconfig.php (for entire wikifarm)%0a%0a!! [[#auth_groups]] Organizing accounts into groups%0a%0aAuthUser also makes it possible to group login accounts together into authorization groups, indicated by a leading "@" sign. As with login accounts, group memberships are maintained by editing the SiteAdmin.AuthUser page. Group memberships can be specified by either listing the groups for a login account (person belongs to groups) or the login accounts for a group (group includes people). You can repeat or mix-and-match the two kinds as desired:%0a%0a @writers: alice, bob%0a carol: @writers, @editors%0a @admins: alice, dave%0a %0aThen, to restrict page access to a particular group, simply use "[@@group@]" as the "password" in [@?action=attr@] or the $DefaultPasswords array, similar to the way that "[@id:username@]" is used to restrict access to specific login accounts.%0a%0a!!! Excluding individuals from password groups%0a%0aGroup password memberships are maintained by editing the SiteAdmin.AuthUser page. To specify a password group that allows access to anyone who is authenticated, you can specify:%0a%0a @wholeoffice: *%0a%0aIf you need to keep "Fred" out of this password group :%0a%0a @wholeoffice: *,-Fred%0a%0aTo allow all users except Fred to change page attributes, for example, you can add to config.php :%0a $DefaultPasswords['attr'] = array('id:*,-Fred');%0a%0a(:if authid:)%0a>>clip%3c%3c%0a!!!!!Wiki Debug%0a* %25newwin%25 [[Diagnostics -> {$Name}?action=diag]]%0a* %25newwin%25 [[PHPInfo -> {$Name}?action=phpinfo]]%0a>>%3c%3c%0a(:ifend:)%0a%0a!! Getting account names and passwords from external sources%0a%0aThe AuthUser script has the capability of obtaining username/password pairs from places other than the SiteAdmin.AuthUser page, such as passwd-formatted files (usually called '.htpasswd' on Apache servers), [[#LDAP|LDAP]] servers, or even the ''local/config.php'' file.%0a%0a!!! Passwd-formatted files (.htpasswd/.htgroup)%0a%0aPasswd-formatted files, commonly called ''.htpasswd'' files in Apache, are text files where each line contains a username and an encrypted password separated by a colon. A typical ''.htpasswd'' file might look like:%0a%0a alice:vK99sgDV1an6I%0a carol:Q1kSeNcTfwqjs%0a%0aTo get AuthUser to obtain usernames and passwords from a ''.htaccess'' file, add the following line to SiteAdmin.AuthUser, replacing "/path/to/.htpasswd" with the filesystem path of the ''.htpasswd'' file:%0a%0a htpasswd: /path/to/.htpasswd%0a%0aCreation and maintenance of the ''.htpasswd'' file can be performed using a text editor, or any number of other third-party tools available for maintaining ''.htpasswd'' files. The Apache web server typically includes an ''htpasswd'' command for creating accounts in .htpasswd:%0a%0a $ htpasswd /path/to/.htpasswd alice%0a New password:%0a Re-type new password:%0a Adding password for user alice%0a $%0a%0aSimilarly, one can use ''.htgroup'' formatted files to specify group memberships. Each line has the name of a group (without the "@"), followed by a colon, followed by a space separated list of usernames in the group.%0a%0a writers: carol%0a editors: alice carol bob%0a admins: alice dave%0a%0aNote that the groups are still "@writers", "@editors", and "@admins" in PmWiki even though the file doesn't specify the @ signs. To get AuthUser to load these groups, use a line in SiteAdmin.AuthUser like:%0a%0a htgroup: /path/to/.htgroup%0a%0a!!! Configuration via ''local/config.php''%0a%0aAuthUser configuration settings can also be made from the ''local/config.php'' file in addition to the SiteAdmin.AuthUser page. Such settings are placed in the $AuthUser array, and ''must be set prior to including the ''authuser.php'' script''. Some examples:%0a%0a # set a password for alice%0a $AuthUser['alice'] = pmcrypt('restaurant');%0a # set a password for carol%0a $AuthUser['carol'] = '$1$CknC8zAs$dC8z2vu3UvnIXMfOcGDON0';%0a # define the @editors group%0a $AuthUser['@editors'] = array('alice', 'carol', 'bob');%0a # Use local/.htpasswd for usernames/passwords%0a $AuthUser['htpasswd'] = 'local/.htpasswd';%0a # Use local/.htgroup for group memberships%0a $AuthUser['htgroup'] = 'local/.htgroup';%0a%0a[[#LDAP]]%0a!!! Configuration via LDAP%0a%0aAuthentication can be performed via an external LDAP server -- simply set an entry for "ldap" in either SiteAdmin.AuthUser or the ''local/config.php'' file.%0a%0a # use ldap.airius.com for authentication%0a $AuthUser['ldap'] = 'ldap://ldap.airius.com/ou=People,o=Airius?cn?sub';%0a%0aMake sure to include AuthUser below the entry for the ldap server:%0a%0a # Want to use AuthUser so we can use ldap for passwords%0a include_once("$FarmD/scripts/authuser.php");%0a%0aAnd remember to assign the Security Variables for edit and history (or whatever):%0a%0a #Security Variables set login for edit & history page%0a # to let anyone edit that has an ldap entry:%0a $HandleAuth['diff'] = 'edit';%0a $DefaultPasswords['edit'] = 'id:*';%0a $Author = $AuthId;%0a%0aLDAP authentication in AuthUser closely follows the model used by Apache 2.0's [[http://httpd.apache.org/docs/2.0/mod/mod_auth_ldap.html|mod_auth_ldap]] module; see especially the documentation for [[http://httpd.apache.org/docs/2.0/mod/mod_auth_ldap.html#authldapurl|AuthLDAPUrl]] for a description of the url format.%0a%0aFor servers that don't allow anonymous binds, AuthUser provides $AuthLDAPBindDN and $AuthLDAPBindPassword variables to specify the binding to be used for searching.%0a%0aSee also [[Cookbook:AuthUser via Microsoft LDAP]]%0a%0a!! Setting the Author Name%0aBy default, PmWiki will use a login name in the Author field of the edit form, but allows the author to change this value prior to saving. To force the login name to always be used as the author name, use the following sequence in config.php to activate AuthUser:%0a%0a include_once("$FarmD/scripts/authuser.php");%0a $Author = $AuthId; # after include_once()%0a%0aTo allow more flexibility, but still enable changes to be linked to the authorized user, one can give the author name a prefix of the $AuthId instead:%0a[@%0a include_once("$FarmD/scripts/author.php");%0a include_once("$FarmD/scripts/authuser.php");%0a if ($Author) {%0a if (strstr($Author, '-') != false) {%0a $Author = "$AuthId-" . preg_replace('/^[^-]*-/', '', $Author);%0a } else if ($Author != $AuthId) {%0a $Author = $AuthId . '-' . $Author;%0a } else {%0a $Author = $AuthId;%0a }%0a } else {%0a $Author = $AuthId;%0a }%0a $AuthorLink = "[[~$Author]]";%0a@]%0aThe above will allow the user to put in the author name of their choice, but that will always be replaced by that name prefixed with "$AuthId-".%0aThe reason why $AuthorLink needs to be set is that, if it isn't, the RecentChanges page will have the wrong link in it.%0a%0a!!! Removing the "Author" edit field%0aTo force users to edit with their AuthID instead of having a field they can place any name in. This enables administration to keep track of who is doing what better. This line also links the Author name to their Profile.\\%0aGo to Site.EditForm, remove the line\\%0a[@$[Author]: (:input e_author:)@]\\%0aor replace it with\\%0a[@$[Author]: [[Profiles/{$Author}]]@]\\%0a%0a!! Authorization, Sessions, and WikiFarms [[#sessions]]%0a%0aPmWiki uses PHP sessions to keep track of any user authorization information. By default PHP is configured so that all interactions with the same server (as identified by the server's domain name) are treated as part of the same session.%0a%0aWhat this means for PmWiki is that if there are multiple wikis running within the same domain name, PHP will treat a login to one wiki as being valid for all wikis in the same domain. The easiest fix is to tell each wiki to have use a different "session cookie". Near the top of a wiki's ''local/config.php'' file, before calling authuser or other recipes, add a line like:%0a%0a-->[@session_name('XYZSESSID');@]%0a%0aThe XYZSESSID can be any unique name (letters only is safest). For the exact naming rules please lookup the [[description in the PHP manual -> http://php.net/session_name]] for the PHP version you use on your server.%0a%0a%25red%25'''Security Reminder:'''%25%25 Using different session names in cookies and/or URLs helps against inter-wiki confusion in a browser, but this is not a protection against session injection attacks on the server. See [[Cookbook:Session Security Advice]] for that.%0a%0a%0a!! See Also%0a%0a* [[PmWiki.Passwords]]%0a* [[PmWiki.PasswordsAdmin]]%0a* [[Cookbook:AuthUser]] for tips and tricks%0a* [[SiteAdmin.AuthUser]]%0a%0a!! FAQ%0a>>faq%3c%3c [[#faq]]%0aQ: Can I specify authorization group memberships from with ''local/config.php''?%0a%0aA: Yes -- put the group definition into the $AuthUser array (in config.php):%0a%0a $AuthUser['@editors'] = array('alice', 'carol', 'bob');%0a%0aQ: Can I have multiple admin groups?%0a%0aA: Yes, define the groups with @@ array('@admins', '@moderators'); @@ like this:%0a%0a $DefaultPasswords['admin'] = array( pmcrypt('masterpass'), # global password%0a '@admins', '@moderators', # +users in these groups%0a 'id:Fred', 'id:Barney'); # +users Fred and Barney%0a%0aQ: I'm running multiple wikis under the same domain name, and logins from one wiki are appearing on other wikis. Shouldn't they be independent?%0a%0aA: This is caused by the way that PHP treats sessions. See [[PmWiki.AuthUser#sessions]] for more details.%0a%0aQ: Is there any way to record the time of the last login for each user when using AuthUser? I need a way to look for stale accounts.%0a%0aA: See [[Cookbook:UserLastAction]].%0a%0aQ: Though every setting seems correct, authentication against LDAP is not working. There is nothing in ldap log, what's wrong?%0a%0aA: Be sure ldap php module is installed ( on debian apt-get install php(4|5)-ldap ; apache(2)ctl graceful )%0a%0aQ: The login form asks for username and password, but only password matters. %0a-> Username can be left blank and it still signs in under the account. Is this intentional and if so, can I change it so that the username and password must both be entered? - X 1/18/07 Never mind I think this has something to do with using the admin password. I created a test account and it's working ok.%0a%0aA: Make sure you are not entering the admin password when testing the account because, if the password is equal to the admin password, it will authenticate directly through the config.php file and skip any other system.%0a%0aA: Do note that even with AuthUser activated you can still log in with a blank username and only entering the password. In that case any password you enter will be "accepted" but only passwords which authenticate in the given context will actually give you any authorization rights. Using this capability AuthUser comfortably coexists with the default password-based system.%0a%0aIf you want to require both username and password, then you need to set an admin id '''before''' including authuser.php:%0a%0a[@%0a## Define usernames and passwords.%0a$AuthUser['carol'] = '$1$CknC8zAs$dC8z2vu3UvnIXMfOcGDON0';%0a%0a## Enable authentication based on username.%0ainclude_once('scripts/authuser.php');%0a%0a# $DefaultPasswords['admin'] = pmcrypt('secret');%0a$DefaultPasswords['admin'] = 'id:carol';%0a@]%0a%0aA username and password will then be required before login is successful.%0a%0aQ: Is there any way to hide IP addresses once someone has logged in so that registered users can keep their IP addresses invisible to everyone except administrators? - X 1/18/07%0a%0aA: Yes, see solution provided at PITS:00400.%0a%0aQ: Is there a way that people could self-register through AuthUser? %0a%0aA: You can see [[(Cookbook:)HtpasswdForm]] or [[(Cookbook:)UserAdmin]] for recipes providing this feature. %0a%0aQ: I would like it that after I have AuthUser turned and a user is authenticated to get on my site, that if I have a password put on a particular page or group that they don't get the AuthUser form to show up (username and password), but only the typical field for password?%0a%0aA: See [[this thread of the mailing list -> http://article.gmane.org/gmane.comp.web.wiki.pmwiki.user/52420]]. %0a -time=1567168090 +rev=227 +targets=PmWiki.Passwords,PmWiki.ThoughtsOnAccessControl,Cookbook.QuickStartForAuthUser,PmWiki.PathVariables,PmWiki.PasswordsAdmin,SiteAdmin.AuthUser,PmWiki.SecurityVariables,PmWiki.AuthUser,Cookbook.AuthUserViaMicrosoftLDAP,PmWiki.BasicVariables,Cookbook.SessionSecurityAdvice,Cookbook.AuthUser,Cookbook.UserLastAction,PITS.00400,Cookbook.HtpasswdForm,Cookbook.UserAdmin +text=(:Summary:Authorization system that uses usernames and passwords:)%0a(:Audience: administrators (intermediate) :)%0aAuthUser is PmWiki's identity-based authorization system that allows access to pages to be controlled through the use of usernames and passwords. AuthUser can be used in addition to the [[Passwords | password-based]] scheme that is PmWiki's default configuration.%0a%0aAuthUser is a very flexible system for managing access control on pages, but flexibility can also bring complexity and increased maintenance overhead to the wiki administrator. This is why PmWiki defaults to the simpler password-based system. For some thoughts about the relative merits of the two approaches, see [[PmWiki:ThoughtsOnAccessControl]].%0a%0aSee also: [[Cookbook:Quick Start for AuthUser]].%0a%0a!! Activating AuthUser%0aTo activate PmWiki's identity-based system, add the following line%0ato ''local/config.php'':%0a%0a-> %25hlt php%25@@include_once("$FarmD/scripts/authuser.php");@@%0a%0aEnsure that you have [[PasswordsAdmin | set a site wide admin password]], otherwise you will not be able to edit @@[[SiteAdmin.AuthUser]]@@.%0a%0a->%25note%25 Note: Older versions of PmWiki (before 2.2.0-beta58) use ''@@Site.AuthUser@@''.%0a%0aPmWiki caches some group and page authorization levels when a page is accessed. For this reason, it is better to include @@authuser.php@@ quite early in config.php, notably%0a* after any recipe which inserts some custom writable PageStore class (MySQL, SQLite, Compressed PageStore or other)%0a* and after any internationalization (UTF-8 and XLPage).%0a%0a(If you don't use a custom PageStore class and i18n, include @@authuser.php@@ first thing in @@config.php@@.)%0a%0aAll other recipes should be included after these.%0a%0a!! Creating user accounts%0aMost of AuthUser's configuration is performed via the [[SiteAdmin.AuthUser]] page. To change the AuthUser configuration, simply edit this page like any other wiki page (you'll typically need to use the site's admin password for this).%0a%0aTo create a login account, simply add lines to SiteAdmin.AuthUser that look like:%0a%0a->%25pmhlt%25@@username: (:encrypt ''password''[=:=])@@%0a%0aFor example, to create a login account for "alice" with a password of "restaurant", enter:%0a%0a->%25pmhlt%25@@alice: (:encrypt restaurant[=:=])@@%0a%0aWhen the page is saved, the "%25pmhlt%25@@(:encrypt restaurant:[=)=]@@" part of the text will be replaced by an encrypted form of the password "restaurant". This encryption is done so that someone looking at the SiteAdmin.AuthUser page cannot easily determine the passwords stored in the page. %0a%0aTo change or reset an account's password, simply replace the encrypted string with another %25pmhlt%25[@(:encrypt:)@] directive.%0a%0a%25note%25 The password cannot contain spaces, tabs, new lines, colon ":" and equals "="; on some systems it should contain at least 4 characters. Usernames and passwords are case sensitive, eg. "User" is not the same as "user".%0a%0a!! Controlling access to pages by login%0a%0aPages and groups can be protected based on login account by using "passwords" of the form %25pmhlt%25[@id:username@] in the password fields of [@?action=attr@] (see [[PmWiki.Passwords]]). For example, to restrict a page to being edited by Alice, one would set the password to "[@id:alice@]".%0a%0aIt's possible to use multiple "id:" declarations and passwords in the [@?action=attr@] form, thus the following setting would allow access to Alice, Carol, and anyone who knows the password "quick":%0a%0a quick id:alice,carol%0a%0aTo allow access to anyone who has successfully logged in, use "[@id:*@]".%0a%0aOne can also perform site-wide restrictions based on identity in the @@$DefaultPasswords@@ array (in @@local/config.php@@): e.g.%0a-> %25hlt php%25[@# require valid login before viewing pages%0a$DefaultPasswords['read'] = 'id:*';%0a# Alice and carol may edit%0a$DefaultPasswords['edit'] = 'id:alice,carol';%0a# All admins and Fred may edit%0a$DefaultPasswords['edit'] = array('@admins', 'id:Fred');@]%0a%0aYou can change the @@$DefaultPasswords@@ array in local customization files such as:%0a* @@local/config.php@@ (for entire wiki)%0a* @@farmconfig.php@@ (for entire wikifarm)%0a%0a!! [[#auth_groups]] Organizing accounts into groups%0a%0aAuthUser also makes it possible to group login accounts together into authorization groups, indicated by a leading "@" sign. As with login accounts, group memberships are maintained by editing the @@SiteAdmin.AuthUser@@ page. Group memberships can be specified by either listing the groups for a login account (person belongs to groups) or the login accounts for a group (group includes people). You can repeat or mix-and-match the two kinds as desired:%0a%0a @writers: alice, bob%0a carol: @writers, @editors%0a @admins: alice, dave%0a %0aThen, to restrict page access to a particular group, simply use "[@@group@]" as the "password" in [@?action=attr@] or the $DefaultPasswords array, similar to the way that "[@id:username@]" is used to restrict access to specific login accounts.%0a%0a!!! Excluding individuals from password groups%0a%0aGroup password memberships are maintained by editing the @@SiteAdmin.AuthUser@@ page. To specify a password group that allows access to anyone who is authenticated, you can specify:%0a%0a @wholeoffice: *%0a%0aIf you need to keep "Fred" out of this password group :%0a%0a @wholeoffice: *,-Fred%0a%0aTo allow all users except Fred to change page attributes, for example, you can add to @@config.php@@ :%0a-> %25hlt php%25@@$DefaultPasswords['attr'] = array('id:*,-Fred');@@%0a%0a(:if authid:) %25comment%25 should this be in here? %25%25%0a>>clip%3c%3c%0a!!!!!Wiki Debug%0a* %25newwin%25 [[Diagnostics -> {$Name}?action=diag]]%0a* %25newwin%25 [[PHPInfo -> {$Name}?action=phpinfo]]%0a>>%3c%3c%0a(:ifend:)%0a%0a!! Getting account names and passwords from external sources%0a%0aThe AuthUser script has the capability of obtaining username/password pairs from places other than the @@SiteAdmin.AuthUser@@ page, such as passwd-formatted files (usually called '.htpasswd' on Apache servers), [[#LDAP|LDAP]] servers, or even the ''@@local/config.php@@'' file.%0a%0a!!! Passwd-formatted files (.htpasswd/.htgroup)%0a%0aPasswd-formatted files, commonly called ''.htpasswd'' files in Apache, are text files where each line contains a username and an encrypted password separated by a colon. A typical ''.htpasswd'' file might look like:%0a%0a alice:vK99sgDV1an6I%0a carol:Q1kSeNcTfwqjs%0a%0aTo get AuthUser to obtain usernames and passwords from a ''.htaccess'' file, add the following line to @@SiteAdmin.AuthUser@@, replacing "/path/to/.htpasswd" with the filesystem path of the ''.htpasswd'' file:%0a%0a htpasswd: /path/to/.htpasswd%0a%0aCreation and maintenance of the ''.htpasswd'' file can be performed using a text editor, or any number of other third-party tools available for maintaining ''.htpasswd'' files. The Apache web server typically includes an ''htpasswd'' command for creating accounts in .htpasswd:%0a%0a $ htpasswd /path/to/.htpasswd alice%0a New password:%0a Re-type new password:%0a Adding password for user alice%0a $%0a%0aSimilarly, one can use ''.htgroup'' formatted files to specify group memberships. Each line has the name of a group (without the "@"), followed by a colon, followed by a space separated list of usernames in the group.%0a%0a writers: carol%0a editors: alice carol bob%0a admins: alice dave%0a%0aNote that the groups are still "@writers", "@editors", and "@admins" in PmWiki even though the file doesn't specify the @ signs. To get AuthUser to load these groups, use a line in @@SiteAdmin.AuthUser@@ like:%0a%0a htgroup: /path/to/.htgroup%0a%0a!!! Configuration via ''@@local/config.php@@''%0a%0aAuthUser configuration settings can also be made from the ''@@local/config.php@@'' file in addition to the @@SiteAdmin.AuthUser@@ page. Such settings are placed in the @@$AuthUser@@ array, and ''must be set prior to including the ''@@authuser.php@@'' script''. Some examples:%0a-> %25hlt php%25[@# set a password for alice%0a$AuthUser['alice'] = pmcrypt('restaurant');%0a# set a password for carol%0a$AuthUser['carol'] = '$1$CknC8zAs$dC8z2vu3UvnIXMfOcGDON0';%0a# define the @editors group%0a$AuthUser['@editors'] = array('alice', 'carol', 'bob');%0a# Use local/.htpasswd for usernames/passwords%0a$AuthUser['htpasswd'] = 'local/.htpasswd';%0a# Use local/.htgroup for group memberships%0a$AuthUser['htgroup'] = 'local/.htgroup';%0a%0ainclude_once("$FarmD/scripts/authuser.php");%0a@]%0a%0a[[#LDAP]]%0a!!! Configuration via LDAP%0a%0aAuthentication can be performed via an external LDAP server -- simply set an entry for "ldap" in either @@SiteAdmin.AuthUser@@ or the ''l@@ocal/config.php@@'' file.%0a-> %25hlt php%25[@# use ldap.airius.com for authentication%0a$AuthUser['ldap'] = 'ldap://ldap.airius.com/ou=People,o=Airius?cn?sub';@]%0a%0aMake sure to include AuthUser below the entry for the ldap server:%0a-> %25hlt php%25[@# Want to use AuthUser so we can use ldap for passwords%0ainclude_once("$FarmD/scripts/authuser.php");@]%0a%0aAnd remember to assign the Security Variables for edit and history (or whatever):%0a-> %25hlt php%25[@#Security Variables set login for edit & history page%0a# to let anyone edit that has an ldap entry:%0a$HandleAuth['diff'] = 'edit';%0a$DefaultPasswords['edit'] = 'id:*';%0a$Author = $AuthId;@]%0a%0aLDAP authentication in AuthUser closely follows the model used by Apache 2.0's [[https://httpd.apache.org/docs/2.4/mod/mod_authnz_ldap.html|mod_authnz_ldap]] module; see especially the documentation for [[https://httpd.apache.org/docs/2.4/mod/mod_authnz_ldap.html#authldapurl|AuthLDAPUrl]] for a description of the URL format.%0a%0aFor servers that don't allow anonymous binds, AuthUser provides @@$AuthLDAPBindDN@@ and @@$AuthLDAPBindPassword@@ variables to specify the binding to be used for searching.%0a%0aSee also [[Cookbook:AuthUser via Microsoft LDAP]]%0a%0a!! Setting the Author Name%0aBy default, PmWiki will use a login name in the Author field of the edit form, but allows the author to change this value prior to saving. To force the login name to always be used as the author name, use the following sequence in @@config.php@@ to activate AuthUser:%0a-> %25hlt php%25[@include_once("$FarmD/scripts/authuser.php");%0a$Author = $AuthId; # after include_once()@]%0a%0aTo allow more flexibility, but still enable changes to be linked to the authorized user, one can give the author name a prefix of the $AuthId instead:%0a%25hlt php%25[@%0a include_once("$FarmD/scripts/author.php");%0a include_once("$FarmD/scripts/authuser.php");%0a if ($Author) {%0a if (strstr($Author, '-') != false) {%0a $Author = "$AuthId-" . preg_replace('/^[^-]*-/', '', $Author);%0a } else if ($Author != $AuthId) {%0a $Author = $AuthId . '-' . $Author;%0a } else {%0a $Author = $AuthId;%0a }%0a } else {%0a $Author = $AuthId;%0a }%0a $AuthorLink = "[[~$Author]]";%0a@]%0aThe above will allow the user to put in the author name of their choice, but that will always be replaced by that name prefixed with "$AuthId-".%0aThe reason why $AuthorLink needs to be set is that, if it isn't, the @@RecentChanges@@ page will have the wrong link in it.%0a%0a!!! Removing the "Author" edit field%0aTo force users to edit with their AuthID instead of having a field they can place any name in. This enables administration to keep track of who is doing what better. This line also links the Author name to their Profile.\\%0aGo to @@Site.EditForm@@, remove the line%0a-> %25pmhlt%25[@$[Author]: (:input e_author:)@]%0aor replace it with%0a-> %25pmhlt%25[@$[Author]: [[Profiles/{$Author}]]@]%0a%0a!! Authorization, Sessions, and WikiFarms [[#sessions]]%0a%0aPmWiki uses PHP sessions to keep track of any user authorization information. By default PHP is configured so that all interactions with the same server (as identified by the server's domain name) are treated as part of the same session.%0a%0aWhat this means for PmWiki is that if there are multiple wikis running within the same domain name, PHP will treat a login to one wiki as being valid for all wikis in the same domain. The easiest fix is to tell each wiki to have use a different "session cookie". Near the top of a wiki's ''@@local/config.php@@'' file, before calling authuser or other recipes, add a line like:%0a%0a-->%25hlt php%25[@session_name('XYZSESSID');@]%0a%0aThe XYZSESSID can be any unique name (letters only is safest). For the exact naming rules please lookup the [[description in the PHP manual -> https://www.php.net/session_name]] for the PHP version you use on your server.%0a%0a%25red%25'''Security Reminder:'''%25%25 Using different session names in cookies and/or URLs helps against inter-wiki confusion in a browser, but this is not a protection against session injection attacks on the server. See [[Cookbook:Session Security Advice]] for that.%0a%0a%0a!! See Also%0a%0a* [[PmWiki.Passwords]]%0a* [[PmWiki.PasswordsAdmin]]%0a* [[Cookbook:AuthUser]] for tips and tricks%0a* [[SiteAdmin.AuthUser]]%0a%0a!! FAQ%0a>>faq%3c%3c [[#faq]]%0aQ: Can I specify authorization group memberships from with ''@@local/config.php@@''?%0a%0aA: Yes -- put the group definition into the $AuthUser array (in @@config.php@@):%0a-> %25hlt php%25[@$AuthUser['@editors'] = array('alice', 'carol', 'bob');@]%0a%0aQ: Can I have multiple admin groups?%0a%0aA: Yes, define the groups with %25hlt php%25@@ array('@admins', '@moderators'); @@ like this:%0a-> %25hlt php%25[@$DefaultPasswords['admin'] = array( pmcrypt('masterpass'), # global password%0a '@admins', '@moderators', # +users in these groups%0a 'id:Fred', 'id:Barney'); # +users Fred and Barney@]%0a%0aQ: I'm running multiple wikis under the same domain name, and logins from one wiki are appearing on other wikis. Shouldn't they be independent?%0a%0aA: This is caused by the way that PHP treats sessions. See [[PmWiki.AuthUser#sessions]] for more details.%0a%0aQ: Is there any way to record the time of the last login for each user when using AuthUser? I need a way to look for stale accounts.%0a%0aA: See [[Cookbook:UserLastAction]].%0a%0aQ: Though every setting seems correct, authentication against LDAP is not working. There is nothing in ldap log, what's wrong?%0a%0aA: Be sure ldap php module is installed ( on debian apt-get install php(4|5)-ldap ; apache(2)ctl graceful )%0a%0aQ: The login form asks for username and password, but only password matters. %0a-> Username can be left blank and it still signs in under the account. Is this intentional and if so, can I change it so that the username and password must both be entered? - X 1/18/07 Never mind I think this has something to do with using the admin password. I created a test account and it's working ok.%0a%0aA: Make sure you are not entering the admin password when testing the account because, if the password is equal to the admin password, it will authenticate directly through the @@config.php@@ file and skip any other system.%0a%0aA: Do note that even with AuthUser activated you can still log in with a blank username and only entering the password. In that case any password you enter will be "accepted" but only passwords which authenticate in the given context will actually give you any authorization rights. Using this capability AuthUser comfortably coexists with the default password-based system.%0a%0aIf you want to require both username and password, then you need to set an admin id '''before''' including @@authuser.php@@:%0a-> %25hlt php%25[@%0a## Define usernames and passwords.%0a$AuthUser['carol'] = '$1$CknC8zAs$dC8z2vu3UvnIXMfOcGDON0';%0a%0a## Enable authentication based on username.%0ainclude_once('scripts/authuser.php');%0a%0a# $DefaultPasswords['admin'] = pmcrypt('secret');%0a$DefaultPasswords['admin'] = 'id:carol';%0a@]%0a%0aA username and password will then be required before login is successful.%0a%0aQ: Is there any way to hide IP addresses once someone has logged in so that registered users can keep their IP addresses invisible to everyone except administrators? - X 1/18/07%0a%0aA: Yes, see solution provided at PITS:00400.%0a%0aQ: Is there a way that people could self-register through AuthUser? %0a%0aA: You can see [[(Cookbook:)HtpasswdForm]] or [[(Cookbook:)UserAdmin]] for recipes providing this feature. %0a%0aQ: I would like it that after I have AuthUser turned and a user is authenticated to get on my site, that if I have a password put on a particular page or group that they don't get the AuthUser form to show up (username and password), but only the typical field for password?%0a%0aA: See [[this thread of the mailing list (authuser vs passwords) -> https://www.pmwiki.org/pipermail/pmwiki-users/2008-November/052767.html]]. %0a%0aQ: How to allow a group or a page for reading or editing, only to signed-in users?%0a%0aA: You can set the password fields to @@id:*@@. Navigate to Group.Page?action=attr (for a single page) or to Group.GroupAttributes?action=attr (for the whole group) and fill the fields "New read password" and "New edit password" with @@id:*@@ then save the form.%0a +time=1673008066 blob - 62030f6ce7b1f1ddd2b196d4dd0500c1b04522bd blob + 159c58f82f5c4d62ea16bae8a214bcd2f8155c69 --- wikilib.d/PmWiki.AvailableActions +++ wikilib.d/PmWiki.AvailableActions @@ -1,9 +1,9 @@ -version=pmwiki-2.2.129 ordered=1 urlencoded=1 -author=simon +version=pmwiki-2.3.18 ordered=1 urlencoded=1 +author=simon charset=UTF-8 -csum=ppdonate (+89) +csum=rmpi (-1) name=PmWiki.AvailableActions -rev=143 -targets=PmWiki.Security,PmWiki.Passwords,PmWiki.ChangeLog,PmWiki.SitePageActions,PmWiki.SecurityVariables,PmWiki.PageHistory,PmWiki.UploadVariables,PmWiki.BasicEditing,Site.AuthForm,PmWiki.LayoutVariables,PmWiki.RefCount,PmWiki.Search,PmWiki.WebFeeds,PmWiki.Uploads,PmWiki.SitePreferences,PmWiki.DebugVariables,PmWiki.CustomMarkup,Cookbook.MarkupRulesetDebugging,PmWiki.SiteAnalyzer,PmWiki.AnalyzeResults,PmWiki.UrlApprovals,PmWiki.CustomActions,Cookbook.UserAuth2,Cookbook.Attachman,Cookbook.BackupPages,Cookbook.SearchCloud,Cookbook.CodeMirror,Cookbook.CommentBox,Cookbook.Comments,Cookbook.CommentDb,Cookbook.ROEPatterns,Cookbook.ConvertTable,Cookbook.MovePage,Cookbook.CSVAction,Cookbook.Attachtable,Cookbook.DeleteAction,Cookbook.DiscussionTab,Cookbook.DownloadManager,Cookbook.ExpireDiff,Cookbook.ImportText,Cookbook.MultiLanguageViews,Cookbook.RenamePage,Cookbook.ListCategories,Cookbook.CommentBoxPlus,Cookbook.GeneratePDF,Cookbook.PmWiki2PDF,Cookbook.UploadForm,Cookbook.PPDonate,Cookbook.PublishPDF,Cookbook.ASCIIMath,Cookbook.ThumbList,Cookbook.Mini,Cookbook.RecipeCheck,Cookbook.PageRegenerate,Cookbook.Reindex,Cookbook.SharedPages,PmWiki.WikiFarms,Cookbook.Sitemapper,Cookbook.TotalCounter,Cookbook.Trash,Cookbook.WebAdmin,Cookbook.ZAP,Cookbook.ChoiceColorChanger -text=(:Summary: All PmWiki page actions (?action=) and other query parameters:)%0aPage actions are applied to wiki pages, as a [[Wikipedia:Query_string|query string]] appended to the [[Wikipedia:Uniform_Resource_Locator|URL]].%0a[[Security]] can be applied to all [[#defaultactions|default actions]], and [[#scriptactions|script actions]] with one exception, but not [[#enablediag|diag actions]], through the use of [[passwords]].%0a%0aAlso documented are all other URL queries.%0a%0a'''NOTE:''' All actions will be disabled if the following is set:%0a%0a[@%0a $EnableActions = 0;%0a include('pmwiki.php');%0a@]%0a%0aThis will initialize PmWiki (along with any configuration/customizations%0athat are being made, e.g. from local/config.php), but won't actually%0aperform any actions. The caller can then call the desired action%0aor other functions as desired. This is available from [[PmWiki/ChangeLog#v22022|Version 2.2.0-beta22]] on up.%0a%0a%0a[[#defaultactions]]%0a!! PmWiki Actions%0aSee also [[site page actions]].%0a%0a[[#attr]]%0a:?action='''attr''': displays dialog for setting/changing password of the specified page or group of pages, see [[PmWiki/passwords]], see also $EnablePostAttrClearSession if you do not want to have the session cleared after validating change [- {PmWiki/Passwords$:Summary} -]%0a%0a[[#browse]]%0a:?action='''browse''': display the specified page (default action if no [@?action=@] is present)%0a%0a[[#crypt]]%0a:?action='''crypt''': displays a form for generating hashed [[Passwords | passwords]] out of clear text for usage in your config.php%0a%0a[[#diff]]%0a:?action='''diff''': show a change history of the specified page, see [[PmWiki/page history]] [- {PmWiki/PageHistory$:Summary} -]%0a%0a[[#download]]%0a:?action='''download'''&upname=''file.ext'': retrieve the page's attachment named ''file.ext'', see $EnableDirectDownload%0a%0a[[#edit]]%0a:?action='''edit''': edit the specified page, see [[PmWiki/basic editing]] [- {PmWiki/BasicEditing$:Summary} -]%0a%0a[[#login]]%0a:?action='''login''': prompt visitor for username/password, by default using [[Site.AuthForm]]%0a%0a[[#logout]]%0a:?action='''logout''': remove author, password, and login information%0a%0a[[#print]]%0a:?action='''print''': display the specified page using the skin specified by $ActionSkin['print']%0a%0a[[#refcount]]%0a:?action='''refcount''': bring up the reference count form, which allows the user to generate a list of links (all, missing, existing or orphaned) in or from specified groups. See [[Ref Count]] [- {PmWiki/RefCount$:Summary} -]. Part of the core distribution but must be enabled by the administrator.%0a%0a[[#search]]%0a:?action='''search''': displays searchbox on current page, see [[PmWiki/search]] [- {PmWiki/Search$:Summary} -]%0a:?action='''search'''&q=''searchterm'': performs search with ''searchterm'' and displays results on current page%0a:?action='''search'''&q=link=''pagename'': performs backlinks search with ''pagename'' and displays results on current page%0a%0a[[#source]]%0a:?action='''source''': show page source%0a%0a[[#feed]]%0a:?action='''atom''':%0a:?action='''rdf''':%0a:?action='''rss''':%0a:?action='''dc''': If [[web feeds]] are enabled, returns a syndication feed based on the contents of the page or other options provided by the url, see [[PmWiki/web feeds]] [- {PmWiki/WebFeeds$:Summary} -]%0a%0a[[#upload]]%0a:?action='''upload''': display a form to upload an attachment for the current group, see [[PmWiki/uploads]] [- {Cookbook/Uploads$:Summary} -]%0a[[#defaultactionsend]]%0a----%0a[[#querystrings]]%0a!! Query string parameters%0a%0a[[#from]]%0a:?'''from'''=''page name'': use when a page is redirected%0a%0a[[#n]]%0a:?'''n'''=''page name'': display page%0a%0a[[#setprefs]]%0a:?'''setprefs'''=''SomeGroup.CustomPreferences'': sets cookie to custom preferences page. See [[PmWiki/site preferences]] [- {PmWiki/SitePreferences$:Summary} -]%0a----%0a[[#enablediag]]%0a!! Actions enabled by $EnableDiag%0a[[#BEGENABLEDIAG]]%0aThe following actions are available only if you set @@$EnableDiag = 1;@@ in your configuration file. They can be used for debugging and should not be set in a production environment.%0a%0a:?action='''ruleset''': displays a list of all markups in 4 columns:%0a** column 1 = markup-name (1. parameter of markup() )%0a** column 2 = when will rule apply (2. parameter of markup() )%0a** column 3 = PmWiki's internal sort key (derived from #2)%0a** column 4 = Debug backtrace information for potentially incompatible rules (filename, line number, pattern)%0a->(see [[Custom Markup]] [- {PmWiki/CustomMarkup$:Summary} -]).%0a->To see more than what [@?action=ruleset@] gives you, apply the [[Cookbook:MarkupRulesetDebugging]] recipe: it can also show the pattern and the replacement strings.%0a** doesn't make use of PmWiki's authorization mechanisms.%0a%0a[[#phpinfo]]%0a:?action='''phpinfo''': displays the output of phpinfo() and exits. No page will be processed%0a** doesn't make use of PmWiki's authorization mechanisms.%0a%0a[[#diag]]%0a:?action='''diag''': displays a dump of all global vars and exits. No page will be processed%0a** doesn't make use of PmWiki's authorization mechanisms.%0a%0a[[#ENDENABLEDIAG]]%0a----%0a[[#scriptactions]]%0a!! Actions enabled by PmWiki Scripts%0a%0a[[#analyse]]%0a:?action='''analyze''': see [[(PmWiki:)Site Analyzer]] and [[(PmWiki:)Analyze Results]]%0a%0a[[#approvesites]]%0a:?action='''approvesites''': see [[PmWiki/Url approvals]] [- {PmWiki/UrlApprovals$:Summary} -]%0a** doesn't make use of PmWiki's authorization mechanisms.%0a%0a[[#analyseend]]%0a----%0a[[#cookbook]]%0a!! Actions enabled by [[Cookbook(:.)]] recipes%0a(more information about [[(PmWiki:)Custom Actions]])%0a%0a:?action='''admin''': see [[Cookbook:UserAuth2]] [- {Cookbook/UserAuth2$:Summary} -]%0a%0a:?action='''attachman''': see [[Cookbook:Attachman]] [- {Cookbook/Attachman$:Summary} -]%0a%0a:?action='''backup''': see [[Cookbook:BackupPages]] [- {Cookbook/BackupPages$:Summary} -]%0a%0a:?action='''clearsky''': see [[Cookbook:SearchCloud]] [- {Cookbook/SearchCloud$:Summary} -]%0a%0a:?action='''cm-dependencies''': see [[Cookbook:CodeMirror]] [- {Cookbook/CodeMirror$:Summary} -]%0a%0a:?action='''comment''': see [[Cookbook:CommentBox]] [- {Cookbook/CommentBox$:Summary} -]%0a%0a:?action='''comments''': see [[Cookbook:Comments]] [- {Cookbook/Comments$:Summary} -]%0a%0a:?action='''comment-rss''': see [[Cookbook:CommentDb]] [- {Cookbook/CommentDb$:Summary} -]%0a%0a:?action='''convert''': see [[Cookbook:ROEPatterns]] [- {Cookbook/ROEPatterns$:Summary} -]%0a%0a:?action='''converttable''': [[Cookbook:ConvertTable]] [- {Cookbook/ConvertTable$:Summary} -]%0a%0a:?action='''copy''': see [[Cookbook:MovePage]] [- {Cookbook/MovePage$:Summary} -]%0a%0a:?action='''csv''': see [[Cookbook/CSVAction]] [- {Cookbook/CSVAction$:Summary} -]%0a%0a:?action='''downloaddeleted''':%0a:?action='''delattach''':%0a:?action='''deldelattach''':%0a:?action='''fileinfo''':%0a:?action='''thumbnail''':%0a:?action='''undelattach''': [[Cookbook:Attachtable]] [- {Cookbook/Attachtable$:Summary} -]%0a%0a:?action='''delete''': see [[Cookbook:DeleteAction]] [- {Cookbook/DeleteAction$:Summary} -]%0a%0a:?action='''discuss''': see [[Cookbook:DiscussionTab]] [- {Cookbook/DiscussionTab$:Summary} -]%0a%0a:?action='''downloadman''': see [[Cookbook:DownloadManager]] [- {Cookbook/DownloadManager$:Summary} -]%0a%0a:?action='''expirediff''': see [[Cookbook:ExpireDiff]] [- {Cookbook/ExpireDiff$:Summary} -]%0a%0a:?action='''import''': see [[Cookbook:ImportText]] [- {Cookbook/ImportText$:Summary} -]%0a%0a:?action='''lang''': see [[Cookbook:MultiLanguageViews]] [- {Cookbook/MultiLanguageViews$:Summary} -]%0a:?action='''setlang''': see [[Cookbook:MultiLanguageViews]] [- {Cookbook/MultiLanguageViews$:Summary} -]%0a%0a:?action='''links''': see [[Cookbook:RenamePage]] [- {Cookbook/RenamePage$:Summary} -]%0a%0a:?action='''move''': see [[Cookbook:MovePage]] [- {Cookbook/MovePage$:Summary} -]%0a%0a:?action='''pageindex''': see [[Cookbook:ListCategories]] [- {Cookbook/ListCategories$:Summary} -]%0a%0a:?action='''PageUrl''': see [[Cookbook:CommentBoxPlus]] [- {Cookbook/CommentBoxPlus$:Summary} -]%0a%0a:?action='''pdf''': see [[Cookbook:GeneratePDF]] [- {Cookbook/GeneratePDF$:Summary} -] or [[Cookbook:PmWiki2PDF]] [- {Cookbook/PmWiki2PDF$:Summary} -]%0a%0a:?action='''postupload2''': see [[Cookbook:UploadForm]] [- {Cookbook/UploadForm$:Summary} -]%0a%0a:?action='''ppdonate''': see [[Cookbook:PPDonate]] - [- {Cookbook/PPDonate$:Summary} -]%0a%0a:?action='''publish''': see [[Cookbook:PublishPDF]] [- {Cookbook/PublishPDF$:Summary} -]%0a%0a:?action='''purgeqns''': see [[Cookbook:ASCIIMath]] [- {Cookbook/ASCIIMath$:Summary} -]%0a%0a:?action='''pwchange''': see [[Cookbook:UserAuth2]] [- {Cookbook/UserAuth2$:Summary} -]%0a%0a:?action='''imgtpl''': (the ''imgtpl'' action is called automatically and should not be called by a link in a wiki page)%0a:?action='''createthumb''': (the ''createthumb'' action is called automatically and should not be called by a link in a wiki page)%0a:?action='''mini''': (this action is called automatically and should not be called by a link in a wiki page)%0a:?action='''purgethumbs''': see [[Cookbook:ThumbList]] [- {Cookbook/ThumbList$:Summary} -] \\%0a see [[Cookbook:Mini]] [- {Cookbook/Mini$:Summary} -]%0a%0a:?action='''recipecheck''': see [[Cookbook:RecipeCheck]] [- {Cookbook/RecipeCheck$:Summary} -]%0a%0a:?action='''regen''': see [[Cookbook:PageRegenerate]] [- {Cookbook/PageRegenerate$:Summary} -]%0a%0a:?action='''reindex''': see [[Cookbook:Reindex]] [- {Cookbook/Reindex$:Summary} -]%0a%0a:?action='''rename''':%0a:?action='''links''': see [[Cookbook:RenamePage]] [- {Cookbook/RenamePage$:Summary} -]%0a%0a:?action='''share''':%0a:?action='''unshare''': see [[Cookbook:SharedPages]] [- {Cookbook/SharedPages$:Summary} -]%0a%0a:?action='''sitemapaddgroups''':%0a:?action='''sitemapupdate''': see [[Cookbook:Sitemapper]] [- {Cookbook/Sitemapper$:Summary} -]%0a%0a:?action='''totalcounter''': see [[Cookbook:TotalCounter]] [- {Cookbook/TotalCounter$:Summary} -]%0a%0a:?action='''trash''':%0a:?action='''untrash''': see [[Cookbook:Trash]] [- {Cookbook/Trash$:Summary} -]%0a%0a:?action='''webadmin''': see [[Cookbook:WebAdmin]] [- {Cookbook/WebAdmin$:Summary} -]%0a%0a:?action='''zap''': see [[Cookbook:ZAP]] [- {Cookbook/ZAP$:Summary} -]%0a[[#cookbookend]]%0a----%0a[[#cookbookqueryskins]]%0a!! Query string parameters enabled by [[Cookbook(:.)]] recipes%0a%0a:?'''color'''=''colorscheme'':%0a:?'''setcolor'''=''colorscheme''%0a:?'''skintheme'''=''theme'':%0a:?'''setskintheme'''=''theme'': see [[Cookbook:ChoiceColorChanger ]] [- {Cookbook/ChoiceColorChanger $:Summary} -]%0a%0a%0a:?'''skin'''=''skinname'':%0a:?'''setskin'''=''skinname'': see [[http://www.pmwiki.org/wiki/Skins/SkinChange|SkinChange]] [- {Skins/SkinChange$:Summary} -]%0a%0a!!Custom actions%0a%0a*See [[(PmWiki:)CustomActions]]. -time=1591246088 +rev=152 +targets=PmWiki.Security,PmWiki.Passwords,PmWiki.ChangeLog,PmWiki.SitePageActions,PmWiki.SecurityVariables,PmWiki.PageHistory,PmWiki.UploadVariables,PmWiki.BasicEditing,Site.AuthForm,PmWiki.LayoutVariables,PmWiki.RefCount,PmWiki.Search,Cookbook.EditTemplates,PmWiki.WebFeeds,PmWiki.Uploads,PmWiki.SitePreferences,PmWiki.DebugVariables,PmWiki.CustomMarkup,Cookbook.MarkupRulesetDebugging,PmWiki.SiteAnalyzer,PmWiki.AnalyzeResults,PmWiki.UrlApprovals,PmWiki.CustomActions,Cookbook.UserAuth2,Cookbook.Attachman,Cookbook.BackupPages,Cookbook.SearchCloud,Cookbook.CodeMirror,Cookbook.CommentBox,Cookbook.Comments,Cookbook.CommentDb,Cookbook.ROEPatterns,Cookbook.ConvertTable,Cookbook.MovePage,Cookbook.CSVAction,Cookbook.Attachtable,Cookbook.DeletePage,Cookbook.DiscussionTab,Cookbook.DownloadManager,Cookbook.ExpireDiff,Cookbook.HideDiff,Cookbook.ImportText,Cookbook.MultiLanguageViews,Cookbook.RenamePage,Cookbook.ListCategories,Cookbook.CommentBoxPlus,Cookbook.GeneratePDF,Cookbook.PmWiki2PDF,Cookbook.UploadForm,Cookbook.PPDonate,Cookbook.PublishPDF,Cookbook.ASCIIMath,Cookbook.ThumbList,Cookbook.Mini,Cookbook.RecipeCheck,Cookbook.PageRegenerate,Cookbook.Reindex,Cookbook.ReindexCategories,Test.PageIndex,Cookbook.SharedPages,PmWiki.WikiFarms,Cookbook.Sitemapper,Cookbook.TotalCounter,Cookbook.Trash,Cookbook.WebAdmin,Cookbook.ZAP,Cookbook.ChoiceColorChanger,Skins.Choice +text=(:Summary: All PmWiki page actions (?action=) and other query parameters:)%0aPage actions are applied to wiki pages, as a [[Wikipedia:Query_string|query string]] appended to the [[Wikipedia:Uniform_Resource_Locator|URL]].%0a[[Security]] can be applied to all [[#defaultactions|default actions]], and [[#scriptactions|script actions]] with one exception, but not [[#enablediag|diag actions]], through the use of [[passwords]].%0a%0aAlso documented are all other URL queries.%0a%0a'''NOTE:''' All actions will be disabled if the following is set:%0a%0a%25hlt php%25[@%0a $EnableActions = 0;%0a include('pmwiki.php');%0a@]%0a%0aThis will initialize PmWiki (along with any configuration/customizations%0athat are being made, e.g. from @@local/config.php@@), but won't actually%0aperform any actions. The caller can then call the desired action%0aor other functions as desired. This is available from [[PmWiki/ChangeLog#v22022|Version 2.2.0-beta22]] on up.%0a%0a%0a[[#defaultactions]]%0a!! PmWiki Actions%0aSee also [[site page actions]].%0a%0a[[#attr]]%0a:?action='''attr''': displays dialog for setting/changing password of the specified page or group of pages, see [[PmWiki/passwords]], see also $EnablePostAttrClearSession if you do not want to have the session cleared after validating change [- {PmWiki/Passwords$:Summary} -]%0a%0a[[#browse]]%0a:?action='''browse''': display the specified page (default action if no [@?action=@] is present)%0a%0a[[#crypt]]%0a:?action='''crypt''': displays a form for generating hashed [[Passwords | passwords]] out of clear text for usage in your config.php%0a%0a[[#diff]]%0a:?action='''diff''': show a change history of the specified page, see [[PmWiki/page history]] [- {PmWiki/PageHistory$:Summary} -]%0a%0a[[#download]]%0a:?action='''download'''&upname=''file.ext'': retrieve the page's attachment named ''file.ext'', see $EnableDirectDownload%0a%0a[[#edit]]%0a:?action='''edit''': edit the specified page, see [[PmWiki/basic editing]] [- {PmWiki/BasicEditing$:Summary} -]%0a%0a[[#login]]%0a:?action='''login''': prompt visitor for username/password, by default using [[Site.AuthForm]]%0a%0a[[#logout]]%0a:?action='''logout''': remove author, password, and login information%0a%0a[[#print]]%0a:?action='''print''': display the specified page using the skin specified by $ActionSkin['print']%0a%0a[[#refcount]]%0a:?action='''refcount''': bring up the reference count form, which allows the user to generate a list of links (all, missing, existing or orphaned) in or from specified groups. See [[Ref Count]] [- {PmWiki/RefCount$:Summary} -]. Part of the core distribution but must be enabled by the administrator.%0a%0a[[#search]]%0a:?action='''search''': displays searchbox on current page, see [[PmWiki/search]] [- {PmWiki/Search$:Summary} -]%0a:?action='''search'''&q=''searchterm'': performs search with ''searchterm'' and displays results on current page%0a:?action='''search'''&q=link=''pagename'': performs backlinks search with ''pagename'' and displays results on current page%0a%0a[[#source]]%0a:?action='''source''': show page source%0a%0a[[#template]]%0a:?action='''template''': creates a link that will open the NewPage using the contents of OldPage, see [[Cookbook:Edit Templates]] [-{Cookbook/EditTemplates$:Summary}-]%0a%0a%0a[[#feed]]%0a:?action='''atom''':%0a:?action='''rdf''':%0a:?action='''rss''':%0a:?action='''dc''': If [[web feeds]] are enabled, returns a syndication feed based on the contents of the page or other options provided by the url, see [[PmWiki/web feeds]] [- {PmWiki/WebFeeds$:Summary} -]%0a%0a[[#upload]]%0a:?action='''upload''': display a form to upload an attachment for the current group, see [[PmWiki/uploads]] [- {Cookbook/Uploads$:Summary} -]%0a[[#defaultactionsend]]%0a----%0a[[#querystrings]]%0a!! Query string parameters%0a%0a[[#from]]%0a:?'''from'''=''page name'': use when a page is redirected%0a%0a[[#n]]%0a:?'''n'''=''page name'': display page%0a%0a[[#setprefs]]%0a:?'''setprefs'''=''SomeGroup.CustomPreferences'': sets cookie to custom preferences page. See [[PmWiki/site preferences]] [- {PmWiki/SitePreferences$:Summary} -]%0a----%0a[[#enablediag]]%0a!! Actions enabled by $EnableDiag%0a[[#BEGENABLEDIAG]]%0aThe following actions are available only if you set @@$EnableDiag = 1;@@ in your configuration file. They can be used for debugging and should not be set in a production environment.%0a%0a:?action='''ruleset''': displays a list of all markups in 4 columns:%0a** column 1 = markup-name (1. parameter of %25hlt php%25@@markup()@@ )%0a** column 2 = when will rule apply (2. parameter of %25hlt php%25@@markup()@@ )%0a** column 3 = PmWiki's internal sort key (derived from #2)%0a** column 4 = Debug backtrace information for potentially incompatible rules (filename, line number, pattern)%0a->(see [[Custom Markup]] [- {PmWiki/CustomMarkup$:Summary} -]).%0a->To see more than what [@?action=ruleset@] gives you, apply the [[Cookbook:MarkupRulesetDebugging]] recipe: it can also show the pattern and the replacement strings.%0a** doesn't make use of PmWiki's authorization mechanisms.%0a%0a[[#phpinfo]]%0a:?action='''phpinfo''': displays the output of %25hlt php%25@@phpinfo()@@ and exits. No page will be processed%0a** doesn't make use of PmWiki's authorization mechanisms.%0a%0a[[#diag]]%0a:?action='''diag''': displays a dump of all global vars and exits. No page will be processed%0a** doesn't make use of PmWiki's authorization mechanisms.%0a%0a[[#ENDENABLEDIAG]]%0a----%0a[[#scriptactions]]%0a!! Actions enabled by PmWiki Scripts%0a%0a[[#analyse]]%0a:?action='''analyze''': see [[(PmWiki:)Site Analyzer]] and [[(PmWiki:)Analyze Results]]%0a%0a[[#approvesites]]%0a:?action='''approvesites''': see [[PmWiki/Url approvals]] [- {PmWiki/UrlApprovals$:Summary} -]%0a** doesn't make use of PmWiki's authorization mechanisms.%0a%0a[[#analyseend]]%0a----%0a[[#cookbook]]%0a!! Actions enabled by [[Cookbook(:.)]] recipes%0a(more information about [[(PmWiki:)Custom Actions]])%0a%0a:?action='''admin''': see [[Cookbook:UserAuth2]] [- {Cookbook/UserAuth2$:Summary} -]%0a%0a:?action='''attachman''': see [[Cookbook:Attachman]] [- {Cookbook/Attachman$:Summary} -]%0a%0a:?action='''backup''': see [[Cookbook:BackupPages]] [- {Cookbook/BackupPages$:Summary} -]%0a%0a:?action='''clearsky''': see [[Cookbook:SearchCloud]] [- {Cookbook/SearchCloud$:Summary} -]%0a%0a:?action='''cm-dependencies''': see [[Cookbook:CodeMirror]] [- {Cookbook/CodeMirror$:Summary} -]%0a%0a:?action='''comment''': see [[Cookbook:CommentBox]] [- {Cookbook/CommentBox$:Summary} -]%0a%0a:?action='''comments''': see [[Cookbook:Comments]] [- {Cookbook/Comments$:Summary} -]%0a%0a:?action='''comment-rss''': see [[Cookbook:CommentDb]] [- {Cookbook/CommentDb$:Summary} -]%0a%0a:?action='''convert''': see [[Cookbook:ROEPatterns]] [- {Cookbook/ROEPatterns$:Summary} -]%0a%0a:?action='''converttable''': [[Cookbook:ConvertTable]] [- {Cookbook/ConvertTable$:Summary} -]%0a%0a:?action='''copy''': see [[Cookbook:MovePage]] [- {Cookbook/MovePage$:Summary} -]%0a%0a:?action='''csv''': see [[Cookbook:CSVAction]] [- {Cookbook/CSVAction$:Summary} -]%0a%0a:?action='''downloaddeleted''':%0a:?action='''delattach''':%0a:?action='''deldelattach''':%0a:?action='''fileinfo''':%0a:?action='''thumbnail''':%0a:?action='''undelattach''': [[Cookbook:Attachtable]] [- {Cookbook/Attachtable$:Summary} -]%0a%0a:?action='''delete''': see [[Cookbook:DeletePage]] [- {Cookbook/DeletePage$:Summary} -]%0a%0a:?action='''discuss''': see [[Cookbook:DiscussionTab]] [- {Cookbook/DiscussionTab$:Summary} -]%0a%0a:?action='''downloadman''': see [[Cookbook:DownloadManager]] [- {Cookbook/DownloadManager$:Summary} -]%0a%0a:?action='''expirediff''': see [[Cookbook:ExpireDiff]] [- {Cookbook/ExpireDiff$:Summary} -]%0a%0a:?action='''hidediff''': see [[Cookbook:HideDiff]] [- {Cookbook/HideDiff$:Summary} -]%0a%0a:?action='''import''': see [[Cookbook:ImportText]] [- {Cookbook/ImportText$:Summary} -]%0a%0a:?action='''lang''': see [[Cookbook:MultiLanguageViews]] [- {Cookbook/MultiLanguageViews$:Summary} -]%0a:?action='''setlang''': see [[Cookbook:MultiLanguageViews]] [- {Cookbook/MultiLanguageViews$:Summary} -]%0a%0a:?action='''links''': see [[Cookbook:RenamePage]] [- {Cookbook/RenamePage$:Summary} -]%0a%0a:?action='''move''': see [[Cookbook:MovePage]] [- {Cookbook/MovePage$:Summary} -]%0a%0a:?action='''pageindex''': see [[Cookbook:ListCategories]] [- {Cookbook/ListCategories$:Summary} -]%0a%0a:?action='''PageUrl''': see [[Cookbook:CommentBoxPlus]] [- {Cookbook/CommentBoxPlus$:Summary} -]%0a%0a:?action='''pdf''': see [[Cookbook:GeneratePDF]] [- {Cookbook/GeneratePDF$:Summary} -] %0a: : or [[Cookbook:PmWiki2PDF]] [- {Cookbook/PmWiki2PDF$:Summary} -]%0a%0a:?action='''postupload2''': see [[Cookbook:UploadForm]] [- {Cookbook/UploadForm$:Summary} -]%0a%0a:?action='''ppdonate''': see [[Cookbook:PPDonate]] - [- {Cookbook/PPDonate$:Summary} -]%0a%0a:?action='''publish''': see [[Cookbook:PublishPDF]] [- {Cookbook/PublishPDF$:Summary} -]%0a%0a:?action='''purgeqns''': see [[Cookbook:ASCIIMath]] [- {Cookbook/ASCIIMath$:Summary} -]%0a%0a:?action='''pwchange''': see [[Cookbook:UserAuth2]] [- {Cookbook/UserAuth2$:Summary} -]%0a%0a:?action='''imgtpl''': (the ''imgtpl'' action is called automatically and should not be called by a link in a wiki page)%0a:?action='''createthumb''': (the ''createthumb'' action is called automatically and should not be called by a link in a wiki page)%0a:?action='''mini''': (this action is called automatically and should not be called by a link in a wiki page)%0a:?action='''purgethumbs''': see [[Cookbook:ThumbList]] [- {Cookbook/ThumbList$:Summary} -] \\%0a see [[Cookbook:Mini]] [- {Cookbook/Mini$:Summary} -]%0a%0a:?action='''recipecheck''': see [[Cookbook:RecipeCheck]] [- {Cookbook/RecipeCheck$:Summary} -]%0a%0a:?action='''regen''': see [[Cookbook:PageRegenerate]] [- {Cookbook/PageRegenerate$:Summary} -]%0a%0a:?action='''reindex''': see [[Cookbook:Reindex]] [- {Cookbook/Reindex$:Summary} -]%0a%0a:?action='''reindexcat''': See [[Cookbook:ReindexCategories]] [- {Cookbook/ReindexCategories$:Summary} -]%0a%0a:?action='''rename''':%0a:?action='''links''': see [[Cookbook:RenamePage]] [- {Cookbook/RenamePage$:Summary} -]%0a%0a:?action='''rmpi''': see [[Test.PageIndex]] [- {Test/PageIndex$:Summary} -]%0a%0a:?action='''share''':%0a:?action='''unshare''': see [[Cookbook:SharedPages]] [- {Cookbook/SharedPages$:Summary} -]%0a%0a:?action='''sitemapaddgroups''':%0a:?action='''sitemapupdate''': see [[Cookbook:Sitemapper]] [- {Cookbook/Sitemapper$:Summary} -]%0a%0a:?action='''totalcounter''': see [[Cookbook:TotalCounter]] [- {Cookbook/TotalCounter$:Summary} -]%0a%0a:?action='''trash''':%0a:?action='''untrash''': see [[Cookbook:Trash]] [- {Cookbook/Trash$:Summary} -]%0a%0a:?action='''webadmin''': see [[Cookbook:WebAdmin]] [- {Cookbook/WebAdmin$:Summary} -]%0a%0a:?action='''zap''': see [[Cookbook:ZAP]] [- {Cookbook/ZAP$:Summary} -]%0a[[#cookbookend]]%0a----%0a[[#cookbookqueryskins]]%0a!! Query string parameters enabled by [[Cookbook(:.)]] recipes%0a%0a:?'''color'''=''colorscheme'':%0a:?'''setcolor'''=''colorscheme''%0a:?'''skintheme'''=''theme'':%0a:?'''setskintheme'''=''theme'': see [[Cookbook:ChoiceColorChanger ]] [- {Cookbook/ChoiceColorChanger$:Summary} -]%0a%0a%0a:?'''skin'''=''skinname'':%0a:?'''setskin'''=''skinname'': see [[https://www.pmwiki.org/wiki/Skins/SkinChange|SkinChange]] [- {Skins/SkinChange$:Summary} -]%0a%0a!!Custom actions%0a%0a*See [[(PmWiki:)CustomActions]]. +time=1675553436 blob - c9fa1ac0cacac758b76ab8626e24c60c7990066b blob + d81359b9df12b07b821261657fe697dea4e74db3 --- wikilib.d/PmWiki.BackupAndRestore +++ wikilib.d/PmWiki.BackupAndRestore @@ -1,11 +1,11 @@ -version=pmwiki-2.2.118 ordered=1 urlencoded=1 -author=Petko +version=pmwiki-2.3.12 ordered=1 urlencoded=1 +author=simon charset=UTF-8 -csum=see also at bottom, fix h2/h3 structure +csum=hlt bash (+60) ctime=1134693395 name=PmWiki.BackupAndRestore -rev=40 +rev=42 targets=Cookbook.Cookbook,PmWiki.Uploads,Cookbook.BackupWithRsync,Cookbook.TwoWayMirroringWithRsync,Cookbook.BackupPages,Cookbook.BackupHTMLZip -text=(:title Backup and Restore:)%0a(:Summary:background information and some basic backup and restore procedures:)%0a%0aThis page has some background information on making backups and explains some basic *nix backup and restore procedures.%0a%0a!! Introduction%0a%0aYour wiki installation contains some unique data in the following directories:%0a%0a local/ Local configuration scripts%0a cookbook/ Recipes obtained from the [[(Cookbook:)Cookbook]]%0a pub/ Publicly accessible files%0a wiki.d/ Wiki pages%0a uploads/ [[Uploads|Uploaded files]] (attachments)%0a%0aA good backup plan will include periodically archiving these directories — or at bare minimum [@local/@] and [@wiki.d/@]. Good practice dictates keeping your backup archives on a separate machine.%0a%0a!! Simple Backup and Restore (*nix)%0a%0aWhen it comes to backup, simpler is better. %0aSince the pmwiki distribution is very small (about 1/4 megabyte), it's simplest to just archive the distribution files along with the data.%0a%0a!!! Making a Backup Archive%0a%0aThe following *nix command, executed from the parent directory of your wiki's directory, will put a complete backup archive of your site in your home directory.%0a%0a-> [@%0atar -zcvf ~/wiki-backup-`date +%25Y%25m`.tar.gz wiki/%0a@]%0a%0a[[#restore]]%0a!!! Restoring the Backup Archive%0a%0a!!!! Simple Method%0a%0aYour site can be restored and running in under 30 seconds with%0a%0a-> [@%0atar -zxvf ~/wiki-backup-200512.tar.gz%0afind wiki/uploads/ -type d |xargs chmod 777%0afind wiki/wiki.d/ -type d |xargs chmod 777%0a@]%0a%0a!!!! A Slightly-More-Secure Method%0a%0aThe simple restore commands above will give you world-writable files and directories. You can avoid world-writable permissions by letting PmWiki create directories with the proper attributes (ownership and permissions) for you.%0a%0aStart with%0a%0a-> [@%0atar -zxvf ~/wiki-backup-200512.tar.gz%0arm -rf wiki/wiki.d%0arm -rf uploads%0achmod 2777 wiki/%0a@]%0a%0aNow upload a file in each group that had uploads. If your site doesn't have uploads, just visit your site once so the wiki.d/ directory will be created.%0a%0aFinish your installation with%0a%0a-> [@%0achmod 755 wiki/%0atar -zxvf ~/wiki-backup-200512.tar.gz%0a@]%0a%0a%0a!!! Details%0a%0aThe commands on this page assume your site is in a directory called "wiki/". The test backup was made in December, 2005 so it's named accordingly.%0a%0aYour site will only have an uploads/ directory if uploads are enabled.%0a%0aThe backup command uses a date stamp (YYYYMM) in the filename. If you automate the command via cron you'll wind up with monthly snapshots of your site. You can get a daily snapshot by appending %25d to the date command ([@`date +%25Y%25m%25d`@] will get you YYYYMMDD). Be wary of space limitations if you have a large uploads/ directory.%0a%0a%0a!! Miscellaneous%0a%0a!!! Backup via FTP%0aDownload and install a ftp client like [[http://filezilla-project.org/download.php?type=client|Filezilla]]%0a%0a# Using the ftp client connect to the server where you host pmWiki using%0a## the IP address (ex: 123.234.56.67) or the ftp name (ex: ftp.myhost.com)%0a## supply your account name (ex: mylogin) and password (ex: myp4ssw0rd)%0a# Move to your pmWiki directory (ex: @@/usr/mylogin/web/wiki/@@ or @@/tahi/public_html/pmwiki@@ )%0a# Select the folder you want to backup as explained before (probably either only the data or the whole wiki directory)%0a** for data you will want to backup both the directories%0a*** @@wiki.d@@ for user page data%0a*** @@pmwikiuploads@@ (or @@uploads@@) for your attachments (uploads)%0a** for system you will want, at a minimum, to backup both the directories%0a*** @@local@@ for configuration data %0a*** @@pub@@ for local CSS and skins customisations%0a# Download them to a local folder%0a# Use [[http://www.7-zip.org/ | 7zip]] or a similar software to build an archive of this backup%0a%0aYou can also very easily sync your FTP directories with your hard disc via this command line:%0a-> [@ wget -nv -np -m ftp://user:password@ftp.yourhost.net/ @]%0a'-Download [[http://gnuwin32.sourceforge.net/packages/wget.htm | Wget for Windows]] (other systems normally have it installed).-'%0a%0aAlternatively, you can also mirror your FTP directories with lftp:%0a-> [@ lftp -u your_user_name,your_password -e "mirror --verbose /wiki.d /path/to/local/folder" ftp://your_host @]%0a(this will mirror only the /wiki.d folder, replace with / to mirror everything)%0a%0a[[#rsync]]%0a!!! Using rsync%0aSee Cookbook:BackupWithRsync and Cookbook:TwoWayMirroringWithRsync.%0a%0a!! See Also%0a%0a* A [[http://thread.gmane.org/gmane.comp.web.wiki.pmwiki.user/20317| thread]] [gmane.org] on the pmwiki-users mailing list.%0a* A [[(Cookbook:)Backup Pages]] recipe in the cookbook.%0a* A [[(Cookbook:)Backup HTML Zip]] recipe in the cookbook.%0a -time=1567166412 +text=(:title Backup and Restore:)%0a(:Summary:background information and some basic backup and restore procedures:)%0a%0aThis page has some background information on making backups and explains some basic *nix backup and restore procedures.%0a%0a!! Introduction%0a%0aYour wiki installation contains some unique data in the following directories:%0a%0a local/ Local configuration scripts%0a cookbook/ Recipes obtained from the [[(Cookbook:)Cookbook]]%0a pub/ Publicly accessible files%0a wiki.d/ Wiki pages%0a uploads/ [[Uploads|Uploaded files]] (attachments)%0a%0aA good backup plan will include periodically archiving these directories — or at bare minimum [@local/@] and [@wiki.d/@]. Good practice dictates keeping your backup archives on a separate machine.%0a%0a!! Simple Backup and Restore (*nix)%0a%0aWhen it comes to backup, simpler is better. %0aSince the pmwiki distribution is very small (about 1/4 megabyte), it's simplest to just archive the distribution files along with the data.%0a%0a!!! Making a Backup Archive%0a%0aThe following *nix command, executed from the parent directory of your wiki's directory, will put a complete backup archive of your site in your home directory.%0a%0a-> %25hlt bash%25[@%0atar -zcvf ~/wiki-backup-`date +%25Y%25m`.tar.gz wiki/%0a@]%0a%0a[[#restore]]%0a!!! Restoring the Backup Archive%0a%0a!!!! Simple Method%0a%0aYour site can be restored and running in under 30 seconds with%0a%0a-> %25hlt bash%25[@%0atar -zxvf ~/wiki-backup-200512.tar.gz%0afind wiki/uploads/ -type d |xargs chmod 777%0afind wiki/wiki.d/ -type d |xargs chmod 777%0a@]%0a%0a!!!! A Slightly-More-Secure Method%0a%0aThe simple restore commands above will give you world-writable files and directories. You can avoid world-writable permissions by letting PmWiki create directories with the proper attributes (ownership and permissions) for you.%0a%0aStart with%0a%0a-> %25hlt bash%25[@%0atar -zxvf ~/wiki-backup-200512.tar.gz%0arm -rf wiki/wiki.d%0arm -rf uploads%0achmod 2777 wiki/%0a@]%0a%0aNow upload a file in each group that had uploads. If your site doesn't have uploads, just visit your site once so the wiki.d/ directory will be created.%0a%0aFinish your installation with%0a%0a-> %25hlt bash%25[@%0achmod 755 wiki/%0atar -zxvf ~/wiki-backup-200512.tar.gz%0a@]%0a%0a%0a!!! Details%0a%0aThe commands on this page assume your site is in a directory called "wiki/". The test backup was made in December, 2005 so it's named accordingly.%0a%0aYour site will only have an uploads/ directory if uploads are enabled.%0a%0aThe backup command uses a date stamp (YYYYMM) in the filename. If you automate the command via cron you'll wind up with monthly snapshots of your site. You can get a daily snapshot by appending %25d to the date command ([@`date +%25Y%25m%25d`@] will get you YYYYMMDD). Be wary of space limitations if you have a large uploads/ directory.%0a%0a%0a!! Miscellaneous%0a%0a!!! Backup via FTP%0aDownload and install a ftp client like [[https://filezilla-project.org/download.php?type=client|Filezilla]]%0a%0a# Using the ftp client connect to the server where you host PmWiki using%0a## the IP address (ex: 123.234.56.67) or the ftp name (ex: ftp.myhost.com)%0a## supply your account name (ex: mylogin) and password (ex: myp4ssw0rd)%0a# Move to your pmWiki directory (ex: @@/usr/mylogin/web/wiki/@@ or @@/tahi/public_html/pmwiki@@ )%0a# Select the folder you want to backup as explained before (probably either only the data or the whole wiki directory)%0a** for data you will want to backup both the directories%0a*** @@wiki.d@@ for user page data%0a*** @@pmwikiuploads@@ (or @@uploads@@) for your attachments (uploads)%0a** for system you will want, at a minimum, to backup both the directories%0a*** @@local@@ for configuration data %0a*** @@pub@@ for local CSS and skins customisations%0a# Download them to a local folder%0a# Use [[https://www.7-zip.org/ | 7zip]] or a similar software to build an archive of this backup%0a%0aYou can also very easily sync your FTP directories with your hard disc via this command line:%0a-> %25hlt bash%25[@ wget -nv -np -m ftp://user:password@ftp.yourhost.net/ @]%0a'-Download [[https://sourceforge.net/projects/getgnuwin32/ | Wget for Windows]] (other systems normally have it installed).-'%0a%0aAlternatively, you can also mirror your FTP directories with lftp:%0a-> %25hlt bash%25[@ lftp -u your_user_name,your_password -e "mirror --verbose /wiki.d /path/to/local/folder" ftp://your_host @]%0a(this will mirror only the @@/wiki.d@@ folder, replace with / to mirror everything)%0a%0a[[#rsync]]%0a!!! Using rsync%0aSee Cookbook:BackupWithRsync and Cookbook:TwoWayMirroringWithRsync.%0a%0a!! See Also%0a%0a* A [[https://www.pmwiki.org/pipermail/pmwiki-users/2005-December/thread.html#20661| backups thread]] on the pmwiki-users mailing list.%0a* A [[(Cookbook:)Backup Pages]] recipe in the cookbook.%0a* A [[(Cookbook:)Backup HTML Zip]] recipe in the cookbook.%0a +time=1664588781 title=Backup and Restore blob - fccb0345b100bbbed8581e0d1b844ab3ac0caffe blob + cc30a644f91f3082922b8976cdcb406ec0aa0834 --- wikilib.d/PmWiki.BasicEditing +++ wikilib.d/PmWiki.BasicEditing @@ -1,11 +1,11 @@ -version=pmwiki-2.2.120 ordered=1 urlencoded=1 -author=Petko +version=pmwiki-2.3.4 ordered=1 urlencoded=1 +author=simon charset=UTF-8 -csum= -description=PmWiki's basic edit syntax +csum=pm hlt, hlt php (+75) +description=PmWiki's basic editing rules name=PmWiki.BasicEditing -rev=520 -targets=PmWiki.WikiSandbox,Main.WikiSandbox,PmWiki.WikiWikiWeb,PmWiki.Passwords,PmWiki.TextFormattingRules,PmWiki.MarkupMasterIndex,PmWiki.WikiStyles,PmWiki.ListStyles,PmWiki.WikiGroup,PmWiki.InterMap,PmWiki.NonexistentPages,PmWiki.Links,PmWiki.Tables,PmWiki.TableDirectives,PmWiki.Images,PmWiki.PageLists,PmWiki.BasicEditing,PmWiki.WikiTrails,PmWiki.DocumentationIndex,PmWiki.SpecialCharacters,PmWiki.LayoutVariables,PmWiki.PmWikiPhilosophy,PmWiki.Audiences,Cookbook.EnableHTML -text=(:Summary: PmWiki's basic edit syntax:)(:Audience: authors (basic) :)%0aThe pages on this site are [[wiki(WikiWeb)]]-based pages, which means that pages can be created and edited by multiple authors. To edit a page, click the '''Edit''' link that exists '''somewhere''' on the page, usually in the header or footer. Some pages may be [[password(s)]]-protected, depending on the system's security policies, but many systems allow open editing of pages.%0a%0a%0aPmWiki is not [[(Wikipedia:)WYSIWYG]] - When editing a page, you see the ''markup text'' that describes the content of the page. The basic rules for page markup are simple:%0a# Use a blank line to start a new paragraph [-[[#Paragraphs|more]]-].%0a# To make a list, start each line with # for numbered (ordered) lists or * for bulleted (unordered) lists [-[[#lists|more]]-].%0a# To make a heading, start a line with two or more ! marks; !! is a subheading, and !!! is a sub-subheading [-[[#headings|more]]-].%0a# To emphasize text, enclose it in 2 or 3 ''single quotes''; [@''text''@] for italics or [@'''text'''@] for bold [-[[#emphasis|more]]-].%0a# To make a [[#links | link to another page]], enclose the page's name in double brackets; for example [@[[basic editing]]@] links to this page.%0a# To make a [[#links|link to another site]], type its address, such as [[http://example.com/ | [=[[http://example.com/]]=] ]]. Email links must have "mailto:" before such as [[mailto:xyz@example.com | [=mailto:xyz@example.com=] ]]%0a%0a%0a'''If you want to experiment with editing a page, try it on the [[Main/Wiki Sandbox]].''' You can [[Main/WikiSandbox?action=edit | edit the Wiki Sandbox]] without affecting anything important on this site. On talk pages and discussions, it's courteous to '''sign''' your contribution; using [=~~=]~ effectively 'signs' the name that you provide in the Author field on the Page Edit form.%0a%0a!! Examples of common markups%0a%0aThe tables below demonstrate many of the common markups used to format pages. The left column shows what to write to achieve the effect, the right column shows the effect of the markup. More details are available from the [[text formatting rules]] and other documentation pages. An exhaustive list of default markup is available as the [[markup master index]].%0a%0a!!! [[#Paragraphs]]Paragraphs and line breaks%0a[[#markupheaders]]%0a(:table class='markup horiz' align='center':)%0a(:cellnr class='markup1':)%0a[-'''What to type'''-]%0a(:cell class='markup2':)%0a[-'''What it looks like'''-]%0a(:tableend:)%0a[[#markupheadersend]]%0a%0a(:markup class=horiz:)%0aConsecutive lines%0awill be merged together%0aas part of the same paragraph.%0a%0aOne or more empty lines will start a new paragraph.%0a(:markupend:)%0a%0a(:markup class=horiz:)%0aTwo backslashes at the end of a line \\%0aforce a line break.%0a%0aOr use this markup: [[%3c%3c]] to force a break.%0a(:markupend:)%0aFurther reading:%0a* [[text formatting rules]] for more information on linebreaks, indented or hanging paragraphs.%0a* [[wiki styles]] for centered or right justified paragraphs and "floating" text (boxes), borders and much more.%0a%0a!!![[#lists]]Lists%0aStart each line with # for numbered (ordered) lists or * for bulleted (unordered) lists:%0a%0a(:markup class=horiz:)%0a* Bullet list%0a* Another item%0a** More asterisks produce sub-items%0a** etc.%0a(:markupend:)%0a%0a(:markup class=horiz:)%0a# Numbered lists%0a# Another item%0a## more hashes produce sub-items%0a(:markupend:)%0a%0a(:markup class=horiz:)%0a# List types%0a# can be mixed%0a** numbered list with unordered sub-list%0a(:markupend:)%0a%0a(:if false:)%0aif someone thinks definition lists are "basic":%0a(:markup class=horiz:)%0a: Definition list : list of definitions%0a: item : the item's definition%0a: another item : that item's definition%0a:: indentation : more leading colons produce deeper lists%0a(:markupend:)%0a(:ifend:)%0a%0aLearn more about [[Text Formatting Rules#BulletedLists|lists]] (including [[Text Formatting Rules#DefinitionLists|definition lists]]) and [[(PmWiki:)list styles]].%0a%0a!!![[#headings]] Headings%0aHeadings are useful for creating a "well-structured" page. They're not just for making big text.%0a%0a(:include {$FullName}#markupheaders#markupheadersend:)%0a%0a(:markup class=horiz:)%0a!! Major Subheading%0a!!! Minor Subheading%0a!!!! And More%0a!!!!! Subheadings%0a(:markupend:)%0a%0a!!![[#emphasis]] Text emphasis%0aTo emphasize, enclose text in apostrophes (single-quote marks), not double-quotes.%0a%0a(:include {$FullName}#markupheaders#markupheadersend:)%0a%0a(:markup class=horiz:)%0a''Emphasize'' (italics),%0a'''strong''' (bold), %0a'''''very strong''''' (bold italics).%0a(:markupend:)%0a%0a!!![[#links]] Links%0aTo make a link to another page, enclose the page's name in double square brackets.%0a%0a(:include {$FullName}#markupheaders#markupheadersend:)%0a%0a(:markup class=horiz:)%0aPractice editing in the [[wiki sandbox]]%0a(:markupend:)%0aNote that words are automatically ''capitalized'' in page titles. The link above links to the page WikiSandbox.%0a%0aText after a pipe (|) is used as the link text:%0a(:markup class=horiz:)%0aPractice editing in the%0a[[WikiSandbox | practice area]].%0a(:markupend:)%0a%0a(:comment is this still "basic" or should it be removed? :)%0aEndings become part of the link text, parentheses hide parts of the link name:%0a(:markup class=horiz:)%0a[[wiki sandbox]]es.%0a%0a[[(wiki) sandbox]].%0a(:markupend:)%0a%0aWhen linking to a page in a different [[WikiGroup]], provide the group name, followed by a separator, and then the page name:%0a(:markup class=horiz:)%0a[[Main.Wiki Sandbox]] shows group + name%0a%0a[[Main/Wiki Sandbox]] shows only name%0a(:markupend:)%0a%0aLinks to external sites%0a(:markup class=horiz:)%0abare url: http://www.pmwiki.org%0a%0alink text: [[http://www.pmwiki.org | PmWiki home]]%0a(:markupend:)%0a%0aLinks as reference to external sites%0a(:markup class=horiz:)%0abare url: http://www.pmwiki.org%0a%0alink text: [[http://www.pmwiki.org | #]]%0a(:markupend:)%0a%0a(:comment is this still "basic" or should it be removed? :)%0aColons make [[InterMap]] (also called InterWiki) links to other wikis:%0a(:markup class=horiz:)%0aWhat's an [[Wikipedia:aardvark]], anyway?%0a(:markupend:)%0a%0aLinks to [[nonexistent pages]] are displayed specially, to invite others to create the page.%0a%0aPmWiki supports more link types and a lot of display options, see [[Links]] to learn more.%0a%0a%0a!!!Preformatted text [[#preformatted]]%0aPreformatted text is displayed using a monospace font and not generating linebreaks except where explicitly indicated in the markup.%0a%0aNote that very long lines of preformatted text can cause the whole page to be wide.%0a%0aFor preformatted text with markup (e.g. emphasis) being processed, start each line with a space:%0a(:markup class=horiz:)%0a Lines that begin with a space%0a are formatted exactly as typed%0a in a '''fixed-width''' font.%0a(:markupend:)%0a%0aIf you don't want Wiki markup to be processed, use [=[@ @]=]. Can also be used inline.%0a(:markup class=horiz:)%0a[@%0aText escaped this way has%0athe HTML ''code'' style%0a@]%0a(:markupend:)%0a%0aYou can also use the [[#escape|escape sequence]] preceded with a space on the first line.%0a(:markup class=horiz:)%0a [=The '''escape sequence''',%0apreceded by space(s) on the first line,%0ais rendered preformatted.=]%0a(:markupend:)%0a%0aYou can enable [[WikiStyles#highlight|code highlighting]] for preformatted blocks with recent PmWiki versions.%0a%0a!!! Escape sequence [[#escape]]%0aIf you don't want Wiki markup to be processed, but lines reformatted use [@[= =]@]. Can also be used inline.%0a(:markup class=horiz:)%0a[=%0amarkup is ''not'' processed%0abut lines are reformatted%0a=]%0a(:markupend:)%0a%0a%0a!!! Horizontal line%0a(:markup class=horiz:)%0aFour or more dashes at%0athe beginning of a line%0a----%0aproduce a "horizontal rule"%0a(:markupend:)%0a%0a!!! Tables%0aSimple tables use double pipe characters to separate cells:%0a(:markup class=horiz:)%0a|| border=1%0a||! head 1 ||! head 2 ||! head 3 ||%0a|| cell 1 || cell 2 || cell 3 ||%0a(:markupend:)%0aSee [[Tables|simple tables]] and [[Table Directives|advanced tables]] to learn more about the rich feature set of PmWiki tables.%0a%0a!!! Images%0aSee [[Images]]%0a%0a(:if false:)%0aIMO this is not "basic" and should be removed from this page --OliverBetz%0a!!!Indented and "hanging" paragraphs%0a(:markup class=horiz:)%0a-> An arrow (->) indents content.%0a%0a Line up text to continue the indent.%0a%0a-->Longer arrows (-->) indent further.%0a%0a-%3cA reverse arrow (-%3c) creates a hanging indent, the first line is outdented and remaining lines are indented.%0a(:markupend:)%0a(:ifend:)%0a%0a!!! Character formatting%0a%0a(:include {$FullName}#markupheaders#markupheadersend:)%0a%0a(:markup class=horiz:)%0a* @@Monospaced text@@%0a* Text with '^superscripts^'%0a* Text with '_subscripts_'%0a* deleted {-strikethrough-} text%0a* inserted {+underline+} text%0a* [+big+], [++bigger++] text%0a* [-small-], [--smaller--] text%0a(:markupend:)%0a%0aUse [[WikiStyles]] to change %25red%25 the %25blue%25 text %25green%25 %25color=#ff7f00%25 color %25%25.%0a%0a[[#pagetitles]]%0a!!! Page titles%0aThe [@(:title:)@] directive sets the page's title to something other than its page name.%0a(:markup class=horiz:)%0a(:Title Basic PmWiki editing rules:)%0aThe name of this page is "{$Name}", and its title is "{$Title}".%0a(:markupend:)%0a%0a[[#pagesummary]]%0a!!! Page description%0a%0a* The [@(:Description Page summary here:)@] directive sets the page description. The description is used by search engines, and can be displayed in search results and in [[page lists]].%0a(:markup class=horiz:)%0a(:Description PmWiki's basic edit syntax:)%0aThe summary description of this page is {$Description}.%0a(:markupend:)%0a%0a%0a%0a>>faq%3c%3c [[#faq]]%0a[[#beginning]]%0aQ: I'm new to PmWiki, where can I find some basic help for getting started?%0aA: The [[Basic Editing]] page is a good start. From there, you can just follow the navigational links at the top or the bottom of the page (they are called [[Wiki Trails]]) to the next pages, or to the [[Documentation Index]] page, which provides an outline style index of essential documentation pages, organized from basic to advanced.%0a%0aQ: How do I include special characters such as Copyright (©) and Trademark (® or ™) on my wiki pages?%0aA: See [[special characters]] on how to insert special characters that don't appear on your keyboard.%0a%0aQ: How can I preserve line-breaks from the source text?%0aA: PmWiki normally treats consecutive lines of text as being a paragraph, and merges and wraps lines together on output. This is consistent with most other wiki packages. An author can use the [@(:linebreaks:)@] directive to cause the following lines of markup text in the page to be kept as separate lines in the output. Or a wiki administrator can set in ''config.php'' @@$HTMLPNewline = '%3cbr/>';@@ to force literal new lines for the whole site.%0a%0aQ: Can I just enter HTML directly?%0aA: By default (and by design), PmWiki does not support the use of HTML elements in the editable markup for wiki pages. There are a number of reasons for this described in the [[PmWiki Philosophy]] and [[Audiences]]. Enabling HTML markup within wiki pages in a collaborative environment may exclude some potential authors from being able to edit pages, and pose a number of display and security issues. However, a site administrator can use the [[Cookbook:Enable HTML]] recipe to enable the use of HTML markup directly in pages.%0a%0aQ: Where can I find more documentation?%0aA: See the [[Documentation Index | documentation index]] and the [[markup master index]] pages. -time=1573708072 +rev=585 +targets=PmWiki.WikiSandbox,Main.WikiSandbox,PmWiki.WikiWikiWeb,PmWiki.Passwords,PmWiki.TextFormattingRules,PmWiki.MarkupMasterIndex,PmWiki.WikiStyles,PmWiki.ListStyles,PmWiki.WikiGroup,PmWiki.InterMap,PmWiki.NonexistentPages,PmWiki.Links,PmWiki.Tables,PmWiki.TableDirectives,PmWiki.Images,PmWiki.PageLists,PmWiki.PageTextVariables,PmWiki.PageListTemplates,PmWiki.BasicEditing,PmWiki.WikiTrails,PmWiki.DocumentationIndex,PmWiki.SpecialCharacters,PmWiki.LayoutVariables,PmWiki.PmWikiPhilosophy,PmWiki.Audiences,Cookbook.EnableHTML +text=(:Audience: authors (basic) :)%0aThe pages on this site are [[wiki(WikiWeb)]]-based pages, which means that pages can be created and edited by multiple authors. To edit a page, click the '''Edit''' link that exists '''somewhere''' on the page, usually in the header or footer. Some pages may be [[password(s)]]-protected, depending on the system's security policies, but many systems allow open editing of pages.%0a%0a%0aPmWiki is not [[(Wikipedia:)WYSIWYG]] - When editing a page, you see the ''markup text'' that describes the content of the page. The basic rules for page markup are simple:%0a# Use a blank line to start a new paragraph [-[[#Paragraphs|more]]-].%0a# To make a list, start each line with %25pmhlt%25@@#@@ for numbered (ordered) lists or @@*@@ for bulleted (unordered) lists [-[[#lists|more]]-].%0a# To make a heading, start a line with two or more %25pmhlt%25@@!@@ marks; @@!!@@ is a subheading, and @@!!!@@ is a sub-subheading [-[[#headings|more]]-].%0a# To emphasize text, enclose it in 2 or 3 ''single quotes''; %25pmhlt%25[@''text''@] for italics or [@'''text'''@] for bold [-[[#emphasis|more]]-].%0a# To make a [[#links | link to another page]], enclose the page's name in double brackets; for example %25pmhlt%25[@[[basic editing]]@] links to this page.%0a# To make a [[#links|link to another site]], type its address, such as %25pmhlt%25[@[[https://example.com/]]@]. Email links must have "@@mailto:@@" before such as [@mailto:xyz@example.com@]%0a%0a%0a'''If you want to experiment with editing a page, try it on the [[Main/Wiki Sandbox]].''' You can [[Main/WikiSandbox?action=edit | edit the Wiki Sandbox]] without affecting anything important on this site. On talk pages and discussions, it's courteous to '''sign''' your contribution; using %25pmhlt%25@@[=~~=]~@@ effectively 'signs' the name that you provide in the Author field on the Page Edit form.%0a%0a!! Examples of common markups%0a%0aThe tables below demonstrate many of the common markups used to format pages. The left column shows what to write to achieve the effect, the right column shows the effect of the markup. More details are available from the [[text formatting rules]] and other documentation pages. An exhaustive list of default markup is available as the [[markup master index]].%0a%0a!!! [[#Paragraphs]]Paragraphs and line breaks%0a[[#markupheaders]]%0a(:table class='markup horiz' align='center':)%0a(:cellnr class='markup1':)%0a[-'''What to type'''-]%0a(:cell class='markup2':)%0a[-'''What it looks like'''-]%0a(:tableend:)%0a[[#markupheadersend]]%0a%0a(:markup class=horiz:)%0aConsecutive lines%0awill be merged together%0aas part of the same paragraph.%0a%0aOne or more empty lines will start a new paragraph.%0a(:markupend:)%0a%0a(:markup class=horiz:)%0aTwo backslashes at the end of a line \\%0aforce a line break.%0a%0aOr use this markup: [[%3c%3c]] to force a break.%0a(:markupend:)%0aFurther reading:%0a* [[text formatting rules]] for more information on linebreaks, indented or hanging paragraphs.%0a* [[wiki styles]] for centered or right justified paragraphs and "floating" text (boxes), borders and much more.%0a%0a!!![[#lists]]Lists%0aStart each line with @@#@@ for numbered (ordered) lists or @@*@@ for bulleted (unordered) lists:%0a%0a(:markup class=horiz:)%0a* Bullet list%0a* Another item%0a** More asterisks produce sub-items%0a** etc.%0a(:markupend:)%0a%0a(:markup class=horiz:)%0a# Numbered lists%0a# Another item%0a## more hashes produce sub-items%0a(:markupend:)%0a%0a(:markup class=horiz:)%0a# List types%0a# can be mixed%0a** numbered list with unordered sub-list%0a(:markupend:)%0a%0a(:if false:)%0aif someone thinks definition lists are "basic":%0a(:markup class=horiz:)%0a: Definition list : list of definitions%0a: item : the item's definition%0a: another item : that item's definition%0a:: indentation : more leading colons produce deeper lists%0a(:markupend:)%0a(:ifend:)%0a%0aLearn more about [[Text Formatting Rules#BulletedLists|lists]] (including [[Text Formatting Rules#DefinitionLists|definition lists]]) and [[(PmWiki:)list styles]].%0a%0a!!![[#headings]] Headings%0aHeadings are useful for creating a "well-structured" page. They're not just for making big text.%0a%0a(:include {$FullName}#markupheaders#markupheadersend:)%0a%0a(:markup class=horiz:)%0a!! Major Subheading%0a!!! Minor Subheading%0a!!!! And More%0a!!!!! Subheadings%0a(:markupend:)%0a%0a!!![[#emphasis]] Text emphasis%0aTo emphasize, enclose text in apostrophes (single-quote marks), not double-quotes.%0a%0a(:include {$FullName}#markupheaders#markupheadersend:)%0a%0a(:markup class=horiz:)%0a''Emphasize'' (italics),%0a'''strong''' (bold), %0a'''''very strong''''' (bold italics).%0a(:markupend:)%0a%0a!!![[#links]] Links%0aTo make a link to another page, enclose the page's name in double square brackets.%0a%0a(:include {$FullName}#markupheaders#markupheadersend:)%0a%0a(:markup class=horiz:)%0aPractice editing in the [[wiki sandbox]]%0a(:markupend:)%0aNote that words are automatically ''capitalized'' in page titles. The link above links to the page WikiSandbox.%0a%0aText after a pipe (|) is used as the link text:%0a(:markup class=horiz:)%0aPractice editing in the%0a[[WikiSandbox | practice area]].%0a(:markupend:)%0a%0a(:comment is this still "basic" or should it be removed? :)%0aEndings become part of the link text, parentheses hide parts of the link name:%0a(:markup class=horiz:)%0a[[wiki sandbox]]es.%0a%0a[[(wiki) sandbox]].%0a(:markupend:)%0a%0aWhen linking to a page in a different [[WikiGroup]], provide the group name, followed by a separator, and then the page name:%0a(:markup class=horiz:)%0a[[Main.Wiki Sandbox]] shows group + name%0a%0a[[Main/Wiki Sandbox]] shows only name%0a(:markupend:)%0a%0aLinks to external sites%0a(:markup class=horiz:)%0abare url: https://www.pmwiki.org%0a%0alink text: [[https://www.pmwiki.org | PmWiki home]]%0a(:markupend:)%0a%0aLinks as reference to external sites%0a(:markup class=horiz:)%0abare url: https://www.pmwiki.org%0a%0alink text: [[https://www.pmwiki.org | #]]%0a(:markupend:)%0a%0a(:comment is this still "basic" or should it be removed? :)%0aColons make [[InterMap]] (also called InterWiki) links to other wikis:%0a(:markup class=horiz:)%0aWhat's an [[Wikipedia:aardvark]], anyway?%0a(:markupend:)%0a%0aLinks to [[nonexistent pages]] are displayed specially, to invite others to create the page.%0a%0aPmWiki supports more link types and a lot of display options, see [[Links]] to learn more.%0a%0a!!! Escape sequence [[#escape]]%0aIf you don't want Wiki markup to be processed, but lines reformatted use %25pmhlt%25[@[= =]@]. Can also be used inline.%0a(:markup class=horiz:)%0a[=%0amarkup is ''not'' processed%0abut lines are reformatted%0a=]%0a(:markupend:)%0a%0a!!!Preformatted text [[#preformatted]]%0aPreformatted text is displayed using a monospace font and not generating linebreaks except where explicitly indicated in the markup.%0a%0aNote that very long lines of preformatted text can cause the whole page to be wide.%0a%0aFor preformatted text with markup (e.g. emphasis) being processed, start each line with a space:%0a(:markup class=horiz:)%0a Lines that begin with a space%0a are formatted exactly as typed%0a in a '''fixed-width''' font.%0a(:markupend:)%0a%0aIf you don't want Wiki markup to be processed, use %25pmhlt%25@@[=[@ @]=]@@. Can also be used inline.%0a(:markup class=horiz:)%0a[@%0aText escaped this way has%0athe HTML ''code'' style%0a@]%0a(:markupend:)%0a%0aYou can also use the [[#escape|escape sequence]] preceded with a space on the first line.%0a(:markup class=horiz:)%0a [=The '''escape sequence''',%0apreceded by space(s) on the first line,%0ais rendered preformatted.=]%0a(:markupend:)%0a%0aYou can enable [[WikiStyles#highlight|code highlighting]] for preformatted blocks with recent PmWiki versions.%0a%0a!!! Horizontal line%0a(:markup class=horiz:)%0aFour or more dashes at%0athe beginning of a line%0a----%0aproduce a "horizontal rule"%0a(:markupend:)%0a%0a!!! Tables%0aSimple tables use double pipe characters to separate cells:%0a(:markup class=horiz:)%0a|| border=1%0a||! head 1 ||! head 2 ||! head 3 ||%0a|| cell 1 || cell 2 || cell 3 ||%0a(:markupend:)%0aSee [[Tables|simple tables]] and [[Table Directives|advanced tables]] to learn more about the rich feature set of PmWiki tables.%0a%0a!!! Images%0aSee [[Images]]%0a%0a%0a!!! Character formatting%0a%0a(:include {$FullName}#markupheaders#markupheadersend:)%0a%0a(:markup class=horiz:)%0a* @@Monospaced text@@%0a* Text with '^superscripts^'%0a* Text with '_subscripts_'%0a* deleted {-strikethrough-} text%0a* inserted {+underline+} text%0a* [+big+], [++bigger++] text%0a* [-small-], [--smaller--] text%0a(:markupend:)%0a%0aUse [[WikiStyles]] to change %25red%25 the %25blue%25 text %25green%25 %25color=#ff7f00%25 color %25%25.%0a%0a[[#pagetitles]]%0a!!! Page titles%0aThe %25pmhlt%25[@(:title:)@] directive sets the page's title to something other than its page name.%0a(:markup class=horiz:)%0a(:Title Basic PmWiki editing rules:)%0aThe name of this page is "{$Name}", and its title is "{$Title}".%0a(:markupend:)%0a%0a[[#pagedesc]]%0a!!! Page description%0a* The %25pmhlt%25[@(:Description Page description here:)@] directive sets the page description. The description is used by search engines, and can be displayed in search results and in [[page lists]].%0a(:markup class=horiz:)%0a(:Description PmWiki's basic editing rules:)%0aThe summary description of this page is "{$Description}".%0a(:markupend:)%0a%0a[[#pagesummary]]%0a!!! Page summary%0a* %25pmhlt%25@@[=(:=]Summary:Page summary here:)@@ is a [[PageTextVariable(s)]] that is used in some of the default [[PageList templates]].%0a(:markup class=horiz:)%0a(:Summary:PmWiki's basic edit syntax:)%0aThe summary of this page is "{$:Summary}".%0a(:markupend:)%0a%0a%0a%0a>>faq%3c%3c [[#faq]]%0a[[#beginning]]%0aQ: I'm new to PmWiki, where can I find some basic help for getting started?%0aA: The [[Basic Editing]] page is a good start. From there, you can just follow the navigational links at the top or the bottom of the page (they are called [[Wiki Trails]]) to the next pages, or to the [[Documentation Index]] page, which provides an outline style index of essential documentation pages, organized from basic to advanced.%0a%0aQ: How do I include special characters such as Copyright (©) and Trademark (® or ™) on my wiki pages?%0aA: See [[special characters]] on how to insert special characters that don't appear on your keyboard.%0a%0aQ: How can I preserve line-breaks from the source text?%0aA: PmWiki normally treats consecutive lines of text as being a paragraph, and merges and wraps lines together on output. This is consistent with most other wiki packages. An author can use the %25pmhlt%25[@(:linebreaks:)@] directive to cause the following lines of markup text in the page to be kept as separate lines in the output. Or a wiki administrator can set in ''config.php'' %25hlt php%25@@$HTMLPNewline = '%3cbr/>';@@ to force literal new lines for the whole site.%0a%0aQ: Can I just enter HTML directly?%0aA: By default (and by design), PmWiki does not support the use of HTML elements in the editable markup for wiki pages. There are a number of reasons for this described in the [[PmWiki Philosophy]] and [[Audiences]]. Enabling HTML markup within wiki pages in a collaborative environment may exclude some potential authors from being able to edit pages, and pose a number of display and security issues. However, a site administrator can use the [[Cookbook:Enable HTML]] recipe to enable the use of HTML markup directly in pages.%0a%0aQ: Where can I find more documentation?%0aA: See the [[Documentation Index | documentation index]] and the [[markup master index]] pages. +time=1653085727 title=Basic PmWiki editing rules blob - a62b63254f6e8135eddca55d215dd169bae30366 blob + 3355842490712581889dceb7957ec2a7ed4a48ee --- wikilib.d/PmWiki.BasicVariables +++ wikilib.d/PmWiki.BasicVariables @@ -1,9 +1,9 @@ -version=pmwiki-2.2.109 ordered=1 urlencoded=1 -author=Peter Kay +version=pmwiki-2.3.18 ordered=1 urlencoded=1 +author=Petko charset=UTF-8 -csum=Changed "Variable value" to have variable name +csum=not "page variable". To see PHP variables go to ?action=diag (-19) (-12) name=PmWiki.BasicVariables -rev=107 -targets=PmWiki.BasicVariables,PmWiki.AuthoringPhilosophy,PmWiki.EditVariables,PmWiki.AuthUser,PmWiki.Categories,PmWiki.WikiFarms,PmWiki.WikiGroup,PmWiki.GroupCustomizations,PmWiki.LocalCustomizations,PmWiki.LinkVariables,PmWiki.WikiWord,PmWiki.MarkupExpressions,Cookbook.LimitWikiGroups,Site.Search,Site.EditForm,Site.PageNotFound,SiteAdmin.AuthList,SiteAdmin.AuthUser,SiteAdmin.ApprovedUrls,PmWiki.Skins,PmWiki.PageVariables,Category.PmWikiDeveloper -text=(:Summary: core variables:)%0a%0aWhere the variables are available as wiki markup they are shown as ''Variable value "[={$=]VariableName}"''.%0a%0a:$AsSpacedFunction:The name of the function used to convert WikiWords into normal, spaced strings. Defaults to 'AsSpaced'.%0a:{$AsSpacedFunction} :[@$AsSpacedFunction = 'MyAsSpaced';@]%0a%0a%25rfloat%25$Author is currently "{$Author}"%0a:$Author : Set to the current reader, who is potentially an author ([[PmWiki:AuthoringPhilosophy|see discussion]]). See also $EnablePostAuthorRequired.%0a%0a:$AuthorGroup: The WikiGroup for user profiles. Defaults to 'Profiles'. This variable is implicit in the markup [@[[~AuthorName]]@]%0a: :[@$AuthorGroup = 'Users';@]%0a%0a:$AuthId: For sites using [[AuthUser | user-based authorization]], tracks the "reader" or login name.%0a: :[@SessionAuth($pagename);@]%0a: :[@if( isset($AuthId) ) { // this person has been authenticated@]%0a%0a:$AuthPw: Request for documentation, meanwhile see [[http://permalink.gmane.org/gmane.comp.web.wiki.pmwiki.user/30037|here]].%0a: :[@SessionAuth($pagename);@]%0a: :[@if( isset($AuthPw) ) { // this person has entered a password@] %0a%0a%25rfloat%25$BaseName is currently "{$BaseName}"%0a:$BaseName:%0a:$BaseNamePatterns:Allows population of the [@{$BaseName}@] PageVariable. The key to the hash is the pattern to be replaced and the value is the replacement string.%0a: :[@%0a# If {$FullName} is 'Group.Page-Draft' then {$BaseName} is 'Group.Page'%0a$BaseNamePatterns['/-Draft$/'] = '';%0a# If {$FullName} is 'Comments-Group.Page' then {$BaseName} is 'Group.Page'%0a$BaseNamePatterns['/^Comments-/'] = '';@]%0a%0a:$CategoryGroup: The WikiGroup used for categories. Defaults to 'Category'. (See [[Categories]]). This variable is implicit in the markup [@[[!CategoryName]]@]%0a%0a:$CookiePrefix: A string prefix to be prepended to cookies set from PmWiki scripts. It defaults to '', but can be set to a different value to avoid conflicts with similar-named cookies from other applications, or to allow multiple wikis from the same domain to store separate cookies.%0a: :[@$CookiePrefix = 'pmwiki_';@] # set cookie prefix to 'pmwiki_'%0a::If you have a [[WikiFarm(s)]], use the following in each field's ''config.php'' to get a unique prefix for each field in the farm, thus isolating each field's cookies.:%0a: :[@$CookiePrefix = substr($tmp = md5(__FILE__), 0, 5).'_';@]%0a%0a%25rfloat%25$DefaultGroup is currently "{$DefaultGroup}"%0a:$DefaultGroup:[[WikiGroup]] used by default (on startup) when no group is specified in the URL. %0a%0a%25rfloat%25$DefaultName is currently "{$DefaultName}"%0a:$DefaultName:Name of the default HomePage of each WikiGroup. Used when the group doesn't have a page with the same name as the group.%0a: :Note that the behavior will differ based on whether the page exists or not. Probably you want to alter $PagePathFmt in addition to $DefaultName if you really want it to take effect.%0a-> Note: See comment below under $DefaultPage re the order how this must be defined within your (farm)config scripts - this must be set prior to any call of ResolvePageName().%0a%0a:$DefaultPage:Startup page when PmWiki is called without a specified page, normally ''$DefaultGroup.$DefaultName''.%0a-> Note: for $DefaultGroup, $DefaultName and $DefaultPage variables to work, they should be defined in the beginning of (farm)config.php, before any call to the function ResolvePageName(). This means, before any script from PmWiki and before any recipe that might be using this function. This also means it cannot be set in a per-page or per-group customization script - ResolvePageName() is called before these are loaded.%0a: : Please note that this variable is intended to be set in (farm)config.php, not in individual groups. Trying to use different $DefaultName, $DefaultPage or $PagePathFmt settings in different groups will cause cross-group linking anomalies.%0a%0a:$EnableLocalConfig:Allows/disables local/config.php customizations (usually for a farm's wikis). Can be set to zero in local/farmconfig.php to prevent the farm's wikis' local/config.php from being loaded.%0a: :[@$EnableLocalConfig = 0; # disable PmWiki's local/config@]%0a%0a:$EnableStdConfig:Disables scripts/stdconfig.php and a large part of the core functionalities provided by the scripts in the pmwiki/scripts directory and outlined in the core documentation, unless included by your own local configuration (notably core markup rules, page history, skins, uploads). Allows you to completely reshape the way PmWiki behaves, if you need to.%0a: :[@$EnableStdConfig = 0; # disable many standard features@]%0a%0a%0a:$EnablePGCust:Allows/disables per-page and [[GroupCustomizations | per-group customizations]]. Can be set to zero in any [[local customization(s)]] file to prevent remaining page/group customizations from being loaded.%0a: :[@$EnablePGCust=0; # turn off per-page/group configs@]%0a%0a:$EnableRedirect:When enabled (default), causes page redirects to automatically be performed by the browser. Setting $EnableRedirect to zero causes PmWiki to pause and issue a "Redirect to ''link''" message instead. This is sometimes useful when debugging recipes to be able to see the results of actions before page redirections occur. Not to be confused with $EnableRedirectQuiet.%0a%0a:$EnableWikiWords:Enable [[WikiWord]] processing.%0a%0a:$EnableWSPre:Enables a markup rule that causes lines with leading spaces to be treated as sections of preformatted text. If set to a value greater than 1, indicates the minimum number of leading spaces required for this treatment.%0a: :[@$EnableWSPre = 1; # leading spaces are preformatted text@]%0a: :[@$EnableWSPre = 0; # leading spaces are normal lines of text@]%0a: :[@$EnableWSPre = 4; # 4+ spaces are preformatted text@]%0a%0a:$FTimeFmt:Can be used to override the default date format used by the "ftime" function. The default $FTimeFmt is $TimeFmt. (See [[Markup Expressions]])%0a%0a:$GroupPattern: The regular expression pattern used for valid [[WikiGroup]] name specifications. Defaults to allowing any group name beginning with an uppercase letter, but can be set to limit the valid group names (see Cookbook:LimitWikiGroups).%0a: :[@# limit groups to Site, SiteAdmin, PmWiki, and MyGroup@]%0a: :[@$GroupPattern = '(?:Site|SiteAdmin|PmWiki|MyGroup)';@]%0a: :[@#for case-sensitive group names, note the ?-i switch:@]%0a: :[@$GroupPattern = '(?-i:Site|SiteAdmin|PmWiki|MyGroup)';@]%0a%0a:$LinkWikiWords:If set, then bare WikiWords in a page are automatically linked to pages of the same name. Note that this value can also be affected by the [@(:linkwikiwords:)@] and [@(:nolinkwikiwords:)@] directives.%0a: :[@$LinkWikiWords = 1; # turn on WikiWord links@]%0a: :[@$LinkWikiWords = 0; # disable WikiWord links@]%0a: :Note, this setting requires WikiWords to be enabled, see $EnableWikiWords.%0a%0a:$LogoutRedirectFmt: Identifies the page to which the visitor should be sent after an [@?action=logout@]. Defaults to the current page.%0a: :[@$LogoutRedirectFmt = 'Site.Logout'; # ?action=logout target@]%0a%0a:$LogoutCookies: An array of cookie names to be removed when [@?action=logout@] is invoked.%0a%0a:$NamePattern: The regular expression pattern used for valid page names. Defaults to allowing pages beginning with an uppercase letter or digit, followed by sequences of alphanumeric characters, hyphens, and underscores. %0a%0a:$pagename: A variable that gives the name of the current page.%0a->To access inside a Markup callback function, use%0a-->[@$pagename=$GLOBALS['MarkupToHTML']['pagename'];@]%0a->It is also accessible via%0a-->[@global $pagename;@] # if you use it inside a function%0a-->[@$pagename = ResolvePageName($pagename);@]%0a->See [[PmWiki:LocalCustomizations#configphp-group-page|+]] for more information, including when it's possible to use this variable.%0a->Once you have $pagename, page variables become accessible:%0a-->[@%0a$page = PageVar($pagename, '$FullName'); # =$pagename%0a$group = PageVar($pagename, '$Group');%0a$name = PageVar($pagename, '$Name');%0a@]%0a%0a:$PagePathFmt: An array controlling how the default group home-page name will be determined.%0a: : Please note that this variable is intended to be set in (farm)config.php, not in individual groups. Trying to use different $DefaultName, $DefaultPage or $PagePathFmt settings in different groups will cause cross-group linking anomalies.%0a-> Default Setting:%0a-->[@$PagePathFmt = array('{$Group}.$1','$1.$1','$1.{$DefaultName}');@]%0a-> Setting to use if you wish $DefaultName to actually be the name of your group home-pages:%0a-->[@$PagePathFmt = array('{$Group}.$1','$1.{$DefaultName}','$1.$1');@]%0a-> Do note that if the Groupname.Groupname page does exist but Groupname.Defaultname does not exist, then Groupname.Groupname will still take precedence. You may remove the '$1.$1' entirely to '''require''' Groupname.Defaultname to be the group homepage - that would look like this:%0a-->[@$PagePathFmt = array('{$Group}.$1','$1.{$DefaultName}');@]%0a%0a%25rfloat%25$SiteGroup is currently "{$SiteGroup}"%0a:$SiteGroup:Default group for storing configuration and utility pages such as [[Site.Search]], [[Site.EditForm]], [[Site.PageNotFound]], etc.%0a%0a:$SiteAdminGroup:Default group for locked administrative pages such as [[SiteAdmin.AuthList]], [[SiteAdmin.AuthUser]], [[SiteAdmin.ApprovedUrls]], etc, defaults to 'SiteAdmin'.%0a%0a:$Skin:The name of the directory containing the skin (theme) files, default "pmwiki". See [[Skins]].%0a%0a:$SpaceWikiWords:If set, then WikiWords in pages are automatically spaced according to $AsSpacedFunction. Note that this value can also be affected by the [@(:spacewikiwords:)@] and [@(:nospacewikiwords:)@] directives.%0a: :[@$SpaceWikiWords = 1; # turn on WikiWord spacing@]%0a: :[@$SpaceWikiWords = 0; # turn off WikiWord spacing@]%0a%0a:$TimeFmt: The format to use for dates and times, in [[http://php.net/strftime | strftime()]] format. The default value is [@'%25B %25d, %25Y at %25I:%25M %25p'@], which gives dates of the form "September 8, 2005 at 10:57 PM".%0a: :[@$TimeFmt = '%25B %25d, %25Y'; # dates as "September 8, 2005"@]%0a: :[@$TimeFmt = '%25Y-%25m-%25d'; # dates as "2005-09-08"@]%0a%0a%25rfloat%25$Version is currently "{$Version}"%0a:$Version: A string representing the release version of PmWiki.%0a%0a%25rfloat%25$VersionNum is currently "{$VersionNum}"%0a:$VersionNum: A number representing the release version of PmWiki,%0a with the major and minor release components padded with zeroes to%0a produce three digits. Thus, release "pmwiki-2.1.40" will have $VersionNum set to 2001040.%0a%0a The first digit is a 2, the next three digits are the major%0a release number, and the last three digits are the minor release%0a number. Beta releases use 900-999 for the minor release number.%0a Thus:%0a--> [@%0a2.1.0 2001000%0a2.1.1 2001001%0a...%0a2.1.27 2001027%0a2.2.0-beta1 2001901%0a2.2.0-beta2 2001902%0a...%0a2.2.0-beta18 2001918%0a...%0a2.2.0 2002000%0a@]%0a%0a:$WikiWordPattern: The pattern that describes a WikiWord.%0a%0a:$EnableRelativePageVars:This setting controls how [[Page variables]] in included pages are understood by PmWiki.%0a: :@@$EnableRelativePageVars = 1; # PmWiki current default@@\\%0aIn this case @@[={$Name}=]@@ displays the name of the physical page where it written. If @@[={$Name}=]@@ is in an included page, it will display the name of the included page. (This is currently PmWiki's default.)%0a: :@@$EnableRelativePageVars = 0; # revert to previous default@@\\%0aIn this case @@[={$Name}=]@@ displays the name of the currently browsed page. Even if @@[={$Name}=]@@ is in an included page, it will display the name of the browsed page. This was PmWiki's default in versions 2.2.8 and earlier, and changed in 2.2.9, but you can revert it back with this line in config.php.%0a: : @@[={*$Name}=]@@ with an asterisk always displays the name of the currently browsed page, regardless of $EnableRelativePageVars.%0a%0aCategories: [[!PmWiki Developer]] -time=1538510342 +rev=121 +targets=PmWiki.Variables,PmWiki.BasicVariables,PmWiki.AuthoringPhilosophy,PmWiki.EditVariables,PmWiki.AuthUser,PmWiki.Categories,PmWiki.WikiFarms,PmWiki.WikiGroup,PmWiki.GroupCustomizations,PmWiki.LocalCustomizations,PmWiki.LinkVariables,PmWiki.WikiWord,PmWiki.MarkupExpressions,Cookbook.LimitWikiGroups,Site.Search,Site.EditForm,Site.PageNotFound,SiteAdmin.AuthList,SiteAdmin.AuthUser,SiteAdmin.ApprovedUrls,PmWiki.Skins,PmWiki.LayoutVariables,PmWiki.Functions,PmWiki.PageVariables,Category.PmWikiDeveloper,!PmWikiDeveloper +text=(:Summary: core variables:)%0a%0aWhere the [[variables]] are available as wiki markup they are shown as ''Variable value'' "%25pmhlt%25[@{$VariableName}@]".%0a%0a:$AsSpacedFunction:The name of the function used to convert WikiWords into normal, spaced strings. Defaults to '@@AsSpaced@@'.%0a: :%25hlt php%25[@$AsSpacedFunction = 'MyAsSpaced';@]%0a%0a%25rfloat%25$Author is currently "{$Author}"%0a:$Author : Set to the current reader, who is potentially an author ([[PmWiki:AuthoringPhilosophy|see discussion]]). See also $EnablePostAuthorRequired.%0a%0a:$AuthorGroup: The WikiGroup for user profiles. Defaults to '@@Profiles@@'. This variable is implicit in the markup %25pmhlt%25[@[[~AuthorName]]@]%0a: :%25hlt php%25[@$AuthorGroup = 'Users';@]%0a%0a:$AuthId: For sites using [[AuthUser | user-based authorization]], tracks the "reader" or login name.%0a: :%25hlt php%25[@SessionAuth($pagename);@]%0a: :%25hlt php%25[@if( isset($AuthId) ) { // this person has been authenticated@]%0a%0a:$AuthPw: Request for documentation, meanwhile see [[https://www.pmwiki.org/pipermail/pmwiki-users/2006-August/030386.html|AuthId vs AuthPw]].%0a: :%25hlt php%25[@SessionAuth($pagename);@]%0a: :%25hlt php%25[@if( isset($AuthPw) ) { // this person has entered a password@] %0a%0a%25rfloat%25$BaseName is currently "{$BaseName}"%0a:$BaseName:%0a:$BaseNamePatterns:Allows population of the %25pmhlt%25[@{$BaseName}@] PageVariable. The key to the hash is the pattern to be replaced and the value is the replacement string.%0a: :%25hlt php%25[@%0a# If {$FullName} is 'Group.Page-Draft' then {$BaseName} is 'Group.Page'%0a$BaseNamePatterns['/-Draft$/'] = '';%0a# If {$FullName} is 'Comments-Group.Page' then {$BaseName} is 'Group.Page'%0a$BaseNamePatterns['/^Comments-/'] = '';@]%0a%0a:$CategoryGroup: The WikiGroup used for categories. Defaults to '@@Category@@'. (See [[Categories]]). This variable is implicit in the markup %25pmhlt%25[@[[!CategoryName]]@]%0a%0a:$CookiePrefix: A string prefix to be prepended to cookies set from PmWiki scripts. It defaults to '', but can be set to a different value to avoid conflicts with similar-named cookies from other applications, or to allow multiple wikis from the same domain to store separate cookies.%0a: :%25hlt php%25[@$CookiePrefix = 'pmwiki_'; # set cookie prefix to 'pmwiki_'@]%0a::If you have a [[WikiFarm(s)]], use the following in each field's ''@@config.php@@'' to get a unique prefix for each field in the farm, thus isolating each field's cookies.:%0a: :%25hlt php%25[@$CookiePrefix = substr($tmp = md5(__FILE__), 0, 5).'_';@]%0a%0a%25rfloat%25$DefaultGroup is currently "{$DefaultGroup}"%0a:$DefaultGroup:[[WikiGroup]] used by default (on startup) when no group is specified in the URL. %0a%0a%25rfloat%25$DefaultName is currently "{$DefaultName}"%0a:$DefaultName:Name of the default HomePage of each WikiGroup. Used when the group doesn't have a page with the same name as the group.%0a: :Note that the behavior will differ based on whether the page exists or not. Probably you want to alter $PagePathFmt in addition to $DefaultName if you really want it to take effect.%0a-> Note: See comment below under $DefaultPage re the order how this must be defined within your @@(farm)config.php@@ scripts - this must be set prior to any call of %25hlt php%25[@ResolvePageName()@].%0a%0a:$DefaultPage:Startup page when PmWiki is called without a specified page, normally ''@@$DefaultGroup.$DefaultName@@''.%0a-> Note: for @@$DefaultGroup@@, @@$DefaultName@@ and @@$DefaultPage@@ variables to work, they should be defined in the beginning of @@(farm)config.php@@, before any call to the function %25hlt php%25@@ResolvePageName()@@. This means, before any script from PmWiki and before any recipe that might be using this function. This also means it cannot be set in a per-page or per-group customization script - %25hlt php%25@@ResolvePageName()@@ is called before these are loaded.%0a: : Please note that this variable is intended to be set in @@(farm)config.php@@, not in individual groups. Trying to use different @@$DefaultName@@, @@$DefaultPage@@ or@@ $PagePathFmt@@ settings in different groups will cause cross-group linking anomalies.%0a%0a:$EnableLocalConfig:Allows/disables @@local/config.php@@ customizations (usually for a farm's wikis). Can be set to zero in @@local/farmconfig.php@@ to prevent the farm's wikis' @@local/config.php@@ from being loaded.%0a: :%25hlt php%25[@$EnableLocalConfig = 0; # disable PmWiki's local/config@]%0a%0a:$EnableStdConfig:Disables @@scripts/stdconfig.php@@ and a large part of the core functionalities provided by the scripts in the @@pmwiki/scripts@@ directory and outlined in the core documentation, unless included by your own local configuration (notably core markup rules, page history, skins, uploads). Allows you to completely reshape the way PmWiki behaves, if you need to.%0a: :%25hlt php%25[@$EnableStdConfig = 0; # disable many standard features@]%0a%0a%0a:$EnablePGCust:Allows/disables per-page and [[GroupCustomizations | per-group customizations]]. Can be set to zero in any [[local customization(s)]] file to prevent remaining page/group customizations from being loaded.%0a: :%25hlt php%25[@$EnablePGCust = 0; # turn off per-page/group configs@]%0a%0a:$EnableBaseNameConfig:When enabled, and if the page has a different base page (per $BaseNamePatterns), will include the local configuration for the base page. For example, if the page is "Group.Page-Draft", this would try to include the file @@local/Group.Page.php@@ in addition to @@local/Group.Page-Draft.php@@.%0a: :%25hlt php%25[@$EnableBaseNameConfig = 1; # include basename configuration@]%0a%0a:$EnableRedirect:When enabled (default), causes page redirects to automatically be performed by the browser. Setting $EnableRedirect to zero causes PmWiki to pause and issue a "Redirect to ''link''" message instead. This is sometimes useful when debugging recipes to be able to see the results of actions before page redirections occur. Not to be confused with $EnableRedirectQuiet.%0a%0a:$EnableWikiWords:Enable [[WikiWord]] processing.%0a%0a:$EnableWSPre:Enables a markup rule that causes lines with leading spaces to be treated as sections of preformatted text. If set to a value greater than 1, indicates the minimum number of leading spaces required for this treatment.%0a: :%25hlt php%25[@$EnableWSPre = 1; # leading spaces are preformatted text@]%0a: :%25hlt php%25[@$EnableWSPre = 0; # leading spaces are normal lines of text@]%0a: :%25hlt php%25[@$EnableWSPre = 4; # 4+ spaces are preformatted text@]%0a%0a:$FTimeFmt:Can be used to override the default date format used by the "@@ftime@@" function. The default $FTimeFmt is $TimeFmt. (See [[Markup Expressions]].)%0a%0a:$GroupPattern: The regular expression pattern used for valid [[WikiGroup]] name specifications. Defaults to allowing any group name beginning with an uppercase letter, but can be set to limit the valid group names (see Cookbook:LimitWikiGroups).%0a: :%25hlt php%25[@# limit groups to Site, SiteAdmin, PmWiki, and MyGroup@]%0a: :%25hlt php%25[@$GroupPattern = '(?:Site|SiteAdmin|PmWiki|MyGroup)';@]%0a: :%25hlt php%25[@#for case-sensitive group names, note the ?-i switch:@]%0a: :%25hlt php%25[@$GroupPattern = '(?-i:Site|SiteAdmin|PmWiki|MyGroup)';@]%0a%0a:$LinkWikiWords:If set, then bare WikiWords in a page are automatically linked to pages of the same name. Note that this value can also be affected by the %25pmhlt%25[@(:linkwikiwords:)@] and [@(:nolinkwikiwords:)@] directives.%0a: :%25hlt php%25[@$LinkWikiWords = 1; # turn on WikiWord links@]%0a: :%25hlt php%25[@$LinkWikiWords = 0; # disable WikiWord links@]%0a: :Note, this setting requires WikiWords to be enabled, see $EnableWikiWords.%0a%0a:$LogoutRedirectFmt: Identifies the page to which the visitor should be sent after an [@?action=logout@]. Defaults to the current page.%0a: :%25hlt php%25[@$LogoutRedirectFmt = 'Site.Logout'; # ?action=logout target@]%0a%0a:$LogoutCookies: An array of cookie names to be removed when [@?action=logout@] is invoked.%0a%0a:$NamePattern: The regular expression pattern used for valid page names. Defaults to allowing pages beginning with an uppercase letter or digit, followed by sequences of alphanumeric characters, hyphens, and underscores. %0a%0a:$pagename: A variable that gives the name of the current page.%0a->To access inside a Markup callback function, use%0a-->%25hlt php%25[@$pagename=$GLOBALS['MarkupToHTML']['pagename'];@]%0a->It is also accessible via%0a-->%25hlt php%25[@global $pagename;@] # if you use it inside a function%0a-->%25hlt php%25[@$pagename = ResolvePageName($pagename);@]%0a->See [[PmWiki:LocalCustomizations#configphp-group-page|+]] for more information, including when it's possible to use this variable.%0a->Once you have $pagename, page variables become accessible:%0a-->%25hlt php%25[@%0a$page = PageVar($pagename, '$FullName'); # =$pagename%0a$group = PageVar($pagename, '$Group');%0a$name = PageVar($pagename, '$Name');%0a@]%0a%0a:$PagePathFmt: An array controlling how the default group home-page name will be determined.%0a: : Please note that this variable is intended to be set in @@(farm)config.php@@, not in individual groups. Trying to use different @@$DefaultName@@, @@$DefaultPage@@ or @@$PagePathFmt@@ settings in different groups will cause cross-group linking anomalies.%0a-> Default Setting:%0a-->%25hlt php%25[@$PagePathFmt = array('{$Group}.$1','$1.$1','$1.{$DefaultName}');@]%0a-> Setting to use if you wish $DefaultName to actually be the name of your group home-pages:%0a-->%25hlt php%25[@$PagePathFmt = array('{$Group}.$1','$1.{$DefaultName}','$1.$1');@]%0a-> Do note that if the @@Groupname.Groupname@@ page does exist but @@Groupname.Defaultname@@ does not exist, then @@Groupname.Groupname@@ will still take precedence. You may remove the '@@$1.$1@@' entirely to '''require''' @@Groupname.Defaultname@@ to be the group homepage - that would look like this:%0a-->%25hlt php%25[@$PagePathFmt = array('{$Group}.$1','$1.{$DefaultName}');@]%0a%0a%25rfloat%25$SiteGroup is currently "{$SiteGroup}"%0a:$SiteGroup:Default group for storing configuration and utility pages such as [[Site.Search]], [[Site.EditForm]], [[Site.PageNotFound]], etc.%0a%0a:$SiteAdminGroup:Default group for locked administrative pages such as [[SiteAdmin.AuthList]], [[SiteAdmin.AuthUser]], [[SiteAdmin.ApprovedUrls]], etc, defaults to '@@SiteAdmin@@'.%0a%0a:$Skin:The name of the directory containing the skin (theme) files, default "pmwiki". See [[Skins]].%0a%0a:$SpaceWikiWords:If set, then WikiWords in pages are automatically spaced according to $AsSpacedFunction. Note that this value can also be affected by the %25pmhlt%25[@(:spacewikiwords:)@] and [@(:nospacewikiwords:)@] directives.%0a: :%25hlt php%25[@$SpaceWikiWords = 1; # turn on WikiWord spacing@]%0a: :%25hlt php%25[@$SpaceWikiWords = 0; # turn off WikiWord spacing@]%0a%0a:$TimeFmt: The format to use for dates and times, in [[https://www.php.net/manual/en/function.strftime.php | %25hlt php%25@@strftime()@@]] format. The default value is [@'%25B %25d, %25Y at %25I:%25M %25p'@], which gives dates of the form "September 8, 2005 at 10:57 PM". Formats $CurrentTime variable.%0a: :%25hlt php%25[@$TimeFmt = '%25B %25d, %25Y'; # dates as "September 8, 2005"@]%0a: :%25hlt php%25[@$TimeFmt = '%25Y-%25m-%25d'; # dates as "2005-09-08"@]%0a%0a%0a:$EnableFTimeNew: If set to 1, enables the new functions to format dates and times for PHP before 8.1. This allows you to preview the outputs of dates and times, for example in the page footer, in Recent Changes and page histories, or with the %25pmhlt%25[@{(ftime)}@] markup expression. See explanation at [[Functions#PSFT]]. (For PHP 8.1, strftime() is deprecated, and the new functions are enabled by default.)%0a%0a%0a%25rfloat%25$Version is currently "{$Version}"%0a:$Version: A string representing the release version of PmWiki.%0a%0a%25rfloat%25$VersionNum is currently "{$VersionNum}"%0a:$VersionNum: A number representing the release version of PmWiki,%0a with the major and minor release components padded with zeroes to%0a produce three digits. Thus, release "pmwiki-2.1.40" will have $VersionNum set to 2001040.%0a%0a The first digit is a 2, the next three digits are the major%0a release number, and the last three digits are the minor release%0a number. Beta releases use 900-999 for the minor release number.%0a Thus:%0a--> [@%0a2.1.0 2001000%0a2.1.1 2001001%0a...%0a2.1.27 2001027%0a2.2.0-beta1 2001901%0a2.2.0-beta2 2001902%0a...%0a2.2.0-beta18 2001918%0a...%0a2.2.0 2002000%0a@]%0a%0a:$WikiWordPattern: The pattern that describes a WikiWord.%0a%0a:$EnableRelativePageVars:This setting controls how [[Page variables]] in included pages are understood by PmWiki.%0a: :%25hlt php%25@@$EnableRelativePageVars = 1; # PmWiki current default@@\\%0aIn this case %25pmhlt%25@@[={$Name}=]@@ displays the name of the physical page where it written. If @@[={$Name}=]@@ is in an included page, it will display the name of the included page. (This is currently PmWiki's default.)%0a: :%25hlt php%25@@$EnableRelativePageVars = 0; # revert to previous default@@\\%0aIn this case %25pmhlt%25@@[={$Name}=]@@ displays the name of the currently browsed page. Even if @@[={$Name}=]@@ is in an included page, it will display the name of the browsed page. This was PmWiki's default in versions 2.2.8 and earlier, and changed in 2.2.9, but you can revert it back with this line in config.php.%0a: : %25pmhlt%25@@[={*$Name}=]@@ with an asterisk always displays the name of the currently browsed page, regardless of $EnableRelativePageVars.%0a%0aCategories: [[!PmWiki Developer]] +time=1674963286 blob - 38cbace82c98d084282949a3b4795bd1c7be5b9a blob + 78602acddae4599284294b74caa62448ae53556b --- wikilib.d/PmWiki.BlockMarkup +++ wikilib.d/PmWiki.BlockMarkup @@ -1,10 +1,10 @@ -version=pmwiki-2.2.129 ordered=1 urlencoded=1 -author=simon +version=pmwiki-2.3.4 ordered=1 urlencoded=1 +author=simon charset=UTF-8 -csum=add links (+637) +csum=http+s (+1) ctime=1146213979 name=PmWiki.BlockMarkup -rev=21 +rev=25 targets=PmWiki.Forms,PmWiki.TextFormattingRules,PmWiki.Images,PmWiki.Tables,PmWiki.WikiStyles -text=(:Summary:Markup resulting in paragraphs:)%0a"Block markup" is a term used in the sources of PmWiki indicating all markups resulting in HTML block elements'^[[http://htmlhelp.com/reference/html40/block.html|#]]^' or in other words multiple paragraphs and other content.%0a%0a* [[Forms]]%0a* paragraphs%0a* indent/outdent%0a* [[PmWiki/TextFormattingRules#BulletedLists | lists]]%0a* list items%0a* headings%0a* [[#div|divisions]] and [[#semantic|semantic HTML5 elements]]%0a* [[images]]%0a* pre%0a* [[tables]]%0a%0a[[WikiStyles]] can be applied to blocks, else you don't need to bother about "blockmarkup" as a PmWiki user.%0a%0a[[#div]]%0a!! Division blocks%0a%0aDivision %3cdiv> HTML blocks are inserted with the [@(:div:)...(:divend:)@] markup. You can have the HTML @@id=@@ and @@class=@@ attributes like [@(:div id=id1 class="class1 class2":)@]. A [@(:div:)@] markup automatically closes a previously open such tag. To have nested tags, you need to number the tag, and the matching tag end: [@%0a(:div:)%0aOuter block%0a(:div2:)%0aInner block%0a(:div2end:)%0a(:divend:)%0a@]%0a%0a[[#semantic]]%0a!! Semantic HTML5 elements%0a%0aSince version 2.2.75, PmWiki allows the inclusion of a few semantic HTML5 elements. Note that an opening semantic markup automatically closes any previously opened tag of the same type, but does not verify or tidy the structure for you, so make sure you use closing tags when needed.%0a%0a:[@(:article:)...(:articleend:)@]:Inserts an [[https://developer.mozilla.org/en-US/docs/Web/HTML/Element/article|%3carticle>]] tag. You can have the HTML @@id=@@ and @@class=@@ attributes like [@(:article id=id1 class="class1 class2":)@]. An [@(:article:)@] markup automatically closes a previously open such tag. To have nested tags, you need to number the tag, and the matching tag end: [@%0a(:article:)%0aOuter article%0a(:article2:)%0aInner article%0a(:article2end:)%0a(:articleend:)%0a@]%0a%0a:[@(:section:)...(:sectionend:)@]:Inserts a [[https://developer.mozilla.org/en-US/docs/Web/HTML/Element/section|%3csection>]] tag. You can have the HTML @@id=@@ and @@class=@@ attributes like [@(:section id=id1 class="class1 class2":)@]. A [@(:section:)@] markup automatically closes a previously open such tag. To have nested tags, you need to number the tag, and the matching tag end, like the [@(:article:)@] markup.%0a%0a:[@(:header:)...(:headerend:)@]:Inserts a [[https://developer.mozilla.org/en-US/docs/Web/HTML/Element/header|%3cheader>]] tag. You can have the HTML @@id=@@ and @@class=@@ attributes like [@(:header id=id1 class="class1 class2":)@]. A [@(:header:)@] markup automatically closes a previously open such tag, and it is not possible to nest such tags. %0a%0a:[@(:footer:)...(:footerend:)@]:Inserts a [[https://developer.mozilla.org/en-US/docs/Web/HTML/Element/footer|%3cfooter>]] tag. You can have the HTML @@id=@@ and @@class=@@ attributes like [@(:footer id=id1 class="class1 class2":)@]. A [@(:footer:)@] markup automatically closes a previously open such tag, and it is not possible to nest such tags. %0a%0a:[@(:aside:)...(:asideend:)@]:Inserts an [[https://developer.mozilla.org/en-US/docs/Web/HTML/Element/aside|%3caside>]] tag. You can have the HTML @@id=@@ and @@class=@@ attributes like [@(:aside id=id1 class="class1 class2":)@]. An [@(:aside:)@] markup automatically closes a previously open such tag, and it is not possible to nest such tags. %0a%0a:[@(:address:)...(:addressend:)@]:Inserts an [[https://developer.mozilla.org/en-US/docs/Web/HTML/Element/address|%3caddress>]] tag. You can have the HTML @@id=@@ and @@class=@@ attributes like [@(:address id=id1 class="class1 class2":)@]. An [@(:address:)@] markup automatically closes a previously open such tag, and it is not possible to nest such tags. %0a%0a:[@(:nav:)...(:navend:)@]:Inserts a [[https://developer.mozilla.org/en-US/docs/Web/HTML/Element/nav|%3cnav>]] tag. You can have the HTML @@id=@@ and @@class=@@ attributes like [@(:nav id=id1 class="class1 class2":)@]. A [@(:nav:)@] markup automatically closes a previously open such tag, and it is not possible to nest such tags. %0a%0a:[[#details]][@(:details summary="Summary":)...(:detailsend:)@]:Inserts a [[https://developer.mozilla.org/en-US/docs/Web/HTML/Element/details|%3cdetails>]] and embedded [[https://developer.mozilla.org/en-US/docs/Web/HTML/Element/summary|%3csummary>]] section. Standard-compliant browsers will only show the summary, and the user can click on it to open the full section, without a need for JavaScript. A [@(:details:)@] markup automatically closes a previously open such tag. To have nested tags, you need to number the tag, and the matching tag end, like the [@(:article:)@] markup. This is a recent addition to the HTML5 standard, see https://caniuse.com/#feat=details for current browser support (browsers that do not support it show the section open).%0a%0a(:markup:)%0a(:details summary="Click for more information...":)%0aHere is the content of the %3cdetails> section.%0a(:detailsend:)%0a(:markupend:)%0a%0a: : To have a details section open by default, add the attribute @@open=open@@ like [@(:details open=open summary="Summary":)@]%0a%0a!! See also%0a(:pagelist group=PmWiki name=BlockMarkup-Talk fmt=#titlesummary:)%0a(:pagelist group=PmWiki name=*markup,markup*,-*talk fmt=#titlesummary:)%0a%0a -time=1591492020 +text=(:Summary:Markup resulting in paragraphs:)%0a"Block markup" is a term used in the sources of PmWiki indicating all markups resulting in HTML block elements'^[[https://htmlhelp.com/reference/html40/block.html|#]]^' or in other words multiple paragraphs and other content.%0a%0a* [[Forms]]%0a* paragraphs%0a* indent/outdent%0a* [[PmWiki/TextFormattingRules#BulletedLists | lists]]%0a* list items%0a* headings%0a* [[#div|divisions]] and [[#semantic|semantic HTML5 elements]]%0a* [[images]]%0a* pre%0a* [[tables]]%0a%0a[[WikiStyles]] can be applied to blocks, else you don't need to bother about "blockmarkup" as a PmWiki user.%0a%0a[[#div]]%0a!! Division blocks%0a%0aDivision %25hlt html%25[@%3cdiv>@] HTML blocks are inserted with the %25pmhlt%25[@(:div:)...(:divend:)@] markup. You can have the HTML @@id=@@ and @@class=@@ attributes like [@(:div id=id1 class="class1 class2":)@]. A [@(:div:)@] markup automatically closes a previously open such tag. To have nested tags, you need to number the tag, and the matching tag end: [@%0a(:div:)%0aOuter block%0a(:div2:)%0aInner block%0a(:div2end:)%0a(:divend:)%0a@]%0a%0a[[#semantic]]%0a!! Semantic HTML5 elements%0a%0aSince version 2.2.75, PmWiki allows the inclusion of a few semantic HTML5 elements. Note that an opening semantic markup automatically closes any previously opened tag of the same type, but does not verify or tidy the structure for you, so make sure you use closing tags when needed.%0a%0a:%25pmhlt%25[@(:article:)...(:articleend:)@]:Inserts an [[https://developer.mozilla.org/en-US/docs/Web/HTML/Element/article|%25hlt html%25%3carticle>%25%25]] tag. You can have the HTML @@id=@@ and @@class=@@ attributes like %25pmhlt%25[@(:article id=id1 class="class1 class2":)@]. An [@(:article:)@] markup automatically closes a previously open such tag. To have nested tags, you need to number the tag, and the matching tag end: [@%0a(:article:)%0aOuter article%0a(:article2:)%0aInner article%0a(:article2end:)%0a(:articleend:)%0a@]%0a%0a:%25pmhlt%25[@(:section:)...(:sectionend:)@]:Inserts a [[https://developer.mozilla.org/en-US/docs/Web/HTML/Element/section|%25hlt html%25%3csection>]] tag. You can have the HTML @@id=@@ and @@class=@@ attributes like %25pmhlt%25[@(:section id=id1 class="class1 class2":)@]. A [@(:section:)@] markup automatically closes a previously open such tag. To have nested tags, you need to number the tag, and the matching tag end, like the [@(:article:)@] markup.%0a%0a:%25pmhlt%25[@(:header:)...(:headerend:)@]:Inserts a [[https://developer.mozilla.org/en-US/docs/Web/HTML/Element/header|%25hlt html%25%3cheader>]] tag. You can have the HTML @@id=@@ and @@class=@@ attributes like %25pmhlt%25[@(:header id=id1 class="class1 class2":)@]. A [@(:header:)@] markup automatically closes a previously open such tag, and it is not possible to nest such tags. %0a%0a:%25pmhlt%25[@(:footer:)...(:footerend:)@]:Inserts a [[https://developer.mozilla.org/en-US/docs/Web/HTML/Element/footer|%25hlt html%25%3cfooter>]] tag. You can have the HTML @@id=@@ and @@class=@@ attributes like %25pmhlt%25[@(:footer id=id1 class="class1 class2":)@]. A [@(:footer:)@] markup automatically closes a previously open such tag, and it is not possible to nest such tags. %0a%0a:%25pmhlt%25[@(:aside:)...(:asideend:)@]:Inserts an [[https://developer.mozilla.org/en-US/docs/Web/HTML/Element/aside|%25hlt html%25%3caside>]] tag. You can have the HTML @@id=@@ and @@class=@@ attributes like %25pmhlt%25[@(:aside id=id1 class="class1 class2":)@]. An [@(:aside:)@] markup automatically closes a previously open such tag, and it is not possible to nest such tags. %0a%0a:%25pmhlt%25[@(:address:)...(:addressend:)@]:Inserts an [[https://developer.mozilla.org/en-US/docs/Web/HTML/Element/address|%25hlt html%25%3caddress>%25%25]] tag. You can have the HTML @@id=@@ and @@class=@@ attributes like %25pmhlt%25[@(:address id=id1 class="class1 class2":)@]. An [@(:address:)@] markup automatically closes a previously open such tag, and it is not possible to nest such tags. %0a%0a:%25pmhlt%25[@(:nav:)...(:navend:)@]:Inserts a [[https://developer.mozilla.org/en-US/docs/Web/HTML/Element/nav|%25hlt html%25%3cnav>%25%25]] tag. You can have the HTML @@id=@@ and @@class=@@ attributes like %25pmhlt%25[@(:nav id=id1 class="class1 class2":)@]. A [@(:nav:)@] markup automatically closes a previously open such tag, and it is not possible to nest such tags. %0a%0a:[[#details]]%25pmhlt%25[@(:details summary="Summary":)...(:detailsend:)@]:Inserts a [[https://developer.mozilla.org/en-US/docs/Web/HTML/Element/details|%25hlt html%25%3cdetails>]] and embedded [[https://developer.mozilla.org/en-US/docs/Web/HTML/Element/summary|%25hlt html%25%3csummary>]] section. Standard-compliant browsers will only show the summary, and the user can click on it to open the full section, without a need for JavaScript. A %25pmhlt%25[@(:details:)@] markup automatically closes a previously open such tag. To have nested tags, you need to number the tag, and the matching tag end, like the [@(:article:)@] markup. This is a recent addition to the HTML5 standard, see [[https://caniuse.com/#feat=details]] for current browser support (browsers that do not support it show the section open).%0a%0a(:markup:)%0a(:details summary="Click for more information...":)%0aHere is the content of the %3cdetails> section.%0a(:detailsend:)%0a(:markupend:)%0a%0a: : To have a details section open by default, add the attribute @@open=open@@ like %25pmhlt%25[@(:details open=open summary="Summary":)@]%0a%0a!! See also%0a(:pagelist group=PmWiki name=BlockMarkup-Talk fmt=#titlesummary:)%0a(:pagelist group=PmWiki name=*markup,markup*,-*talk fmt=#titlesummary:)%0a%0a +time=1652474078 blob - 47be50559d4260293136244417f4c6a55dd3779a blob + 1f0932f8fe41c7bdf5fae9d67c52e29ff9812209 --- wikilib.d/PmWiki.Blocklist +++ wikilib.d/PmWiki.Blocklist @@ -1,10 +1,10 @@ -version=pmwiki-2.2.86 ordered=1 urlencoded=1 -author=Petko +version=pmwiki-2.3.5 ordered=1 urlencoded=1 +author=simon charset=UTF-8 -csum=#unblock +csum=hlt php, http+s (+402) ctime=1159592216 name=PmWiki.Blocklist -rev=70 -targets=Category.Spam,PmWiki.Security,PmWiki.Passwords,PmWiki.PasswordsAdmin,SiteAdmin.Blocklist,PmWiki.PageHistory,PmWiki.WikiAdministrator,Cookbook.SharedPages,PmWiki.PageVariables -text=(:Summary:Blocking IP addresses, phrases, and expressions to counteract spam and vandalism.:)%0a(:Audience: administrators (basic) :)%0a%0aThe block list is one of a number of [[security]] measures that can be taken to protect your wiki from [[!spam]] and other unwelcome postings.%0a%0aUnfortunately, the open-editability of many wiki systems often makes them attractive targets for "link spam" or "wikispam", in which links are added to pages in an effort to increase search engine rankings or drive traffic to other sites. Also, many link spammers have developed automated systems to locate sites that accept visitor input and attempt to flood the site with unwanted links.%0aAlso, and harder to deal with, is just plain [[PmWiki/Security#wikivandalism|wiki vandalism]] where nonsense changes are made, often replacing entire pages.%0a%0aBy far the best countermeasure against wikispam is to restrict editing through the use of passwords (see [[Passwords]] and [[Passwords Admin]]). Experience has shown that passwords can be effective even if the password is widely known, and even if the password is publicly available on the site itself. However, there are many cases where passwording may be an impediment, so these will generally want to use some form of blocklist.%0a%0a!! Blocklist basics%0a%0aA ''blocklist'' is a list of IP addresses, phrases, and expressions which are prevented from being added into pages on the website. PmWiki is distributed with a built-in blocklisting capability; blocklists can be enabled by adding the following line to ''local/config.php'':%0a%0a-> $EnableBlocklist = 1;%0a%0aThis tells PmWiki to scan the [[SiteAdmin.Blocklist]] page and the "SiteAdmin.Blocklist-Farm" page (and possibly other pages -- see below) looking for phrases and IP addresses to be excluded from posting to the site.%0a%0a!!! Blocking by word or phrase%0aThe simplest form of block is simply a line containing "[@block:@]" followed by a word or phrase to be excluded from postings. For example, a line like %0a%0a-> [@block:spam.com @]%0a%0ain SiteAdmin.Blocklist will block any posts containing the string "spam.com" (case-insensitive) anywhere in the post.%0a%0a[[#blockbyipaddress]]%0a!!! Blocking by IP address%0aSometimes we wish to restrict posts coming from particular addresses or address ranges that are known as sources of wikispam. If a blocklist page contains IP addresses of the form "a.b.c.d" or "a.b.c.*", then any posts coming from that address or range will be blocked. %0a%0a-> %25note%25 To find an author's IP address, try hovering the mouse over the author name in the [[page history]] for a page.%0a%0a!!! Blocking by regular expression or pattern%0aBlocking on simple words can sometimes pose difficulties; for example, a simple "[@block:cial@]" entry will also block the word "specialist". For these cases it's often helpful to use a regular expression, as in:%0a%0a->[@block:/\bcial\b/@]%0a%0aThis says to block "cial" only if it doesn't occur in the middle of a larger word. The leading slash (/) after "block:" tells PmWiki to use a regular expression match instead of a simple string match. (Blocklist uses PCRE or "Perl Compatible Regular Expressions"; see http://php.net/manual/en/ref.pcre.php for more information.)%0a%0a!!!! Regular expression to block 'href'%0a%0aIf you want to block '@@href@@', you can use the following markup:%0a-> [@block:/[^\w\\]href\b/@]%0awhich blocks '@@href@@', but neither '@@\href@@' nor '@@toughref@@'.%0a%0aThe regular expression can be interpreted as follows: Match any character that is '''neither''' a word character%0a'''nor''' a '\', followed by @@href@@ which ends in a word boundary.%0a%0a!! Letting authors know why they've been blocked%0a%0aBy default, blocklist only tells an author that a particular edit has been blocked, but doesn't give a specific reason for the blocking (e.g., the offending phrase). Setting the following in a local customization file will also provide the reasons for the block:%0a%0a-> $EnableWhyBlocked = 1;%0a%0a%0a!! Managing multiple blocklists%0a%0aPmWiki allows blocklist entries to come from multiple pages by setting the $BlocklistPages variable. By default $BlocklistPages is set to "SiteAdmin.Blocklist", as well as any automatically downloaded blocklists as described below. PmWiki will use all entries in all the blocklists for filtering wikispam. Setting a value of $BlocklistPages changes the default:%0a%0a-> $BlocklistPages = array('Main.Blocklist', '{$Group}.Blocklist');%0a%0aThe order of blocklists really doesn't matter -- all of the blocklist%0apages ultimately get used, and the [@unblock:@] entries are processed %0aafter all of the blocklist pages have been loaded.%0a%0a[[#automaticblocklists]]%0a!! Automatically downloaded blocklists%0a%0aMaintaining blocklists is relatively easy to do, but can become tedious over time. Several groups have formed and maintain "shared blocklists", where a common blocklist is made available to all. PmWiki's blocklist capability has built-in features for automatically downloading and updating such shared blocklists.%0a%0aIf you're just in a hurry to make use of some standard blocklists, make the following setting in ''local/config.php'':%0a%0a-> $EnableBlocklist = 10;%0a%0aThis tells PmWiki to not only enable blocklists on the site, but to also configure itself to automatically retrieve and maintain local copies of well-known blocklists such as [[http://moinmo.in/|MoinMaster]]. These local copies will be saved in SiteAdmin.Blocklist-MoinMaster and refreshed once per day (as determined by the value of $BlocklistDownloadRefresh).%0a%0aTo automatically retrieve the [[SiteAdmin.Blocklist]] page used at pmwiki.org, add the following setting in ''local/config.php'':%0a%0a-> [@ $BlocklistDownload["$SiteAdminGroup.Blocklist-PmWiki"] = array('format' => 'pmwiki'); @]%0a%0a'-The blocklist from chongqed.org which we used in the past is no longer available as of 2013.-'%0a%0a!! Ignoring specific entries in a blocklist (unblock) [[#unblock]]%0a%0aWhen using a large master blocklist or blocklists automatically refreshed from external sites, it may be that some entries in the blocklists are inappropriate or overeager and block legitimate content. In this case a wikiadministrator can use "unblock" in a blocklist page to ignore an entry from the blocklist. For example, to allow "spam.com" even if another blocklist has a block entry for it:%0a%0a-> unblock:spam.com%0a%0aIn order for unblocking to work the phrase or pattern following "unblock:" must be ''exactly'' the same as the original.%0a%0a!! Permissions on blocklist pages%0a%0aIn general, an [[(wiki )administrator]] will want to edit-protect the SiteAdmin.Blocklist and any other blocklist pages to prevent arbitrary changes to the blocklist (see [[Passwords]]). Since most pages in the SiteAdmin.* group are edit-protected by default anyway, this usually isn't a problem.%0a%0aAdministrators may also wish to read-protect the various blocklist pages so that others do not know the exact phrases and/or IP addresses that are being blocked. (By their nature blocklists tend to contain phrases or terms that may be offensive or inappropriate to some.)%0a%0aAny pages created via automatic download (see above) are automatically locked against viewing except by administrators. %0a%0a%25audience%25 administrators (intermediate)%0a!! Detailed configuration of automatically downloaded blocklists%0a%0aAutomatic downloading of blocklist information is controlled by the $BlocklistDownload array. An entry for MoinMaster might look like:%0a%0a-> $BlocklistDownload["$SiteAdminGroup.Blocklist-MoinMaster"] = array(%0a--> 'url' => 'http://moinmo.in/BadContent?action=raw',%0a--> 'format' => 'regex',%0a--> 'refresh' => 86400);%0a%0aThis says to download the blocklist data from the given url into the SiteAdmin.Blocklist-MoinMaster page, that the entries in the blocklist are regular expressions, and to refresh the information every 86,400 seconds (one day).%0a%0aIf 'refresh' is omitted, then the page will be refreshed at the time interval given by $BlocklistDownloadRefresh (default one day). If 'format' is omitted, the page is assumed to have PmWiki-formatted entries as described above. If 'url' is omitted, then the blocklist information is downloaded from a standard location on the pmwiki.org site.%0a%0aTo force a refresh of an automatically downloaded blocklist, simply delete the existing page -- a new version will be installed upon the next blocklist scan. Blocklist pages are checked for download in response to any ?action=edit request.%0a%0aIf you are specifying your Blocklist-Pages in the config.php you have to specify the automatically updated pages too, else they won't be updated or created even if you use $EnableBlocklist = 10; .%0a%0a!! Farm-wide blocklist%0a%0aA blocklist can be applied farm-wide (see [[(Cookbook:)SharedPages]]). %0aAfter these pages are created they can be moved into the farm ''shared.d/'' directory:%0a%0a!! [[#variables]] Blocklist Variables%0a%0aThe following variables help control the configuration and operation of blocklists:%0a%0a:$EnableBlocklist:If set to a non-zero value, then blocklists are enabled on the site. If set to a value of ten or higher, then add entries for automatic downloads of standard blocklists.%0a: : $EnableBlocklist = 1; # enable blocklists%0a: : $EnableBlocklist = 10; # auto-configure standard blocklists%0a%0a:$EnableWhyBlocked:By default, authors are not told which particular phrases or IP addresses are causing a particular post to be blocked; setting $EnableWhyBlocked to 1 provides this information.%0a: : $EnableWhyBlocked = 1; # give reasons for blocking%0a%0a:$BlocklistPages:An array of pages to be checked for blocklist entries. The elements of the array may contain [[page variables]]. Defaults to "SiteAdmin.Blocklist", plus any other automatically downloaded blocklist pages.%0a%0a:$BlocklistMessageFmt:The message to provide the author whenever a post has been blocked.%0a%0a:$BlockedMessagesFmt:If $EnableWhyBlocked is set, defines the text to use for each type of block being performed. Currently only 'ip' and 'text' are recognized.%0a: : $BlockedMessagesFmt['ip'] = "$[IP address blocked from posting]: ";%0a: : $BlockedMessagesFmt['text'] = "$[Text blocked from posting]: ";%0a%0a:$BlocklistDownload:An array of automatically-downloaded blocklists. The keys of the array are the pages in which the blocklists should be stored, the values contain the url, format, and refresh interval for the downloaded blocklist.%0a->[@ # Download the MoinMaster blocklist every twelve hours%0a $BlocklistDownload["$SiteAdminGroup.Blocklist-MoinMaster"] = array(%0a 'url' => 'http://moinmo.in/BadContent?action=raw', %0a 'format' => 'regex',%0a 'refresh' => 43200);%0a # Download a shared blocklist from pmwiki.org every day%0a $BlocklistDownload["$SiteAdminGroup.Blocklist-Shared"] = array(%0a 'format' => 'pmwiki');%0a@]%0a%0a:$BlocklistDownloadRefresh:The default refresh interval for any $BlocklistDownload entries that don't explicitly specify a 'refresh' value.%0a: : # perform automatic downloads once per week by default%0a: : $BlocklistDownloadRefresh = 86400 * 7;%0a%0a:$BlocklistDownloadFmt:The format to use when saving automatically downloaded blocklists.%0a%0a%0a:$EnableBlocklistImmediate:Some cookbook recipes update pages with author input but don't use the built-in data posting routines. If $EnableBlocklistImmediate is set (default) and the current action is listed in $BlocklistActions (below), then an immediate blocklist scan is performed on the incoming text.%0a%0a:$BlocklistActions:A list of actions for which immediate blocklist checks should be performed (see $EnableBlocklistImmediate above).%0a: : # perform immediate checks for ?action=comment%0a: : $BlocklistActions['comment'] = 1;%0a: : # perform immediate checks for ?action=postdata%0a: : $BlocklistActions['postdata'] = 1;%0a -time=1462235273 +rev=74 +targets=PmWiki.Security,Category.Spam,!Spam,PmWiki.Passwords,PmWiki.PasswordsAdmin,PmWiki.Blocklist,SiteAdmin.Blocklist,PmWiki.PageHistory,PmWiki.WikiAdministrator,Cookbook.SharedPages,PmWiki.PageVariables +text=(:Summary:Blocking IP addresses, phrases, and expressions to counteract spam and vandalism.:)%0a(:Audience: administrators (basic) :)%0a%0aThe block list is one of a number of [[security]] measures that can be taken to protect your wiki from [[!spam]] and other unwelcome postings.%0a%0aUnfortunately, the open-editability of many wiki systems often makes them attractive targets for "link spam" or "wikispam", in which links are added to pages in an effort to increase search engine rankings or drive traffic to other sites. Also, many link spammers have developed automated systems to locate sites that accept visitor input and attempt to flood the site with unwanted links.%0aAlso, and harder to deal with, is just plain [[PmWiki/Security#wikivandalism|wiki vandalism]] where nonsense changes are made, often replacing entire pages.%0a%0aBy far the best countermeasure against wikispam is to restrict editing through the use of passwords (see [[Passwords]] and [[Passwords Admin]]). Experience has shown that passwords can be effective even if the password is widely known, and even if the password is publicly available on the site itself. However, there are many cases where passwording may be an impediment, so these will generally want to use some form of blocklist.%0a%0a!! Blocklist basics%0a%0aA ''blocklist'' is a list of IP addresses, phrases, and expressions which are prevented from being added into pages on the website. PmWiki is distributed with a built-in blocklisting capability; blocklists can be enabled by adding the following line to ''@@local/config.php@@'':%0a%0a-> %25hlt php%25@@$EnableBlocklist = 1;@@%0a%0aThis tells PmWiki to scan the [[SiteAdmin.Blocklist]] page and the "SiteAdmin.Blocklist-Farm" page (and possibly other pages -- see below) looking for phrases and IP addresses to be excluded from posting to the site.%0a%0a!!! Blocking by word or phrase%0aThe simplest form of block is simply a line containing "[@block:@]" followed by a word or phrase to be excluded from postings. For example, a line like %0a%0a-> [@block:spam.com @]%0a%0ain @@SiteAdmin.Blocklist@@ will block any posts containing the string "spam.com" (case-insensitive) anywhere in the post.%0a%0a[[#blockbyipaddress]]%0a!!! Blocking by IP address%0aSometimes we wish to restrict posts coming from particular addresses or address ranges that are known as sources of wikispam. If a blocklist page contains IP addresses of the form "a.b.c.d" or "a.b.c.*", then any posts coming from that address or range will be blocked. %0a%0a-> %25note%25 To find an author's IP address, try hovering the mouse over the author name in the [[page history]] for a page.%0a%0a!!! Blocking by regular expression or pattern%0aBlocking on simple words can sometimes pose difficulties; for example, a simple "[@block:cial@]" entry will also block the word "specialist". For these cases it's often helpful to use a regular expression, as in:%0a%0a->[@block:/\bcial\b/@]%0a%0aThis says to block "@@cial@@" only if it doesn't occur in the middle of a larger word. The leading slash (/) after "block:" tells PmWiki to use a regular expression match instead of a simple string match. (Blocklist uses PCRE or "Perl Compatible Regular Expressions"; see [[https://www.php.net/manual/en/ref.pcre.php | PCRE functions]] for more information.)%0a%0a!!!! Regular expression to block 'href'%0a%0aIf you want to block '@@href@@', you can use the following markup:%0a-> [@block:/[^\w\\]href\b/@]%0awhich blocks '@@href@@', but neither '@@\href@@' nor '@@toughref@@'.%0a%0aThe regular expression can be interpreted as follows: Match any character that is '''neither''' a word character%0a'''nor''' a '\', followed by @@href@@ which ends in a word boundary.%0a%0a!! Letting authors know why they've been blocked%0a%0aBy default, blocklist only tells an author that a particular edit has been blocked, but doesn't give a specific reason for the blocking (e.g., the offending phrase). Setting the following in a local customization file will also provide the reasons for the block:%0a%0a-> %25hlt php%25@@$EnableWhyBlocked = 1;@@%0a%0a%0a!! Managing multiple blocklists%0a%0aPmWiki allows blocklist entries to come from multiple pages by setting the @@$BlocklistPages@@ variable. By default @@$BlocklistPages@@ is set to "@@SiteAdmin.Blocklist@@", as well as any automatically downloaded blocklists as described below. PmWiki will use all entries in all the blocklists for filtering wikispam. Setting a value of @@$BlocklistPages@@ changes the default:%0a%0a-> %25hlt php%25[@$BlocklistPages = array('Main.Blocklist', '{$Group}.Blocklist');@]%0a%0aThe order of blocklists really doesn't matter -- all of the blocklist%0apages ultimately get used, and the [@unblock:@] entries are processed %0aafter all of the blocklist pages have been loaded.%0a%0a[[#automaticblocklists]]%0a!! Automatically downloaded blocklists%0a%0aMaintaining blocklists is relatively easy to do, but can become tedious over time. Several groups have formed and maintain "shared blocklists", where a common blocklist is made available to all. PmWiki's blocklist capability has built-in features for automatically downloading and updating such shared blocklists.%0a%0aIf you're just in a hurry to make use of some standard blocklists, make the following setting in ''@@local/config.php@@'':%0a%0a-> %25hlt php%25@@$EnableBlocklist = 10;@@%0a%0aThis tells PmWiki to not only enable blocklists on the site, but to also configure itself to automatically retrieve and maintain local copies of well-known blocklists such as [[https://moinmo.in/|MoinMaster]]. These local copies will be saved in @@SiteAdmin.Blocklist-MoinMaster@@ and refreshed once per day (as determined by the value of @@$BlocklistDownloadRefresh@@).%0a%0aTo automatically retrieve the [[SiteAdmin.Blocklist]] page used at pmwiki.org, add the following setting in ''@@local/config.php@@'':%0a%0a-> %25hlt php%25[@ $BlocklistDownload["$SiteAdminGroup.Blocklist-PmWiki"] = array('format' => 'pmwiki'); @]%0a%0a'-The blocklist from chongqed.org which we used in the past is no longer available as of 2013.-'%0a%0a!! Ignoring specific entries in a blocklist (unblock) [[#unblock]]%0a%0aWhen using a large master blocklist or blocklists automatically refreshed from external sites, it may be that some entries in the blocklists are inappropriate or overeager and block legitimate content. In this case a wikiadministrator can use "unblock" in a blocklist page to ignore an entry from the blocklist. For example, to allow "spam.com" even if another blocklist has a block entry for it:%0a%0a-> [@unblock:spam.com@]%0a%0aIn order for unblocking to work the phrase or pattern following "unblock:" must be ''exactly'' the same as the original.%0a%0a!! Permissions on blocklist pages%0a%0aIn general, an [[(wiki )administrator]] will want to edit-protect the @@SiteAdmin.Blocklist@@ and any other blocklist pages to prevent arbitrary changes to the blocklist (see [[Passwords]]). Since most pages in the @@SiteAdmin.*@@ group are edit-protected by default anyway, this usually isn't a problem.%0a%0aAdministrators may also wish to read-protect the various blocklist pages so that others do not know the exact phrases and/or IP addresses that are being blocked. (By their nature blocklists tend to contain phrases or terms that may be offensive or inappropriate to some.)%0a%0aAny pages created via automatic download (see above) are automatically locked against viewing except by administrators. %0a%0a%25audience%25 administrators (intermediate)%0a!! Detailed configuration of automatically downloaded blocklists%0a%0aAutomatic downloading of blocklist information is controlled by the $BlocklistDownload array. An entry for MoinMaster might look like:%0a%0a-> %25hlt php%25[@$BlocklistDownload["$SiteAdminGroup.Blocklist-MoinMaster"] = array(%0a 'url' => 'http://moinmo.in/BadContent?action=raw',%0a 'format' => 'regex',%0a 'refresh' => 86400);@]%0a%0aThis says to download the blocklist data from the given url into the @@SiteAdmin.Blocklist-MoinMaster@@ page, that the entries in the blocklist are regular expressions, and to refresh the information every 86,400 seconds (one day).%0a%0aIf 'refresh' is omitted, then the page will be refreshed at the time interval given by @@$BlocklistDownloadRefresh@@ (default one day). If 'format' is omitted, the page is assumed to have PmWiki-formatted entries as described above. If 'url' is omitted, then the blocklist information is downloaded from a standard location on the pmwiki.org site.%0a%0aTo force a refresh of an automatically downloaded blocklist, simply delete the existing page -- a new version will be installed upon the next blocklist scan. Blocklist pages are checked for download in response to any ?action=edit request.%0a%0aIf you are specifying your Blocklist-Pages in the config.php you have to specify the automatically updated pages too, else they won't be updated or created even if you use @@$EnableBlocklist = 10;@@ .%0a%0a!! Farm-wide blocklist%0a%0aA blocklist can be applied farm-wide (see [[(Cookbook:)SharedPages]]). %0aAfter these pages are created they can be moved into the farm ''@@shared.d/@@'' directory:%0a%0a!! [[#variables]] Blocklist Variables%0a%0aThe following variables help control the configuration and operation of blocklists:%0a%0a:@@$EnableBlocklist@@: If set to a non-zero value, then blocklists are enabled on the site. If set to a value of ten or higher, then add entries for automatic downloads of standard blocklists.%0a: : %25hlt php%25@@$EnableBlocklist = 1; # enable blocklists@@%0a: : %25hlt php%25@@$EnableBlocklist = 10; # auto-configure standard blocklists@@%0a%0a:@@$EnableWhyBlocked@@: By default, authors are not told which particular phrases or IP addresses are causing a particular post to be blocked; setting @@$EnableWhyBlocked@@ to 1 provides this information.%0a: : %25hlt php%25@@$EnableWhyBlocked = 1; # give reasons for blocking@@%0a%0a:@@$BlocklistPages@@: An array of pages to be checked for blocklist entries. The elements of the array may contain [[page variables]]. Defaults to "@@SiteAdmin.Blocklist@@", plus any other automatically downloaded blocklist pages.%0a%0a:@@$BlocklistMessageFmt@@: The message to provide the author whenever a post has been blocked.%0a%0a:@@$BlockedMessagesFmt@@: If @@$EnableWhyBlocked@@ is set, defines the text to use for each type of block being performed. Currently only 'ip' and 'text' are recognized.%0a: : %25hlt php%25@@$BlockedMessagesFmt['ip'] = "$[IP address blocked from posting]: ";@@%0a: : %25hlt php%25@@$BlockedMessagesFmt['text'] = "$[Text blocked from posting]: ";@@%0a%0a:@@$BlocklistDownload@@: An array of automatically-downloaded blocklists. The keys of the array are the pages in which the blocklists should be stored, the values contain the url, format, and refresh interval for the downloaded blocklist.%0a->%25hlt php%25[@ # Download the MoinMaster blocklist every twelve hours%0a $BlocklistDownload["$SiteAdminGroup.Blocklist-MoinMaster"] = array(%0a 'url' => 'http://moinmo.in/BadContent?action=raw', %0a 'format' => 'regex',%0a 'refresh' => 43200);%0a # Download a shared blocklist from pmwiki.org every day%0a $BlocklistDownload["$SiteAdminGroup.Blocklist-Shared"] = array(%0a 'format' => 'pmwiki');@]%0a%0a:@@$BlocklistDownloadRefresh@@: The default refresh interval for any @@$BlocklistDownload@@ entries that don't explicitly specify a 'refresh' value.%0a: : %25hlt php%25@@# perform automatic downloads once per week by default@@%0a: : %25hlt php%25@@$BlocklistDownloadRefresh = 86400 * 7;@@%0a%0a:@@$BlocklistDownloadFmt@@: The format to use when saving automatically downloaded blocklists.%0a%0a%0a:@@$EnableBlocklistImmediate@@: Some cookbook recipes update pages with author input but don't use the built-in data posting routines. If @@$EnableBlocklistImmediate@@ is set (default) and the current action is listed in @@$BlocklistActions@@ (below), then an immediate blocklist scan is performed on the incoming text.%0a%0a:@@$BlocklistActions@@: A list of actions for which immediate blocklist checks should be performed (see @@$EnableBlocklistImmediate@@ above).%0a: : %25hlt php%25@@# perform immediate checks for ?action=comment@@%0a: : %25hlt php%25@@$BlocklistActions['comment'] = 1;@@%0a: : %25hlt php%25@@# perform immediate checks for ?action=postdata@@%0a: : %25hlt php%25@@$BlocklistActions['postdata'] = 1;@@%0a +time=1654814858 blob - 5f4c8607cb7f52a714895ce9477be14a05dd1b2c blob + 0b6418fe5502ed5d14f99e5357d330ca391337b4 --- wikilib.d/PmWiki.Categories +++ wikilib.d/PmWiki.Categories @@ -1,10 +1,10 @@ -version=pmwiki-2.2.118 ordered=1 urlencoded=1 +version=pmwiki-2.3.4 ordered=1 urlencoded=1 author=Petko charset=UTF-8 -csum=lead section without heading +csum=either full URL or page variable $PageUrl; remove outdated "guts" section (-634) (-546) keywords=categories, tags name=PmWiki.Categories -rev=81 -targets=Category.Category,Category.GroupFooter,PmWiki.PageLists,PmWiki.BasicVariables,Cookbook.SubgroupMarkup,Cookbook.Tagger,PITS.00447,PmWiki.EditVariables -text=(:Summary:Categories are a way to organize and find related pages:)%0a(:keywords categories, tags:)%0a(:Audience: authors (intermediate) :)%0a%0a[[Category/|Categories]] (also known as "tags") are a way to organize and find related pages. Categories are implemented by default in PmWiki, and in most wikis they don't require any special code or markup, they're just a useful convention. The idea is that every page that falls into a particular subject area should have a link to a shared page containing links to other pages on that subject. These pages are created in the ''Category'' group, and thus these subject areas are called "categories".%0a%0a!!Using categories%0aGetting categories to work requires a single step: adding links to each category. A category named Subject is created by adding a link to [=Category.Subject=] on any page. When you add the link to a page, the page can be described as being ''in'' the category "Subject". %0a%0aThere is a special markup for creating these links which makes categories work more smoothly: [=[[!Subject]]=] will create a link to Category.Subject. So [=[[!Subject]]=] is a kind of shortcut to the page Subject in the category group.%0a%0aA [[Category.GroupFooter]] file is included in the PmWiki release that contains the line [@(:pagelist link={*$FullName} list=normal:)@] so that whenever a category page is displayed, it will show a list of links to pages that reference that page in the category group. Like any other page in [@wikilib.d@] you can modify this page and it will not get overwritten by another release.%0a%0aIt is worth noting that rather than using Category.GroupFooter, the pagelist directive can be added to Category.GroupHeader to similar effect; it just depends on whether you'd prefer to have the list of pages appear before or after any text that you add to the individual category pages (which can be edited just like normal pages).%0a%0aBecause we use the normal [[PmWiki.PageLists|PageList]] @@link=@@ markup, you can use it not only in the category group. If you want to show all pages belonging to the category Subject you can use on any wiki page [@(:pagelist link=Category.Subject list=normal:)@].%0a%0aSimilarly, there's no requirement that a "category page" has to be in the ''Category'' group -- any page can define a "category" of pages that link to it.%0a%0aAn administrator can override the default category group name of "Category" by setting the $CategoryGroup variable in ''config.php'' to another group name. (Normally a change such as this should be done during initial setup on a new wiki; changing this on a wiki with existing content can cause problems with pagelists unless each page with a category is re-saved.)%0a%0aA page author can also link to a category list without adding the linking page to the category by using [=[[ {Category.Subject$PageUrl} | Subject ]]=]. This will create a link that looks like [=[[!Subject]]=] without adding the linking page to the category listing.%0a%0a!!!Recap%0aSo, by adding the link [=[[!Subject]]=] to a page, a link to that page will automatically appear on the page ''Category.Subject'', as long as ''Category.GroupFooter'' has been tweaked appropriately. Thus, you can create a page that automatically creates an alphabetized list of all movies discussed on your wiki by creating links to [=[[!Movies]]=] on each film's page; the resulting automatic list would be on the page ''Category.Movies'' . %0a%0a%25audience%25 authors (advanced)%0a[[#CategoryNesting]]%0a!!Category nesting%0aCategories have the potential for even greater usefulness because [@Category.*@] pages can themselves be placed into categories! To follow an excellent example from John Rankin, let's suppose we have the following film pages in the categories listed to the right:%0a%0a-> [@%0aFilm.ShaunOfTheDead [[!Horror]] [[!Comedy]] [[!2003]]%0aFilm.InMyFathersDen [[!Drama]] [[!2004]]%0aFilm.TheCorporation [[!Documentary]] [[!2003]]%0a@]%0a%0aNow then, we can create [@Category.Horror@], [@Category.Comedy@], [@Category.Drama@], and [@Category.Documentary@], and in each one of those pages we put [@[[!Genre]]@]. In [@Category.2003@] and [@Category.2004@], we put [@[[!Year]]@].%0a%0aSo, what happens when we display [@Category.Genre@] ? We see links to "Comedy", "Drama", "Documentary", and "Horror", because they're in the Genre category. When we click on one of those links, we see all of the films listed in one of those categories. Similarly, if we click on [@Category.Year@], we see links to "2003" and "2004", each of which in turn displays the list of films for that year.%0a%0aFinally, in [@Category.Genre@] and [@Category.Year@] we can put [@[[!Category]]@], which makes them "top-level" categories reachable from the [@Category.Category@] page. Voila, we now have an instant "hierarchy":%0a%0a-> [@%0aCategory.Category%0a Category.Genre%0a Category.Comedy%0a Film.ShaunOfTheDead%0a Category.Drama%0a Film.InMyFathersDen%0a Category.Documentary%0a Film.TheCorporation%0a Category.Horror%0a Film.ShaunOfTheDead%0a Category.Year%0a Category.2003%0a Film.ShaunOfTheDead%0a Film.TheCorporation%0a Category.2004%0a Film.InMyFathersDen%0a@]%0a%0aNote however that this isn't a "strict" hierarchy--i.e., any page or category can appear simultaneously in multiple categories. For example, [@Category.Documentary@] could be a member of both the Genre and top-level category listings.%0a%0aEach category page can have content text before the generated list, e.g., to give a generic description of things in the category. (Or it can be empty, which works fine.) It can also contain associations to related categories ("see also" references). For example, in a tourism wiki, the ''bed and breakfast" category might contain a see-also reference to the "self-catering" category.%0a%0a%25audience%25 administrators (intermediate)%0a!!The guts of the category markup%0aAs mentioned, all of the necessary markup features for Categories are enabled by default in current releases of PmWiki 2.0, but here's how they work for those who are interested. The use of the Category group as the repository for all categories is determined by setting the $CategoryGroup variable, and the special [=[[!Subject]]=] markup is activated by a call to the Markup() function:%0a %0a-> [@SDV($CategoryGroup,'Category');%0aMarkup('[[!','%3clinks','/\[\[!([^\|\]] ?)\]\]/',%0a "%3cspan class='category'>[[$CategoryGroup/$1]]%3c/span>");%0a@]%0a%0a%0a!!Coming up with good category schemes%0aThe hard part about using categories is choosing a good vocabulary. Site content managers may wish to follow the Guidelines for the establishment and development of monolingual thesauri (ISO 2788-1986) and the Guidelines for the establishment and development of multilingual thesauri (ISO 5964-1985). Questions to think about include:%0a* whether a scheme already exists and can be reused%0a* number of levels in a multilevel scheme (not too shallow, not too deep -- e.g. 3)%0a* number of categories per page (not too many, not too few -- e.g. 3)%0a* consistent use of singular ([@[[Mercury]] is a [[!planet]]@]) or plural ([@[[Mercury]] is in the [[!planets]] category@])%0a* disambiguation and use of phrases ([@[[!musical instruments]]@] and [@[[!medical instruments]]@]) or [[Cookbook:Subgroup Markup]] ([@[[!Instruments*Musical]]@] and [@[[!Instruments*Medical]]@])%0a%0aOr you can just let people use whatever category terms they find meaningful. A vocabulary (or "folksonomy") will emerge over time.%0a%0a!!Showing a list of categories%0a%0aTo show a list of categories we can use a pagelist for the pages in the category group. %0aFor instance the following will list pages in the Category group, put it on page [[Category.Category]] for convenience, or on any other page:%0a%0a->[@(:pagelist group=Category list=normal fmt=#title:)@]%0a%0aBut there is a problem: Just adding a category markup to a page will not create a corresponding category page, even though following the link will show the page with a list of pages linking to it!\\%0aTo have category pages automatically created in group 'Category' add the following to config.php:%0a%0a->[@$AutoCreate['/^Category\./'] = array('ctime' => $Now, 'text' => 'List of pages linking to {$Title}');@] (note the quotes)%0a%0aChange 'Category' to the name of your category group. You can also add more definitions for more category groups, useful if you use a recipe like Cookbook:Tagger which allows multiple category groups.%0a%0a!! Linking = Categorizing %0aNote that categorizing a page (using the [@[[!category markup]]@]) cannot be distinguished from referring or linking to a category (using the normal [@[[link markup]]@]), i.e. pages referring to a category become part of that category.%0aThis is the subject of a long outstanding [[PITS:00447|feature request]] that seems to be hard to implement without breaking other functionality. You can link to a category without categorizing the page by using an external link, such as: [@[[{Category.MyCategory$PageUrl}|MyCategory]]@]. Since the link is external, all pages (not just the category page) will ignore it when listing backlinks.%0a%0aSee also [[PmWiki/EditVariables#AutoCreate]] -time=1567166131 +rev=87 +targets=Category.Category,Category.GroupFooter,PmWiki.PageLists,PmWiki.BasicVariables,Cookbook.SubgroupMarkup,Cookbook.Tagger,PmWiki.EditVariables +text=(:Summary:Categories are a way to organize and find related pages:)%0a(:keywords categories, tags:)%0a(:Audience: authors (intermediate) :)%0a[[Category/|Categories]] (also known as "tags") are a way to organize and find related pages. Categories are implemented by default in PmWiki. %0aThe idea is that every page that falls into a particular "subject" area should have a reference to a shared page containing links to other pages on that subject. %0aThese pages are created in the ''Category'' group, and thus these subject areas are called "categories".%0a%0a!!Using categories%0aGetting categories to work requires a single step: adding a reference to a category on a page. %0aA category named @@Subject@@ is created by using special markup that adds a reference to @@[=Category.Subject=]@@ on any page. %0aWhen you add the markup to a page, the page can be described as being ''in'' the category "Subject". %0a%0aThe markup for creating these references is: %25pmhlt%25[@[[!Subject]]@]. %0aSo %25pmhlt%25[@[[!Subject]]@] is a kind of shortcut to the page @@Subject@@ in the @@Category@@ group.%0a%0aA [[Category.GroupFooter]] file is included in the PmWiki release that contains the line %25pmhlt%25[@(:pagelist link={*$FullName} list=normal:)@] so that whenever a category page is displayed, it will show a list of links to pages that reference that page in the category group. Like any other page in [@wikilib.d@] you can modify this page and it will not get overwritten by another release.%0a-> Note: use the markup %25pmhlt%25[@(:pagelist category={*Name} list=normal:)@] to include only 'tagged' pages.%0a%0aIt is worth noting that rather than using @@Category.GroupFooter@@, the [[PageLists#pagelistcategory|pagelist directive]] can be added to @@Category.GroupHeader@@ to similar effect; it just depends on whether you'd prefer to have the list of pages appear before or after any text that you add to the individual category pages (which can be edited just like normal pages).%0a%0aBecause we use the normal [[PmWiki.PageLists|PageList]] @@category=@@ markup, you can use it not only in the category group. If you want to show all pages belonging to the category Subject you can use on any wiki page %25pmhlt%25[@(:pagelist category=Subject list=normal:)@].%0a%0aAn administrator can override the default category group name of "@@Category@@" by setting the @@$CategoryGroup@@ variable in ''@@config.php@@'' to another group name. (Normally a change such as this should be done during initial setup on a new wiki; changing this on a wiki with existing content can cause problems with pagelists unless each page with a category is re-saved.)%0a%0aA page author can link to a category list without adding the linking page to the category by using the full URL link markup %25pmhlt%25 @@[=[[ https://your-wiki/Category/Subject | Subject ]]=]@@ or with a page variable [@[[ {Category.Subject$PageUrl} | Subject ]]@].%0a%0a!!!Recap%0aSo, by adding the markup %25pmhlt%25[@[[!Subject]]@] to a page, a link to that page will automatically appear on the page ''Category.Subject'', as long as ''Category.GroupFooter'' has been tweaked appropriately. Thus, you can create a page that automatically creates an alphabetized list of all movies discussed on your wiki by creating links to [@[[!Movies]]@] on each film's page; the resulting automatic list would be on the page ''Category.Movies'' . %0a%0a%25audience%25 authors (advanced)%0a[[#CategoryNesting]]%0a!!Category nesting%0aCategories have the potential for even greater usefulness because [@Category.*@] pages can themselves be placed into categories! To follow an excellent example from John Rankin, let's suppose we have the following film pages in the categories listed to the right:%0a%0a-> %25pmhlt%25[@%0aFilm.ShaunOfTheDead [[!Horror]] [[!Comedy]] [[!2003]]%0aFilm.InMyFathersDen [[!Drama]] [[!2004]]%0aFilm.TheCorporation [[!Documentary]] [[!2003]]%0a@]%0a%0aNow then, we can create %25pmhlt%25[@Category.Horror@], [@Category.Comedy@], [@Category.Drama@], and [@Category.Documentary@], and in each one of those pages we put [@[[!Genre]]@]. In [@Category.2003@] and [@Category.2004@], we put [@[[!Year]]@].%0a%0aSo, what happens when we display %25pmhlt%25[@Category.Genre@] ? We see links to "Comedy", "Drama", "Documentary", and "Horror", because they're in the Genre category. When we click on one of those links, we see all of the films listed in one of those categories. Similarly, if we click on [@Category.Year@], we see links to "2003" and "2004", each of which in turn displays the list of films for that year.%0a%0aFinally, in %25pmhlt%25[@Category.Genre@] and [@Category.Year@] we can put [@[[!Category]]@], which makes them "top-level" categories reachable from the [@Category.Category@] page. Voila, we now have an instant "hierarchy":%0a%0a-> [@%0aCategory.Category%0a Category.Genre%0a Category.Comedy%0a Film.ShaunOfTheDead%0a Category.Drama%0a Film.InMyFathersDen%0a Category.Documentary%0a Film.TheCorporation%0a Category.Horror%0a Film.ShaunOfTheDead%0a Category.Year%0a Category.2003%0a Film.ShaunOfTheDead%0a Film.TheCorporation%0a Category.2004%0a Film.InMyFathersDen%0a@]%0a%0aNote however that this isn't a "strict" hierarchy--i.e., any page or category can appear simultaneously in multiple categories. For example, %25pmhlt%25[@Category.Documentary@] could be a member of both the Genre and top-level category listings.%0a%0aEach category page can have content text before the generated list, e.g., to give a generic description of things in the category. (Or it can be empty, which works fine.) It can also contain associations to related categories ("see also" references). For example, in a tourism wiki, the ''bed and breakfast" category might contain a see-also reference to the "self-catering" category.%0a%0a%0a!!Coming up with good category schemes%0aThe hard part about using categories is choosing a good vocabulary. Site content managers may wish to follow the Guidelines for the establishment and development of thesauri ([[https://www.niso.org/schemas/iso25964 | ISO 25964]]). Questions to think about include:%0a* whether a scheme already exists and can be reused%0a* number of levels in a multilevel scheme (not too shallow, not too deep -- e.g. 3)%0a* number of categories per page (not too many, not too few -- e.g. 3)%0a* consistent use of singular %25pmhlt%25([@[[Mercury]] is a [[!planet]]@]) (recommended) or plural ([@[[Mercury]] is in the [[!planets]] category@])%0a* disambiguation and use of phrases %25pmhlt%25([@[[!musical instruments]]@] and [@[[!medical instruments]]@]) or [[Cookbook:Subgroup Markup]] ([@[[!Instruments*Musical]]@] and [@[[!Instruments*Medical]]@])%0a%0aOr you can just let people use whatever category terms they find meaningful. A vocabulary (or "folksonomy") will emerge over time.%0a%0a!!Showing a list of categories%0a%0aTo show a list of categories we can use a pagelist for the pages in the category group. %0aFor instance the following will list pages in the Category group, put it on page [[Category.Category]] for convenience, or on any other page:%0a%0a->%25pmhlt%25[@(:pagelist group=Category list=normal fmt=#title:)@]%0a%0aBut there is a problem: Just adding a category markup to a page will not create a corresponding category page, even though following the link will show the page with a list of pages linking to it!\\%0aTo have category pages automatically created in group 'Category' add the following to @@config.php@@:%0a%0a->%25hlt php%25[@$AutoCreate['/^Category\./'] = array('ctime' => $Now, 'text' => 'List of pages linking to {$Title}');@] (note the quotes)%0a%0aChange 'Category' to the name of your category group. You can also add more definitions for more category groups, useful if you use a recipe like Cookbook:Tagger which allows multiple category groups.%0a%0aSee also [[PmWiki/EditVariables#AutoCreate]] +time=1652508123 blob - a437abd8bf3ca16cf26f2fa3581c18ceba005010 blob + 45da8b3dbf1c4465a4a7f8062864f626569de7f4 --- wikilib.d/PmWiki.ChangeLog +++ wikilib.d/PmWiki.ChangeLog @@ -1,9 +1,9 @@ -version=pmwiki-2.2.129 ordered=1 urlencoded=1 +version=pmwiki-2.3.19 ordered=1 urlencoded=1 author=Petko charset=UTF-8 -csum=Version 2.2.130 (2020-07-04) * Update documentation. (+71) +csum=2.3.20 (+112) name=PmWiki.ChangeLog -rev=1464 -targets=Cookbook.RecentChanges,PmWiki.MailingLists,PmWiki.Skins-Talk,Skins.SkinChange,PmWiki.LayoutVariables,PmWiki.OtherVariables,PmWiki.SecurityVariables,Cookbook.ToggleNext,PmWiki.Forms,PmWiki.TableOfContents,Cookbook.SectionEdit,PITS.01448,Cookbook.RecipeCheck,PITS.01145,PmWiki.BasicVariables,PmWiki.BlockMarkup,PmWiki.EditVariables,Cookbook.DeObMail,Cookbook.FixURL,Cookbook.NotSavedWarning,Cookbook.EditHelp,Cookbook.AutoTOC,Cookbook.DeltaBytesRecentChanges,Cookbook.RowspanInSimpleTables,Cookbook.LocalCSS,PmWiki.LinkVariables,Cookbook.PreviewChanges,PmWiki.PagelistVariables,PmWiki.MarkupExpressions,PmWiki.DebugVariables,PmWiki.Notify,PITS.01425,PITS.01422,PITS.01300,SiteAdmin.AuthList,PITS.01408,PITS.01404,Skins.2016,PITS.01406,PITS.01407,PITS.01400,PmWiki.PathVariables,Cookbook.HtmlUrls-Talk,PITS.01401,PITS.01390,PITS.01392,PITS.00638,PITS.01388,PITS.00951,Site.UploadQuickReference,PITS.00197,PITS.00435,PITS.01378,PITS.01379,PITS.01140,PITS.01373,PmWiki.TextFormattingRules-Talk,PITS.01087,PITS.00835,PITS.01110,PITS.01367,PITS.01032,PITS.00489,PITS.00497,PmWiki.Functions,PITS.01363,PITS.01360,PITS.01359,Site.EditQuickReference,PITS.01350,PmWiki.WikiStyles,PITS.00860,PITS.01337,PITS.01112,PmWiki.PageListTemplates,PITS.01345,PITS.01346,PmWiki.LinkSchemes,PITS.01278,PmWiki.Blocklist,PmWiki.PageDirectives,PITS.01319,PITS.01007,PITS.01259,PmWiki.UploadVariables,PITS.01308,PITS.01304,PITS.00978,PITS.01292,PITS.01285,PITS.01282,PITS.01275,PITS.01271,PITS.01266,PmWiki.I18nVariables,PITS.01262,PITS.01260,PITS.01263,PITS.01253,PITS.01255,PITS.01242,PITS.01213,PITS.01212,PITS.01188,PITS.01180,PITS.01201,PITS.01217,PITS.01198,PITS.01190,PITS.01192,PITS.01199,PITS.01191,PITS.01132,PITS.01202,PITS.01197,PITS.01184,PITS.01164,PITS.01121,PITS.01127,PITS.01152,PITS.00657,PITS.01157,PITS.00571,PITS.01106,PITS.00796,PITS.00535,PITS.01098,PITS.00266,PITS.00779,PITS.01155,PITS.01156,PITS.01149,PITS.01150,PITS.01141,PmWiki.CustomMarkup,PITS.01125,PITS.00703,PITS.00088,PITS.00976,PITS.01146,PITS.00813,PITS.01126,PITS.01131,PITS.01071,PITS.00802,PITS.01102,PITS.00238,PITS.01114,PITS.01062,PITS.01103,PITS.01104,PITS.00915,PITS.01099,PITS.00396,PITS.01037,PITS.00836,PITS.00998,PITS.01073,PITS.00980,Cookbook.UTF-8,PmWiki.ReleaseNotes,PITS.00407,PITS.00919,PITS.01081,PITS.01066,PITS.00984,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 ]] \%0a([[https://www.pmwiki.org/pub/pmwiki-devel/pmwiki-latest-svn.zip|ZIP]]) of PmWiki::)\%0a{$:xPrerelease}%0a%0a!!! Version 2.2.130 (2020-07-04) [[#v22130]]%0a* Update documentation.%0a%0a!!! Version 2.2.129 (2020-05-21) [[#v22129]]%0a* Mute some PHP notices.%0a* Copy "simpletable" styles from the "pmwiki-responsive" skin into the old "pmwiki" skin.%0a* Update documentation.%0a%0a!!! Version 2.2.128 (2020-04-26) [[#v22128]]%0a* Strip some trailing spaces and convert some tabs to spaces.%0a* Add comments next to preg_replace() and create_function() where old addons may cause PHP deprecation notices.%0a* Mute some PHP notices.%0a* Print the invalid pagename in the error message.%0a* Update documentation.%0a%0a!!! Version 2.2.127 (2020-03-23) [[#v22127]]%0a* Mute some PHP "undefined variable" notices.%0a* Responsive skin set #wikiedit textarea max-height: 60vh (after discussion+tests at PmWiki:Skins-Talk). %0a* Prefix PmTOC classes "pmtoc-show" and "pmtoc-hide" to avoid processing by other frameworks (reported by Finar).%0a* Add Skins:SkinChange to the core, enabled by either of the variables $EnableAutoSkinList and/or $PageSkinList.%0a* Add FileSizeCompact() and DiffTimeCompact() (can be used by recipes).%0a* Add $FmtV["$upresult"] can be intercepted by recipes.%0a* Update documentation.%0a%0a!!! Version 2.2.126 (2020-02-01) [[#v22126]]%0a* Mute some "Undefined" notices. %0a* Fix caches.php to write an updated .htaccess format.%0a* Fix bug with $PmTOC['MinNumber'] = -1 reported by SteP.%0a* Update documentation.%0a%0a%0a!!! Version 2.2.124, 2.2.125 (2020-01-27) [[#v22124]] [[#v22125]]%0a* Hide .PmTOCdiv if empty.%0a* Add $SetCookieFunction.%0a* Add $ToggleNextSelector, see Cookbook:ToggleNext.%0a* Update documentation.%0a%0a%0a!!! Version 2.2.123 (2019-12-31) [[#v22123]]%0a* Allow for escaped [@[=link address=]@] to have any special characters, including quotes, parentheses and pipes.%0a* Fix PmXMail when the link contains a quote, and to work from headers, footers and sidebars.%0a* Add [[forms|form]] attribute "formnovalidate" (suggested by Robert Riebisch).%0a* Allow [[table of contents]] to work better with Cookbook:SectionEdit (reported by Johan Bengtsson).%0a* Mute a number of PHP notices for undefined variables. %0a* Add that "URL" means in browser in sample-config.php (PITS:01448). %0a* Add Cookbook:RecipeCheck in diag.php.%0a* Refactor functions that handle $EnableRCDiffBytes to show the deltas in the page histories.%0a* Remove $EnableRelativePageVars from sample-config.php (confusing, PITS:01145).%0a* Add upload extensions [[https://developers.google.com/speed/webp | @@webp@@ ]] image format and [[https://www.opus-codec.org/ | @@opus@@]] audio codec.%0a* Update documentation.%0a%0a!!! Version 2.2.122 (2019-11-19) [[#v22122]]%0aVersion 2.2.121 was released by mistake and contained some experimental code that was meant to be tested first.%0a* ObfuscateLinkIMap: Fix bug with special or international characters in custom subject fields, reported by FidelioEspoir.%0a* Add $DefaultUnsetPageTextVars, $DefaultEmptyPageTextVars.%0a* Mute "Uninitialized string offset messages" for error_reporting(E_ALL), reported by DFaure.%0a* Fix PmTOC, when NumberedHeadings is enabled, to number headings even when the TOC would not be created.%0a* Add [@{$$EachCount}@] pagelist template pseudovariable, containing the count for the current "each" loop.%0a* Add $InputAttrs @@role@@ and @@aria-*@@ form attributes, allow aria-\\w* attributes for the [@(:searchbox:)@] field.%0a* Update documentation.%0a%0a!!! Version 2.2.120 (2019-10-13) [[#v22120]]%0a* Add @@(:[[forms#datalist|input datalist]]:)@@ form element.%0a* Add [@(:details summary="...":)...(:detailsend:)@] [[block markup]].%0a* Fix bugs with guiedit.php/guiedit.js reported by FidelioEspoir.%0a* PmTOC: add max-height and overflow-auto to the block.%0a* Update documentation.%0a%0a!!! Version 2.2.119 (2019-10-03) [[#v22119]]%0a* Update for PHP 7.4 "string offset with curly braces is deprecated".%0a* Add @@required="required"@@ attributes to input author/uploader fields when $EnableUploadAuthorRequired or $EnablePostAuthorRequired are set.%0a* Add @@required="required"@@ attributes to the "upload file" element (to prevent posting the form without an attached file).%0a* Add ObfuscateLinkIMap() based on Cookbook:DeObMail, default disabled.%0a* GuiEdit: Add FixUrl button based on Cookbook:FixURL default disabled, add $EnableGuiEditFixUrl;%0a* EditForm: Add features from Cookbook:NotSavedWarning, default disabled, add $EnableNotSavedWarning.%0a* EditForm: Add scroll position to edit text area will be remembered on save-and-edit and preview.%0a* EditForm: Add $EnableEditAutoText and features from Cookbook:EditHelp. %0a* Add $PmTOC, [@(:toc:)@], [@(:notoc:)@], based on a simplified variant of Cookbook:AutoTOC.%0a* Fix bug with pagelist while preview, reported by Finar.%0a* Add $EnableSortable, basic sortable tables based on public domain code from [[https://github.com/tofsjonas/sortable|Jonas Earendel]].%0a* Add $EnableRCDiffBytes based on Cookbook:DeltaBytesRecentChanges. %0a* Add $EnableSimpleTableRowspan replicating features of Cookbook:RowspanInSimpleTables.%0a* Add $WikiPageCSSFmt enables CSS in a wiki page, based on Cookbook:LocalCSS.%0a* Add $EnableHighlight code highlight feature compatible with "highlight.js".%0a* Attachlist @@ext=@@ and @@names=@@ arguments now accept patterns and negatives like @@ext=jpg,png@@, @@ext=-pdf@@, or @@names=-th*---*.jpg@@.%0a* Attachlist: allow both ext= and names= to cohabitate.%0a* MarkupExpr: remove unused declaration.%0a* EditAutoText: use event.ctrlKey and event.shiftKey instead of 2 functions.%0a* Redirect: add 3rd argument $redirecturl which can be provided directly%0a* Add $AddLinkCSS['othergroup'] and $AddLinkCSS['samedomain'] can contain link CSS classes.%0a* Update documentation.%0a%0a!!! Version 2.2.118 (2019-08-28) [[#v22118]]%0a* Add $EnablePreviewChanges and PreviewDiff() based on Cookbook:PreviewChanges.%0a* Update documentation.%0a%0a!!! Version 2.2.117 (2019-07-28) [[#v22117]]%0a* Add $EnableUploadAuthorRequired default to $EnablePostAuthorRequired, add Author field in upload form.%0a* Implement partial content indirect downloads (suggested by Christopher Cox, required for embedded video on iOS).%0a* Add allowed upload video extensions 'm4v' and '3gp'.%0a* Fix lowercase "Content-Disposition" header for downloads.%0a* Update documentation.%0a%0a!!! Version 2.2.116 (2019-06-19) [[#v22116]]%0a* Add $PageListVarFoldFn, defaults to $StrFoldFunction, for international case-insensitive matches of page (text) variables.%0a* Update documentation.%0a%0a!!! Version 2.2.115 (2019-05-13) [[#v22115]]%0a* Responsive skin: Simplify CSS for custom backgrounds, remove repetition.%0a* Update documentation.%0a%0a!!! Version 2.2.114 (2019-04-02) [[#v22114]]%0a* Fix bug with input select lists where an already defined id= attribute may get overwritten.%0a* Vardoc: Move the id= attribute from a standalone anchor to the definition term element (allows ":target" styling).%0a* Vardoc: Localize table header and link text (suggested by Michael F. Wolff).%0a* Add $SkinTemplateIncludeLevel, IncludeTemplate skin directive.%0a* Add input "tel" type, and attribute "pattern". Fix classnames of new input types.%0a* Update documentation.%0a%0a!!! Version 2.2.113 (2019-03-01) [[#v22113]]%0a* Add input button element.%0a* Add $EnableInputDataAttr.%0a* Update documentation.%0a%0a!!! Version 2.2.112 (2019-01-09) [[#v22112]]%0a* Fix switch break for PHP 7.3, reported by Hans-Jürgen Godau.%0a* Update documentation.%0a%0a!!! Version 2.2.111 (2018-12-08) [[#v22111]]%0a* Add @@$[==]Id$@@ subversion keyword to pmwiki.php, requested by Peter Gragert.%0a* Fix responsive skin search form max-width in desktop mode, reported by Moni Kellermann. %0a* Add $DenyHtaccessContent variable. Update protective .htaccess files.%0a* Add tz= and locale= arguments to [@{(ftime )}@] [[MarkupExpression(s)]] (PHP5+).%0a* Update documentation.%0a%0a!!! Version 2.2.110 (2018-11-05) [[#v22110]]%0a* Fix [@{(substr )}@] markup expression with non-number arguments could cause warnings, reported by Simon.%0a* Add $PageListSortCmpFunction, default to current 'strcasecmp'.%0a* Add global $MarkupMarkupLevel which changes when the processing is inside [@(:markup:)@] blocks.%0a* Fix inconsistent white space with inline @@[=[@escaped code@]=]@@, reported by Dannybpng.%0a* Update documentation.%0a%0a!!! Version 2.2.109 (2018-07-09) [[#v22109]]%0a* Update pmcrypt() to exclude negative -@groups from hash checking.%0a* Add $EnableMarkupDiag to backtrace all markup calls, suggested by ChuckG.%0a* Fix Path InterMap broken in 2.2.108, reported by ChuckG.%0a* Update documentation.%0a%0a!!! Version 2.2.108 (2018-07-05) [[#v22108]]%0a* Add $PCCFOverrideFunction.%0a* $AuthUserPageFmt can now be an array of page names.%0a* Add $PageCacheFileFmt default to "%25s/%25s,cache" (like before), allowing custom cache filenames.%0a* Form checkbox labels now have the same tooltip title as the checkbox.%0a* Add [@%25reversed%25@] WikiStyle.%0a* RefCount: add label to checkbox, class to table.%0a* Vardoc: fix markup call, reported by Hans-Jürgen Godau.%0a* pmcrypt() return false when salt appears to be some old PmWiki attribute.%0a* Default InterMap PmWiki URLs have now the HTTPS protocol (suggested by Simon).%0a* Update documentation.%0a%0a!!! Version 2.2.107 (2018-02-02) [[#v22107]]%0a* Fix Forms and Pagelists warnings in PHP 7.2, reported by DFaure.%0a** Fix order=title broken with the previous commit, reported by ChuckG.%0a* Add $MailFunction.%0a* Add ".rtl *" styles.%0a* Update documentation.%0a%0a!!! Version 2.2.106 (2017-12-01) [[#v22106]]%0a* Add pmsetcookie(), $EnableCookieSecure, $EnableCookieHTTPOnly (PITS:01425).%0a* Refactor PageListSort() to make it work for PHP 7.2 without requiring create_function().%0a** Fix ordering broken with the previous commit, reported by ChuckG.%0a* Fix `wikiword markup, reported by Steve Glover.%0a* Update documentation.%0a%0a!!! Version 2.2.105 (2017-11-07) [[#v22105]]%0a* Refactor @@HandleUpload()@@ - add @@UploadSetVars($pagename)@@ to allow custom upload add-ons to set variables.%0a* Fix bug with PQA() that caused invalid HTML with attributes glued together.%0a%0a!!! Version 2.2.104 (2017-10-11) [[#v22104]]%0a* Fix bug with WikiTrails introduced with 2.2.103 (PITS:01422).%0a%0a!!! Version 2.2.103 (2017-10-01) [[#v22103]]%0a* Add pagelist list=grouphomes and fmt=#grouphomes.%0a* Update all scripts for PHP 7.2 (bugtrack).%0a* Make responsive skin also compatible with PmWiki versions 2.2.55 or earlier.%0a* Add *.vtt (web subtitles) as allowed upload extension.%0a* Fix Charset headers for xlpage-iso-*.php%0a* Refactor PageStore class to remove create_function() calls.%0a* Add "title" attribute to input form elements.%0a* Re-add the definition of the $rrep variable in Markup expressions, reported by ChuckG.%0a* Add $AuthLDAPReferrals to set LDAP_OPT_REFERRALS if needed, reported by Kirk Zurell.%0a* Fix missing $pagename for WikiWord links.%0a* Update documentation.%0a%0a%0a!!! Version 2.2.102 (2017-08-05) [[#v22102]]%0a* Revert fix for PITS:01300, the markup engine breaks when a text variable content is longer than 2699 characters.%0a* Add a text box in [[SiteAdmin.AuthList]] to allow filtering of the results.%0a%0a!!! Version 2.2.101 (2017-07-30) [[#v22101]]%0a* Rename function PageStore to __construct, to prevent PHP 7 strict or deprecated notices.%0a%0a!!! Version 2.2.100 (2017-07-30) [[#v22100]]%0a* Workaround around Subversion incompatibility with @@$Author[==]:...$@@ string not intended as SVN keyword.%0a* Responsive skin: add spacing above the #wikitext block, similar to the default skin.%0a* Update documentation.%0a%0a!!! Version 2.2.99 (2017-06-26) [[#v2299]]%0a* Fix Preview didn't show changes due to $ROSPatterns (PITS:01408).%0a* Remove markup rules for previewing author signature not needed anymore.%0a* Fix bug and warning appearing in PHP 4 installations.%0a* Update Wikipedia intermap entry (secure https).%0a* Fix bug with [@[[%3c%3c]]@] styles "clear:both".%0a* {-Fix incomplete definition of page text variable halts the rendering (PITS:01300).-}%0a* Fix $Version didn't work as a vardoc link.%0a* Update documentation.%0a%0a!!! Version 2.2.98 (2017-05-31) [[#v2298]]%0a* Fix WikiStyles where "pct" was incorrectly dropped from some classnames (PITS:01404).%0a* Hide warning about missing intermap file.%0a* Add pmwiki-responsive skin, based on modified Skins:2016.%0a* Responsive skin: Hide icon if PageActions empty. Fix "close" icon didn't appear for the PageActions block. Unrestrict menu height. Switching from portrait view with menu open to landscape: page should not be greyed out (PITS:01406). Landscape view: fix overflow for search form in Epiphany (likely Safari and other AppleWebKit-based browsers). Move the %3cmain> tag up to allow scrolling of the whole #wikibody. Large preformatted blocks will also scroll in the mobile view. Set limit for desktop layout to 50em~800px. Scrollable tables via cosmetic JavaScript.%0a* Both skins: Set default text color (PITS:01406).%0a* Fix Deprecated notice for Site.AuthUser password attributes.%0a* Vardoc links now use MakeLink() to allow a custom LinkPage function, fix bug reported by ChuckG.%0a* $InclCount now counts per browsed page (for multi-page processing recipes).%0a* Make $markupid variable available to markup replacement functions.%0a* Refactor function ReplaceOnSave to allow easier calling from recipes (PITS:01407).%0a* Enable *.mkv as allowed video extension.%0a* Fix bug with attachlist markup.%0a* Fix alternative bold/italics markup in sample-config.php (PITS:01400).%0a* Fix lost space in markup tables, replace markup tables %3ccode> with %3cpre> and add style "pre-wrap" (reported by ChuckG).%0a* Update documentation.%0a%0a!!! Version 2.2.97 (2017-04-07) [[#v2297]]%0a* Fix bug concerning $ScriptUrl when $EnablePathInfo is set, introduced in 2.2.96, reported by 3 users.%0a* Update documentation.%0a%0a!!! Version 2.2.96 (2017-04-05) [[#v2296]]%0a* Fix severe PHP code injection vulnerability, reported by Gabriel Margiani.%0a** Filter $pagename to exclude certain characters.%0a** Add $pagename_unfiltered in case a recipe requires it.%0a* Update documentation.%0a%0a!!! Version 2.2.95 (2017-02-28) [[#v2295]]%0a* Update documentation.%0a%0a!!! Version 2.2.94 (2017-01-31) [[#v2294]]%0a* Strip both .html and .htm extensions (Cookbook:HtmlUrls-Talk).%0a* Clear $PageExistsCache[$pagename] when a page is created or deleted (PITS:01401).%0a* Update documentation.%0a%0a!!! Version 2.2.93 (2016-12-31) [[#v2293]]%0a* Update documentation.%0a%0a!!! Version 2.2.92 (2016-11-30) [[#v2292]]%0a* Skip checking for $AllowPassword if empty or false.%0a* Enable FmtPageName() to expand PageVariables with asterisks.%0a* Update documentation.%0a%0a!!! Version 2.2.91 (2016-09-30) [[#v2291]]%0a* Update documentation.%0a%0a!!! Version 2.2.90 (2016-08-31) [[#v2290]]%0a* Add action parameter to upload form URL.%0a* Add @@imgonly@@ and @@imgcaption@@ CSS classes (PITS:01390).%0a* Fix plus-links with suffix [@[[Page|+]]s@] (PITS:01392).%0a* Update documentation.%0a%0a!!! Version 2.2.89 (2016-07-30) [[#v2289]]%0a* Add identifiers to Site.EditForm elements to enable easier styling.%0a* Add $SimpleTableDefaultClassName, default unset (PITS:00638).%0a* Add temporary $new['=html'] entry, in SaveAttributes().%0a* Fix superfluous line breaks in SiteAdmin.AuthList.%0a* Add optional placeholder attribute in [@(:searchbox:)@].%0a* Add $SearchBoxInputType, default 'text'.%0a* Set $HTMLStylesFmt via SDVA() in vardoc.php, urlapprove.php, and xlpage-utf-8.php.%0a* Fix vardoc.php to recognize and link variables $pagename, $Author, $Skin, and to sort case insensitively.%0a* Update documentation.%0a%0a!!! Version 2.2.88 (2016-06-29) [[#v2288]]%0a* Fix invalid HTML output of WikiTrail links (PITS:01388).%0a* Add 4th argument $double_encode to PHSC() for safe replacement of htmlspecialchars().%0a* Add page variable [@{$SiteAdminGroup}@] (PITS:00951).%0a* Update documentation.%0a%0a!!! Version 2.2.87 (2016-05-31) [[#v2287]]%0a* Add $HTMLTagAttr, to allow inclusion of lang, manifest and other attributes.%0a* Add $EnableRevUserAgent, $FmtV['$DiffUserAgent'].%0a* Fix relative link in [[Site.UploadQuickReference]].%0a* Update documentation.%0a%0a!!! Version 2.2.86 (2016-04-28) [[#v2286]]%0a* Fix PageStore() for PHP 7.%0a* Fix $DefaultPasswords for PHP 7.%0a* Update documentation.%0a%0a!!! Version 2.2.85 (2016-03-31) [[#v2285]]%0a* Add svg(z) and SVG(Z) as embeddable image extensions (PITS:00197, PITS:00435).%0a* Add *.svgz as allowed upload extension.%0a* Update documentation.%0a%0a!!! Version 2.2.84 (2016-02-21) [[#v2284]]%0a* Update/fix URL in UPGRADES.txt (PITS:01378).%0a* Fix indent and outdent CSS for RTL languages (PITS:01379).%0a* Add $EnableLinkPlusTitlespaced (PITS:01140).%0a* Update documentation.%0a%0a!!! Version 2.2.83 (2015-12-31) [[#v2283]]%0a* Update documentation.%0a%0a!!! Version 2.2.82 (2015-11-30) [[#v2282]]%0a* Enable stripmagic() to process arrays recursively.%0a* Update documentation.%0a%0a!!! Version 2.2.81 (2015-10-31) [[#v2281]]%0a* Fix single line PageTextVariable definition (reported by HansB).%0a* Add .ltr and .rtl CSS classes for UTF-8.%0a* Update documentation.%0a%0a!!! Version 2.2.80 (2015-09-30) [[#v2280]]%0a* Modify [@(:searchbox:)@] to use type="search" input.%0a* Update documentation.%0a%0a!!! Version 2.2.79 (2015-08-27) [[#v2279]]%0a* Modify guiedit.js::insMarkup() to accept a custom function name processing the text, and a custom id for the text area.%0a* Add CSS basic colors 'fuchsia','olive','lime','teal','aqua','orange' and 'grey' as WikiStyles (PITS:01373).%0a* Add $EnableROSEscape, default 0 (PmWiki:TextFormattingRules-Talk).%0a* Remove 'target' attribute in input forms (breaks PmForm).%0a* Add HTML5 input types email, url, number, date, search.%0a* Add attribution in script comments.%0a* Update documentation.%0a%0a!!! Version 2.2.78 (2015-07-21) [[#v2278]]%0a* Update $RobotPattern with current user agents.%0a* Accept 'target' attribute in input forms.%0a* Update documentation.%0a%0a!!! Version 2.2.77 (2015-06-19) [[#v2277]]%0a* Add generic function MakeNames() to process MakePageNames().%0a* Extend [@(:if attachments:)@] to specify file and page names (PITS:01087).%0a* Optimize PageStore::recode() to cache utf8_decode and utf8_encode callbacks.%0a* Add [@{$WikiTitle}@] page variable.%0a* Update documentation.%0a%0a!!! Version 2.2.76 (2015-05-31) [[#v2276]]%0a* Recover posted arrays (indexed or associative, not multidimensional) when a password is required (PITS:00835, PITS:01110).%0a* Add label argument to checkbox and radio inputs (PITS:01367).%0a* Enable PHSC() to process arrays recursively.%0a* Enable processing of arrays as input values (PITS:01032).%0a* Add CSS classes to standalone image div and caption (PITS:00489, PITS:00497).%0a* Update documentation.%0a%0a!!! Version 2.2.75 (2015-04-26) [[#v2275]]%0a* Fix uploads to respect $EnableReadOnly.%0a* Escape HTML special characters when printing failed callback creation.%0a* Add [[Functions#pmcrypt | pmcrypt()]] for PHP 5.6 compatibility.%0a* Add markup for HTML5 [[PmWiki:BlockMarkup#semantic | semantic ]] tags article, section, nav, header, footer, aside, address.%0a* Update documentation.%0a%0a%0a!!! Version 2.2.74 (2015-03-28) [[#v2274]]%0a* Allow translation of the "OK" string in forms (PITS:01363).%0a* Update documentation.%0a%0a!!! Version 2.2.73 (2015-02-28) [[#v2273]]%0a* Update documentation.%0a%0a!!! Version 2.2.72 (2015-01-27) [[#v2272]]%0a* Enable markup debug messages even when debug_backtrace() is not available.%0a* Add $AbortFunction.%0a* Restore ability to set a custom $MarkupWordwrapFunction, add $MarkupWrapTag (related to earlier fix for PITS:01360).%0a* Update documentation.%0a%0a!!! Version 2.2.71 (2014-12-29) [[#v2271]]%0a* Add $DraftActionsPattern.%0a* Enable "input default source" parameter to contain multiple pages.%0a* Enable "pagelist request" parameter to contain a list of (dis)allowed parameters.%0a* Enable Markup() backtrace for ?action=ruleset.%0a* Fix strict warning for blacklisted uploads (PITS:01359).%0a* Fix wrong hard wrap in [@(:markup:)@] code examples (PITS:01360).%0a* Update documentation.%0a%0a!!! Version 2.2.70 (2014-11-08) [[#v2270]]%0a* Update documentation.%0a%0a!!! Version 2.2.69 (2014-10-13) [[#v2269]]%0a* Fix DRange() for ISO-8601 dates +/- X days.%0a* Fix wording in [[Site.UploadQuickReference]].%0a* Update documentation.%0a%0a!!! Version 2.2.68 (2014-09-01) [[#v2268]]%0a* Add Skins: InterMap prefix.%0a* Add signature to [[Site.EditQuickReference]] (PITS:01350).%0a* Allow $PostConfig entries to be launched after per-page customization, before other stdconfig.php inclusions if values%3c50.%0a* Add [[WikiStyles]] clear, min and max width and height (PITS:00860), fix [=%25p class=...%25=] with more than one space.%0a* Update documentation.%0a%0a!!! Version 2.2.67 (2014-08-02) [[#v2267]]%0a* Fix InputDefault/PageTextVariables inconsistency (PITS:01337).%0a* Update documentation.%0a%0a!!! Version 2.2.66 (2014-07-02) [[#v2266]]%0a* Fix Author in Notifcations when deleting pages (PITS:01112).%0a* Exclude "_" to be considered as a function name in various $*Patterns.%0a* Update documentation.%0a%0a!!! [[#v2265]] Version 2.2.65 (2014-06-07)%0a* Fix [={$$PseudoVars}=] containing [={*$PageVars}=] in [[PageList Templates]].%0a* Fix wording in scripts/.htaccess (PITS:01345).%0a* Fix fixperms() if directory owner is root (PITS:01346).%0a* Update documentation.%0a%0a!!! [[#v2264]] Version 2.2.64 (2014-05-08)%0a* Add [={(mod)}=] [[PmWiki/MarkupExpressions | markup expression]].%0a* Add tel: and geo: [[PmWiki/LinkSchemes | URI schemes]].%0a* Add $SysMergePassthru to allow Merge() to use passthru() instead of popen().%0a* Update documentation.%0a%0a!!! [[#v2263]] Version 2.2.63 (2014-04-05)%0a* Allow [[PmWiki/Forms | form]] elements to have a dash in the attribute names.%0a* Strip magic slashes for pagelist/search request vars.%0a* Allow input attributes readonly, placeholder and autocomplete for HTML5 sites.%0a* Update documentation.%0a%0a!!! [[#v2262]] Version 2.2.62 (2014-02-28)%0a* Add $CallbackFnTemplates["return"].%0a* Add 4th argument to Markup_e() - $template.%0a* Add $EnableTableAutoValignTop.%0a* Update documentation.%0a%0a!!! [[#v2261]] Version 2.2.61 (2014-01-31)%0a* Add $TableCellAlignFmt.%0a* Remove unused snippet in prefs.php (reported by Oliver Betz).%0a* Remove unused calls to PSS() (reported by John Rankin).%0a* Update documentation.%0a%0a!!! [[#v2260]] Version 2.2.60 (2014-01-12)%0a* Revert to previous pmwiki.css file.%0a%0a!!! [[#v2259]] Version 2.2.59 (2014-01-11)%0a* Fix checking multiple posted fields in blocklist.php (reported by Randy Brown).%0a* Allow Markup_e() to accept a callback as well as code.%0a* Fix "+" shortcut for internal anchor links.%0a* Disable HTML cache if count($_GET)>1 not >2 (PITS:01278).%0a* Fix query string if a "?" is encoded to uppercase "%253F".%0a* Replace CSS font sizes from points (fixed) to percents (relative) for the default skin.%0a* Fix nested conditionals containing $pagename (reported by Benjamin Grassineau).%0a* Update documentation.%0a%0a!!! [[#v2258]] Version 2.2.58 (2013-12-25)%0a* Allow $LinkUpload to be usable in [=(:attachlist:)=].%0a* Enable customizations of [=(:input auth_form:)=].%0a* Remove unused variable $Block in FormatTableRow(), reported by Klonk.%0a* Fix $EnableBlocklistImmediate to check all posted fields for blocked terms.%0a* Add $GLOBALS['MarkupToHTML'] to pass parameters such as $pagename to markup calls.%0a* Update documentation.%0a%0a!!! [[#v2257]] Version 2.2.57 (2013-11-03)%0a* Encode international character used for detection of a recode function.%0a* Enable $IMapLinkFmt['Attach:'] to be used in [[PmWiki/PageDirectives#attachlist|[=(:attachlist:)=]]] links.%0a* Add $MakePageNameSplitPattern.%0a* Update documentation.%0a%0a!!! [[#v2256]] Version 2.2.56 (2013-09-30)%0a* Work in progress to remove the core dependency of the deprecated "eval" feature of the preg_replace() function (PITS:01319).%0a* Add functions PCCF(), PPRE(), PPRA(), Markup_e(), migrating all core calls to these functions.%0a* Fix detection of proper PageStore->recodefn.%0a* Update documentation.%0a%0a%0a!!! [[#v2255]] Version 2.2.55 (2013-09-16)%0a* Add $EnableDraftAtomicDiff (PITS:01007).%0a* Update documentation.%0a%0a!!! [[#v2254]] Version 2.2.54 (2013-08-13)%0a* Fix broken page history for draft pages, reported by ChuckG.%0a* Update documentation.%0a%0a!!! [[#v2253]] Version 2.2.53 (2013-07-08)%0a* Show a message when the post has been blocked because of too many unapproved links.%0a* Update documentation.%0a%0a!!! [[#v2252]] Version 2.2.52 (2013-06-08)%0a* Add docx, pptx, xlsx upload extentions.%0a* Hide E_DEPRECATED warnings for PHP 5.5.%0a* Update documentation.%0a%0a!!! [[#v2251]] Version 2.2.51 (2013-05-08)%0a* Update url to MoinMoin's blocklist.%0a* Comment-out blacklist.chongqed.org as the domain appears to have expired.%0a* Fix possible XSS vulnerability in prefs.php, discovered today.%0a* Fix access keys to be a single character.%0a* Fix $AuthorPage if there is a group named the same as the author (PITS:01259).%0a* Update documentation.%0a%0a!!! [[#v2250]] Version 2.2.50 (2013-04-08)%0a* Update documentation.%0a%0a!!! [[#v2249]] Version 2.2.49 (2013-03-09)%0a* Add $UploadBlacklist array.%0a* Update documentation.%0a%0a!!! [[#v2248]] Version 2.2.48 (2013-02-11)%0a* Fix bug introduced yesterday with some links, reported by Michael Weiner (PITS:01308).%0a%0a!!! [[#v2247]] Version 2.2.47 (2013-02-10)%0a* Enable tooltip titles for links to anchors on the same page.%0a* Update documentation.%0a%0a!!! [[#v2246]] Version 2.2.46 (2013-01-07)%0a* Add third parameter to fixperms() explicitly setting the permissions.%0a* Add $UploadPermAdd and $UploadPermSet variables.%0a* Update documentation.%0a%0a!!! [[#v2245]] Version 2.2.45 (2012-12-02)%0a* Cleanup some PHP notices (PITS:01304).%0a* Update documentation.%0a%0a!!! [[#v2244]] Version 2.2.44 (2012-10-21)%0a* Better display of whitespace in page histories.%0a* Fix definition for PageTextVariables containing a dash (PITS:00978).%0a* Update documentation.%0a%0a!!! [[#v2243]] Version 2.2.43 (2012-09-20)%0a* Allow for HTML attribute names to contain dashes, eg. data-transition, data-role etc.%0a* Remove warning when previewing Site.EditForm.%0a* Update documentation.%0a%0a!!! [[#v2242]] Version 2.2.42 (2012-08-20)%0a* Convert the line-endings in the docs/ directory to \r\n compatible with Windows.%0a* Modify PHSC() to call htmlspecialchars() with a single-byte encoding argument.%0a* Update documentation.%0a%0a!!! [[#v2241]] Version 2.2.41 (2012-08-12)%0a* Change $KeepToken to "\034\034" which is compatible with more encodings.%0a* Update documentation.%0a%0a!!! [[#v2240]] Version 2.2.40 (2012-07-21)%0a* Add PHSC() helper function as a replacement of htmlspecialchars() for PHP 5.4 (PITS:01292).%0a* Update documentation.%0a%0a!!! [[#v2239]] Version 2.2.39 (2012-06-25)%0a* Fix URL encoding of attachment links.%0a* Update documentation.%0a%0a!!! [[#v2238]] Version 2.2.38 (2012-05-21)%0a* Fix "Wrong parameter count for utf8_decode" warning, reported by Simon.%0a* Update documentation.%0a%0a!!! [[#v2237]] Version 2.2.37 (2012-05-01)%0a* Add page filename encoding functions.%0a* Better handling of dots in [@[[#anchor_1.2]]@] sections (PITS:01285).%0a* Expand PageVariables in [[PageList templates]] defaults (PITS:01282).%0a* Add test for iconv() and mb_convert_encoding(), refactor recode().%0a* Update documentation.%0a%0a!!! [[#v2236]] Version 2.2.36 (2011-12-28)%0a* Add $EnableOldCharset variable and $page["=oldcharset"] entry.%0a* Refactor PageStore->recode() to recover Windows-1252 characters.%0a* Add exit line to xlpage-iso-8859-2.php (PITS:01275).%0a* Fix difference in defining and removing "invisible" PTVs.%0a* Update documentation.%0a%0a!!! [[#v2235]] Version 2.2.35 (2011-11-11)%0a* Fix critical PHP injection vulnerability (PITS:01271, reported by Egidio Romano).%0a* Important change: Disable script loading from XLPage().%0a* Move the processing of [@[[link|+]]@] inside LinkPage() and delete markup rule from stdmarkup.php.%0a* Modify MakeLink() to better handle link titles.%0a* Add optional $LinkTitleFunction allowing recipes to customize the link titles.%0a* Fix ReadTrail() to better handle links with titles.%0a* Add title attributes for the HTML templates in the @@ $LinkPage*Fmt @@ variables.%0a* Add upload extensions svg, xcf, ogg, flac, ogv, mp4, webm, odg, epub.%0a* Minor optimization for the MarkupExpressions for UTF-8 strings.%0a* Minor optimization of the rendering of page history.%0a%0a!!! [[#v2234]] Version 2.2.34 (2011-10-10)%0a* Add [[PmWiki/MarkupExpressions]] replacements for UTF-8.%0a* Reset timestamps of Site(Admin).AuthUser to 1000000000, used in upgrades.php.%0a* Update documentation.%0a%0a!!! [[#v2233]] Version 2.2.33 (2011-09-23)%0a* Fix locked states for Site and SiteAdmin GroupAttributes (reported by Brijesh Kothari).%0a* Fix intermap.txt entries PITS: and Wikipedia: to point to their current locations.%0a* Fix refcount.php to produce valid HTML (PITS:01266).%0a%0a!!! [[#v2232]] Version 2.2.32 (2011-09-18)%0a* Add required html xmlns attribute to the print skin template.%0a* Add PageStore->recode() function.%0a* Add $DefaultPageCharset array.%0a* Optimize for speed the inline diff for page history when too many lines were added or deleted.%0a* Update and convert to UTF-8 the documentation.%0a%0a%25note%25 Note: Due to a manipulation error, a version 2.2.31 was created before it was ready for a release.%0a%0a!!! [[#v2230]] Version 2.2.30 (2011-08-13)%0a* Fix $Charset definition in iso-8859-*.php files.%0a* Add $EnableRangeMatchUTF8, set it to 1 to enable range matches in UTF-8.%0a* Update documentation.%0a%0a!!! [[#v2229]] Version 2.2.29 (2011-07-24)%0a* Fix Attach links that were broken with the Path fix in 2.2.28.%0a* Add $IMapLocalPath array containing InterMap prefixes that should be treated as local.%0a%0a!!! [[#v2228]] Version 2.2.28 (2011-07-24)%0a* Fix potential XSS vulnerability in refcount.php (PITS:01262).%0a* Fix bug in Path: links (PITS:01260).%0a* Fix potential XSS vulnerability in custom SitePreferences (PITS:01263).%0a* Update documentation.%0a%0a!!! [[#v2227]] Version 2.2.27 (2011-06-19)%0a* Add block WikiStyle [=%25justify%25=] (PITS:01253).%0a* Remove unused %3cvspace> after a redirection (PITS:01255).%0a* Add ?nodiff=1 parameter for page history to disable diff rendering and show only restore links.%0a* Update documentation.%0a%0a!!! [[#v2226]] Version 2.2.26 (2011-05-21)%0a* Fix ReadTrail(), redundant replacing of hashes, already done in MakePageName().%0a* Update documentation.%0a%0a!!! [[#v2225]] Version 2.2.25 (2011-03-22)%0a* Update documentation.%0a%0a!!! [[#v2224]] Version 2.2.24 (2011-02-15)%0a* Add [@{$$PageTrailDepth}@] pseudovariable for [[PageList templates]].%0a* Fix PageVar(), add $authpage array for an authenticated page data, removed $EnablePageVarAuth.%0a* Update documentation.%0a%0a!!! [[#v2223]] Version 2.2.23 (2011-01-25)%0a* Default $EnablePageVarAuth to 0 until the resolution of PITS:01242.%0a%0a!!! [[#v2222]] Version 2.2.22 (2011-01-16)%0a* Add $EnableXLPageScriptLoad to XLPage() to prevent editors from changing the encoding.%0a* PageVariables now respect authentications (PITS:01213).%0a* Add $EnablePageVarAuth.%0a* Update documentation.%0a%0a!!! [[#v2221]] Version 2.2.21 (2010-12-14)%0a* Fix potential XSS vulnerability, reported by DFaure.%0a* Fix invalid HTML for simple table captions, reported by JL.%0a* Fix WikiStyles could work not properly if a value was empty like accesskey="".%0a%0a!!! [[#v2220]] Version 2.2.20 (2010-12-14)%0a* Fix Pagelist [={$$variable}=] didn't work in template none (PITS:01212).%0a* Fix interface access keys in browse mode (PITS:01188).%0a* Add PmL10n: intermap prefix for the Localization/ group on pmwiki.org (PITS:01180).%0a* Fix AuthUser excluding members didn't work (PITS:01201).%0a* Update documentation.%0a%0a!!! [[#v2219]] Version 2.2.19 (2010-11-10)%0a* Update documentation.%0a%0a!!! [[#v2218]] Version 2.2.18 (2010-09-04)%0a* Fix $SaveAttrPatterns to skip nested conditionals (reported by RandyB).%0a* Fix RecentChanges when an edit summary contains the dollar sign (PITS:01217).%0a* Fix RDF feed number of elements (PITS:01198).%0a* Update documentation.%0a%0a!!! [[#v2217]] Version 2.2.17 (2010-06-20)%0a* Add tabindex as a valid form attribute (PITS:01190).%0a* Collapse adjacent insertions in DiffRenderSource (PITS:01192).%0a* Fix HandleDownload to flush() output before exit (PITS:01199).%0a* Fix HandleDownload to respect $EnableIMSCaching (PITS:01191).%0a* Add $PostConfig functions and scripts, loaded after stdconfig.php (PITS:01132).%0a* Add $AuthUserPat variable for the regexp pattern in AuthUserId() (PITS:01202).%0a* Pass $authlist as last parameter to $AuthUserFunctions (PITS:01197).%0a* Fix "exists" conditional to work with old link markup.%0a* Update documentation.%0a%0a!!! [[#v2216]] Version 2.2.16 (2010-05-10)%0a* Allow "exists" conditional to accept wildcards (PITS:01184)%0a* Fix GUI button [=%25center%25=] which didn't work correctly.%0a* Fix incorrectly parsed quote in PQA(), possible script injection (discovered by Hanno Boeck).%0a%0a!!! [[#v2215]] Version 2.2.15 (2010-03-27)%0a* Add @@ (Auth|Edit)Form @@ to auto-translated titles.%0a* Fix [@ (:if auth LEVEL:) @] to respect $HandleAuth (PITS:01164).%0a* Skip loading of the second half of draft.php if $action!="edit".%0a* Fix bug with [@ (:template none:) @] introduced in 2.2.14, reported by Holger.%0a* Fix HandleDownload() to use binary file-read.%0a%0a!!! [[#v2214]] Version 2.2.14 (2010-02-27)%0a* Fix inline styles in WikiTrails (PITS:01121).%0a* Add a negation parameter to pagelist first/last templates (PITS:01127).%0a* Refactor FPLTemplateFormat(), move repeated code blocks into FPLExpandItemVars().%0a* Add $EnableUndefinedTemplateVars allowing to hide or show undefined template/include [={$$variables}=] (PITS:01152).%0a* Add "title" attribute to external links (PITS:00657).%0a* Add FmtPageTitle() to allow automatic i18n titles for RecentChanges and other technical pages (PITS:01157).%0a* Update documentation.%0a%0a!!! [[#v2213]] Version 2.2.13 (2010-02-21)%0a* Replace deprecated in PHP 5.3 function split() with explode().%0a* Add $WordDiffFunction default to PHPDiff().%0a* Use existing border colors as highlighting background.%0a* Refactor/optimize DiffRenderSource(), merge with DiffRenderInline().%0a* Change default history to show word-level highlighting.%0a* Fix bug with $DiffKeepNum which kept less revisions than it should.%0a* Fix RetrieveAuthPage() call from HandleDiff().%0a* Update documentation.%0a%0a!!! [[#v2212]] Version 2.2.12 (2010-02-17)%0a* Allow a custom $DiffHTMLFunction to skip the line rendering if it returns false.%0a* Add $EnableDiffInline, simple word-level diffs (PITS:00571).%0a* Update documentation.%0a%0a!!! [[#v2211]] Version 2.2.11 (2010-02-14)%0a* Break PrintDiff() into customizable functions (PITS:01106).%0a* Add anchors to individual diffs (PITS:00796).%0a* Remove unused $RecipeInfo definition in markupexpr.php (reported by P.Bowers).%0a* Add [=(:head:) and (:headnr:)=] table directives (PITS:00535).%0a* Fix $GroupPattern and $NamePattern in xlpage-utf-8.php.%0a* Update documentation.%0a%0a!!! [[#v229]] [[#v2210]] Version 2.2.9, 2.2.10 (2010-01-17)%0a* Fix i18n string in PasswdVar(), reported by SteP.%0a* Fix sample-config.php with correct information about $EnableWSPre (PITS:01145).%0a* Fix range searches for wikis in UTF-8 (reported by Maxim).%0a* Fix global variable $StringFolding in scripts/xlpage-utf-8.php.%0a* Fix markup for italics in creole.php.%0a* Fix previews for PTVs, [[PageList templates]] and included sections (PITS:01098).%0a* Add $DiffKeepNum - number of revisions kept, even if older than $DiffKeepDays.%0a* Add Yandex to robots.php.%0a* Change default $EnableRelativePageVars to 1 (PITS:01145).%0a* Add fifth parameter to SetProperty() : keep existing property.%0a* Add $EnablePageTitlePriority (PITS:00266, PITS:00779).%0a* Update documentation.%0a%0a!!! [[#v228]] Version 2.2.8 (2009-12-07)%0a* Fix apostrophes in Author field (PITS:01155).%0a* Fix Condition "exists" for PHP 5.3 (PITS:01156).%0a* Update documentation.%0a%0a!!! [[#v227]] Version 2.2.7 (2009-11-08)%0a* Fix GlobToPCRE() to work with !excl and -excl with PHP 5.3 (PITS:01149).%0a* Fix HandleDownload() correctly quote the filenames (PITS:01150).%0a* Fix SessionAuth() for PHP 5.3, the $_REQUEST array doesn't contain the $_COOKIE array (PITS:01141).%0a* Fix default timezone for PHP 5.3 (PITS:01141).%0a* Update documentation.%0a%0a!!! [[#v226]] Version 2.2.6 (2009-10-04)%0a* Escape apostrophes for multiline textarea/hidden form fields.%0a* Fix global unset of $MarkupRules in [[PmWiki/CustomMarkup|Markup()]] and DisableMarkup(), reported by D.Faure.%0a* Fix call to BuildMarkupRules() in MarkupToHTML(), suggested by Pm.%0a* Allow disabling of $PageListFilters and $FPLTemplateFunctions if set to -1 and thus allow replacing a core function with a custom one.%0a* Fix DRange() returned timestamps +1min or +1day when it shouldn't (PITS:01125).%0a* Add $MarkupWordwrapFunction to allow custom [@(:markup:)@] line width for multibyte wikis (PITS:00703).%0a* Add $MakeUploadNamePatterns to allow custom filename normalization for uploads.%0a* Add a fourth argument to PostRecentChanges() to allow this function to be called with a custom $RecentChangesFmt array.%0a* Add $RecentUploadsFmt, to allow logging of new uploads to the RecentChanges pages (PITS:00088).%0a* Fix Notify for some installations in safe_mode (PITS:00976).%0a* Add $HTMLHeaderFmt['guiedit'] variable in guiedit.php to allow customization (PITS:01146).%0a* Update documentation.%0a%0a!!! [[#v225]] Version 2.2.5 (2009-08-25)%0a* Add *.7z as accepted upload extension (PITS:00813).%0a* Fix global variable $HandleAttrFmt in HandleAttr (PITS:01126).%0a* Allow brackets in input element names (PITS:01131).%0a* Fix CSS class applied twice (PITS:01071).%0a* Fix Not-Modified headers could prevent caching (PITS:00802).%0a* Break FPLTemplate() into configurable sub-parts (PITS:01102).%0a* Add [@(:template none:)@] section for [[PageList templates]].%0a* Fix attr-protected page could be deleted with edit permissions (PITS:00238).%0a* Update documentation.%0a%0a!!! [[#v224]] Version 2.2.4 (2009-07-16)%0a* Fix bug with page attributes, which somehow didn't make it in the 2.2.3 release.%0a* Fix bug with HTML entities in XLPages introduced earlier today in 2.2.3 (reverted, PITS:01114).%0a%0a!!! [[#v223]] Version 2.2.3 (2009-07-16)%0a* Fix action=logout could incorrectly set a session cookie (PITS:01062).%0a* Fix page history trim in vardoc.php (PITS:01103).%0a* Add $EnableUploadGroupAuth, use group password for downloads (PITS:01104).%0a* Fix recursive PTV loops, added $MaxPageTextVars (PITS:00915, PITS:01099).%0a* Fix mkdirp() messages for absolute paths (PITS:00396).%0a* Fix sample-config.php order for urlapprove.php (PITS:01037).%0a* Fix broken signature links on preview.%0a* Fix crypt.php (action=crypt) could malfunction for passwords with quotes or apostrophes.%0a* Fix @@ @_site_*@@ passwords to work in GroupAttributes (PITS:00836, PITS:00998).%0a* Fix possible XSS vulnerabilities, reported by Michael Engelke.%0a* Update documentation.%0a%0a!!! [[#v222]] Version 2.2.2 (2009-06-21)%0a* Fix class in pages not on the breadcrumbs trail, reported by Ed W.%0a* Fix @@tabindex@@ and @@onclick@@ to guiedit buttons.%0a* Fix $GroupPrintHeaderFmt in print.php (PITS:01073).%0a* Fix global vars in xlpage-utf-8.php (PITS:00980).%0a* Fix $txt in LinkPage (reported by Eemeli Aro).%0a* Add $EnableNotifySubjectEncode for international wikis (Cookbook:UTF-8).%0a* Fix international message in Abort().%0a* Fix security bug with AuthUser, reported by Eemeli Aro. See [[Release notes]].%0a* Fix $ActionTitleFmt for login and upload, reported by Eemeli Aro.%0a%0a!!! [[#v221]] Version 2.2.1 (2009-03-28)%0a* Fix $FPLTemplateMarkupFunction which somehow didn't get in the 2.2.0 archive.%0a* Fix wikitrails to work cross-group (PITS:00407).%0a* Add $EnableRedirectQuiet variable (PITS:00919).%0a* Fix [={$Title}=] could display global variables (reported by HansB).%0a* Fix reloaded form submissions could lose values (reported by DaveG).%0a* Fix preview while restoring a version from history (PITS:01081).%0a* Fix relative links with international characters (reported by G. Hermanowicz).%0a* Add in sample-config.php example call to xlpage-utf-8.php (PITS:01066).%0a* Update documentation.%0a* Fix guiedit.php to produce valid HTML.%0a%0a!!! [[#v220]] Version 2.2.0 (2009-01-18)%0a* Convert beta series to official release series.%0a* Add $FPLTemplateMarkupFunction (PITS:00984, requested by John Rankin).%0a%0a!!! [[#older]] Older versions%0a[[(PmWiki:)ChangeLog Archive]] - changes prior to version 2.2.0.%0a -time=1593841718 +rev=1709 +targets=Cookbook.RecentChanges,PmWiki.MailingLists,PmWiki.PagelistVariables,PmWiki.OtherVariables,PITS.01486,PmWiki.UploadVariables,PITS.01297,PmWiki.LayoutVariables,PITS.01485,Cookbook.EditHelp,PmWiki.EditVariables,PmWiki.BasicVariables,PITS.01484,PmWiki.SecurityVariables,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,PITS.01472,PITS.01461,PITS.01465,PITS.01454,PmWiki.Skins-Talk,Skins.SkinChange,Cookbook.ToggleNext,PmWiki.Links,PmWiki.Forms,PmWiki.TableOfContents,Cookbook.SectionEdit,PITS.01448,Cookbook.RecipeCheck,PITS.01145,PmWiki.BlockMarkup,Cookbook.DeObMail,Cookbook.FixURL,Cookbook.NotSavedWarning,Cookbook.AutoTOC,Cookbook.DeltaBytesRecentChanges,Cookbook.RowspanInSimpleTables,Cookbook.LocalCSS,PmWiki.LinkVariables,Cookbook.PreviewChanges,PmWiki.MarkupExpressions,PmWiki.DebugVariables,PmWiki.Notify,PITS.01425,PITS.01422,PITS.01300,SiteAdmin.AuthList,PITS.01408,PITS.01404,Skins.2016,PITS.01406,PITS.01407,PITS.01400,PmWiki.PathVariables,Cookbook.HtmlUrls-Talk,PITS.01401,PITS.01390,PITS.01392,PITS.00638,PITS.01388,PITS.00951,Site.UploadQuickReference,PITS.00197,PITS.00435,PITS.01378,PITS.01379,PITS.01140,PITS.01373,PmWiki.TextFormattingRules-Talk,PITS.01087,PITS.00835,PITS.01110,PITS.01367,PITS.01032,PITS.00489,PITS.00497,PmWiki.Functions,PITS.01363,PITS.01360,PITS.01359,Site.EditQuickReference,PITS.01350,PmWiki.WikiStyles,PITS.00860,PITS.01337,PITS.01112,PmWiki.PageListTemplates,PITS.01345,PITS.01346,PmWiki.LinkSchemes,PITS.01278,PmWiki.PageDirectives,PITS.01319,PITS.01007,PITS.01259,PITS.01308,PITS.01304,PITS.00978,PITS.01292,PITS.01285,PITS.01282,PITS.01275,PITS.01271,PITS.01266,PmWiki.I18nVariables,PITS.01262,PITS.01260,PITS.01263,PITS.01253,PITS.01255,PITS.01242,PITS.01213,PITS.01212,PITS.01188,PITS.01180,PITS.01201,PITS.01217,PITS.01198,PITS.01190,PITS.01192,PITS.01199,PITS.01191,PITS.01132,PITS.01202,PITS.01197,PITS.01184,PITS.01164,PITS.01121,PITS.01127,PITS.01152,PITS.00657,PITS.01157,PITS.00571,PITS.01106,PITS.00796,PITS.00535,PITS.01098,PITS.00266,PITS.00779,PITS.01155,PITS.01156,PITS.01149,PITS.01150,PITS.01141,PmWiki.CustomMarkup,PITS.01125,PITS.00703,PITS.00088,PITS.00976,PITS.01146,PITS.00813,PITS.01126,PITS.01131,PITS.01071,PITS.00802,PITS.01102,PITS.00238,PITS.01114,PITS.01062,PITS.01103,PITS.01104,PITS.00915,PITS.01099,PITS.00396,PITS.01037,PITS.00836,PITS.00998,PITS.01073,PITS.00980,Cookbook.UTF-8,PmWiki.ReleaseNotes,PITS.00407,PITS.00919,PITS.01081,PITS.01066,PITS.00984,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[[#svn-revision-4370]]%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 $IsFarmArchive, $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,...%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%0a!!! Version 2.2.145 (2021-12-11) [[#v22145]]%0a* Hide undefined variable notices for PHP8. %0a* Pagelist searches with wrong $SearchPatterns (list=abc argument) will now use $SearchPatterns["default"] rather than an empty array (effectively all pages). This is to allow admins to limit search locations.%0a* Obsolete markups: change ⚠ emoji for entity [=⚠=] (emoji doesn't work in non-UTF8 wikis).%0a* Update documentation.%0a%0a!!! Version 2.2.144 (2021-11-06) [[#v22144]]%0a* Fix CmpPageAttr() for PHP 8 (suggested by Chris Caputo).%0a* Optimize conditional "exists" if called many times, like from a pagelist.%0a* Allow for CondExists(), MatchPageNames(), and MatchNames() to be called with a $caseinsensitive argument set to ''false'' (default case insensitive is ''true'' like before).%0a* Update intermap.txt for Meatball wiki (PITS:01472).%0a* Update documentation.%0a%0a!!! Version 2.2.143 (2021-10-02) [[#v22143]]%0a* Prevent PHP from crashing with older markups and patterns.%0a* Add ObsoleteMarkup(). Obsolete markup rules are now disabled and will appear framed with a "warning" icon.%0a* Update documentation.%0a%0a!!! Version 2.2.142 (2021-08-31) [[#v22142]]%0a* Mute some PHP notices.%0a* Add form attributes autofocus, accept.%0a* Update documentation.%0a%0a!!! Version 2.2.141 (2021-07-09) [[#v22141]]%0a* Add $MultiFactorAuthFunction.%0a* Add $PageIndexFoldFunction.%0a* Update documentation%0a%0a!!! Version 2.2.140 (2021-06-26) [[#v22140]]%0a* Fix warnings for undefined variables in PHP 8 (PITS:01461).%0a* Update pub/drt-utils.js to use the new API function call for Highlight.js, the old one having been deprecated. This change requires Highlight.js version 10.7.0 or newer (currently 11.0.0).%0a* Update documentation.%0a%0a!!! Version 2.2.139 (2021-05-05) [[#v22139]]%0a* Remove empty title attributes, reported by Martin Cuno.%0a* Hide warning in pagelist.php for PHP 8, reported by Dominique Faure.%0a* Hide warning in wikiwords.php for PHP 8, reported by Jue (PITS:01461).%0a* Update documentation.%0a%0a!!! Version 2.2.138 (2021-03-02) [[#v22138]]%0a* Fix details summary incorrectly escaped HTML, reported by Jack Applin (PITS:01465).%0a* Update documentation.%0a%0a!!! Version 2.2.137 (2021-02-26) [[#v22137]]%0a* Fix bug with twice encoded entities in PQA() quoted arguments.%0a%0a!!! Version 2.2.136 (2021-02-26) [[#v22136]]%0a* Fix XSS vulnerability for WikiStyles reported today by Igor Sak-Sakovskiy.%0a* The PQA() function accepts a second argument $keep default true.%0a%0a!!! Version 2.2.135 (2021-01-31) [[#v22135]]%0a* Fix a number of PHP8 compatibility issues. Report others at PITS:01461.%0a* Add pmtoken(), AutoCheckToken() currently transparent.%0a* Blocklists: disabled a defunct one.%0a* PmTOC: rewrite handling of section editing links.%0a* Update documentation.%0a%0a%0a!!! Version 2.2.134 (2020-11-30) [[#v22134]]%0a* Update documentation.%0a%0a!!! Version 2.2.133 (2020-10-25) [[#v22133]]%0a* Escape unintended variable evaluation in link tooltip titles, reported by Finar.%0a* Responsive skin css: remove ul/ol forced padding (clips numbered list markers in long lists, reported by Colin Cody; complex to override cross-browser).%0a* Add image extensions WEBP and APNG (PITS:01454) and upload extensions.%0a* Fix potential vulnerability to CWE-384: Session Fixation, reported by Dominique Faure. Add $EnableAuthPostRegenerateSID default enabled.%0a* RecipeCheck - only inject CSS when the action is called.%0a* Update documentation.%0a%0a!!! Version 2.2.132 (2020-09-30) [[#v22132]]%0a* Update documentation.%0a%0a!!! Version 2.2.131 (2020-08-30) [[#v22131]]%0a* Update documentation.%0a%0a!!! Version 2.2.130 (2020-07-04) [[#v22130]]%0a* Update documentation.%0a%0a!!! Version 2.2.129 (2020-05-21) [[#v22129]]%0a* Mute some PHP notices.%0a* Copy "simpletable" styles from the "pmwiki-responsive" skin into the old "pmwiki" skin.%0a* Update documentation.%0a%0a!!! Version 2.2.128 (2020-04-26) [[#v22128]]%0a* Strip some trailing spaces and convert some tabs to spaces.%0a* Add comments next to preg_replace() and create_function() where old addons may cause PHP deprecation notices.%0a* Mute some PHP notices.%0a* Print the invalid pagename in the error message.%0a* Update documentation.%0a%0a!!! Version 2.2.127 (2020-03-23) [[#v22127]]%0a* Mute some PHP "undefined variable" notices.%0a* Responsive skin set #wikiedit textarea max-height: 60vh (after discussion+tests at PmWiki:Skins-Talk). %0a* Prefix PmTOC classes "pmtoc-show" and "pmtoc-hide" to avoid processing by other frameworks (reported by Finar).%0a* Add Skins:SkinChange to the core, enabled by either of the variables $EnableAutoSkinList and/or $PageSkinList.%0a* Add FileSizeCompact() and DiffTimeCompact() (can be used by recipes).%0a* Add $FmtV["$upresult"] can be intercepted by recipes.%0a* Update documentation.%0a%0a!!! Version 2.2.126 (2020-02-01) [[#v22126]]%0a* Mute some "Undefined" notices. %0a* Fix caches.php to write an updated .htaccess format.%0a* Fix bug with $PmTOC['MinNumber'] = -1 reported by SteP.%0a* Update documentation.%0a%0a%0a!!! Version 2.2.124, 2.2.125 (2020-01-27) [[#v22124]] [[#v22125]]%0a* Hide .PmTOCdiv if empty.%0a* Add $SetCookieFunction.%0a* Add $ToggleNextSelector, see Cookbook:ToggleNext.%0a* Update documentation.%0a%0a%0a!!! Version 2.2.123 (2019-12-31) [[#v22123]]%0a* Allow for [[Links#escaped | escaped [@[=link address=]@]]] to have any special characters, including quotes, parentheses and pipes.%0a* Fix PmXMail when the link contains a quote, and to work from headers, footers and sidebars.%0a* Add [[forms|form]] attribute "formnovalidate" (suggested by Robert Riebisch).%0a* Allow [[table of contents]] to work better with Cookbook:SectionEdit (reported by Johan Bengtsson).%0a* Mute a number of PHP notices for undefined variables. %0a* Add that "URL" means in browser in sample-config.php (PITS:01448). %0a* Add Cookbook:RecipeCheck in diag.php.%0a* Refactor functions that handle $EnableRCDiffBytes to show the deltas in the page histories.%0a* Remove $EnableRelativePageVars from sample-config.php (confusing, PITS:01145).%0a* Add upload extensions [[https://developers.google.com/speed/webp | @@webp@@ ]] image format and [[https://www.opus-codec.org/ | @@opus@@]] audio codec.%0a* Update documentation.%0a%0a!!! Version 2.2.122 (2019-11-19) [[#v22122]]%0aVersion 2.2.121 was released by mistake and contained some experimental code that was meant to be tested first.%0a* ObfuscateLinkIMap: Fix bug with special or international characters in custom subject fields, reported by FidelioEspoir.%0a* Add $DefaultUnsetPageTextVars, $DefaultEmptyPageTextVars.%0a* Mute "Uninitialized string offset messages" for error_reporting(E_ALL), reported by DFaure.%0a* Fix PmTOC, when NumberedHeadings is enabled, to number headings even when the TOC would not be created.%0a* Add [@{$$EachCount}@] pagelist template pseudovariable, containing the count for the current "each" loop.%0a* Add $InputAttrs @@role@@ and @@aria-*@@ form attributes, allow aria-\\w* attributes for the [@(:searchbox:)@] field.%0a* Update documentation.%0a%0a!!! Version 2.2.120 (2019-10-13) [[#v22120]]%0a* Add @@(:[[forms#datalist|input datalist]]:)@@ form element.%0a* Add [@(:details summary="...":)...(:detailsend:)@] [[block markup]].%0a* Fix bugs with guiedit.php/guiedit.js reported by FidelioEspoir.%0a* PmTOC: add max-height and overflow-auto to the block.%0a* Update documentation.%0a%0a!!! Version 2.2.119 (2019-10-03) [[#v22119]]%0a* Update for PHP 7.4 "string offset with curly braces is deprecated".%0a* Add @@required="required"@@ attributes to input author/uploader fields when $EnableUploadAuthorRequired or $EnablePostAuthorRequired are set.%0a* Add @@required="required"@@ attributes to the "upload file" element (to prevent posting the form without an attached file).%0a* Add ObfuscateLinkIMap() based on Cookbook:DeObMail, default disabled.%0a* GuiEdit: Add FixUrl button based on Cookbook:FixURL default disabled, add $EnableGuiEditFixUrl;%0a* EditForm: Add features from Cookbook:NotSavedWarning, default disabled, add $EnableNotSavedWarning.%0a* EditForm: Add scroll position to edit text area will be remembered on save-and-edit and preview.%0a* EditForm: Add $EnableEditAutoText and features from Cookbook:EditHelp. %0a* Add $PmTOC, [@(:toc:)@], [@(:notoc:)@], based on a simplified variant of Cookbook:AutoTOC.%0a* Fix bug with pagelist while preview, reported by Finar.%0a* Add $EnableSortable, basic sortable tables based on public domain code from [[https://github.com/tofsjonas/sortable|Jonas Earendel]].%0a* Add $EnableRCDiffBytes based on Cookbook:DeltaBytesRecentChanges. %0a* Add $EnableSimpleTableRowspan replicating features of Cookbook:RowspanInSimpleTables.%0a* Add $WikiPageCSSFmt enables CSS in a wiki page, based on Cookbook:LocalCSS.%0a* Add $EnableHighlight code highlight feature compatible with "highlight.js".%0a* Attachlist @@ext=@@ and @@names=@@ arguments now accept patterns and negatives like @@ext=jpg,png@@, @@ext=-pdf@@, or @@names=-th*---*.jpg@@.%0a* Attachlist: allow both ext= and names= to cohabitate.%0a* MarkupExpr: remove unused declaration.%0a* EditAutoText: use event.ctrlKey and event.shiftKey instead of 2 functions.%0a* Redirect: add 3rd argument $redirecturl which can be provided directly%0a* Add $AddLinkCSS['othergroup'] and $AddLinkCSS['samedomain'] can contain link CSS classes.%0a* Update documentation.%0a%0a!!! Version 2.2.118 (2019-08-28) [[#v22118]]%0a* Add $EnablePreviewChanges and PreviewDiff() based on Cookbook:PreviewChanges.%0a* Update documentation.%0a%0a!!! Version 2.2.117 (2019-07-28) [[#v22117]]%0a* Add $EnableUploadAuthorRequired default to $EnablePostAuthorRequired, add Author field in upload form.%0a* Implement partial content indirect downloads (suggested by Christopher Cox, required for embedded video on iOS).%0a* Add allowed upload video extensions 'm4v' and '3gp'.%0a* Fix lowercase "Content-Disposition" header for downloads.%0a* Update documentation.%0a%0a!!! Version 2.2.116 (2019-06-19) [[#v22116]]%0a* Add $PageListVarFoldFn, defaults to $StrFoldFunction, for international case-insensitive matches of page (text) variables.%0a* Update documentation.%0a%0a!!! Version 2.2.115 (2019-05-13) [[#v22115]]%0a* Responsive skin: Simplify CSS for custom backgrounds, remove repetition.%0a* Update documentation.%0a%0a!!! Version 2.2.114 (2019-04-02) [[#v22114]]%0a* Fix bug with input select lists where an already defined id= attribute may get overwritten.%0a* Vardoc: Move the id= attribute from a standalone anchor to the definition term element (allows ":target" styling).%0a* Vardoc: Localize table header and link text (suggested by Michael F. Wolff).%0a* Add $SkinTemplateIncludeLevel, IncludeTemplate skin directive.%0a* Add input "tel" type, and attribute "pattern". Fix classnames of new input types.%0a* Update documentation.%0a%0a!!! Version 2.2.113 (2019-03-01) [[#v22113]]%0a* Add input button element.%0a* Add $EnableInputDataAttr.%0a* Update documentation.%0a%0a!!! Version 2.2.112 (2019-01-09) [[#v22112]]%0a* Fix switch break for PHP 7.3, reported by Hans-Jürgen Godau.%0a* Update documentation.%0a%0a!!! Version 2.2.111 (2018-12-08) [[#v22111]]%0a* Add @@$[==]Id$@@ subversion keyword to pmwiki.php, requested by Peter Gragert.%0a* Fix responsive skin search form max-width in desktop mode, reported by Moni Kellermann. %0a* Add $DenyHtaccessContent variable. Update protective .htaccess files.%0a* Add tz= and locale= arguments to [@{(ftime )}@] [[MarkupExpression(s)]] (PHP5+).%0a* Update documentation.%0a%0a!!! Version 2.2.110 (2018-11-05) [[#v22110]]%0a* Fix [@{(substr )}@] markup expression with non-number arguments could cause warnings, reported by Simon.%0a* Add $PageListSortCmpFunction, default to current 'strcasecmp'.%0a* Add global $MarkupMarkupLevel which changes when the processing is inside [@(:markup:)@] blocks.%0a* Fix inconsistent white space with inline @@[=[@escaped code@]=]@@, reported by Dannybpng.%0a* Update documentation.%0a%0a!!! Version 2.2.109 (2018-07-09) [[#v22109]]%0a* Update pmcrypt() to exclude negative -@groups from hash checking.%0a* Add $EnableMarkupDiag to backtrace all markup calls, suggested by ChuckG.%0a* Fix Path InterMap broken in 2.2.108, reported by ChuckG.%0a* Update documentation.%0a%0a!!! Version 2.2.108 (2018-07-05) [[#v22108]]%0a* Add $PCCFOverrideFunction.%0a* $AuthUserPageFmt can now be an array of page names.%0a* Add $PageCacheFileFmt default to "%25s/%25s,cache" (like before), allowing custom cache filenames.%0a* Form checkbox labels now have the same tooltip title as the checkbox.%0a* Add [@%25reversed%25@] WikiStyle.%0a* RefCount: add label to checkbox, class to table.%0a* Vardoc: fix markup call, reported by Hans-Jürgen Godau.%0a* pmcrypt() return false when salt appears to be some old PmWiki attribute.%0a* Default InterMap PmWiki URLs have now the HTTPS protocol (suggested by Simon).%0a* Update documentation.%0a%0a!!! Version 2.2.107 (2018-02-02) [[#v22107]]%0a* Fix Forms and Pagelists warnings in PHP 7.2, reported by DFaure.%0a** Fix order=title broken with the previous commit, reported by ChuckG.%0a* Add $MailFunction.%0a* Add ".rtl *" styles.%0a* Update documentation.%0a%0a!!! Version 2.2.106 (2017-12-01) [[#v22106]]%0a* Add pmsetcookie(), $EnableCookieSecure, $EnableCookieHTTPOnly (PITS:01425).%0a* Refactor PageListSort() to make it work for PHP 7.2 without requiring create_function().%0a** Fix ordering broken with the previous commit, reported by ChuckG.%0a* Fix `wikiword markup, reported by Steve Glover.%0a* Update documentation.%0a%0a!!! Version 2.2.105 (2017-11-07) [[#v22105]]%0a* Refactor @@HandleUpload()@@ - add @@UploadSetVars($pagename)@@ to allow custom upload add-ons to set variables.%0a* Fix bug with PQA() that caused invalid HTML with attributes glued together.%0a%0a!!! Version 2.2.104 (2017-10-11) [[#v22104]]%0a* Fix bug with WikiTrails introduced with 2.2.103 (PITS:01422).%0a%0a!!! Version 2.2.103 (2017-10-01) [[#v22103]]%0a* Add pagelist list=grouphomes and fmt=#grouphomes.%0a* Update all scripts for PHP 7.2 (bugtrack).%0a* Make responsive skin also compatible with PmWiki versions 2.2.55 or earlier.%0a* Add *.vtt (web subtitles) as allowed upload extension.%0a* Fix Charset headers for xlpage-iso-*.php%0a* Refactor PageStore class to remove create_function() calls.%0a* Add "title" attribute to input form elements.%0a* Re-add the definition of the $rrep variable in Markup expressions, reported by ChuckG.%0a* Add $AuthLDAPReferrals to set LDAP_OPT_REFERRALS if needed, reported by Kirk Zurell.%0a* Fix missing $pagename for WikiWord links.%0a* Update documentation.%0a%0a%0a!!! Version 2.2.102 (2017-08-05) [[#v22102]]%0a* Revert fix for PITS:01300, the markup engine breaks when a text variable content is longer than 2699 characters.%0a* Add a text box in [[SiteAdmin.AuthList]] to allow filtering of the results.%0a%0a!!! Version 2.2.101 (2017-07-30) [[#v22101]]%0a* Rename function PageStore to __construct, to prevent PHP 7 strict or deprecated notices.%0a%0a!!! Version 2.2.100 (2017-07-30) [[#v22100]]%0a* Workaround around Subversion incompatibility with @@$Author[==]:...$@@ string not intended as SVN keyword.%0a* Responsive skin: add spacing above the #wikitext block, similar to the default skin.%0a* Update documentation.%0a%0a!!! Version 2.2.99 (2017-06-26) [[#v2299]]%0a* Fix Preview didn't show changes due to $ROSPatterns (PITS:01408).%0a* Remove markup rules for previewing author signature not needed anymore.%0a* Fix bug and warning appearing in PHP 4 installations.%0a* Update Wikipedia intermap entry (secure https).%0a* Fix bug with [@[[%3c%3c]]@] styles "clear:both".%0a* {-Fix incomplete definition of page text variable halts the rendering (PITS:01300).-}%0a* Fix $Version didn't work as a vardoc link.%0a* Update documentation.%0a%0a!!! Version 2.2.98 (2017-05-31) [[#v2298]]%0a* Fix WikiStyles where "pct" was incorrectly dropped from some classnames (PITS:01404).%0a* Hide warning about missing intermap file.%0a* Add pmwiki-responsive skin, based on modified Skins:2016.%0a* Responsive skin: Hide icon if PageActions empty. Fix "close" icon didn't appear for the PageActions block. Unrestrict menu height. Switching from portrait view with menu open to landscape: page should not be greyed out (PITS:01406). Landscape view: fix overflow for search form in Epiphany (likely Safari and other AppleWebKit-based browsers). Move the %3cmain> tag up to allow scrolling of the whole #wikibody. Large preformatted blocks will also scroll in the mobile view. Set limit for desktop layout to 50em~800px. Scrollable tables via cosmetic JavaScript.%0a* Both skins: Set default text color (PITS:01406).%0a* Fix Deprecated notice for Site.AuthUser password attributes.%0a* Vardoc links now use MakeLink() to allow a custom LinkPage function, fix bug reported by ChuckG.%0a* $InclCount now counts per browsed page (for multi-page processing recipes).%0a* Make $markupid variable available to markup replacement functions.%0a* Refactor function ReplaceOnSave to allow easier calling from recipes (PITS:01407).%0a* Enable *.mkv as allowed video extension.%0a* Fix bug with attachlist markup.%0a* Fix alternative bold/italics markup in sample-config.php (PITS:01400).%0a* Fix lost space in markup tables, replace markup tables %3ccode> with %3cpre> and add style "pre-wrap" (reported by ChuckG).%0a* Update documentation.%0a%0a!!! Version 2.2.97 (2017-04-07) [[#v2297]]%0a* Fix bug concerning $ScriptUrl when $EnablePathInfo is set, introduced in 2.2.96, reported by 3 users.%0a* Update documentation.%0a%0a!!! Version 2.2.96 (2017-04-05) [[#v2296]]%0a* Fix severe PHP code injection vulnerability, reported by Gabriel Margiani.%0a** Filter $pagename to exclude certain characters.%0a** Add $pagename_unfiltered in case a recipe requires it.%0a* Update documentation.%0a%0a!!! Version 2.2.95 (2017-02-28) [[#v2295]]%0a* Update documentation.%0a%0a!!! Version 2.2.94 (2017-01-31) [[#v2294]]%0a* Strip both .html and .htm extensions (Cookbook:HtmlUrls-Talk).%0a* Clear $PageExistsCache[$pagename] when a page is created or deleted (PITS:01401).%0a* Update documentation.%0a%0a!!! Version 2.2.93 (2016-12-31) [[#v2293]]%0a* Update documentation.%0a%0a!!! Version 2.2.92 (2016-11-30) [[#v2292]]%0a* Skip checking for $AllowPassword if empty or false.%0a* Enable FmtPageName() to expand PageVariables with asterisks.%0a* Update documentation.%0a%0a!!! Version 2.2.91 (2016-09-30) [[#v2291]]%0a* Update documentation.%0a%0a!!! Version 2.2.90 (2016-08-31) [[#v2290]]%0a* Add action parameter to upload form URL.%0a* Add @@imgonly@@ and @@imgcaption@@ CSS classes (PITS:01390).%0a* Fix plus-links with suffix [@[[Page|+]]s@] (PITS:01392).%0a* Update documentation.%0a%0a!!! Version 2.2.89 (2016-07-30) [[#v2289]]%0a* Add identifiers to Site.EditForm elements to enable easier styling.%0a* Add $SimpleTableDefaultClassName, default unset (PITS:00638).%0a* Add temporary $new['=html'] entry, in SaveAttributes().%0a* Fix superfluous line breaks in SiteAdmin.AuthList.%0a* Add optional placeholder attribute in [@(:searchbox:)@].%0a* Add $SearchBoxInputType, default 'text'.%0a* Set $HTMLStylesFmt via SDVA() in vardoc.php, urlapprove.php, and xlpage-utf-8.php.%0a* Fix vardoc.php to recognize and link variables $pagename, $Author, $Skin, and to sort case insensitively.%0a* Update documentation.%0a%0a!!! Version 2.2.88 (2016-06-29) [[#v2288]]%0a* Fix invalid HTML output of WikiTrail links (PITS:01388).%0a* Add 4th argument $double_encode to PHSC() for safe replacement of htmlspecialchars().%0a* Add page variable [@{$SiteAdminGroup}@] (PITS:00951).%0a* Update documentation.%0a%0a!!! Version 2.2.87 (2016-05-31) [[#v2287]]%0a* Add $HTMLTagAttr, to allow inclusion of lang, manifest and other attributes.%0a* Add $EnableRevUserAgent, $FmtV['$DiffUserAgent'].%0a* Fix relative link in [[Site.UploadQuickReference]].%0a* Update documentation.%0a%0a!!! Version 2.2.86 (2016-04-28) [[#v2286]]%0a* Fix PageStore() for PHP 7.%0a* Fix $DefaultPasswords for PHP 7.%0a* Update documentation.%0a%0a!!! Version 2.2.85 (2016-03-31) [[#v2285]]%0a* Add svg(z) and SVG(Z) as embeddable image extensions (PITS:00197, PITS:00435).%0a* Add *.svgz as allowed upload extension.%0a* Update documentation.%0a%0a!!! Version 2.2.84 (2016-02-21) [[#v2284]]%0a* Update/fix URL in UPGRADES.txt (PITS:01378).%0a* Fix indent and outdent CSS for RTL languages (PITS:01379).%0a* Add $EnableLinkPlusTitlespaced (PITS:01140).%0a* Update documentation.%0a%0a!!! Version 2.2.83 (2015-12-31) [[#v2283]]%0a* Update documentation.%0a%0a!!! Version 2.2.82 (2015-11-30) [[#v2282]]%0a* Enable stripmagic() to process arrays recursively.%0a* Update documentation.%0a%0a!!! Version 2.2.81 (2015-10-31) [[#v2281]]%0a* Fix single line PageTextVariable definition (reported by HansB).%0a* Add .ltr and .rtl CSS classes for UTF-8.%0a* Update documentation.%0a%0a!!! Version 2.2.80 (2015-09-30) [[#v2280]]%0a* Modify [@(:searchbox:)@] to use type="search" input.%0a* Update documentation.%0a%0a!!! Version 2.2.79 (2015-08-27) [[#v2279]]%0a* Modify guiedit.js::insMarkup() to accept a custom function name processing the text, and a custom id for the text area.%0a* Add CSS basic colors 'fuchsia','olive','lime','teal','aqua','orange' and 'grey' as WikiStyles (PITS:01373).%0a* Add $EnableROSEscape, default 0 (PmWiki:TextFormattingRules-Talk).%0a* Remove 'target' attribute in input forms (breaks PmForm).%0a* Add HTML5 input types email, url, number, date, search.%0a* Add attribution in script comments.%0a* Update documentation.%0a%0a!!! Version 2.2.78 (2015-07-21) [[#v2278]]%0a* Update $RobotPattern with current user agents.%0a* Accept 'target' attribute in input forms.%0a* Update documentation.%0a%0a!!! Version 2.2.77 (2015-06-19) [[#v2277]]%0a* Add generic function MakeNames() to process MakePageNames().%0a* Extend [@(:if attachments:)@] to specify file and page names (PITS:01087).%0a* Optimize PageStore::recode() to cache utf8_decode and utf8_encode callbacks.%0a* Add [@{$WikiTitle}@] page variable.%0a* Update documentation.%0a%0a!!! Version 2.2.76 (2015-05-31) [[#v2276]]%0a* Recover posted arrays (indexed or associative, not multidimensional) when a password is required (PITS:00835, PITS:01110).%0a* Add label argument to checkbox and radio inputs (PITS:01367).%0a* Enable PHSC() to process arrays recursively.%0a* Enable processing of arrays as input values (PITS:01032).%0a* Add CSS classes to standalone image div and caption (PITS:00489, PITS:00497).%0a* Update documentation.%0a%0a!!! Version 2.2.75 (2015-04-26) [[#v2275]]%0a* Fix uploads to respect $EnableReadOnly.%0a* Escape HTML special characters when printing failed callback creation.%0a* Add [[Functions#pmcrypt | pmcrypt()]] for PHP 5.6 compatibility.%0a* Add markup for HTML5 [[PmWiki:BlockMarkup#semantic | semantic ]] tags article, section, nav, header, footer, aside, address.%0a* Update documentation.%0a%0a%0a!!! Version 2.2.74 (2015-03-28) [[#v2274]]%0a* Allow translation of the "OK" string in forms (PITS:01363).%0a* Update documentation.%0a%0a!!! Version 2.2.73 (2015-02-28) [[#v2273]]%0a* Update documentation.%0a%0a!!! Version 2.2.72 (2015-01-27) [[#v2272]]%0a* Enable markup debug messages even when debug_backtrace() is not available.%0a* Add $AbortFunction.%0a* Restore ability to set a custom $MarkupWordwrapFunction, add $MarkupWrapTag (related to earlier fix for PITS:01360).%0a* Update documentation.%0a%0a!!! Version 2.2.71 (2014-12-29) [[#v2271]]%0a* Add $DraftActionsPattern.%0a* Enable "input default source" parameter to contain multiple pages.%0a* Enable "pagelist request" parameter to contain a list of (dis)allowed parameters.%0a* Enable Markup() backtrace for ?action=ruleset.%0a* Fix strict warning for blacklisted uploads (PITS:01359).%0a* Fix wrong hard wrap in [@(:markup:)@] code examples (PITS:01360).%0a* Update documentation.%0a%0a!!! Version 2.2.70 (2014-11-08) [[#v2270]]%0a* Update documentation.%0a%0a!!! Version 2.2.69 (2014-10-13) [[#v2269]]%0a* Fix DRange() for ISO-8601 dates +/- X days.%0a* Fix wording in [[Site.UploadQuickReference]].%0a* Update documentation.%0a%0a!!! Version 2.2.68 (2014-09-01) [[#v2268]]%0a* Add Skins: InterMap prefix.%0a* Add signature to [[Site.EditQuickReference]] (PITS:01350).%0a* Allow $PostConfig entries to be launched after per-page customization, before other stdconfig.php inclusions if values%3c50.%0a* Add [[WikiStyles]] clear, min and max width and height (PITS:00860), fix [=%25p class=...%25=] with more than one space.%0a* Update documentation.%0a%0a!!! Version 2.2.67 (2014-08-02) [[#v2267]]%0a* Fix InputDefault/PageTextVariables inconsistency (PITS:01337).%0a* Update documentation.%0a%0a!!! Version 2.2.66 (2014-07-02) [[#v2266]]%0a* Fix Author in Notifcations when deleting pages (PITS:01112).%0a* Exclude "_" to be considered as a function name in various $*Patterns.%0a* Update documentation.%0a%0a!!! [[#v2265]] Version 2.2.65 (2014-06-07)%0a* Fix [={$$PseudoVars}=] containing [={*$PageVars}=] in [[PageList Templates]].%0a* Fix wording in scripts/.htaccess (PITS:01345).%0a* Fix fixperms() if directory owner is root (PITS:01346).%0a* Update documentation.%0a%0a!!! [[#v2264]] Version 2.2.64 (2014-05-08)%0a* Add [={(mod)}=] [[PmWiki/MarkupExpressions | markup expression]].%0a* Add tel: and geo: [[PmWiki/LinkSchemes | URI schemes]].%0a* Add $SysMergePassthru to allow Merge() to use passthru() instead of popen().%0a* Update documentation.%0a%0a!!! [[#v2263]] Version 2.2.63 (2014-04-05)%0a* Allow [[PmWiki/Forms | form]] elements to have a dash in the attribute names.%0a* Strip magic slashes for pagelist/search request vars.%0a* Allow input attributes readonly, placeholder and autocomplete for HTML5 sites.%0a* Update documentation.%0a%0a!!! [[#v2262]] Version 2.2.62 (2014-02-28)%0a* Add $CallbackFnTemplates["return"].%0a* Add 4th argument to Markup_e() - $template.%0a* Add $EnableTableAutoValignTop.%0a* Update documentation.%0a%0a!!! [[#v2261]] Version 2.2.61 (2014-01-31)%0a* Add $TableCellAlignFmt.%0a* Remove unused snippet in prefs.php (reported by Oliver Betz).%0a* Remove unused calls to PSS() (reported by John Rankin).%0a* Update documentation.%0a%0a!!! [[#v2260]] Version 2.2.60 (2014-01-12)%0a* Revert to previous pmwiki.css file.%0a%0a!!! [[#v2259]] Version 2.2.59 (2014-01-11)%0a* Fix checking multiple posted fields in blocklist.php (reported by Randy Brown).%0a* Allow Markup_e() to accept a callback as well as code.%0a* Fix "+" shortcut for internal anchor links.%0a* Disable HTML cache if count($_GET)>1 not >2 (PITS:01278).%0a* Fix query string if a "?" is encoded to uppercase "%253F".%0a* Replace CSS font sizes from points (fixed) to percents (relative) for the default skin.%0a* Fix nested conditionals containing $pagename (reported by Benjamin Grassineau).%0a* Update documentation.%0a%0a!!! [[#v2258]] Version 2.2.58 (2013-12-25)%0a* Allow $LinkUpload to be usable in [=(:attachlist:)=].%0a* Enable customizations of [=(:input auth_form:)=].%0a* Remove unused variable $Block in FormatTableRow(), reported by Klonk.%0a* Fix $EnableBlocklistImmediate to check all posted fields for blocked terms.%0a* Add $GLOBALS['MarkupToHTML'] to pass parameters such as $pagename to markup calls.%0a* Update documentation.%0a%0a!!! [[#v2257]] Version 2.2.57 (2013-11-03)%0a* Encode international character used for detection of a recode function.%0a* Enable $IMapLinkFmt['Attach:'] to be used in [[PmWiki/PageDirectives#attachlist|[=(:attachlist:)=]]] links.%0a* Add $MakePageNameSplitPattern.%0a* Update documentation.%0a%0a!!! [[#v2256]] Version 2.2.56 (2013-09-30)%0a* Work in progress to remove the core dependency of the deprecated "eval" feature of the preg_replace() function (PITS:01319).%0a* Add functions PCCF(), PPRE(), PPRA(), Markup_e(), migrating all core calls to these functions.%0a* Fix detection of proper PageStore->recodefn.%0a* Update documentation.%0a%0a%0a!!! [[#v2255]] Version 2.2.55 (2013-09-16)%0a* Add $EnableDraftAtomicDiff (PITS:01007).%0a* Update documentation.%0a%0a!!! [[#v2254]] Version 2.2.54 (2013-08-13)%0a* Fix broken page history for draft pages, reported by ChuckG.%0a* Update documentation.%0a%0a!!! [[#v2253]] Version 2.2.53 (2013-07-08)%0a* Show a message when the post has been blocked because of too many unapproved links.%0a* Update documentation.%0a%0a!!! [[#v2252]] Version 2.2.52 (2013-06-08)%0a* Add docx, pptx, xlsx upload extentions.%0a* Hide E_DEPRECATED warnings for PHP 5.5.%0a* Update documentation.%0a%0a!!! [[#v2251]] Version 2.2.51 (2013-05-08)%0a* Update url to MoinMoin's blocklist.%0a* Comment-out blacklist.chongqed.org as the domain appears to have expired.%0a* Fix possible XSS vulnerability in prefs.php, discovered today.%0a* Fix access keys to be a single character.%0a* Fix $AuthorPage if there is a group named the same as the author (PITS:01259).%0a* Update documentation.%0a%0a!!! [[#v2250]] Version 2.2.50 (2013-04-08)%0a* Update documentation.%0a%0a!!! [[#v2249]] Version 2.2.49 (2013-03-09)%0a* Add $UploadBlacklist array.%0a* Update documentation.%0a%0a!!! [[#v2248]] Version 2.2.48 (2013-02-11)%0a* Fix bug introduced yesterday with some links, reported by Michael Weiner (PITS:01308).%0a%0a!!! [[#v2247]] Version 2.2.47 (2013-02-10)%0a* Enable tooltip titles for links to anchors on the same page.%0a* Update documentation.%0a%0a!!! [[#v2246]] Version 2.2.46 (2013-01-07)%0a* Add third parameter to fixperms() explicitly setting the permissions.%0a* Add $UploadPermAdd and $UploadPermSet variables.%0a* Update documentation.%0a%0a!!! [[#v2245]] Version 2.2.45 (2012-12-02)%0a* Cleanup some PHP notices (PITS:01304).%0a* Update documentation.%0a%0a!!! [[#v2244]] Version 2.2.44 (2012-10-21)%0a* Better display of whitespace in page histories.%0a* Fix definition for PageTextVariables containing a dash (PITS:00978).%0a* Update documentation.%0a%0a!!! [[#v2243]] Version 2.2.43 (2012-09-20)%0a* Allow for HTML attribute names to contain dashes, eg. data-transition, data-role etc.%0a* Remove warning when previewing Site.EditForm.%0a* Update documentation.%0a%0a!!! [[#v2242]] Version 2.2.42 (2012-08-20)%0a* Convert the line-endings in the docs/ directory to \r\n compatible with Windows.%0a* Modify PHSC() to call htmlspecialchars() with a single-byte encoding argument.%0a* Update documentation.%0a%0a!!! [[#v2241]] Version 2.2.41 (2012-08-12)%0a* Change $KeepToken to "\034\034" which is compatible with more encodings.%0a* Update documentation.%0a%0a!!! [[#v2240]] Version 2.2.40 (2012-07-21)%0a* Add PHSC() helper function as a replacement of htmlspecialchars() for PHP 5.4 (PITS:01292).%0a* Update documentation.%0a%0a!!! [[#v2239]] Version 2.2.39 (2012-06-25)%0a* Fix URL encoding of attachment links.%0a* Update documentation.%0a%0a!!! [[#v2238]] Version 2.2.38 (2012-05-21)%0a* Fix "Wrong parameter count for utf8_decode" warning, reported by Simon.%0a* Update documentation.%0a%0a!!! [[#v2237]] Version 2.2.37 (2012-05-01)%0a* Add page filename encoding functions.%0a* Better handling of dots in [@[[#anchor_1.2]]@] sections (PITS:01285).%0a* Expand PageVariables in [[PageList templates]] defaults (PITS:01282).%0a* Add test for iconv() and mb_convert_encoding(), refactor recode().%0a* Update documentation.%0a%0a!!! [[#v2236]] Version 2.2.36 (2011-12-28)%0a* Add $EnableOldCharset variable and $page["=oldcharset"] entry.%0a* Refactor PageStore->recode() to recover Windows-1252 characters.%0a* Add exit line to xlpage-iso-8859-2.php (PITS:01275).%0a* Fix difference in defining and removing "invisible" PTVs.%0a* Update documentation.%0a%0a!!! [[#v2235]] Version 2.2.35 (2011-11-11)%0a* Fix critical PHP injection vulnerability (PITS:01271, reported by Egidio Romano).%0a* Important change: Disable script loading from XLPage().%0a* Move the processing of [@[[link|+]]@] inside LinkPage() and delete markup rule from stdmarkup.php.%0a* Modify MakeLink() to better handle link titles.%0a* Add optional $LinkTitleFunction allowing recipes to customize the link titles.%0a* Fix ReadTrail() to better handle links with titles.%0a* Add title attributes for the HTML templates in the @@ $LinkPage*Fmt @@ variables.%0a* Add upload extensions svg, xcf, ogg, flac, ogv, mp4, webm, odg, epub.%0a* Minor optimization for the MarkupExpressions for UTF-8 strings.%0a* Minor optimization of the rendering of page history.%0a%0a!!! [[#v2234]] Version 2.2.34 (2011-10-10)%0a* Add [[PmWiki/MarkupExpressions]] replacements for UTF-8.%0a* Reset timestamps of Site(Admin).AuthUser to 1000000000, used in upgrades.php.%0a* Update documentation.%0a%0a!!! [[#v2233]] Version 2.2.33 (2011-09-23)%0a* Fix locked states for Site and SiteAdmin GroupAttributes (reported by Brijesh Kothari).%0a* Fix intermap.txt entries PITS: and Wikipedia: to point to their current locations.%0a* Fix refcount.php to produce valid HTML (PITS:01266).%0a%0a!!! [[#v2232]] Version 2.2.32 (2011-09-18)%0a* Add required html xmlns attribute to the print skin template.%0a* Add PageStore->recode() function.%0a* Add $DefaultPageCharset array.%0a* Optimize for speed the inline diff for page history when too many lines were added or deleted.%0a* Update and convert to UTF-8 the documentation.%0a%0a%25note%25 Note: Due to a manipulation error, a version 2.2.31 was created before it was ready for a release.%0a%0a!!! [[#v2230]] Version 2.2.30 (2011-08-13)%0a* Fix $Charset definition in iso-8859-*.php files.%0a* Add $EnableRangeMatchUTF8, set it to 1 to enable range matches in UTF-8.%0a* Update documentation.%0a%0a!!! [[#v2229]] Version 2.2.29 (2011-07-24)%0a* Fix Attach links that were broken with the Path fix in 2.2.28.%0a* Add $IMapLocalPath array containing InterMap prefixes that should be treated as local.%0a%0a!!! [[#v2228]] Version 2.2.28 (2011-07-24)%0a* Fix potential XSS vulnerability in refcount.php (PITS:01262).%0a* Fix bug in Path: links (PITS:01260).%0a* Fix potential XSS vulnerability in custom SitePreferences (PITS:01263).%0a* Update documentation.%0a%0a!!! [[#v2227]] Version 2.2.27 (2011-06-19)%0a* Add block WikiStyle [=%25justify%25=] (PITS:01253).%0a* Remove unused %3cvspace> after a redirection (PITS:01255).%0a* Add ?nodiff=1 parameter for page history to disable diff rendering and show only restore links.%0a* Update documentation.%0a%0a!!! [[#v2226]] Version 2.2.26 (2011-05-21)%0a* Fix ReadTrail(), redundant replacing of hashes, already done in MakePageName().%0a* Update documentation.%0a%0a!!! [[#v2225]] Version 2.2.25 (2011-03-22)%0a* Update documentation.%0a%0a!!! [[#v2224]] Version 2.2.24 (2011-02-15)%0a* Add [@{$$PageTrailDepth}@] pseudovariable for [[PageList templates]].%0a* Fix PageVar(), add $authpage array for an authenticated page data, removed $EnablePageVarAuth.%0a* Update documentation.%0a%0a!!! [[#v2223]] Version 2.2.23 (2011-01-25)%0a* Default $EnablePageVarAuth to 0 until the resolution of PITS:01242.%0a%0a!!! [[#v2222]] Version 2.2.22 (2011-01-16)%0a* Add $EnableXLPageScriptLoad to XLPage() to prevent editors from changing the encoding.%0a* PageVariables now respect authentications (PITS:01213).%0a* Add $EnablePageVarAuth.%0a* Update documentation.%0a%0a!!! [[#v2221]] Version 2.2.21 (2010-12-14)%0a* Fix potential XSS vulnerability, reported by DFaure.%0a* Fix invalid HTML for simple table captions, reported by JL.%0a* Fix WikiStyles could work not properly if a value was empty like accesskey="".%0a%0a!!! [[#v2220]] Version 2.2.20 (2010-12-14)%0a* Fix Pagelist [={$$variable}=] didn't work in template none (PITS:01212).%0a* Fix interface access keys in browse mode (PITS:01188).%0a* Add PmL10n: intermap prefix for the Localization/ group on pmwiki.org (PITS:01180).%0a* Fix AuthUser excluding members didn't work (PITS:01201).%0a* Update documentation.%0a%0a!!! [[#v2219]] Version 2.2.19 (2010-11-10)%0a* Update documentation.%0a%0a!!! [[#v2218]] Version 2.2.18 (2010-09-04)%0a* Fix $SaveAttrPatterns to skip nested conditionals (reported by RandyB).%0a* Fix RecentChanges when an edit summary contains the dollar sign (PITS:01217).%0a* Fix RDF feed number of elements (PITS:01198).%0a* Update documentation.%0a%0a!!! [[#v2217]] Version 2.2.17 (2010-06-20)%0a* Add tabindex as a valid form attribute (PITS:01190).%0a* Collapse adjacent insertions in DiffRenderSource (PITS:01192).%0a* Fix HandleDownload to flush() output before exit (PITS:01199).%0a* Fix HandleDownload to respect $EnableIMSCaching (PITS:01191).%0a* Add $PostConfig functions and scripts, loaded after stdconfig.php (PITS:01132).%0a* Add $AuthUserPat variable for the regexp pattern in AuthUserId() (PITS:01202).%0a* Pass $authlist as last parameter to $AuthUserFunctions (PITS:01197).%0a* Fix "exists" conditional to work with old link markup.%0a* Update documentation.%0a%0a!!! [[#v2216]] Version 2.2.16 (2010-05-10)%0a* Allow "exists" conditional to accept wildcards (PITS:01184)%0a* Fix GUI button [=%25center%25=] which didn't work correctly.%0a* Fix incorrectly parsed quote in PQA(), possible script injection (discovered by Hanno Boeck).%0a%0a!!! [[#v2215]] Version 2.2.15 (2010-03-27)%0a* Add @@ (Auth|Edit)Form @@ to auto-translated titles.%0a* Fix [@ (:if auth LEVEL:) @] to respect $HandleAuth (PITS:01164).%0a* Skip loading of the second half of draft.php if $action!="edit".%0a* Fix bug with [@ (:template none:) @] introduced in 2.2.14, reported by Holger.%0a* Fix HandleDownload() to use binary file-read.%0a%0a!!! [[#v2214]] Version 2.2.14 (2010-02-27)%0a* Fix inline styles in WikiTrails (PITS:01121).%0a* Add a negation parameter to pagelist first/last templates (PITS:01127).%0a* Refactor FPLTemplateFormat(), move repeated code blocks into FPLExpandItemVars().%0a* Add $EnableUndefinedTemplateVars allowing to hide or show undefined template/include [={$$variables}=] (PITS:01152).%0a* Add "title" attribute to external links (PITS:00657).%0a* Add FmtPageTitle() to allow automatic i18n titles for RecentChanges and other technical pages (PITS:01157).%0a* Update documentation.%0a%0a!!! [[#v2213]] Version 2.2.13 (2010-02-21)%0a* Replace deprecated in PHP 5.3 function split() with explode().%0a* Add $WordDiffFunction default to PHPDiff().%0a* Use existing border colors as highlighting background.%0a* Refactor/optimize DiffRenderSource(), merge with DiffRenderInline().%0a* Change default history to show word-level highlighting.%0a* Fix bug with $DiffKeepNum which kept less revisions than it should.%0a* Fix RetrieveAuthPage() call from HandleDiff().%0a* Update documentation.%0a%0a!!! [[#v2212]] Version 2.2.12 (2010-02-17)%0a* Allow a custom $DiffHTMLFunction to skip the line rendering if it returns false.%0a* Add $EnableDiffInline, simple word-level diffs (PITS:00571).%0a* Update documentation.%0a%0a!!! [[#v2211]] Version 2.2.11 (2010-02-14)%0a* Break PrintDiff() into customizable functions (PITS:01106).%0a* Add anchors to individual diffs (PITS:00796).%0a* Remove unused $RecipeInfo definition in markupexpr.php (reported by P.Bowers).%0a* Add [=(:head:) and (:headnr:)=] table directives (PITS:00535).%0a* Fix $GroupPattern and $NamePattern in xlpage-utf-8.php.%0a* Update documentation.%0a%0a!!! [[#v229]] [[#v2210]] Version 2.2.9, 2.2.10 (2010-01-17)%0a* Fix i18n string in PasswdVar(), reported by SteP.%0a* Fix sample-config.php with correct information about $EnableWSPre (PITS:01145).%0a* Fix range searches for wikis in UTF-8 (reported by Maxim).%0a* Fix global variable $StringFolding in scripts/xlpage-utf-8.php.%0a* Fix markup for italics in creole.php.%0a* Fix previews for PTVs, [[PageList templates]] and included sections (PITS:01098).%0a* Add $DiffKeepNum - number of revisions kept, even if older than $DiffKeepDays.%0a* Add Yandex to robots.php.%0a* Change default $EnableRelativePageVars to 1 (PITS:01145).%0a* Add fifth parameter to SetProperty() : keep existing property.%0a* Add $EnablePageTitlePriority (PITS:00266, PITS:00779).%0a* Update documentation.%0a%0a!!! [[#v228]] Version 2.2.8 (2009-12-07)%0a* Fix apostrophes in Author field (PITS:01155).%0a* Fix Condition "exists" for PHP 5.3 (PITS:01156).%0a* Update documentation.%0a%0a!!! [[#v227]] Version 2.2.7 (2009-11-08)%0a* Fix GlobToPCRE() to work with !excl and -excl with PHP 5.3 (PITS:01149).%0a* Fix HandleDownload() correctly quote the filenames (PITS:01150).%0a* Fix SessionAuth() for PHP 5.3, the $_REQUEST array doesn't contain the $_COOKIE array (PITS:01141).%0a* Fix default timezone for PHP 5.3 (PITS:01141).%0a* Update documentation.%0a%0a!!! [[#v226]] Version 2.2.6 (2009-10-04)%0a* Escape apostrophes for multiline textarea/hidden form fields.%0a* Fix global unset of $MarkupRules in [[PmWiki/CustomMarkup|Markup()]] and DisableMarkup(), reported by D.Faure.%0a* Fix call to BuildMarkupRules() in MarkupToHTML(), suggested by Pm.%0a* Allow disabling of $PageListFilters and $FPLTemplateFunctions if set to -1 and thus allow replacing a core function with a custom one.%0a* Fix DRange() returned timestamps +1min or +1day when it shouldn't (PITS:01125).%0a* Add $MarkupWordwrapFunction to allow custom [@(:markup:)@] line width for multibyte wikis (PITS:00703).%0a* Add $MakeUploadNamePatterns to allow custom filename normalization for uploads.%0a* Add a fourth argument to PostRecentChanges() to allow this function to be called with a custom $RecentChangesFmt array.%0a* Add $RecentUploadsFmt, to allow logging of new uploads to the RecentChanges pages (PITS:00088).%0a* Fix Notify for some installations in safe_mode (PITS:00976).%0a* Add $HTMLHeaderFmt['guiedit'] variable in guiedit.php to allow customization (PITS:01146).%0a* Update documentation.%0a%0a!!! [[#v225]] Version 2.2.5 (2009-08-25)%0a* Add *.7z as accepted upload extension (PITS:00813).%0a* Fix global variable $HandleAttrFmt in HandleAttr (PITS:01126).%0a* Allow brackets in input element names (PITS:01131).%0a* Fix CSS class applied twice (PITS:01071).%0a* Fix Not-Modified headers could prevent caching (PITS:00802).%0a* Break FPLTemplate() into configurable sub-parts (PITS:01102).%0a* Add [@(:template none:)@] section for [[PageList templates]].%0a* Fix attr-protected page could be deleted with edit permissions (PITS:00238).%0a* Update documentation.%0a%0a!!! [[#v224]] Version 2.2.4 (2009-07-16)%0a* Fix bug with page attributes, which somehow didn't make it in the 2.2.3 release.%0a* Fix bug with HTML entities in XLPages introduced earlier today in 2.2.3 (reverted, PITS:01114).%0a%0a!!! [[#v223]] Version 2.2.3 (2009-07-16)%0a* Fix action=logout could incorrectly set a session cookie (PITS:01062).%0a* Fix page history trim in vardoc.php (PITS:01103).%0a* Add $EnableUploadGroupAuth, use group password for downloads (PITS:01104).%0a* Fix recursive PTV loops, added $MaxPageTextVars (PITS:00915, PITS:01099).%0a* Fix mkdirp() messages for absolute paths (PITS:00396).%0a* Fix sample-config.php order for urlapprove.php (PITS:01037).%0a* Fix broken signature links on preview.%0a* Fix crypt.php (action=crypt) could malfunction for passwords with quotes or apostrophes.%0a* Fix @@ @_site_*@@ passwords to work in GroupAttributes (PITS:00836, PITS:00998).%0a* Fix possible XSS vulnerabilities, reported by Michael Engelke.%0a* Update documentation.%0a%0a!!! [[#v222]] Version 2.2.2 (2009-06-21)%0a* Fix class in pages not on the breadcrumbs trail, reported by Ed W.%0a* Fix @@tabindex@@ and @@onclick@@ to guiedit buttons.%0a* Fix $GroupPrintHeaderFmt in print.php (PITS:01073).%0a* Fix global vars in xlpage-utf-8.php (PITS:00980).%0a* Fix $txt in LinkPage (reported by Eemeli Aro).%0a* Add $EnableNotifySubjectEncode for international wikis (Cookbook:UTF-8).%0a* Fix international message in Abort().%0a* Fix security bug with AuthUser, reported by Eemeli Aro. See [[Release notes]].%0a* Fix $ActionTitleFmt for login and upload, reported by Eemeli Aro.%0a%0a!!! [[#v221]] Version 2.2.1 (2009-03-28)%0a* Fix $FPLTemplateMarkupFunction which somehow didn't get in the 2.2.0 archive.%0a* Fix wikitrails to work cross-group (PITS:00407).%0a* Add $EnableRedirectQuiet variable (PITS:00919).%0a* Fix [={$Title}=] could display global variables (reported by HansB).%0a* Fix reloaded form submissions could lose values (reported by DaveG).%0a* Fix preview while restoring a version from history (PITS:01081).%0a* Fix relative links with international characters (reported by G. Hermanowicz).%0a* Add in sample-config.php example call to xlpage-utf-8.php (PITS:01066).%0a* Update documentation.%0a* Fix guiedit.php to produce valid HTML.%0a%0a!!! [[#v220]] Version 2.2.0 (2009-01-18)%0a* Convert beta series to official release series.%0a* Add $FPLTemplateMarkupFunction (PITS:00984, requested by John Rankin).%0a%0a!!! [[#older]] Older versions%0a[[(PmWiki:)ChangeLog Archive]] - changes prior to version 2.2.0.%0a +time=1676190532 blob - 291ed14749355de4ceff0ed11dc00913fb7337ca blob + 44cc0ab5fdbd44b06b203453386e56d12c2a1fa5 --- wikilib.d/PmWiki.ConditionalMarkup +++ wikilib.d/PmWiki.ConditionalMarkup @@ -1,9 +1,9 @@ -version=pmwiki-2.2.129 ordered=1 urlencoded=1 -author=Siegfried Seibert +version=pmwiki-2.3.16 ordered=1 urlencoded=1 +author=Petko charset=UTF-8 -csum=FILENAMES in attachexists must not have quotation marks (+40) +csum=careful with %25pmhlt%25 for nested lines (-1) (+36) name=PmWiki.ConditionalMarkup -rev=188 -targets=PmWiki.Passwords,PmWiki.Security,PITS.01417,PmWiki.AuthUser,Cookbook.AuthUser,PmWiki.PageTextVariables,PmWiki.WikiTrails,PmWiki.PageVariables,PmWiki.MarkupExpressions,Cookbook.ConditionalMarkupSamples -text=(:Summary:The if directive allows portions of a page to be included or excluded from rendering:)%0a%25define=indent block margin-left=2em%25%0a(:Audience: authors, admins (advanced) :)%0aThe [@(:if:)@] directive allows portions of a page to be included or excluded from rendering. %0a%0a!! Using the [=(:if:)=] Directive%0aThe generic forms of the [@(:if:)@] directive are%0a%0a-> [@(:if cond param:) body (:ifend:)@]%0a-> [@(:if cond param:) body (:else:) body (:ifend:)@]%0a-> [@(:if cond param:) body (:elseif cond param:) body (:ifend:)@]%0a-> [@(:if cond param:) body (:elseif cond param:) body (:else:) body (:ifend:)@]%0a%0awhere "cond" names a condition to be tested, and "param" is a parameter or other argument to the condition.%0a%0a''Note that [@(:if:)@] without parameters and [@(:ifend:)@] are identical. Also note that [@(:if cond:)@] automatically closes a previous conditional. For nested multiple levels, see [[#nested-conditions|Nested conditionals]].''%0a%0a!! Built-in Conditions [[#built-in-conditions]]%0aThe built-in conditions include:%0a%0a(:table class='indent' border=0 cellpadding=0 cellspacing=0 valign=top:)%0a(:cellnr:)[@(:if name PAGENAME:)@]%0a(:cell:) - %0a(:cell:)current page is named "''[@PAGENAME@]''" or "''[@GROUPNAME.PAGENAME@]''"%0a(:cellnr:)[@(:if group GROUPNAME:)@]%0a(:cell:) - %0a(:cell:)current group is named "''[@GROUPNAME@]''"%0a(:cellnr:)[@(:if auth LEVEL PAGENAME:)@]%0a(:cell:) - %0a(:cell:)viewer is authorized - meaning "what they are allowed to do" - matches a "[@LEVEL@]" where [@LEVEL@] can be: [@read@], [@edit@], [@upload@], [@attr@] or [@admin@]; [@PAGENAME@] is optional.%0aThis is mostly used to hide and show portions of the interface only useful to editors or admins.%0a\\%0a%25red%25'''Security warning:''' Neither this nor any other condition is meant to hide ''secrets''. \%0aConditions may easily be circumvented%25%25 in many cases, as described in [[Passwords(#condmarkup-secrets)]].%0aSee also: [[Security]], [[PITS:01417]].%0a(:cellnr:)[@(:if authid:)@]%0a(:cell:) - %0a(:cell:)current viewer is authenticated - meaning they have proven who they are via login - to use this the wiki must include recipe [[PmWiki/AuthUser|AuthUser]] or others which set the [@$AuthId@] variable.%0a(:cellnr:)[@(:if enabled InvalidLogin:)@]%0a(:cell:) - %0a(:cell:)username and password not authenticated. To use this the wiki must include recipe [[Cookbook:AuthUser]].%0a(:cellnr:)[@(:if true:)@]%0a(:cell:) - %0a(:cell:)always include text, case sensitive%0a(:cellnr:)[@(:if false:)@]%0a(:cell:) - %0a(:cell:)always exclude text (same as a comment, but [[Page Text Variables(#conditionals)]] ARE set), case sensitive%0a(:cellnr:)[@(:if attachments FILENAMES PAGENAME:)@]%0a(:cell:) - %0a(:cell:)@@PAGENAME@@ has one or more attachments among the specified. A pagename can be omitted, in that case the current page is implied. %0a@@FILENAMES@@ specify an attachment like "pic1.jpg" or attachment patterns separated by commas, like "pic*.jpg,*.png" where asterisk (*) means "anything"; if omitted, any attachment (i.e. "*") is implied. \\%0aIf used in a sidebar, header, or footer, and the @@PAGENAME@@ is not specified, the condition applies to the main page. \\%0ae.g. [@(:if attachments *.png,*.gif Groupname.PageName:)@] (FILENAMES must not have quotation marks)%0a(:cellnr colspan=3:)In the following "if date" examples:%0a* [@DATE@] may be year-month. year-month-day is optional. %0a* [@VALUE@] can be a recognizable date via %25newwin%25[[http://php.net/manual/en/function.strtotime.php | strtotime()]]%0a* @@DATE@@ (or @@DATE1@@ and @@DATE2@@ below) have a more fixed format which explicitly must exclude spaces. Any spaces in @@DATE1@@ or @@DATE2@@ cause unpredictable results%0a* "now" or "today" is assumed if @@VALUE@@ is omitted%0a* %25newwin%25dates are in [[http://w3.org/QA/Tips/iso-date|standard]] format @@yyyy-mm-dd@@ or @@yyyymmdd@@ or @@yyyymmddThhmm@@ (note the "T" between the date and the hour, and also see comment above on format of @@VALUE@@)%0a* the ".." cannot have leading (when used with @@DATE1@@) or trailing spaces (when used with @@DATE2@@)%0a(:cellnr:)[@(:if date DATE VALUE:)@]%0a(:cell:) - %0a(:cell:)Evaluates to true if [@VALUE@] is within [@DATE@] %0a(:cellnr:)[@(:if date DATE1.. VALUE:)@]%0a(:cell:) - %0a(:cell:)true if [@VALUE@] (or current date if omitted) is [@DATE1@] or later (unlimited)%0a(:cellnr:)[@(:if date ..DATE2 VALUE:)@]%0a(:cell:) - %0a(:cell:)true if [@VALUE@] (or current date if omitted) is [@DATE2@] or earlier (unlimited)%0a(:cellnr:)[@(:if date DATE1..DATE2 VALUE:)@]%0a(:cell:) - %0a(:cell:)true if [@VALUE@] (or current date if omitted) is in range [@DATE1@] to [@DATE2@] (inclusive) %0a(:cellnr:)[@(:if enabled VAR:)@]%0a(:cell:) - %0a(:cell:)true if PHP @@VAR@@ is true%0a(:cellnr:)[@(:if enabled AuthPw:)@]%0a(:cell:) - %0a(:cell:)true if user has entered any password during the current browser session.%0a- This does not mean the user has entered the correct password, just that they entered one.%0a(:cellnr:)[@(:if equal STRING1 STRING2:)@]%0a(:cell:) - %0a(:cell:)true if [@STRING1@] equals [@STRING2@], use quotes if the string or string variable contains spaces, eg [@"MY STRING"@]%0a(:cellnr:)[@(:if match REG_EXPRESSION:)@]%0a(:cell:) - %0a(:cell:)true if current page name matches the regular expression%0a(:cellnr:)[@(:if exists PAGENAME:)@]%0a(:cell:) - %0a(:cell:)true if the page "''[@pagename@]''" or "''[@groupname.pagename@]''" exists%0a(:cellnr:)[@(:if ontrail WikiTrailPage ThisPage:)@] [[#ontrail]]%0a(:cell:) - %0a(:cell:)true if @@ThisPage@@ is in a list used as a [[wiki trails | trail]] on "''[@WikiTrailPage@]''"%0a(:tableend:)%0a%0aThe name and group conditionals will work even for an included page, as the "name" and "group" conditionals always check the currently displayed page, as opposed to the page that the markup appears in.%0a%0a'''Note''': Although there is no built-in conditional markup to test ?action=, you can use [@(:if equal {$Action} ACTION:)@]%0ato test what the current action being requested is.%0a%0a[[#concatenatedconditions]]%0a!! Concatenated conditions%0aIn some cases where built in conditions have a parameter the parameters may be concatenated using a comma, viz:%0a* @@ [=(:=]if name Name1,Name2,-Name3:) @@%0a* @@ [=(:=]if group -Group1,Group2,Group3:) @@%0a%0a!! Negated Conditions%0aNegated forms of conditions also work:%0a%0a(:table class='indent' border=0 cellpadding=0 cellspacing=0 valign=top:)%0a(:cellnr:)[@(:if !attachments:)@]%0a(:cell:) - %0a(:cell:)this page has no attachments%0a(:cellnr colspan=3:) %0a(:cellnr:)[@(:if ! name PAGENAME:)@]%0a(:cell rowspan=2 valign=middle:) - %0a(:cell rowspan=2 valign=middle:)current page is NOT named "[@PAGENAME@]"%0a(:cellnr:)[@(:if name -PAGENAME :)@]%0a(:cell:)%0a(:cellnr:)[@(:if group -GROUPNAME1,-GROUPNAME2 :)@]%0a(:cell:) - %0a(:cell:)group is not named "[@GROUPNAME1@]" or "[@GROUPNAME2@]"%0a(:tableend:)%0a%0a!! Nesting Conditions [[#nested-conditions]]%0aNote that [@(:if cond:)@] automatically closes a previous conditional. Thus, the following two examples have identical meaning:%0a* @@ [=(:=]if cond1:) cond1 is true [=(:=]if cond2:) cond2 is true [=(:=]ifend:)@@%0a* @@ [=(:=]if cond1:) cond1 is true %25bgcolor=#fcc%25[=(:=]ifend:)%25%25[=(:=]if cond2:) cond2 is true [=(:=]ifend:)@@%0a%0aConditions can be nested from 2.2.beta 66. To have nested conditionals you need to number the if, and the matching else/ifend:%0a->[@%0a(:if cond1:)%0a cond1 is true%0a (:if2 cond2:)%0a cond1 and cond2 are true%0a (:elseif2 cond3:)%0a cond1 and cond3 are true, cond2 is not%0a (:else2:)%0a cond1 is true, cond2 and cond3 are not%0a (:if2end:)%0a(:else:)%0a cond1 is false, cond2 testing was ignored%0a(:ifend:)%0a@]%0a[-''Spaces were added for better readability.''-]%0a%0a!! Using wildcard placeholders%0aThe character [@*@] can be used as a wildcard to represent any character, zero, one, or multiple times.\\%0aThe character [@?@] can be used as a wildcard to represent any character exactly once.\\%0aWildcard characters ([@*@] and [@?@]) can be used with the ''name'' and ''group'' conditional markups, thus:%0a%0a(:table class='indent' border=0 cellpadding=0 cellspacing=0 valign=top:)%0a(:cellnr:)[@(:if name PmCal.2005* :)@]%0a(:cell:) - %0a(:cell:)current page is in group PmCal and begins with 2005%0a(:cellnr:)[@(:if group PmWiki* :)@]%0a(:cell:) - %0a(:cell:)current page is in group PmWiki or a group beginning with PmWiki%0a(:cellnr:)[@(:if name Profiles.*,-Profiles.Profiles :)@]%0a(:cell:) - %0a(:cell:)current page is in group [@Profiles@] but not [@Profiles.Profiles@]%0a(:tableend:)%0a%0a!!Using [[PmWiki/page text variables]], [[PmWiki/page variables]] and [[PmWiki/markup expressions]]%0aPage text variables (PTVs), page variables (PVs) and markup expressions can be used in conditional markup. They will be assigned/evaluated before the condition(s). %0a%0a[[#combiningconditions]]%0a!! Combining conditions%0aConditions (as previously defined) may be combined into more complex conditional expressions using one of these three equivalent forms:%0a%0a->[@%0a(:if expr EXPRESSION :)%0a(:if [ EXPRESSION ] :)%0a(:if ( EXPRESSION ) :)@]%0a%0aConditions are combined into expressions with boolean operators and brackets. In the next table, A and B are either regular conditions or (round-)bracketed sub-expressions of regular conditions:%0a%0a>>indent%3c%3c%0a|| border=1 cellpadding=2 cellspacing=0%0a||! Expression ||! Operator ||! Result ||%0a|| [@A and B@] || And ||TRUE if both A and B are TRUE.||%0a|| [@A or B@] || Or ||TRUE if either A or B is TRUE.||%0a|| [@A xor B@] || Xor ||TRUE if either A or B is TRUE, but not both.||%0a|| [@! A@] || Not ||TRUE if A is not TRUE.||%0a|| [@A && B@] || And ||TRUE if both A and B are TRUE.||%0a|| [@A || B@] || Or ||TRUE if either A or B is TRUE.||%0a>>%3c%3c%0a%0aExample%0a->[@%0a(:if [ name SomePage and group SomeGroup ]:) equivalent to (:if name SomeGroup.SomePage:)@]%0a%0a'''Important Notes:'''%0a* Spaces are ''required'' around operators and brackets.%0a* No specific feedback is given for syntax errors or unbalanced brackets.%0a* Use round brackets (not square) for nested expressions.%0a%0aThus, the following is a valid way of building an expression that shows the following contents only when the user is either the administrator, or is logged in and the time is later than the given date:%0a%0a->[@(:if [ auth admin || ( authid && date 2006-06-01.. ) ] :)@]%0a%0aNesting with square brackets will silently fail to work as expected:%0a%0a->[@(:if [ auth admin || [ authid && date 2006-06-01 ] ] :) @]   %25red%25NOTE: Doesn't Work!%0a%0aA common use of these complex tests are for expressions like:%0a%0a->[@(:if expr auth admin || auth attr || auth edit :)@]%0a->[@[[Logout -> {$Name}?action=logout]]@]%0a->[@(:ifend:)@]%0a%0awhich provides a ''logout'' link only when the browser has admin, attr, or edit permissions.%0a%0a%25audience%25 admins (advanced)%0a!! Creating new conditions%0aSee [[Cookbook:ConditionalMarkupSamples]].%0a%0aSee also [[PmWiki/PageVariables#specialreferences|special references]] for the use of [={*$Variables}=]. -time=1592303086 +rev=203 +targets=PmWiki.Passwords,PmWiki.Security,PITS.01417,PmWiki.AuthUser,Cookbook.AuthUser,PmWiki.PageTextVariables,Cookbook.ConditionalMarkupSamples,PmWiki.WikiTrails,PmWiki.PageVariables,PmWiki.MarkupExpressions +text=(:Summary:The if directive allows portions of a page to be included or excluded from rendering:)%0a%25define=indent block margin-left=2em%25%0a(:Audience: authors, admins (advanced) :)%0aThe %25pmhlt%25[@(:if:)@] directive allows portions of a page to be included or excluded from rendering. %0a%0a!! Using the %25pmhlt%25[=(:if:)=] Directive%0a%0aThe generic forms of the %25pmhlt%25[@(:if:)@] directive are%0a%0a%0a(:markup class=norender:)%0a(:if cond param:) body (:ifend:)%0a(:if cond param:) body (:else:) body (:ifend:)%0a(:if cond param:) body (:elseif cond param:) body (:ifend:)%0a(:if cond param:) body (:elseif cond param:) body (:else:) body (:ifend:)%0a(:markupend:)%0a%0awhere "cond" names a condition to be tested, and "param" is a parameter or other argument to the condition.%0a%0a''Note that %25pmhlt%25[@(:if:)@] without parameters and [@(:ifend:)@] are identical. Also note that [@(:if cond:)@] automatically closes a previous conditional. For nested multiple levels, see [[#nested-conditions|Nested conditionals]].''%0a%0a!! Built-in Conditions [[#built-in-conditions]]%0aThe built-in conditions include:%0a%0a:[@(:if name PAGENAME:)@]: %25list pmhlt%25 current page is named "''[@PAGENAME@]''" or "''[@GROUPNAME.PAGENAME@]''"%0a%0a:[@(:if group GROUPNAME:)@]: current group is named "''[@GROUPNAME@]''"%0a%0a:[@(:if auth LEVEL PAGENAME:)@]:viewer is authorized - meaning "what they are allowed to do" - matches a "[@LEVEL@]" where [@LEVEL@] can be: [@read@], [@edit@], [@upload@], [@attr@] or [@admin@]; [@PAGENAME@] is optional.\\%0aThis is mostly used to hide and show portions of the interface only useful to editors or admins.\\%0a%25red%25'''Security warning:''' Neither this nor any other condition is meant to hide ''secrets''. \%0aConditions may easily be circumvented%25%25 in many cases, as described in [[Passwords(#condmarkup-secrets)]]. \%0aSee also: [[Security]], [[PITS:01417]].%0a%0a:[@(:if auth @readers,@editors:)@]:current viewer is member of at least one user group among "@readers" or "@editors". This can be configured with [[PmWiki/AuthUser|AuthUser]] or via custom recipes (from PmWiki 2.3.17).%0a%0a:[@(:if authid:)@]:current viewer is authenticated - meaning they have proven who they are via login - to use this the wiki must include recipe [[PmWiki/AuthUser|AuthUser]] or others which set the [@$AuthId@] variable.%0a%0a:[@(:if enabled InvalidLogin:)@]:username and password not authenticated. To use this the wiki must include recipe [[Cookbook:AuthUser]].%0a%0a:[@(:if true:)@]:always include text, case sensitive%0a%0a:[@(:if false:)@]:always exclude text (same as a comment, but [[Page Text Variables(#conditionals)]] ARE set), case sensitive%0a%0a:[@(:if attachments FILENAMES PAGENAME:)@]:@@PAGENAME@@ has one or more attachments among the specified. A pagename can be omitted, in that case the current page is implied.\\%0a@@FILENAMES@@ specify an attachment like "pic1.jpg" or attachment patterns separated by commas, like "pic*.jpg,*.png" where asterisk (*) means "anything"; if omitted, any attachment (i.e. "*") is implied. \\%0aIf used in a sidebar, header, or footer, and the @@PAGENAME@@ is not specified, the condition applies to the main page. \\%0ae.g. [@(:if attachments *.png,*.gif Groupname.PageName:)@] (FILENAMES must not have quotation marks)%0a%0aIn the following "if date" examples:%0a* [@DATE@] may be year-month. year-month-day is optional. %0a* [@VALUE@] can be a recognizable date via %25newwin%25[[http://php.net/manual/en/function.strtotime.php | strtotime()]]%0a* @@DATE@@ (or @@DATE1@@ and @@DATE2@@ below) have a more fixed format which explicitly must exclude spaces. Any spaces in @@DATE1@@ or @@DATE2@@ cause unpredictable results%0a* "now" or "today" is assumed if @@VALUE@@ is omitted%0a* dates are in %25newwin%25 [[http://w3.org/QA/Tips/iso-date|standard]] format @@yyyy-mm-dd@@ or @@yyyymmdd@@ or @@yyyymmddThhmm@@ (note the "T" between the date and the hour, and also see comment above on format of @@VALUE@@)%0a* the ".." cannot have leading (when used with @@DATE1@@) or trailing spaces (when used with @@DATE2@@)%0a%0a:[@(:if date DATE VALUE:)@]:%25list pmhlt%25Evaluates to true if [@VALUE@] is within [@DATE@] %0a%0a:[@(:if date DATE1.. VALUE:)@]:true if [@VALUE@] (or current date if omitted) is [@DATE1@] or later (unlimited)%0a%0a:[@(:if date ..DATE2 VALUE:)@]:true if [@VALUE@] (or current date if omitted) is [@DATE2@] or earlier (unlimited)%0a%0a:[@(:if date DATE1..DATE2 VALUE:)@]:true if [@VALUE@] (or current date if omitted) is in range [@DATE1@] to [@DATE2@] (inclusive) %0a%0a:[@(:if enabled VAR:)@]:true if PHP @@VAR@@ exists and is not false%0a%0a:[@(:if enabled AuthPw:)@]:true if user has entered any password during the current browser session. This does not mean the user has entered the correct password, just that they entered one.%0a%0a:[@(:if equal STRING1 STRING2:)@]:true if [@STRING1@] equals [@STRING2@], use quotes if the string or string variable contains spaces, eg [@"MY STRING"@]%0a%0a:[@(:if match REG_EXPRESSION:)@]:true if current page name matches the regular expression%0a%0a:[@(:if exists PAGENAME:)@]:true if the page "''[@pagename@]''" or "''[@groupname.pagename@]''" exists ([[Cookbook:ConditionalMarkupSamples#exists|case insensitive]])\\%0aMultiple pages can be specified, e.g. @@[=(:if exists p1,p2,mygroup.*:)=]@@ is true if at least one among the pages "p1", "p2" or those in the "mygroup" group exist.%0a%0a:[@(:if ontrail WikiTrailPage ThisPage:)@] [[#ontrail]]:true if @@ThisPage@@ is in a list used as a [[wiki trails | trail]] on "''[@WikiTrailPage@]''"%0a%0aThe name and group conditionals will work even for an included page, as the "name" and "group" conditionals always check the currently displayed page, as opposed to the page that the markup appears in.%0a%0a'''Note''': Although there is no built-in conditional markup to test ?action=, you can use [@(:if equal {$Action} ACTION:)@]%0ato test what the current action being requested is.%0a%0a[[#concatenatedconditions]]%0a!! Concatenated conditions%0aIn some cases where built in conditions have a parameter the parameters may be concatenated using a comma, viz:%0a* %25pmhlt%25@@[=(:=]if name Name1,Name2,-Name3:) @@%0a* %25pmhlt%25@@[=(:=]if group -Group1,Group2,Group3:) @@%0a%0a!! Negated Conditions%0aNegated forms of conditions also work:%0a%0a:[@(:if !attachments:)@]:%25list pmhlt%25this page has no attachments%0a%0a:[@(:if ! name PAGENAME:)@]: %0a:[@(:if name -PAGENAME :)@]:current page is NOT named "[@PAGENAME@]"%0a%0a:[@(:if group -GROUPNAME1,-GROUPNAME2 :)@]:group is not named "[@GROUPNAME1@]" or "[@GROUPNAME2@]"%0a%0a%0a!! Nesting Conditions [[#nested-conditions]]%0aNote that %25pmhlt%25[@(:if cond:)@] automatically closes a previous conditional. Thus, the following two examples have identical meaning:%0a(:comment careful with %25pmhlt%25 below:)%0a* %25pmhlt%25[@(:if cond1:)@] cond1 is true [@(:if cond2:)@] cond2 is true [@(:ifend:)@]%0a* %25pmhlt%25[@(:if cond1:)@]%25%25 cond1 is true %25bgcolor=#fcc%25'''[@(:ifend:)@]'''%25pmhlt%25[@(:if cond2:)@] cond2 is true [@(:ifend:)@]%0a%0aConditions can be nested from 2.2.beta 66. To have nested conditionals you need to number the if, and the matching else/ifend:%0a%0a(:markup class=norender:)%0a(:if cond1:)%0a cond1 is true%0a (:if2 cond2:)%0a cond1 and cond2 are true%0a (:elseif2 cond3:)%0a cond1 and cond3 are true, cond2 is not%0a (:else2:)%0a cond1 is true, cond2 and cond3 are not%0a (:if2end:)%0a(:else:)%0a cond1 is false, cond2 testing was ignored%0a(:ifend:)%0a(:markupend:)%0a%0a[-''Spaces were added for better readability.''-]%0a%0a!! Using wildcard placeholders%0aThe character [@*@] can be used as a wildcard to represent any character, zero, one, or multiple times.\\%0aThe character [@?@] can be used as a wildcard to represent any character exactly once.\\%0aWildcard characters ([@*@] and [@?@]) can be used with the ''name'' and ''group'' conditional markups, thus:%0a%0a:[@(:if name PmCal.2005* :)@]:%25list pmhlt%25current page is in group PmCal and begins with 2005%0a%0a:[@(:if group PmWiki* :)@]:current page is in group PmWiki or a group beginning with PmWiki%0a%0a:[@(:if name Profiles.*,-Profiles.Profiles :)@]:current page is in group [@Profiles@] but not [@Profiles.Profiles@]%0a%0a!!Using [[PmWiki/page text variables]], [[PmWiki/page variables]] and [[PmWiki/markup expressions]]%0aPage text variables (PTVs), page variables (PVs) and markup expressions can be used in conditional markup. They will be assigned/evaluated before the condition(s). %0a%0a[[#combiningconditions]]%0a!! Combining conditions%0aConditions (as previously defined) may be combined into more complex conditional expressions using one of these three equivalent forms:%0a%0a(:markup class=norender:)%0a(:if expr EXPRESSION :)%0a(:if [ EXPRESSION ] :)%0a(:if ( EXPRESSION ) :)%0a(:markupend:)%0a%0aConditions are combined into expressions with boolean operators and brackets. In the next table, A and B are either regular conditions or (round-)bracketed sub-expressions of regular conditions:%0a%0a>>indent%3c%3c%0a|| border=1 cellpadding=2 cellspacing=0%0a||! Expression ||! Operator ||! Result ||%0a|| [@A and B@] || And ||TRUE if both A and B are TRUE.||%0a|| [@A or B@] || Or ||TRUE if either A or B is TRUE.||%0a|| [@A xor B@] || Xor ||TRUE if either A or B is TRUE, but not both.||%0a|| [@! A@] || Not ||TRUE if A is not TRUE.||%0a|| [@A && B@] || And ||TRUE if both A and B are TRUE.||%0a|| [@A || B@] || Or ||TRUE if either A or B is TRUE.||%0a>>%3c%3c%0a%0aExample%0a%0a(:markup class=norender:)%0a(:if [ name SomePage and group SomeGroup ]:) %0aequivalent to (:if name SomeGroup.SomePage:)%0a(:markupend:)%0a%0a%0a'''Important Notes:'''%0a* Spaces are ''required'' around operators and brackets.%0a* No specific feedback is given for syntax errors or unbalanced brackets.%0a* Use round brackets (not square) for nested expressions.%0a%0aThus, the following is a valid way of building an expression that shows the following contents only when the user is either the administrator, or is logged in and the time is later than the given date:%0a%0a->%25pmhlt%25[@(:if [ auth admin || ( authid && date 2006-06-01.. ) ] :)@]%0a%0aNesting with square brackets will silently fail to work as expected:%0a%0a->%25pmhlt%25[@(:if [ auth admin || [ authid && date 2006-06-01 ] ] :) @]   %25red%25NOTE: Doesn't Work!%0a%0aA common use of these complex tests are for expressions like:%0a%0a%0a(:markup class=norender:)%0a(:if expr auth admin || auth attr || auth edit :)%0a[[Logout -> {*$Name}?action=logout]]%0a(:ifend:)%0a(:markupend:)%0a%0awhich provides a ''logout'' link only when the browser has admin, attr, or edit permissions.%0a%0a%25audience%25 admins (advanced)%0a!! Creating new conditions%0aSee [[Cookbook:ConditionalMarkupSamples]].%0a%0aSee also [[PmWiki/PageVariables#specialreferences|special references]] for the use of %25pmhlt%25@@[={*$Variables}=]@@. +time=1671270540 blob - 7c662e270c6d389a20e0deedc7e24079e55902b4 blob + 1fd4d6c7d8514aaa0526291c8537f31afa64a656 --- wikilib.d/PmWiki.ContactUs +++ wikilib.d/PmWiki.ContactUs @@ -1,11 +1,11 @@ -version=pmwiki-2.2.119 ordered=1 urlencoded=1 -author=Petko +version=pmwiki-2.2.145 ordered=1 urlencoded=1 +author=simon charset=UTF-8 -csum=fix protocol +csum=http+s (+1) ctime=1276999784 name=PmWiki.ContactUs -rev=28 +rev=29 targets=PmWiki.Download,PmWiki.Installation,PmWiki.MailingLists,PmWiki.HowToGetAssistance,PITS.PITS,PmWiki.Petko,PmWiki.PmWiki -text=(:title Contact us:)(:Summary:How to reach the PmWiki developers and community:)%0a(:if expr equal "{$ScriptUrl}" "https://www.pmwiki.org/wiki" || equal "{$ScriptUrl}" "http://www.pmwiki.org/wiki" :)%0aThis page contains information about some ways to contact the developers of the PmWiki software.%0a%0a'''If you have an objection about the content on some website other than pmwiki.org, please contact the owners of that website, not us.''' We only develop the PmWiki software which someone [[PmWiki:Download|downloaded]] and [[PmWiki:Installation|installed]] on their server.%0a%0a'''Questions about the software should be asked on the [[(https://)www.pmwiki.org]] site "talk" pages or on our public [[(PmWiki:)mailing lists]].''' See also [[(PmWiki:)How To Get Assistance]].%0a%0a'''Bugs''' should be reported to our [[(PITS:)PITS]] issue tracking system, or on our public [[(PmWiki:)mailing lists]].%0a%0aFor '''security bug disclosures''' please [[mailto:5ko@5ko.fr?cc=pmichaud@pobox.com&subject=PmWiki%2520security%2520disclosure|e-mail Petko with cc: to Pm]].%0a%0a%0aThe primary author of PmWiki is Dr. Patrick R. Michaud (Pm) who can be contacted at http://www.pmichaud.com.%0a%0aThe current core developer of PmWiki and webmaster of pmwiki.org is [[PmWiki:Petko|Petko Yotov]] who can be contacted via e-mail at [[(mailto:)5ko@5ko.fr]]. If you need assistance with our software, please read [[(PmWiki:)How To Get Assistance]].%0a%0a(:else:)%0aThis website "{$WikiTitle}" is powered by the open source [[https://www.pmwiki.org/|PmWiki collaborative content management system]].%0a%0aTo contact the owners/editors of the "{$WikiTitle}" '''website''', look around starting at [[{$DefaultGroup}/]] or [[Path:/]]. Questions or objections about the website content should be directed to them.%0a%0aTo contact the developers and community publishing the PmWiki '''software''', please visit https://www.pmwiki.org/. %0a%0a(:if:)%0a%0a %0a -time=1570747084 +text=(:title Contact us:)(:Summary:How to reach the PmWiki developers and community:)%0a(:if expr equal "{$ScriptUrl}" "https://www.pmwiki.org/wiki" || equal "{$ScriptUrl}" "http://www.pmwiki.org/wiki" :)%0aThis page contains information about some ways to contact the developers of the PmWiki software.%0a%0a'''If you have an objection about the content on some website other than pmwiki.org, please contact the owners of that website, not us.''' We only develop the PmWiki software which someone [[PmWiki:Download|downloaded]] and [[PmWiki:Installation|installed]] on their server.%0a%0a'''Questions about the software should be asked on the [[(https://)www.pmwiki.org]] site "talk" pages or on our public [[(PmWiki:)mailing lists]].''' See also [[(PmWiki:)How To Get Assistance]].%0a%0a'''Bugs''' should be reported to our [[(PITS:)PITS]] issue tracking system, or on our public [[(PmWiki:)mailing lists]].%0a%0aFor '''security bug disclosures''' please [[mailto:5ko@5ko.fr?cc=pmichaud@pobox.com&subject=PmWiki%2520security%2520disclosure|e-mail Petko with cc: to Pm]].%0a%0a%0aThe primary author of PmWiki is Dr. Patrick R. Michaud (Pm) who can be contacted at https://www.pmichaud.com.%0a%0aThe current core developer of PmWiki and webmaster of pmwiki.org is [[PmWiki:Petko|Petko Yotov]] who can be contacted via e-mail at [[(mailto:)5ko@5ko.fr]]. If you need assistance with our software, please read [[(PmWiki:)How To Get Assistance]].%0a%0a(:else:)%0aThis website "{$WikiTitle}" is powered by the open source [[https://www.pmwiki.org/|PmWiki collaborative content management system]].%0a%0aTo contact the owners/editors of the "{$WikiTitle}" '''website''', look around starting at [[{$DefaultGroup}/]] or [[Path:/]]. Questions or objections about the website content should be directed to them.%0a%0aTo contact the developers and community publishing the PmWiki '''software''', please visit https://www.pmwiki.org/. %0a%0a(:if:)%0a%0a %0a +time=1641089448 title=Contact us blob - 2f4e2f71ffd3a1e0d74da5300fc947ba477619ad blob + 24250099d03ac3dc2d1b3246d7ef8ad803333316 --- wikilib.d/PmWiki.Contributors +++ wikilib.d/PmWiki.Contributors @@ -1,10 +1,10 @@ -version=pmwiki-2.2.56 ordered=1 urlencoded=1 -author=Ian MacGregor +version=pmwiki-2.3.2 ordered=1 urlencoded=1 +author=Dfaure charset=UTF-8 -csum=updated my information +csum=added myself (+82) name=PmWiki.Contributors post= Save -rev=66 +rev=68 targets=PmWiki.PmWiki,PmWiki.Uploads,PmWiki.Links,PmWiki.WikiGroup,Cookbook.EmacsPmWikiMode,PmWiki.Petko,PmWiki.ChangeLog,PITS.PITS,PmWiki.MailingLists -text=(:Summary:A list of contributors to PmWiki development and improvement:)%0aHere's a list of contributors to [[PmWiki]] development and improvement. My apologies if I've forgotten anyone -- feel free to add your name if you've been left out, feel free to remove your name if you don't want to be associated with these people. :-)%0a%0a* GNUZoo - Several recipes, some security and bug fixes%0a* Scott Duff - pmwe, simple-journal.php, all-around Pm sanity checker %0a* Ross Kowalski - [[uploads]] and printable page research%0a* John Rankin - WikiTrails, [[Links]], `EditQuickReference, notify.php, documentation, debugging%0a* Joachim Durchholz - hacking documentation, general pest%0a* Jessica Tishmack - uploads, testing%0a* Jean-Claude Gorichon - voting%0a* Janice Heinold - early PmWiki testing and suggestions, documentation%0a* James Davis - WikiStyles markup, testing%0a* Isabelle Michaud - floating images markup, [[Wiki Group]]s, [[uploads]]/attachments%0a* Glenn Blalock - WikiStyles suggestions, testing, documentation%0a* Dawn Green - WikiStyles suggestions, [[uploads]], documentation%0a* Christian Ridderström - [[Cookbook:EmacsPmWikiMode |pmwiki-mode for Emacs]] and some other hacks/modifications.%0a* Carlo Strozzi - Internationalization, PmWiki on Boa, HTML redirection%0a* Michael Weiner - Modifications to the ToDo, RssFeedDisplay, MyPmWiki, and CommentBox recipes%0a* Criss Ittermann (aka Crisses/XES) - ye old best seller Blocklist2 that topped the charts for a while and many other recipes%0a* Rev. Ian MacGregor - I've contributed with monetary donations, skins, bug reports and continued testing. [[http://www.ianmacgregor.net/ | My personal website]] is powered by PmWiki.%0a* Petko Yotov - I have been the PmWiki core developer and pmwiki.org webmaster since January 2009 (after having worked with it since 2004). My contributions are at the [[Change log]] page, in the [[(PITS:)PITS]] issue tracking system and in the [[(PmWiki:)mailing lists]]. My cookbook recipes can be found at [[PmWiki:Petko|my profile page]].%0a -time=1381253012 +text=(:Summary:A list of contributors to PmWiki development and improvement:)%0aHere's a list of contributors to [[PmWiki]] development and improvement. My apologies if I've forgotten anyone -- feel free to add your name if you've been left out, feel free to remove your name if you don't want to be associated with these people. :-)%0a%0a* Scott Duff - pmwe, simple-journal.php, all-around Pm sanity checker %0a* Ross Kowalski - [[uploads]] and printable page research%0a* John Rankin - WikiTrails, [[Links]], `EditQuickReference, notify.php, documentation, debugging%0a* Joachim Durchholz - hacking documentation, general pest%0a* Jessica Tishmack - uploads, testing%0a* Jean-Claude Gorichon - voting%0a* Janice Heinold - early PmWiki testing and suggestions, documentation%0a* James Davis - WikiStyles markup, testing%0a* Isabelle Michaud - floating images markup, [[Wiki Group]]s, [[uploads]]/attachments%0a* Glenn Blalock - WikiStyles suggestions, testing, documentation%0a* Dawn Green - WikiStyles suggestions, [[uploads]], documentation%0a* Christian Ridderström - [[Cookbook:EmacsPmWikiMode |pmwiki-mode for Emacs]] and some other hacks/modifications.%0a* Carlo Strozzi - Internationalization, PmWiki on Boa, HTML redirection%0a* Michael Weiner - Modifications to the ToDo, RssFeedDisplay, MyPmWiki, and CommentBox recipes%0a* Criss Ittermann (aka Crisses/XES) - ye old best seller Blocklist2 that topped the charts for a while and many other recipes%0a* Rev. Ian MacGregor - I've contributed with monetary donations, skins, bug reports and continued testing. [[http://www.ianmacgregor.net/ | My personal website]] is powered by PmWiki.%0a* Dominique Faure - some core internals (condition evaluation), recipes & testing%0a* Petko Yotov - I have been the PmWiki core developer and pmwiki.org webmaster since January 2009 (after having worked with it since 2004). My contributions are at the [[Change log]] page, in the [[(PITS:)PITS]] issue tracking system and in the [[(PmWiki:)mailing lists]]. My cookbook recipes can be found at [[PmWiki:Petko|my profile page]].%0a +time=1644858716 blob - a5cb686665b74ef09fcf11c0e6e90b860cd0015f blob + f0340985e09393f69b8d897ada0c05f8b0f08217 --- wikilib.d/PmWiki.CreatingNewPages +++ wikilib.d/PmWiki.CreatingNewPages @@ -1,10 +1,10 @@ -version=pmwiki-2.2.42 ordered=1 urlencoded=1 -author=Ian MacGregor +version=pmwiki-2.3.13 ordered=1 urlencoded=1 +author=MFWolff charset=UTF-8 -csum=edited for grammar and appearance +csum=summary missed for Cookbook:EditTemplatesMenu (-9) name=PmWiki.CreatingNewPages -rev=113 -targets=PmWiki.Links,PmWiki.MyNewPage,Site.SideBar,PmWiki.WikiGroup -text=(:Summary:How to create a new page:)%0a(:title Creating New Pages:)%0a(:Audience: authors (basic) :)%0aThe first step to create a new page is to edit an existing page and add a link to the page you want to create. %0a%0a-> To link to your new page, you must choose a name for it. The best names describe the page's contents well, so that everyone can remember and type the name easily.%0a%0a-> To create a link, surround the page name with '''double brackets'''. Typing [@[[my new page]]@] will create a link to [[my new page]]. There's [[a lot you can do -> Links]] with double bracket links.%0a%0aYou can see that the links to [[my new page]] all have question marks after them. That's because [[my new page]] hasn't been written yet. Clicking the link as second step will take you to an edit form where you could write and finally save the new page. %0a%0a----%0aAnother way to create a page: in your browser's address bar (where the page URL is), replace the name of the current page with the name of the page you wish to create, and hit Enter or do whatever you would normally do to go to a new location. PmWiki will then dutifully tell you that the page you entered doesn't exist, but you can click on the "Edit" link in order to create, edit, and save the new page.%0a%0aThe drawback to this method is that there are no links to your new page, so you're the only person who knows it exists. It will be an orphan, unread, unlinked, unloved. That's why adding a link to an existing page or to the [[Site/SideBar]] is a better way to create a page.%0a----%0a%0aLearn more:%0a* You can also organize related pages into [[wiki group | groups]], and link between pages in different groups.%0a%0a>>faq%3c%3c [[#faq]]%0a[[#beginning]]%0aQ: How do I create a new page?%0aA: Typing [=[[my new page]]=] will create a link to the new page. There's [[PmWiki.Links | a lot you can do]] with double bracket links.%0a%0aQ: Why do some new pages have a title with spaces like "Creating New Pages" and others end up with a WikiWord-like title like "CreatingNewPages"?%0aA: The default page title is simply the name of page, which is normally stored as "CreatingNewPages." However, you can override a page's title by using the [@(:title Creating New Pages:)@] directive. This is especially useful when there are special characters or capitalization that you want in the title that cannot be used in the page name.%0a -time=1347315131 +rev=148 +targets=PmWiki.Links,PmWiki.MyNewPage,Site.SideBar,PmWiki.WikiGroup,Cookbook.NewPageBoxPlus,Cookbook.EditTemplates,Cookbook.EditTemplatesMenu +text=(:Summary:How to create a new page:)%0a(:title Creating New Pages:)%0a(:Audience: authors (basic) :)%0aThe first step to create a new page is to edit an existing page and add a link to the page you want to create. %0a%0a-> To link to your new page, you must choose a name for it. The best names describe the page's contents well, so that everyone can remember and type the name easily.%0a%0a-> To create a link, surround the page name with '''double brackets'''. Typing %25pmhlt%25[@[[my new page]]@] will create a link to [[my new page]]. There's [[a lot you can do -> Links]] with double bracket links.%0a%0aYou can see that the links to [[my new page]] all have question marks after them. That's because [[my new page]] hasn't been written yet. Clicking the link as second step will take you to an edit form where you could write and finally save the new page. %0a%0a----%0aAnother way to create a page: in your browser's address bar (where the page URL is), replace the name of the current page with the name of the page you wish to create, and hit Enter or do whatever you would normally do to go to a new location. PmWiki will then dutifully tell you that the page you entered doesn't exist, but you can click on the "Edit" link in order to create, edit, and save the new page.%0a%0aThe drawback to this method is that there are no links to your new page, so you're the only person who knows it exists. It will be an orphan, unread, unlinked, unloved. That's why adding a link to an existing page or to the [[Site/SideBar]] is a better way to create a page.%0a----%0a%0aLearn more:%0a* You can also organize related pages into [[wiki group | groups]], and link between pages in different groups.%0a%0aYou can use a recipe to create new pages%0a* [[Cookbook:NewPageBoxPlus]] [-{Cookbook/NewPageBoxPlus$:Summary}-]%0aand to create new pages from templates%0a* [[Cookbook:EditTemplates]] [-{Cookbook/EditTemplates$:Summary}-]%0a* [[Cookbook:EditTemplatesMenu]] [-{Cookbook/EditTemplatesMenu$:Summary}-]%0a%0a>>faq%3c%3c [[#faq]]%0a[[#beginning]]%0aQ: How do I create a new page?%0aA: Typing %25pmhlt%25[@[[my new page]]@] will create a link to the new page. There's [[PmWiki.Links | a lot you can do]] with double bracket links.%0a%0aQ: Why do some new pages have a title with spaces like "Creating New Pages" and others end up with a WikiWord-like title like "CreatingNewPages"?%0aA: The default page title is simply the name of page, which is normally stored as "CreatingNewPages." However, you can override a page's title by using the %25pmhlt%25[@(:title Creating New Pages:)@] directive. This is especially useful when there are special characters or capitalization that you want in the title that cannot be used in the page name.%0a +time=1666681864 title=Creating New Pages blob - cdc962590917368324f3af4bfa2b46462f14f5d7 blob + 782662d1694a2f4247d495f2ed98bd9be0f3329b --- wikilib.d/PmWiki.CustomMarkup +++ wikilib.d/PmWiki.CustomMarkup @@ -1,9 +1,9 @@ -version=pmwiki-2.2.118 ordered=1 urlencoded=1 -author=Petko +version=pmwiki-2.3.16 ordered=1 urlencoded=1 +author=simon charset=UTF-8 -csum=lead section +csum=add to markup category. (+32) name=PmWiki.CustomMarkup -rev=179 -targets=PmWiki.PageTextVariables,PmWiki.Links,PmWiki.CustomMarkup,PmWiki.DebugVariables,Cookbook.Cookbook,PmWiki.LocalCustomizations,Cookbook.ParseArgs,PmWiki.ReleaseNotes,PmWiki.Functions,PmWiki.BasicVariables,PmWiki.CustomMarkup-Talk,PmWiki.MailingLists,Cookbook.JavaScript,Cookbook.JavaScript-Editable,PmWiki.Skins,PmWiki.LayoutVariables,PmWiki.CustomMarkupAlt -text=(:Summary: Using the Markup() function for custom wiki syntax; migration to PHP 5.5:)%0a(:Audience: administrators (intermediate) :)%0a%0aPmWiki's markup translation engine is handled by a set of rules; each rule searches for a specific pattern in the markup text and replaces it with some replacement text. Internally, this is accomplished by using PHP's "[[(http://www.php.net/)preg_replace]]" function.%0a%0a!! Introduction%0aRules are added to the translation engine via PmWiki's Markup() or function, which look like%0a->[@Markup($name, $when, $pattern, $replace); # if no evaluation is needed, or if PHP %3c 5.5%0aMarkup($name, $when, $pattern, $replace_function); # if evaluation is needed%0a%0a# DEPRECATED, will not work as of PHP 7.2%0aMarkup_e($name, $when, $pattern, $replace); # if evaluation is needed and 5.5%3c=PHP%3c=7.1@]%0a%0a* [@$name@] is a unique name (a string) given to the rule%0a* [@$when@] says when the rule should be applied relative to other rules%0a* [@$pattern@] is the pattern to be searched for in the markup text%0a* [@$replace@] is what the pattern should be replaced with.%0a* [@$replace_function@] is the name of the function which should be called with the match, and should return the replacement.%0a%0aFor example, here's the code that creates the rule for [@''emphasized text''@] (in ''scripts/stdmarkup.php''):%0a->[@Markup("em", "inline", "/''(.*?)''/", "%3cem>$1%3c/em>");@]%0a%0aBasically this statement says to create a rule called "em" to be performed with the other "inline" markups, and the rule replaces any text inside two pairs of single quotes with the same text ($1) surrounded by [@%3cem>@] and [@%3c/em>@].%0a%0a!!! Sequence in which rules are applied%0aThe first two parameters to Markup() are used to specify the sequence in which rules should be applied. The first parameter provides a name for a rule -- "[@em@]" in the example above. We could've chosen other names such as "[@''@]", or even "[@twosinglequotes@]". In general PmWiki uses the markup itself to name the rule (i.e., PmWiki uses "[@''@]" instead of "[@em@]"), but to keep this example easier to read later on we'll use a mnemonic name for now.%0a%0aThe second parameter says that this rule is to be done along with the other "inline" markups. PmWiki divides the translation process into a number of phases:%0a%0a _begin start of translation%0a [={$var}=] [[Page Text Variables]] happen here.%0a fulltext translations to be performed on the full text %0a split conversion of the full markup text into lines to be processed%0a directives directive processing%0a inline inline markups%0a links conversion of [[links]], url-links, and WikiWords %0a block block markups%0a style style handling %0a _end end of translation%0a%0a%0aThis argument is normally specified as a left-angle bracket ("before") or a right-angle bracket ("after") followed by the name of another rule. %0a%0aThus, specifying "inline" for the second parameter says that this rule should be applied when the other "inline" rules are being performed. If we want a rule to be performed with the directives -- i.e., before inline rules are processed, we would specify "directives" or "%3cinline" for the second parameter.%0a%0a!!!!! [={$var}=] and [=(:if ...:)=] conditionals%0aA significant rule in terms of ordering is "[={$var}=]" which substitutes variables -- if you say "%3c[={$var}=]" then your markup will be processed before variables are substituted whereas if you say ">[={$var}=]" then your markup will be processed after variables are substituted. This happens before conditional [=(:if...:)=] expressions, which is why page text variables are processed even if they are defined inside [=(:if false:)=].%0a%0a!!! Markup regular expression definition%0aThe third parameter is a Perl-compatible regular expression. Basically, it is a slash, a [[regular expression -> http://www.php.net/manual/en/reference.pcre.pattern.syntax.php]], another slash, and a set of optional [[modifiers -> http://www.php.net/manual/en/reference.pcre.pattern.modifiers.php]].%0a%0aThe example uses the pattern string [@"/''(.*?)''/"@], which uses [@''(.*?)''@] as the regular expression and no options. (The regular expression says "find two single quotes in succession, then as few arbitrary characters as are needed to make the match find something, then two additional single quotes in succession"; the parentheses "capture" a part of the wikitext for later use.)%0a%0a!!! Replacement text%0aThe fourth parameter is the replacement text that should be inserted instead of the marked-up wikitext. You can use [@$1@], [@$2@], etc. to insert the text from the first, second etc. parenthesised part of the regular expression.%0a%0aIn the example, we have [@"%3cem>$1%3c/em>"@], which is an [@%3cem>@], the text matched by the first parentheses (i.e. by the [@.*?@] section of the pattern), and [@%3c/em>@].%0a%0aHere's a rule for [@@@monospaced@@@] text:%0a%0a->[@Markup("@@", "inline", "/@@(.*?)@@/", "%3ccode>$1%3c/code>");@]%0a%0aand for a [@[:comment ...:]@] directive that is simply removed from the output:%0a%0a->[@Markup("comment", "directives", "/\\[:comment .*?:\\]/", '');@]%0a%0aOkay, now how about the rule for [@'''strong emphasis'''@]? We have to be a bit careful here, because although this translation should be performed along with other inline markup, we also have to make sure that the rule for [@'''@] is handled ''before'' the rule for [@''@], because [@'''@] also contains [@''@]. The second parameter to Markup() can be used to specify the new rule's relationship to any other rule:%0a%0a->[@Markup("strong", "%3cem", "/'''(.*?)'''/", "%3cstrong>$1%3c/strong>");@]%0a%0aThis creates a rule called "strong", and the second parameter "%3cem" says to be sure that this rule is processed before the "em" rule we defined above. If we wanted to do something after the "em" rule, we would use ">em" instead. Thus, it's possible to add rules at any point in PmWiki's markup translation process in an extensible manner. (In fact, the "inline", "block", "directives", etc., phases above are just placeholder rules used to provide an overall sequence for other rules. Thus one can use "%3cinline" to specify rules that should be handled before any other inline rules.) %0a%0aIf you want to disable available markup just call e.g.:%0a%0a->[@DisableMarkup("strong");@]%0a%0aPmWiki's default markup rules are defined in the ''scripts/stdmarkup.php'' file. To see the entire translation table as the program is running, the scripts/diag.php module adds "[@?action=ruleset@]", which displays the set of defined markup rules in the sequence in which they will be processed. You can see it at [[CustomMarkup?action=ruleset | CustomMarkup?action=ruleset]]. You must first enable the action by setting $EnableDiag = 1 in your configuration file.%0a%0a!! Other common examples%0a%0a!!! Define a custom markup to produce a specific HTML or Javascript sequence%0a%0aSuppose an admin wants to have a simple "[@(:example:)@]" markup that will always produce a fixed HTML string in the output, such as for a webring, Google AdSense display, or Javascript. The Markup() call to do this would be:%0a%0a->[@%0aMarkup('example', 'directives',%0a '/\\(:example:\\)/',%0a Keep("%3cdiv class='example'>%3cp>Here is a %0a %3ca target='_blank' href='http://www.example.com'>link%3c/a> to%0a %3cem>example.com%3c/em>%3c/p>%3c/div>") );%0a@]%0a%0a* The first argument is a unique name for the markup ("example").%0a* The second argument says to perform this markup along with other directives.%0a* The third argument is the pattern to look for "(:example:)".%0a* The fourth argument is the HTML that "(:example:)" is to be replaced with. We use the Keep() function here to prevent the output from being further processed by PmWiki's markup rule -- in the above example, we don't want the http://www.example.com url to be again converted to a link.%0a%0a[[#random]]%0a!!! Define a markup to call a custom function that returns content%0a%0a->%25red%25 The /e modifier has been deprecated and should not be used in ongoing development. See [[#php55|below]] for more details.%25%25%0a%0aFor older PHP versions (%3c 7.2) an 'e' option on the [@$pattern@] parameter causes the [@$replace@] parameter to be treated as a PHP expression to be evaluated instead of replacement text. To avoid using the deprecated e/ parameter, a markup to produce a random number between 1 and 100 might now look like:%0a%0a->[@%0aMarkup('random', 'directives',%0a '/\\(:random:\\)/',%0a "MyRandomFunction");%0afunction MyRandomFunction() {%0a return rand(1, 100);%0a}%0a@]%0a%0aThis calls the PHP built-in rand() function and substitutes the directive with the result. Any function can be called, including functions defined in a [[local customization(s)]] file or in [[Cookbook:Cookbook|Cookbook]] recipes.%0a%0aArguments can also be passed by using regular expression capturing parentheses, thus%0a%0a->[@%0aMarkup('randomargs', 'directives',%0a '/\\(:random (\\d+) (\\d+):\\)/',%0a "MyRandomFunction");%0afunction MyRandomFunction($m) {%0a return rand($m[1], $m[2]);%0a}%0a@]%0a%0awill cause the markup [@(:random 50 100:)@] to generate a random number between 50 and 100.%0a%0a->%25note%25 Note: the /e modifier in regular expressions is deprecated since PHP version 5.5, and removed since PHP version 7. The reason for this is, that malicious authors could pass strings that could cause arbitrary and undesirable PHP functions to be executed.%0a%0aFor a PmWiki function to help with parsing arbitrary sequences of arguments and key=value pairs, see Cookbook:ParseArgs.%0a%0a[[#php55]]%0a!! Migration to PHP 5.5 and @@Markup_e()@@%0aSince PHP version 5.5, the @@/e@@ evaluation modifier is deprecated and some hosting providers don't allow its use.%0a%0aRecent [[ReleaseNotes | versions]] of the PmWiki core (2.2.58 and newer) allow new ways to define markup rules without being dependent on the @@/e@@ eval modifier. The historical ways to define markup rules are not removed and work, but may be incompatible with PHP 5.5 installations.%0a%0a''Note: whether your replacement pattern needs evaluation or not, you must use %25green%25@@Markup()@@%25%25 and %25red%25not @@Markup_e()@@.%25%25'' The latter is deprecated and should no longer be used for new recipes and customizations, and old recipes using @@Markup_e@@ should be upgraded to the new format.%0a%0aThe examples below all require PmWiki 2.2.58 (2013-12-25) or newer but the latest version is recommended.%0a%0a>>frame%3c%3c%0aTHE SHORT ANSWER: If your markup regular expression (the 3rd argument) contains an "e" after the closing slash (i.e., @@/regex/e@@ or @@/regex/se@@ or etc) AND your 4th argument is entirely surrounded with double-quotes then you may be able to get away with simply following these simple steps:%0a%0a# Delete the "e" from after the closing slash in the 3rd argument%0a# Create a new replacement function with $m as argument.%0a# In your function, the previous occurrences of '$1', '$2', etc. are now found as $m[1], $m[2], etc. You should no longer call @@[[Functions#PSS|PSS()]]@@.%0a# In your function, call @@extract($GLOBALS['MarkupToHTML']);@@ in order to get the current $pagename and $markupid.%0a# Your function needs to '''return''' the result from the markup processing, either html or another markup.%0a# Set the name of the replacement function as 4th argument of the Markup() call.%0a%0aIn some cases this will not suffice - it depends on how quoting was done - but in many cases following these simple steps will result in PHP 5.5+ compatibility. %0a%0aIf you try those steps and are still having problems then continue to read below for a deeper understanding.%0a>>%3c%3c%0a%0aThe following is acceptable for PHP 5.5+ (compatible with PmWiki 2.2.58+, will also work in PHP 5.4 and older)%0a* @@Markup($name, $when, $pattern, $replace)@@; %0a** @@$pattern@@ can no longer have an "@@/e@@" modifier%0a** @@$replace@@ can be a function name (callback) which will be called with the array of matches as argument%0a** instead of a string, the fourth parameter can be a definition of an anonymous function (note you can use anon functions this way since [[http://php.net/manual/en/functions.anonymous.php | PHP 5.3.0+]]).%0a%0a* @@Markup_e($name, $when, $pattern, $replace)@@; %25red%25 DEPRECATED, should no longer be used%0a%0aExamples:%0a%0a* For PHP 5.4 and older, this was acceptable:[@%0aMarkup('randomargs', 'directives',%0a '/\\(:random (\\d+) (\\d+):\\)/e',%0a "rand('$1', '$2')"%0a );@]%0a%0a* For PHP 5.5 and newer, $replace is callback, we call Markup():[@%0aMarkup('randomargs', 'directives',%0a '/\\(:random (\\d+) (\\d+):\\)/',%0a "MyRandom"%0a );%0afunction MyRandom($m) { # $m = matches%0a return rand($m[1], $m[2]); # note "return" is used, unlike before%0a@]%0a %25note%25 This will also work in PHP 5.4 and older%25%25%0a%0aOther example:%0a* PHP 5.4 or older: [@%0aMarkup('Maxi:','%3clinks',%0a "/\\b([Mm]axi:)([^\\s\"\\|\\[\\]]+)(\"([^\"]*)\")?/e",%0a "Keep(LinkMaxi(\$pagename,'$1','$2','$4','$1$2'),'L')"%0a );%0a@]%0a%0a* PHP 5.5 or newer, PmWiki 2.2.58+, $replace is a function name: [@%0aMarkup('Maxi:','%3clinks',%0a "/\\b([Mm]axi:)([^\\s\"\\|\\[\\]]+)(\"([^\"]*)\")?/",%0a "LinkMaxi"%0a );%0afunction LinkMaxi($m) {%0a extract($GLOBALS['MarkupToHTML']); # to get $pagename%0a # do stuff with $m[1], $m[2], etc.%0a return Keep($out, 'L');%0a}%0a@]%0a %25note%25 This will also work in PHP 5.4 and older%25%25%0a%0a* $replace can also be a callback function, we call Markup(): [@%0aMarkup('Maxi:','%3clinks',%0a "/\\b([Mm]axi:)([^\\s\"\\|\\[\\]]+)(\"([^\"]*)\")?/",%0a "CallbackMaxi"%0a);%0afunction CallbackMaxi($m) {%0a extract($GLOBALS["MarkupToHTML"]); # to get $pagename%0a return Keep(LinkMaxi($pagename,$m[1],$m[2],$m[4],$m[1].$m[2]),'L');%0a}%0a@]%0a %25note%25 This will also work in PHP 5.4 and older%25%25%0a%0aThe above may seem complicated, but it is actually simpler to use your own callback function:%0a>>frame%3c%3c[@%0aMarkup('mykey', 'directives', %0a '/\\(:mydirective (.*?) (.*?):\\)/i',%0a 'MyFunction'%0a);%0afunction MyFunction($m) {%0a extract($GLOBALS["MarkupToHTML"]);%0a%0a # ... do stuff with $m (the matches), drop PSS() ...%0a%0a return $out; # or return Keep($html);%0a}%0a@]%0a>>%3c%3c%0a%0aIf you have any questions about the new way to define custom markup, you can ask us [[PmWiki:CustomMarkup-Talk|at the talk page]] or on the [[PmWiki/mailing lists]].%0a%0a%0a!!FAQ%0a>>faq%3c%3c [[#faq]]%0aQ: How can I embed JavaScript into a page's output?%0aA: There are several ways to do this. The [[Cookbook:JavaScript]] recipe describes a simple means for embedding static JavaScript into web pages using [[custom markup]]. For editing JavaScript directly in wiki pages (which can pose various security risks), see the [[(Cookbook:)JavaScript-Editable]] recipe. For JavaScript that is to appear in headers or footers of pages, the [[skin(s)]] template can be modified directly, or %3cscript> statements can be inserted using the $HTMLHeaderFmt array.%0a%0aQ: How would I create a markup (''[=(:nodiscussion:)=]'') that will set a page variable (''[={$HideDiscussion}=]'') which can be used by ''[=(:if enabled HideDiscussion:)=]'' in [=.PageActions=]?%0aA: Add the following section of code to your config.php%0a-> [@%0aSDV($HideDiscussion, 0); #define var name%0aMarkup('hideDiscussion', '%3c{$var}',%0a '/\\(:nodiscussion:\\)/', 'setHideDiscussion'); %0afunction setHideDiscussion() { %0a global $HideDiscussion; %0a $HideDiscussion = true;%0a} %0a@]%0a%0aThis will enable the @@[=(:if enabled HideDiscussion:)=]@@ markup to be used. If you want to print the current value of [={$HideDiscussion}=] (for testing purposes) on the page, you'll also need to add the line: \\%0a@@[=$FmtPV['$HideDiscussion'] = '$GLOBALS["HideDiscussion"]';=]@@%0a%0a%0aQ: It appears that (.*?) does not match newlines in these functions, making the above example inoperable if the text to be wrappen in %3cem> contains new lines.%0aA: If you include the "s" modifier on the regular expression then the dot (.) will match newlines. Thus your regular expression will be "/STUFF(.*?)/s". That s at the very end is what you are looking for. If you start getting into multi-line regexes you may be forced to look at the m option as well - let's anchors (^ and $) match not begin/end of strings but also begin/end of lines (i.e., right before/after a newline). Also make sure your markup is executed during the fulltext phase.%0a %0aQ: How can the text returned by my markup function be re-processed by the markup engine?%0aA: If the result of your markup contains more markup that should be processed, you have two options. First is to select a "when" argument that is processed earlier than the markup in your result. For example, if your markup may return [=[[links]]=], your "when" argument could be @@"%3clinks"@@ and your markup will be processed before the links markup. The second option is to call the PRR() function in your markup definition or inside your markup function. In this case, after your markup is processed, PmWiki will restart all markups from the beginning. %0a%0aQ: How do I get started writing recipes and creating my own custom markup?%0aA: [[PmWiki:CustomMarkupAlt|(alternate) Introduction to custom markup for Beginners]]%0a%0aQ: How do I make a rule that runs once at the end of all other rule processing?%0aA: Use this statement instead of the usual @@Markup()@@ call:%0a-->@@$MarkupFrameBase['posteval']['myfooter'] = "\$out = onetimerule(\$out);";@@ -time=1567166609 +rev=195 +targets=PmWiki.PageTextVariables,PmWiki.Links,PmWiki.CustomMarkup,PmWiki.DebugVariables,Cookbook.Cookbook,PmWiki.LocalCustomizations,Cookbook.ParseArgs,PmWiki.ReleaseNotes,PmWiki.Functions,PmWiki.BasicVariables,PmWiki.CustomMarkup-Talk,PmWiki.MailingLists,Cookbook.JavaScript,Cookbook.JavaScript-Editable,PmWiki.Skins,PmWiki.LayoutVariables,PmWiki.CustomMarkupAlt,Category.Markup,!Markup +text=(:Summary: Using the Markup() function for custom wiki syntax; migration to PHP 5.5:)%0a(:Audience: administrators (intermediate) :)%0a%0aPmWiki's markup translation engine is handled by a set of rules; each rule searches for a specific pattern in the markup text and replaces it with some replacement text. Internally, this is accomplished by using PHP's "[[https://www.php.net/manual/en/function.preg-replace.php | preg_replace]]" function.%0a%0a!! Introduction%0aRules are added to the translation engine via PmWiki's %25hlt php%25@@Markup()@@ function, which looks like%0a->%25hlt php%25[@Markup($name, $when, $pattern, $replace); # if no evaluation is needed, or if PHP %3c 5.5@]%0a->%25hlt php%25@@Markup($name, $when, $pattern, $replace_function); # if evaluation is needed@@'%0a'^#^' DEPRECATED, will not work as of PHP 7.2%0a->@@{-Markup_e($name, $when, $pattern, $replace); # if evaluation is needed and 5.5%3c=PHP%3c=7.1-}@@%0a%0a* [@$name@] is a unique name (a string) given to the rule%0a* [@$when@] says when the rule should be applied relative to other rules%0a* [@$pattern@] is the pattern to be searched for in the markup text%0a* [@$replace@] is the text or HTML that should replace the matched pattern.%0a* [@$replace_function@] is the name of the function which should be called with the match, and should return the replacement.%0a%0aFor example, here's the code that creates the rule for [@''emphasized text''@] (in ''scripts/stdmarkup.php''):%0a->%25hlt php%25[@Markup("em", "inline", "/''(.*?)''/", "%3cem>$1%3c/em>");@]%0a%0aBasically this statement says to create a rule called "em" to be performed with the other "inline" markups, and the rule replaces any text inside two pairs of single quotes with the same text ($1) surrounded by %25hlt html%25[@%3cem>@] and [@%3c/em>@].%0a%0a!!! Sequence in which rules are applied%0aThe first two parameters to %25hlt php%25@@Markup()@@ are used to specify the sequence in which rules should be applied. The first parameter provides a name for a rule -- "[@em@]" in the example above. We could've chosen other names such as "[@''@]", or even "[@twosinglequotes@]". In general PmWiki uses the markup itself to name the rule (i.e., PmWiki uses "[@''@]" instead of "[@em@]"), but to keep this example easier to read later on we'll use a mnemonic name for now.%0a%0aThe second parameter says that this rule is to be done along with the other "inline" markups. PmWiki divides the translation process into a number of phases:%0a%0a _begin start of translation%0a [={$var}=] [[Page Text Variables]] happen here.%0a fulltext translations to be performed on the full text %0a split conversion of the full markup text into lines to be processed%0a directives directive processing%0a inline inline markups%0a links conversion of [[links]], url-links, and WikiWords %0a block block markups%0a style style handling %0a _end end of translation%0a%0a%0aThis argument is normally specified as a left-angle bracket "%3c" ("before") or a right-angle bracket ">" ("after") followed by the name of another rule. %0a%0aThus, specifying "inline" for the second parameter says that this rule should be applied when the other "inline" rules are being performed. If we want a rule to be performed with the directives -- i.e., before inline rules are processed, we would specify "directives" or "%3cinline" for the second parameter.%0a%0a!!!! [={$var}=] and [=(:if ...:)=] conditionals%0aA significant rule in terms of ordering is "[@{$var}@]" which substitutes variables -- if you say "[@%3c{$var}@]" then your markup will be processed before variables are substituted whereas if you say ">[={$var}=]" then your markup will be processed after variables are substituted. This happens before conditional %25pmhlt%25[@(:if...:)@] expressions, which is why page text variables are processed even if they are defined inside [@(:if false:)@].%0a%0a!!! Markup regular expression definition%0aThe third parameter is a Perl-compatible regular expression. Basically, it is a slash, a [[regular expression -> https://www.php.net/manual/en/reference.pcre.pattern.syntax.php]], another slash, and a set of optional [[modifiers -> https://www.php.net/manual/en/reference.pcre.pattern.modifiers.php]].%0a%0aThe example uses the pattern string [@"/''(.*?)''/"@], which uses [@''(.*?)''@] as the regular expression and no options. (The regular expression says "find two single quotes in succession, then as few arbitrary characters as are needed to make the match find something, then two additional single quotes in succession"; the parentheses "capture" a part of the wikitext for later use.)%0a%0a!!! Replacement text%0aThe fourth parameter is the replacement text that should be inserted instead of the marked-up wikitext. You can use [@$1@], [@$2@], etc. to insert the text from the first, second etc. parenthesised part of the regular expression.%0a%0aIn the example, we have %25hlt html%25[@"%3cem>$1%3c/em>"@], which is an [@%3cem>@], the text matched by the first parentheses (i.e. by the [@.*?@] section of the pattern), and [@%3c/em>@].%0a%0aHere's a rule for %25pmhlt%25[@@@monospaced@@@] text:%0a%0a->%25hlt php%25[@Markup("@@", "inline", "/@@(.*?)@@/", "%3ccode>$1%3c/code>");@]%0a%0aand for a [@[:comment ...:]@] directive that is simply removed from the output:%0a%0a->%25hlt php%25[@Markup("comment", "directives", "/\\[:comment .*?:\\]/", '');@]%0a%0aOkay, now how about the rule for %25pmhlt%25[@'''strong emphasis'''@]? We have to be a bit careful here, because although this translation should be performed along with other inline markup, we also have to make sure that the rule for [@'''@] is handled ''before'' the rule for [@''@], because [@'''@] also contains [@''@]. The second parameter to %25hlt php%25@@Markup()@@ can be used to specify the new rule's relationship to any other rule:%0a%0a->%25hlt php%25[@Markup("strong", "%3cem", "/'''(.*?)'''/", "%3cstrong>$1%3c/strong>");@]%0a%0aThis creates a rule called "strong", and the second parameter "%3cem" says to be sure that this rule is processed before the "em" rule we defined above. If we wanted to do something after the "em" rule, we would use ">em" instead. Thus, it's possible to add rules at any point in PmWiki's markup translation process in an extensible manner. (In fact, the "inline", "block", "directives", etc., phases above are just placeholder rules used to provide an overall sequence for other rules. Thus one can use "%3cinline" to specify rules that should be handled before any other inline rules.) %0a%0aIf you want to disable available markup just call e.g.:%0a%0a->%25hlt php%25[@DisableMarkup("strong");@]%0a%0aPmWiki's default markup rules are defined in the ''scripts/stdmarkup.php'' file. To see the entire translation table as the program is running, the scripts/diag.php module adds "[@?action=ruleset@]", which displays the set of defined markup rules in the sequence in which they will be processed. You can see it at [[CustomMarkup?action=ruleset | CustomMarkup?action=ruleset]]. You must first enable the action by setting $EnableDiag = 1 in your configuration file.%0a%0a!! @@%3c:vspace>@@ and @@%3c:block>@@%0a@@%3c:vspace>@@ is inserted into the page text very early in page text processing to preserve an empty line (i.e. two newlines in a row). Very late in processing HTML is inserted into the page output to preserve the empty lines.%0aUnless markup processing detects this it can be ignored.%0a%0a@@%3c:block>@@\\%0aAt the start of a line, @@%3c:block>@@ means "start a block-level element",%0ai.e. break out of the paragraphs.%0a%0aSay you have these markups:%0a* (:abc:) returns 'ABC'%0a* (:def:) returns '%3c:block>DEF'%0a%0aThis wiki text:%0a Some text%0a (:abc:)%0a some other text%0a%0awill produce this HTML (simplified):%0a %3cp>Some text%0a ABC%0a some other text%3c/p>%0a%0aWhile this wiki text:%0a Some text%0a (:def:)%0a some other text%0a%0awill produce this HTML (simplified):%0a %3cp>Some text%3c/p>%0a DEF%0a %3cp>some other text%3c/p>%0a%0aThis is intended for a markup rule to return a block level element like%0a%3cdiv>...%3c/div> that is not allowed inside an HTML paragraph.%0a%0a!! Other common examples%0a!!! Define a custom markup to produce a specific HTML or Javascript sequence%0a%0aSuppose an admin wants to have a simple "[@(:example:)@]" markup that will always produce a fixed HTML string in the output, such as for a webring, Google AdSense display, or Javascript. The %25hlt php%25@@Markup()@@ call to do this would be:%0a-> %25hlt php%25[@%0aMarkup('example', 'directives',%0a '/\\(:example:\\)/',%0a Keep("%3cdiv class='example'>%3cp>Here is a %0a %3ca target='_blank' href='https://www.example.com'>link%3c/a> to%0a %3cem>example.com%3c/em>%3c/p>%3c/div>") );%0a@]%0a%0a* The first argument is a unique name for the markup ("example").%0a* The second argument says to perform this markup along with other directives.%0a* The third argument is the pattern to look for "(:example:)".%0a* The fourth argument is the HTML that "(:example:)" is to be replaced with. We use the %25hlt php%25@@Keep()@@ function here to prevent the output from being further processed by PmWiki's markup rule -- in the above example, we don't want the https://www.example.com url to be again converted to a link.%0a%0a[[#random]]%0a!!! Define a markup to call a custom function that returns content%0a%0a->%25red%25 The /e modifier has been deprecated and should not be used in ongoing development. See [[#php55|below]] for more details.%25%25%0a%0aFor older PHP versions (%3c 7.2) an 'e' option on the [@$pattern@] parameter causes the [@$replace@] parameter to be treated as a PHP expression to be evaluated instead of replacement text. To avoid using the deprecated e/ parameter, a markup to produce a random number between 1 and 100 might now look like:%0a-> %25hlt php%25[@%0aMarkup('random', 'directives',%0a '/\\(:random:\\)/',%0a "MyRandomFunction");%0afunction MyRandomFunction() {%0a return rand(1, 100);%0a}%0a@]%0a%0aThis calls the PHP built-in %25hlt php%25@@rand()@@ function and substitutes the directive with the result. Any function can be called, including functions defined in a [[local customization(s)]] file or in [[Cookbook:Cookbook|Cookbook]] recipes.%0a%0aArguments can also be passed by using regular expression capturing parentheses, thus%0a-> %25hlt php%25[@%0aMarkup('randomargs', 'directives',%0a '/\\(:random (\\d+) (\\d+):\\)/',%0a "MyRandomFunction");%0afunction MyRandomFunction($m) {%0a return rand($m[1], $m[2]);%0a}%0a@]%0a%0awill cause the markup %25pmhlt%25[@(:random 50 100:)@] to generate a random number between 50 and 100.%0a%0a->%25note%25 Note: the /e modifier in regular expressions is deprecated since PHP version 5.5, and removed since PHP version 7. The reason for this is, that malicious authors could pass strings that could cause arbitrary and undesirable PHP functions to be executed.%0a%0aFor a PmWiki function to help with parsing arbitrary sequences of arguments and key=value pairs, see Cookbook:ParseArgs.%0a%0a[[#php55]]%0a!! Migration to PHP 5.5 and @@Markup_e()@@%0aSince PHP version 5.5, the @@/e@@ evaluation modifier is deprecated and some hosting providers don't allow its use.%0a%0aRecent [[ReleaseNotes | versions]] of the PmWiki core (2.2.58 and newer) allow new ways to define markup rules without being dependent on the @@/e@@ eval modifier. The historical ways to define markup rules are not removed and work, but may be incompatible with PHP 5.5 installations.%0a%0a''Note: whether your replacement pattern needs evaluation or not, you must use %25hlt php%25@@Markup()@@%25%25 and %25red%25not @@Markup_e()@@.%25%25'' The latter is deprecated and should no longer be used for new recipes and customizations, and old recipes using @@Markup_e@@ should be upgraded to the new format.%0a%0aThe examples below all require PmWiki 2.2.58 (2013-12-25) or newer but the latest version is recommended.%0a%0a>>frame%3c%3c%0aTHE SHORT ANSWER: If your markup regular expression (the 3rd argument) contains an "e" after the closing slash (i.e., @@/regex/e@@ or @@/regex/se@@ or etc) AND your 4th argument is entirely surrounded with double-quotes then you may be able to get away with simply following these simple steps:%0a%0a# Delete the "e" from after the closing slash in the 3rd argument%0a# Create a new replacement function with $m as argument.%0a# In your function, the previous occurrences of '$1', '$2', etc. are now found as $m[1], $m[2], etc. You should no longer call @@[[Functions#PSS|PSS()]]@@.%0a# In your function, call %25hlt php%25@@extract($GLOBALS['MarkupToHTML']);@@ in order to get the current $pagename and @@$markupid@@.%0a# Your function needs to '''return''' the result from the markup processing, either html or another markup.%0a# Set the name of the replacement function as 4th argument of the Markup() call.%0a%0aIn some cases this will not suffice - it depends on how quoting was done - but in many cases following these simple steps will result in PHP 5.5+ compatibility. %0a%0aIf you try those steps and are still having problems then continue to read below for a deeper understanding.%0a>>%3c%3c%0a%0aThe following is acceptable for PHP 5.5+ (compatible with PmWiki 2.2.58+, will also work in PHP 5.4 and older)%0a* %25hlt php%25@@Markup($name, $when, $pattern, $replace)@@; %0a** @@$pattern@@ can no longer have an "@@/e@@" modifier%0a** @@$replace@@ can be a function name (callback) which will be called with the array of matches as argument%0a** instead of a string, the fourth parameter can be a definition of an anonymous function (note you can use anon functions this way since [[https://www.php.net/manual/en/functions.anonymous.php | PHP 5.3.0+]]).%0a%0a* @@Markup_e($name, $when, $pattern, $replace)@@; %25red%25 DEPRECATED, should no longer be used%0a%0aExamples:%0a%0a* For PHP 5.4 and older, this was acceptable:%25hlt php%25[@%0aMarkup('randomargs', 'directives',%0a '/\\(:random (\\d+) (\\d+):\\)/e',%0a "rand('$1', '$2')"%0a );@]%0a%0a* For PHP 5.5 and newer, $replace is callback, we call %25hlt php%25@@Markup()@@:[@%0aMarkup('randomargs', 'directives',%0a '/\\(:random (\\d+) (\\d+):\\)/',%0a "MyRandom"%0a );%0afunction MyRandom($m) { # $m = matches%0a return rand($m[1], $m[2]); # note "return" is used, unlike before%0a}%0a@]%0a %25note%25 This will also work in PHP 5.4 and older%25%25%0a%0aOther example:%0a* PHP 5.4 or older: %25hlt php%25[@%0aMarkup('Maxi:','%3clinks',%0a "/\\b([Mm]axi:)([^\\s\"\\|\\[\\]]+)(\"([^\"]*)\")?/e",%0a "Keep(LinkMaxi(\$pagename,'$1','$2','$4','$1$2'),'L')"%0a );%0a@]%0a%0a* PHP 5.5 or newer, PmWiki 2.2.58+, $replace is a function name: %25hlt php%25[@%0aMarkup('Maxi:','%3clinks',%0a "/\\b([Mm]axi:)([^\\s\"\\|\\[\\]]+)(\"([^\"]*)\")?/",%0a "LinkMaxi"%0a );%0afunction LinkMaxi($m) {%0a extract($GLOBALS['MarkupToHTML']); # to get $pagename%0a # do stuff with $m[1], $m[2], etc.%0a return Keep($out, 'L');%0a}%0a@]%0a %25note%25 This will also work in PHP 5.4 and older%25%25%0a%0a* $replace can also be a callback function, we call %25hlt php%25@@Markup()@@: [@%0aMarkup('Maxi:','%3clinks',%0a "/\\b([Mm]axi:)([^\\s\"\\|\\[\\]]+)(\"([^\"]*)\")?/",%0a "CallbackMaxi"%0a);%0afunction CallbackMaxi($m) {%0a extract($GLOBALS["MarkupToHTML"]); # to get $pagename%0a return Keep(LinkMaxi($pagename,$m[1],$m[2],$m[4],$m[1].$m[2]),'L');%0a}%0a@]%0a %25note%25 This will also work in PHP 5.4 and older%25%25%0a%0aThe above may seem complicated, but it is actually simpler to use your own callback function:%0a-> %25hlt php%25[@%0aMarkup('mykey', 'directives', %0a '/\\(:mydirective (.*?) (.*?):\\)/i',%0a 'MyFunction'%0a);%0afunction MyFunction($m) {%0a extract($GLOBALS["MarkupToHTML"]);%0a%0a # ... do stuff with $m (the matches), drop PSS() ...%0a%0a return $out; # or return Keep($html);%0a}%0a@]%0a%0aIf you have any questions about the new way to define custom markup, you can ask us [[PmWiki:CustomMarkup-Talk|at the talk page]] or on the [[PmWiki/mailing lists]].%0a%0a%0a!!FAQ%0a>>faq%3c%3c [[#faq]]%0aQ: How can I embed JavaScript into a page's output?%0aA: There are several ways to do this. The [[Cookbook:JavaScript]] recipe describes a simple means for embedding static JavaScript into web pages using [[custom markup]]. For editing JavaScript directly in wiki pages (which can pose various security risks), see the [[(Cookbook:)JavaScript-Editable]] recipe. For JavaScript that is to appear in headers or footers of pages, the [[skin(s)]] template can be modified directly, or %3cscript> statements can be inserted using the $HTMLHeaderFmt array.%0a%0aQ: How would I create a markup %25pmhlt%25(''[@(:nodiscussion:)@]'') that will set a page variable (''[@{$HideDiscussion}@]'') which can be used by ''[@(:if enabled HideDiscussion:)@]'' in [=.PageActions=]?%0aA: Add the following section of code to your @@config.php@@%0a-> %25hlt php%25[@%0aSDV($HideDiscussion, 0); #define var name%0aMarkup('hideDiscussion', '%3c{$var}',%0a '/\\(:nodiscussion:\\)/', 'setHideDiscussion'); %0afunction setHideDiscussion() { %0a global $HideDiscussion; %0a $HideDiscussion = true;%0a} %0a@]%0a%0aThis will enable the %25pmhlt%25@@[=(:if enabled HideDiscussion:)=]@@ markup to be used. If you want to print the current value of [={$HideDiscussion}=] (for testing purposes) on the page, you'll also need to add the line: \\%0a%25hlt php%25@@[=$FmtPV['$HideDiscussion'] = '$GLOBALS["HideDiscussion"]';=]@@%0a%0a%0aQ: It appears that (.*?) does not match newlines in these functions, making the above example inoperable if the text to be wrappen in %3cem> contains new lines.%0aA: If you include the "s" modifier on the regular expression then the dot (.) will match newlines. Thus your regular expression will be "/STUFF(.*?)/s". That s at the very end is what you are looking for. If you start getting into multi-line regexes you may be forced to look at the m option as well - let's anchors (^ and $) match not begin/end of strings but also begin/end of lines (i.e., right before/after a newline). Also make sure your markup is executed during the fulltext phase.%0a %0aQ: [[#PRR]] How can the text returned by my markup function be re-processed by the markup engine? %0aA: If the result of your markup contains more markup that should be processed, you have two options. First is to select a "when" argument that is processed earlier than the markup in your result. For example, if your markup may return [=[[links]]=], your "when" argument could be @@"%3clinks"@@ and your markup will be processed before the links markup. The second option is to call the %25hlt php%25@@PRR()@@ function in your markup definition or inside your markup function. In this case, after your markup is processed, PmWiki will restart all markups from the beginning. %0a%0aQ: How do I get started writing recipes and creating my own custom markup?%0aA: [[PmWiki:CustomMarkupAlt|(alternate) Introduction to custom markup for Beginners]]%0a%0aQ: How do I make a rule that runs once at the end of all other rule processing?%0aA: Use this statement instead of the usual %25hlt php%25@@Markup()@@ call:%0a-->%25hlt php%25@@$MarkupFrameBase['posteval']['myfooter'] = "\$out = onetimerule(\$out);";@@%0a%0aCategory: [[!Markup]] +time=1671245949 blob - aa401b513d84c067173aa5cf28f0d6395289156b blob + d11a8d5fa74ec3550b9f335bc51a0cdfe220e906 --- wikilib.d/PmWiki.CustomWikiStyles +++ wikilib.d/PmWiki.CustomWikiStyles @@ -1,9 +1,9 @@ -version=pmwiki-2.2.118 ordered=1 urlencoded=1 -author=Petko +version=pmwiki-2.3.7 ordered=1 urlencoded=1 +author=simon charset=UTF-8 -csum= +csum=hlt php, pm hlt, hlt css, hlt html (+419) name=PmWiki.CustomWikiStyles -rev=65 +rev=66 targets=PmWiki.WikiStyles,PmWiki.WikiAdministrator,PmWiki.LayoutVariables,Cookbook.Functions,Cookbook.WikiStylesPlus,Cookbook.Callout -text=(:Summary: Predefined PmWiki styles & adding custom wiki styles:)%0a(:Audience: administrators (intermediate) :)%0aThis page describes the predefined [[Wiki Styles]] and how a [[Wiki Administrator]] can define additional [[Wiki Styles]] as a local customization for all pages (in local/config.php) or specific groups (in local/$Group.php).%0a%0aAll predefined [[Wiki Styles]] are setup in the global array $WikiStyle.%0aTo define your own [[Wiki Styles]], add the setting of the correspondent `WikiStyle within the array.%0a%0a[[#predef]]%0a!! Predefined Wiki Styles%0a%0aThe following array-values are set by [@scripts/wikistyles.php@] using the [[Cookbook:Functions#SDV |SDV()-function]] (so you can overwrite them by setting them prior in config.php or farmconfig.php):%0a%0a||class='tabtable'%0a||!markup: ||!definition: ||%0a||[[%3c%3c]]'''text colors:''' ||[-(equivalent to [@%25define=xxxx color=xxxx%25@])-] ||%0a|| [@black@] ||[@$WikiStyle['black']['color'] = 'black';@] ||%0a|| [@white@] ||[@$WikiStyle['white']['color'] = 'white';@] ||%0a|| [@red@] ||[@$WikiStyle['red']['color'] = 'red';@] ||%0a|| [@yellow@] ||[@$WikiStyle['yellow']['color'] = 'yellow';@] ||%0a|| [@blue@] ||[@$WikiStyle['blue']['color'] = 'blue';@] ||%0a|| [@gray@] ||[@$WikiStyle['gray']['color'] = 'gray';@] ||%0a|| [@silver@] ||[@$WikiStyle['silver']['color'] = 'silver';@] ||%0a|| [@maroon@] ||[@$WikiStyle['maroon']['color'] = 'maroon';@] ||%0a|| [@green@] ||[@$WikiStyle['green']['color'] = 'green';@] ||%0a|| [@navy@] ||[@$WikiStyle['navy']['color'] = 'navy';@] ||%0a|| [@purple@] ||[@$WikiStyle['purple']['color'] = 'purple';@] ||%0a||[[%3c%3c]]'''list-styles:''' ||||%0a|| [@decimal@] ||[@$WikiStyle['decimal']['apply'] = 'list';@][[%3c%3c]][@$WikiStyle['decimal']['list-style'] = 'decimal';@] ||%0a|| [@roman@] ||[@$WikiStyle['roman']['apply'] = 'list';@][[%3c%3c]][@$WikiStyle['roman']['list-style'] = 'lower-roman';@] ||%0a|| [@ROMAN@] ||[@$WikiStyle['ROMAN']['apply'] = 'list';@][[%3c%3c]][@$WikiStyle['ROMAN']['list-style'] = 'upper-roman';@] ||%0a|| [@alpha@] ||[@$WikiStyle['alpha']['apply'] = 'list';@][[%3c%3c]][@$WikiStyle['alpha']['list-style'] = 'lower-alpha';@] ||%0a|| [@ALPHA@] ||[@$WikiStyle['ALPHA']['apply'] = 'list';@][[%3c%3c]][@$WikiStyle['ALPHA']['list-style'] = 'upper-alpha';@] ||%0a||[[%3c%3c]]'''special:''' ||||%0a||open links in a new browser-window: ||||%0a|| [@newwin@] ||[@$WikiStyle['newwin']['target'] = '_blank';@] ||%0a||Turns markup into a comment via display:none CSS ||||%0a|| [@comment@] ||[@$WikiStyle['comment']['display'] = 'none';@] ||%0a||[[%3c%3c]]'''wiki styles''' ||||%0a|| [@frame@] ||border:1px solid #cccccc; padding:4px; background-color:#f9f9f9; ||%0a|| [@lfloat@] ||float:left; margin-right:0.5em; ||%0a|| [@rfloat@] ||float:right; margin-left:0.5em; ||%0a|| [@thumb@] ||%0a|| [@lframe@] ||frame lfloat||%0a|| [@rframe@] ||frame rfloat||%0a|| [@cframe@] ||%0a|| [@pre@] ||block white-space:pre ||%0a|| [@sidehead@] ||block class:sidehead ||%0a%0a!!Author-Defined Wiki Styles%0a%0a# The first index of the array defines the style name (e.g. mynewstyle, projectentry etc)%0a# the second index defines the attribute name (e.g. color, background-color, etc.)%0a# the value set defines the attribute value (e.g. red, bold, #00ffcc, etc.)%0a%0a'''Sample:''' If you want to define a (site-wide) style the same as the page style%0a->[@%25define=projectentry color:red%25@]%0ause%0a->[@$WikiStyle['projectentry']['color'] = 'red';@]%0a%0a%0aThe [@$WikiStyle['projectentry']['apply']@] variable may be defined if the wikistyle concerns a particular tag. It may be @@'item' (for li|dt), 'list' (for ul|ol|dl), 'div', 'pre', 'img', 'p'@@ or the combining @@'block' (for p|div|ul|ol|dl|li|dt|pre|h[1-6])@@. Example:%0a%0a [@$WikiStyle['top']['apply'] = 'item';@]%0a [@$WikiStyle['top']['class'] = 'top';@]%0a%0athen a markup%0a [@* %25top%25 An important list-item@]%0awill output%0a [@%3cli class="top">An important list-item%3c/li>@]%0a%0a!! Printer-Friendly Styles%0a%0aIf your custom-styles (in local/config.php) are getting very colorful it might be useful to disable them in print-view. This can be done easily by putting them into a condition.%0a%0a[@if($action!="print") {%0a // your custom-styles%0a}@]%0a%0a%0a!!FAQ%0a>>faq%3c%3c [[#faq]]%0aQ: I tried this but background didn't work, though border and float worked?[@%0a$WikiStyle['vMenu']['background']='#ffffcc' ;%0a$WikiStyle['vMenu']['float']='left' ;%0a$WikiStyle['vMenu']['border']='1px dotted red' ;%0a@]%0a%0aA: Try using [@$WikiStyle['vMenu']['background-color']='#ffffcc';@] -- unlike @@background@@, @@background-color@@ is defined in the $WikiStyleCSS array, which is checked for valid properties.%0a%0a%0aQ: How would I set an image to the left of a paragraph in a WikiStyle? I'd like to provide an icon for paragraphs that are notes, important, warnings, etc.%0a%0aA: See [[(Cookbook:)WikiStylesPlus]] and [[(Cookbook:)Callout]].%0a%0a%0aQ:How can I remove underlining from a link, but make it underlined blue when the mouse hovers?%0a%0aA:Put in pub/css/local.css:%0a .noul a {text-decoration: none;}%0a .noul a:hover {text-decoration: underline; color: blue;}%0a%0aThen use this markup:%0a [@%25noul%25 [[Link]] %25%25@]%0a -time=1567166862 +text=(:Summary: Predefined PmWiki styles & adding custom wiki styles:)%0a(:Audience: administrators (intermediate) :)%0aThis page describes the predefined [[Wiki Styles]] and how a [[Wiki Administrator]] can define additional [[Wiki Styles]] as a local customization for all pages (in @@local/config.php@@) or specific groups (in @@local/$Group.php@@).%0a%0aAll predefined [[Wiki Styles]] are setup in the global array $WikiStyle.%0aTo define your own [[Wiki Styles]], add the setting of the correspondent `WikiStyle within the array.%0a%0a[[#predef]]%0a!! Predefined Wiki Styles%0a%0aThe following array-values are set by [@scripts/wikistyles.php@] using the [[Cookbook:Functions#SDV |SDV()-function]] (so you can overwrite them by setting them prior in @@config.php@@ or @@farmconfig.php@@):%0a%0a||class='tabtable'%0a||!markup: ||!definition: ||%0a||[[%3c%3c]]'''text colors:''' ||(equivalent to %25pmhlt%25[@%25define=xxxx color=xxxx%25@]) ||%0a|| [@black@] ||%25hlt php%25[@$WikiStyle['black']['color'] = 'black';@] ||%0a|| [@white@] ||%25hlt php%25[@$WikiStyle['white']['color'] = 'white';@] ||%0a|| [@red@] ||%25hlt php%25[@$WikiStyle['red']['color'] = 'red';@] ||%0a|| [@yellow@] ||%25hlt php%25[@$WikiStyle['yellow']['color'] = 'yellow';@] ||%0a|| [@blue@] ||%25hlt php%25[@$WikiStyle['blue']['color'] = 'blue';@] ||%0a|| [@gray@] ||%25hlt php%25[@$WikiStyle['gray']['color'] = 'gray';@] ||%0a|| [@silver@] ||%25hlt php%25[@$WikiStyle['silver']['color'] = 'silver';@] ||%0a|| [@maroon@] ||%25hlt php%25[@$WikiStyle['maroon']['color'] = 'maroon';@] ||%0a|| [@green@] ||%25hlt php%25[@$WikiStyle['green']['color'] = 'green';@] ||%0a|| [@navy@] ||%25hlt php%25[@$WikiStyle['navy']['color'] = 'navy';@] ||%0a|| [@purple@] ||%25hlt php%25[@$WikiStyle['purple']['color'] = 'purple';@] ||%0a||[[%3c%3c]]'''list-styles:''' ||||%0a|| [@decimal@] ||%25hlt php%25[@$WikiStyle['decimal']['apply'] = 'list';@][[%3c%3c]][@$WikiStyle['decimal']['list-style'] = 'decimal';@] ||%0a|| [@roman@] ||%25hlt php%25[@$WikiStyle['roman']['apply'] = 'list';@][[%3c%3c]][@$WikiStyle['roman']['list-style'] = 'lower-roman';@] ||%0a|| [@ROMAN@] ||%25hlt php%25[@$WikiStyle['ROMAN']['apply'] = 'list';@][[%3c%3c]][@$WikiStyle['ROMAN']['list-style'] = 'upper-roman';@] ||%0a|| [@alpha@] ||%25hlt php%25[@$WikiStyle['alpha']['apply'] = 'list';@][[%3c%3c]][@$WikiStyle['alpha']['list-style'] = 'lower-alpha';@] ||%0a|| [@ALPHA@] ||%25hlt php%25[@$WikiStyle['ALPHA']['apply'] = 'list';@][[%3c%3c]][@$WikiStyle['ALPHA']['list-style'] = 'upper-alpha';@] ||%0a||[[%3c%3c]]'''special:''' ||||%0a||open links in a new browser-window: ||||%0a|| [@newwin@] ||%25hlt php%25[@$WikiStyle['newwin']['target'] = '_blank';@] ||%0a||Turns markup into a comment via display:none CSS ||||%0a|| [@comment@] ||%25hlt php%25[@$WikiStyle['comment']['display'] = 'none';@] ||%0a||[[%3c%3c]]'''wiki styles''' ||||%0a|| [@frame@] ||%25hlt css%25@@border:1px solid #cccccc; padding:4px; background-color:#f9f9f9;@@ ||%0a|| [@lfloat@] ||%25hlt css%25@@float:left; margin-right:0.5em;@@ ||%0a|| [@rfloat@] ||%25hlt css%25@@float:right; margin-left:0.5em;@@ ||%0a|| [@thumb@] ||%0a|| [@lframe@] ||%25hlt css%25@@frame lfloat@@ ||%0a|| [@rframe@] ||%25hlt css%25@@frame rfloat@@ ||%0a|| [@cframe@] ||%0a|| [@pre@] ||%25hlt css%25@@block white-space:pre@@ ||%0a|| [@sidehead@] ||%25hlt css%25@@block class:sidehead@@ ||%0a%0a!!Author-Defined Wiki Styles%0a%0a# The first index of the array defines the style name (e.g. mynewstyle, projectentry etc)%0a# the second index defines the attribute name (e.g. color, background-color, etc.)%0a# the value set defines the attribute value (e.g. red, bold, #00ffcc, etc.)%0a%0a'''Sample:''' If you want to define a (site-wide) style the same as the page style%0a->%25pmhlt%25[@%25define=projectentry color:red%25@]%0ause%0a->%25hlt php%25[@$WikiStyle['projectentry']['color'] = 'red';@]%0a%0a%0aThe %25hlt php%25[@$WikiStyle['projectentry']['apply']@] variable may be defined if the wikistyle concerns a particular tag. It may be '@@item@@' (for @@li|dt@@), '@@list@@' (for @@ul|ol|dl@@), '@@div@@', '@@pre@@', '@@img@@', '@@p@@' or the combining '@@block@@' (for @@p|div|ul|ol|dl|li|dt|pre|h[1-6]@@). Example:%0a-> %25hlt php%25[@%0a$WikiStyle['top']['apply'] = 'item';%0a$WikiStyle['top']['class'] = 'top';@]%0a%0athen a markup%0a %25pmhlt%25[@* %25top%25 An important list-item@]%0awill output%0a %25hlt html%25[@%3cli class="top">An important list-item%3c/li>@]%0a%0a!! Printer-Friendly Styles%0a%0aIf your custom-styles (in @@local/config.php@@) are getting very colorful it might be useful to disable them in print-view. This can be done easily by putting them into a condition.%0a%0a%25hlt php%25[@if($action!="print") {%0a // your custom-styles%0a}@]%0a%0a%0a!!FAQ%0a>>faq%3c%3c [[#faq]]%0aQ: I tried this but background didn't work, though border and float worked?%0a%25hlt php%25[@$WikiStyle['vMenu']['background']='#ffffcc' ;%0a$WikiStyle['vMenu']['float']='left' ;%0a$WikiStyle['vMenu']['border']='1px dotted red' ;%0a@]%0a%0aA: Try using %25hlt php%25[@$WikiStyle['vMenu']['background-color']='#ffffcc';@] -- unlike @@background@@, @@background-color@@ is defined in the $WikiStyleCSS array, which is checked for valid properties.%0a%0a%0aQ: How would I set an image to the left of a paragraph in a WikiStyle? I'd like to provide an icon for paragraphs that are notes, important, warnings, etc.%0a%0aA: See [[(Cookbook:)WikiStylesPlus]] and [[(Cookbook:)Callout]].%0a%0a%0aQ:How can I remove underlining from a link, but make it underlined blue when the mouse hovers?%0a%0aA:Put in @@pub/css/local.css@@:%0a-> %25hlt css%25[@.noul a {text-decoration: none;}%0a.noul a:hover {text-decoration: underline; color: blue;}@]%0a%0aThen use this markup:%0a %25pmhlt%25[@%25noul%25 [[Link]] %25%25@]%0a +time=1657872988 blob - b8cd30a5cacd955a369cccffdbab01788408bd7b blob + b0bb6a307a5be86a9ff9a682bfb51c847e176bc0 --- wikilib.d/PmWiki.DebugVariables +++ wikilib.d/PmWiki.DebugVariables @@ -1,10 +1,10 @@ -version=pmwiki-2.2.109 ordered=1 urlencoded=1 -author=Petko +version=pmwiki-2.3.9 ordered=1 urlencoded=1 +author=simon charset=UTF-8 -csum=$EnableMarkupDiag +csum=hlt php, hlt html (+58) ctime=1156512549 name=PmWiki.DebugVariables -rev=18 +rev=19 targets=PmWiki.DebugVariables,Cookbook.Stopwatch,PmWiki.AvailableActions,PmWiki.BasicVariables -text=(:Summary:variables useful for debugging:)%0a%0a:$AbortFunction:A custom function name replacing the built-in Abort() function. %0a:$EnableDiag:%0a>>indent%3c%3c%0a(:include AvailableActions#BEGENABLEDIAG#ENDENABLEDIAG:)%0a>>%3c%3c%0a%0a:$EnableMarkupDiag:By default, the "ruleset" action will display all markup rules, and the old-format patterns requiring update for PHP 7 will list with their files and line numbers. Setting $EnableMarkupDiag to 1 will list files and line numbers of all patterns. Note, this needs to be set early in config.php before a Markup() call or before including a recipe.%0a%0a:$EnableIMSCaching:A variable which, when set equal to 1, recognizes the "If-Modified-Since" header coming from browsers and allows browsers to use locally cached pages. Disabled by default to help the administrator customize its page without needing permanent reloading.%0a%0a:$EnableStopWatch:This activates an internal stopwatch that shows how long it takes to render a page. (If you have a wiki that composes a HTML page from multiple pages, such as a normal layout with a sidebar, you'll get separate timings for each subpage and for the total page.)%0a%0a: :The timings can be displayed by adding [@%3c!--function:StopWatchHTML 1-->@] in the wiki template.%0a%0a: :Valid values are:%0a $EnableStopWatch = 0; # No timings (the default). No HTML will be generated.%0a $EnableStopWatch = 1; # Wall-clock timings only.%0a $EnableStopWatch = 2; # Wall-clock and CPU usage timings. Won't work on Windows.%0a%0a: :See [[(Cookbook:)Stopwatch]] for more details.%0a%0aSee also:%0a* [[AvailableActions#refcount|scripts/refcount.php]] is useful for debugging%0a%0a%0a----%0a>>faq%3c%3c[[#faq]]%0aQ:Is it possible for someone with admin priviledges to always have access to debugging tools, without letting everyone else access them?%0aA:You can easily & automatically allow debugging for anyone with admin priviledges (meanwhile leaving it off for everyone else) by including this line in config.php - ''just be sure that 1) $EnableDiag is either null or set to 0, and 2) to include it near the end of config.php, AFTER declaring your passwords, and after any AuthUser or other priviledge settings'':%0a%0a-->@@if (CondAuth($pagename, 'admin')) $EnableDiag = 1; # allows admin to always call phpinfo, etc@@%0a%0a>>%3c%3c%0a -time=1531569167 +text=(:Summary:variables useful for debugging:)%0a%0a:$AbortFunction:A custom function name replacing the built-in %25hlt php%25@@Abort()@@ function. %0a:$EnableDiag:%0a>>indent%3c%3c%0a(:include AvailableActions#BEGENABLEDIAG#ENDENABLEDIAG:)%0a>>%3c%3c%0a%0a:$EnableMarkupDiag:By default, the "ruleset" action will display all markup rules, and the old-format patterns requiring update for PHP 7 will list with their files and line numbers. Setting $EnableMarkupDiag to 1 will list files and line numbers of all patterns. Note, this needs to be set early in @@config.php@@ before a %25hlt php%25@@Markup()@@ call or before including a recipe.%0a%0a:$EnableIMSCaching:A variable which, when set equal to 1, recognizes the "If-Modified-Since" header coming from browsers and allows browsers to use locally cached pages. Disabled by default to help the administrator customize its page without needing permanent reloading.%0a%0a:$EnableStopWatch:This activates an internal stopwatch that shows how long it takes to render a page. (If you have a wiki that composes a HTML page from multiple pages, such as a normal layout with a sidebar, you'll get separate timings for each subpage and for the total page.)%0a%0a: :The timings can be displayed by adding %25hlt html%25[@%3c!--function:StopWatchHTML 1-->@] in the wiki template.%0a%0a: :Valid values are:%0a $EnableStopWatch = 0; # No timings (the default). No HTML will be generated.%0a $EnableStopWatch = 1; # Wall-clock timings only.%0a $EnableStopWatch = 2; # Wall-clock and CPU usage timings. Won't work on Windows.%0a%0a: :See [[(Cookbook:)Stopwatch]] for more details.%0a%0aSee also:%0a* [[AvailableActions#refcount|@@scripts/refcount.php@@]] is useful for debugging%0a%0a%0a----%0a>>faq%3c%3c[[#faq]]%0aQ:Is it possible for someone with admin privileges to always have access to debugging tools, without letting everyone else access them?%0aA:You can easily & automatically allow debugging for anyone with admin privileges (meanwhile leaving it off for everyone else) by including this line in @@config.php@@ - ''just be sure that 1) $EnableDiag is either null or set to 0, and 2) to include it near the end of @@config.php@@, AFTER declaring your passwords, and after any AuthUser or other privilege settings'':%0a%0a-->%25hlt php%25@@if (CondAuth($pagename, 'admin')) $EnableDiag = 1; # allows admin to always call phpinfo, etc@@%0a%0a>>%3c%3c%0a +time=1660940390 blob - c7f21ea654b469bcda34264d91b1a10c5c303286 blob + 94f9e688d74c497b1853a222a27f262e8abdf2f8 --- wikilib.d/PmWiki.DeletingPages +++ wikilib.d/PmWiki.DeletingPages @@ -1,9 +1,9 @@ -version=pmwiki-2.2.54 ordered=1 urlencoded=1 -author=MichaelPaulukonis +version=pmwiki-2.3.7 ordered=1 urlencoded=1 +author=simon charset=UTF-8 -csum=added maintenance tag +csum=pm hlt (+16) name=PmWiki.DeletingPages -rev=37 -targets=PmWiki.WikiAdministrator,Site.AllRecentChanges,PmWiki.EditVariables,Cookbook.DeleteAction,PmWiki.BackupAndRestore,Cookbook.CleanUp,PmWiki.WikiGroup,PmWiki.RecentChanges,Cookbook.RecentChangesDeletion,PmWiki.Categories,Category.Maintenance -text=(:Summary: Removing wiki pages:)%0aTo delete a wiki page, edit the page, select (highlight) all text in the edit textarea, and replace it with the single word%0a%0a->[@delete@]%0a%0aIt is a good idea to add a comment to the @@summary@@ field%0aexplaining why you deleted the page. (The field @@summary@@ is usually found%0ajust below the edit textarea).%0a%0aOn saving the change the page is deleted. As an added safety feature, the deleted page still exists on the server (with a timestamp) and can be restored to the former page by the [[wiki administrator]].%0a%0aIf you suspect that a page has been deleted but aren't sure, have a look at the wikigroup's [=RecentChanges=]. Erasing a page counts as editing the page, and the activity is recorded there and on [[{$SiteGroup}.AllRecentChanges]].%0a%0aThe default word used for page deletion ("delete") can be changed in @@config.php@@ by setting the variable $DeleteKeyPattern (see [[Edit Variables]]). %0aIf there is a danger of malicious page deletion it may be a good idea to change the delete word to something more obscure. %0aThere is also a recipe for creating a separate delete action at Cookbook:DeleteAction.%0a%0a[[#cleanup]]%0a!! Removing deleted pages%0a%0aThe deleted pages are retained in the same @@wiki.d@@ directory in which they were created.%0aThey are renamed with an extension of @@,del-123456789@@ where @@123456789@@ is a unique number (timestamp). %0aA wiki administrator may log into the server via FTP or SSH and periodically remove these files.%0a%0aOne way to remove the files is to delete them. %0aIf you have shell access, you could use different commands, for example, go into the wiki.d directory and type one of these lines:%0a->[@rm -f *,del-*%0afind . -name '*,del-*' -delete@]%0a%0aAlternatively, the Cookbook:CleanUp recipe can purge those unused files. See also [[BackupAndRestore]].%0a%0a%0a>>faq%3c%3c [[#faq]]%0a%0aQ: How is a [[Wiki Group]] deleted?%0aA: An admin can remove the group pages from @@wiki.d/@@. Note that a wiki page may also have related uploads.%0a%0aA: Fully deleting a group via the wiki isn't possible, since a delete counts as an "update" which causes the [[Recent Changes]] page to be re-created.%0aIt is possible to modify the site's configuration to allow deletion of the group's RecentChanges page -- see Cookbook:RecentChangesDeletion.%0a%0aQ: How is a [[Categories|Category]] deleted?%0aA: To delete a category, delete all the [@[[!Category]]@] references from all pages where they occur, then delete the category page as explained above.%0a%0a[[!maintenance]]%0a -time=1377051424 +rev=42 +targets=PmWiki.WikiAdministrator,Site.AllRecentChanges,PmWiki.EditVariables,Cookbook.DeleteAction,PmWiki.BackupAndRestore,Cookbook.CleanUp,PmWiki.WikiGroup,PmWiki.RecentChanges,Cookbook.RecentChangesDeletion,PmWiki.Categories,Category.Maintenance,!Maintenance +text=(:Summary: Removing wiki pages:)%0aTo delete a wiki page, edit the page, select (highlight) all text in the edit textarea, and replace it with the single word%0a%0a->[@delete@]%0a%0aIt is a good idea to add a comment to the edit @@summary@@ field%0aexplaining why you deleted the page. (The field @@summary@@ is usually found%0ajust below the edit textarea).%0a%0aOn saving the change the page is deleted. As an added safety feature, the deleted page still exists on the server (with a timestamp) and can be restored to the former page by the [[wiki administrator]].%0a%0aIf you suspect that a page has been deleted but aren't sure, have a look at the wikigroup's [@RecentChanges@]. Erasing a page counts as editing the page, and the activity is recorded there and on [[{$SiteGroup}.AllRecentChanges]].%0a%0aThe default word used for page deletion ("delete") can be changed in @@config.php@@ by setting the variable $DeleteKeyPattern (see [[Edit Variables]]). %0aIf there is a danger of malicious page deletion it may be a good idea to change the delete word to something more obscure. %0aThere is also a recipe for creating a separate delete action at Cookbook:DeleteAction.%0a%0a[[#cleanup]]%0a!! Removing deleted pages%0a%0aThe deleted pages are retained in the same @@wiki.d@@ directory in which they were created.%0aThey are renamed with an extension of @@,del-123456789@@ where @@123456789@@ is a unique number (timestamp). %0aA wiki administrator may log into the server via FTP or SSH and periodically remove these files.%0a%0aOne way to remove the files is to delete them. %0aIf you have shell access, you could use different commands, for example, go into the wiki.d directory and type one of these lines:%0a->[@rm -f *,del-*%0afind . -name '*,del-*' -delete@]%0a%0aAlternatively, the Cookbook:CleanUp recipe can purge those unused files. See also [[BackupAndRestore]].%0a%0a%0a>>faq%3c%3c [[#faq]]%0a%0aQ: How is a [[Wiki Group]] deleted?%0aA: An admin can remove the group pages from @@wiki.d/@@. Note that a wiki page may also have related uploads.%0a%0aA: Fully deleting a group via the wiki isn't possible, since a delete counts as an "update" which causes the [[Recent Changes]] page to be re-created.%0aIt is possible to modify the site's configuration to allow deletion of the group's @@RecentChanges@@ page -- see Cookbook:RecentChangesDeletion.%0a%0aQ: How is a [[Categories|Category]] deleted?%0aA: To delete a category, delete all the %25pmhlt%25[@[[!Category]]@] references from all pages where they occur, then delete the category page as explained above.%0a%0a[[!maintenance]]%0a +time=1658471226 blob - 00424f08afd52c9552e4f4e573ee40d6a82ebeee blob + 5f523c6e256a593df0b0226b4f89b061d0db47cf --- wikilib.d/PmWiki.DesignNotes +++ wikilib.d/PmWiki.DesignNotes @@ -1,9 +1,9 @@ -version=pmwiki-2.2.36 ordered=1 urlencoded=1 -author=Caroline Guénette +version=pmwiki-2.3.11 ordered=1 urlencoded=1 +author=simon charset=UTF-8 -csum=Add to category "PmWiki Developer" +csum=http+s (+52) name=PmWiki.DesignNotes -rev=27 -targets=PmWiki.PmWikiPhilosophy,PmWiki.MailingLists,PmWiki.FlatFileAdvantages,PmWiki.HierarchicalGroups,PmWiki.PageLocking,PmWiki.SimultaneousEdits,PmWiki.PageFileFormat,PmWiki.SearchImprovements,PmWiki.FilePermissions,PmWiki.WikiGroupMotivation,PmWiki.WYSIWYG,PmWiki.DesignNotes,Category.PmWikiDeveloper -text=(:Summary:Some of the features and notes about PmWiki's design decisions:)%0aHere are some of the features and notes about PmWiki's design decisions. %0aMany of these derive directly from the [[PmWiki Philosophy]] and lots of discussion on the [[mailing lists]].%0a%0a* [[PmWiki:Flat File Advantages]] - why PmWiki uses flat files to store pages instead of an SQL database%0a* [[PmWiki:Hierarchical Groups]] - why PmWiki doesn't support nested groups%0a* [[PmWiki:Page Locking]] - how PmWiki works without locking pages (see also [[simultaneous edits]])%0a* [[PmWiki:Page File Format]] - the format of PmWiki's page files%0a* [[PmWiki:Search Improvements]] - why PmWiki has a native search engine%0a* [[PmWiki:File Permissions]] - some information about PmWiki's file permission settings%0a* [[PmWiki:Wiki Group Motivation]] - why WikiGroups%0a* [[PmWiki:WYSIWYG]] - why not WYSIWYG.%0a%0a>>faq%3c%3c [[#faq]]%0a%0aQ: Why doesn't PmWiki use hierarchical / nested groups?%0aA: It essentially comes down to figuring out how to handle %0apage links between nested groups; if someone can figure out %0aan obvious, intuitive way for authors to%0ado that, then nested groups become plausible. See [[Design Notes]]%0aand [[PmWiki:Hierarchical Groups]].%0a%0aQ: Why don't PmWiki's scripts have a closing ?> tag?%0aA: All of PmWiki's scripts now omit the closing ?> tag. The tag is not%0arequired, and it avoids problems with unnoticed spaces or blank%0alines at the end of the file. Also, some file transfer protocols%0amay change the newline character(s) in the file, which can also%0acause problems. See also the [[http://php.net/manual/en/language.basic-syntax.instruction-separation.php | Instruction separation ]] page in the PHP manual.%0a%0aQ: Does PmWiki support WYSIWYG editing (or something like the FCKEditor)?%0aA: Short answer: PmWiki provides GUI buttons in a toolbar for common markups, but otherwise does not have WYSIWYG editing. For the reasons why, see PmWiki:WYSIWYG.%0a%0aCategories: [[!PmWiki Developer]]%0a%0a -time=1330954338 +rev=29 +targets=PmWiki.PmWikiPhilosophy,PmWiki.MailingLists,PmWiki.FlatFileAdvantages,PmWiki.HierarchicalGroups,PmWiki.PageLocking,PmWiki.SimultaneousEdits,PmWiki.PageFileFormat,PmWiki.SearchImprovements,PmWiki.FilePermissions,PmWiki.WikiGroupMotivation,PmWiki.WYSIWYG,PmWiki.DesignNotes,Cookbook.Worse,Cookbook.PmSyntax,Category.PmWikiDeveloper,!PmWikiDeveloper +text=(:Summary:Some of the features and notes about PmWiki's design decisions:)%0aHere are some of the features and notes about PmWiki's design decisions. %0aMany of these derive directly from the [[PmWiki Philosophy]] and lots of discussion on the [[mailing lists]].%0a%0a* [[PmWiki:Flat File Advantages]] - why PmWiki uses flat files to store pages instead of an SQL database%0a* [[PmWiki:Hierarchical Groups]] - why PmWiki doesn't support nested groups%0a* [[PmWiki:Page Locking]] - how PmWiki works without locking pages (see also [[simultaneous edits]])%0a* [[PmWiki:Page File Format]] - the format of PmWiki's page files%0a* [[PmWiki:Search Improvements]] - why PmWiki has a native search engine%0a* [[PmWiki:File Permissions]] - some information about PmWiki's file permission settings%0a* [[PmWiki:Wiki Group Motivation]] - why WikiGroups%0a* [[PmWiki:WYSIWYG]] - why not WYSIWYG.%0a%0a>>faq%3c%3c [[#faq]]%0a%0aQ: Why doesn't PmWiki use hierarchical / nested groups?%0aA: It essentially comes down to figuring out how to handle %0apage links between nested groups; if someone can figure out %0aan obvious, intuitive way for authors to%0ado that, then nested groups become plausible. See [[Design Notes]]%0aand [[PmWiki:Hierarchical Groups]].%0a%0aQ: Why don't PmWiki's scripts have a closing ?> tag?%0aA: All of PmWiki's scripts now omit the closing ?> tag. The tag is not%0arequired, and it avoids problems with unnoticed spaces or blank%0alines at the end of the file. Also, some file transfer protocols%0amay change the newline character(s) in the file, which can also%0acause problems. See also the [[https://www.php.net/manual/en/language.basic-syntax.instruction-separation.php | Instruction separation ]] page in the PHP manual.%0a%0aQ: Does PmWiki support WYSIWYG editing (or something like the FCKEditor)?%0aA: Short answer: PmWiki provides GUI buttons in a toolbar for common markups, but otherwise does not have WYSIWYG editing. For the reasons why, see PmWiki:WYSIWYG. See also Cookbook:Worse and Cookbook:PmSyntax.%0a%0aCategories: [[!PmWiki Developer]]%0a%0a +time=1663576113 blob - 8859ba306b09f5f4e1e7aff3c1d52537d35bf697 blob + e6a41c8c0a0984e51a120967d36cc1944bc562f8 --- wikilib.d/PmWiki.DocumentationIndex +++ wikilib.d/PmWiki.DocumentationIndex @@ -1,10 +1,10 @@ -version=pmwiki-2.2.118 ordered=1 urlencoded=1 +version=pmwiki-2.2.145 ordered=1 urlencoded=1 author=Petko charset=UTF-8 -csum=rm manual TOC +csum=$EnablePmSyntax (+4) (+187) name=PmWiki.DocumentationIndex -rev=423 -targets=PmWiki.DocumentationIndex,PmWiki.DocumentationGuidelines,PmWiki.Introduction,PmWiki.BasicEditing,PmWiki.CreatingNewPages,PmWiki.Links,PmWiki.Images,PmWiki.TextFormattingRules,PmWiki.MarkupMasterIndex,PmWiki.Uploads,PmWiki.Tables,PmWiki.TableDirectives,PmWiki.TableOfContents,PmWiki.WikiStyles,PmWiki.WikiStyleExamples,PmWiki.AccessKeys,PmWiki.PageDirectives,PmWiki.IncludeOtherPages,PmWiki.InterMap,PmWiki.ConditionalMarkup,PmWiki.PageVariables,PmWiki.PageTextVariables,PmWiki.MarkupExpressions,PmWiki.Forms,PmWiki.SimultaneousEdits,PmWiki.WikiStructure,PmWiki.WikiGroup,PmWiki.GroupHeaders,PmWiki.WikiTrails,PmWiki.PageHistory,PmWiki.Passwords,PmWiki.Categories,PmWiki.PageLists,PmWiki.DeletingPages,PmWiki.WikiElements,PmWiki.SpecialPages,PmWiki.Installation,PmWiki.InitialSetupTasks,PmWiki.Upgrades,PmWiki.BackupAndRestore,PmWiki.UploadsAdmin,PmWiki.Security,PmWiki.CustomMarkup,PmWiki.CustomWikiStyles,PmWiki.Internationalizations,PmWiki.LocalCustomizations,PmWiki.GroupCustomizations,PmWiki.Skins,PmWiki.SkinTemplates,PmWiki.SitePreferences,PmWiki.WebFeeds,PmWiki.WikiFarms,PmWiki.FAQ,PmWiki.AQ,PmWiki.FAQCandidate,PmWiki.Questions,PmWiki.HowToGetAssistance,PmWiki.Troubleshooting,PmWiki.AvailableActions,PmWiki.AuthUser,PmWiki.Blocklist,PmWiki.Notify,PmWiki.PasswordsAdmin,PmWiki.RefCount,PmWiki.UrlApprovals,Cookbook.ModuleGuidelines,PmWiki.Variables,PmWiki.Functions,PmWiki.PageFileFormat,PmWiki.Audiences,PmWiki.Contributors,PmWiki.MailingLists,PmWiki.PmWikiPhilosophy,PmWiki.DesignNotes,PmWiki.ReleaseNotes,PmWiki.ChangeLog,PmWiki.References,PmWiki.Glossary,PmWiki.BasicVariables,PmWiki.EditVariables,PmWiki.FilePermissions,PmWiki.FmtPageName,PmWiki.I18nVariables,PmWiki.LayoutVariables,PmWiki.LinkVariables,PmWiki.OtherVariables,PmWiki.PagelistVariables,PmWiki.PageListTemplates,PmWiki.PathVariables,PmWiki.Requirements,PmWiki.SpecialCharacters,PmWiki.UploadVariables,PmWiki.WikiAdministrator,PmWiki.WikiPage,PmWiki.WikiWikiWeb,PmWiki.WikiWord -text=(:title Documentation Index:)(:Summary: PmWiki documentation index:)%0a%0aThe pages below describe various aspects of [[#using|using]], [[#admin|administering]] and [[#troubleshoot|troubleshooting]] a PmWiki installation, as well as aspects of the [[#misc|PmWiki community]].%0a%0aAs you know, documentation is ''always'' incomplete. %0aFeel free to help yourself and others by contributing to it. %0aJust edit the pages on %25newwin%25[[PmWiki:DocumentationIndex|pmwiki.org]]%25%25. %0aYou might want to follow or contribute to the %25newwin%25[[PmWiki:DocumentationGuidelines | documentation guidelines]]%25%25.%0a----%0a[[#trailstart]]%0a* [[Introduction]] %25item comment%25%0a%0a!! [[#using]] Beginner Topics for Creating and Editing Pages%0a%0a* [[Basic editing]] - {BasicEditing$:Summary}%0a* [[Creating new pages]] - {CreatingNewPages$:Summary}%0a* [[Links]] - {Links$:Summary}%0a* [[Images]] - {Images$:Summary}%0a* [[Text formatting rules]] - {TextFormattingRules$:Summary}%0a%0a!! [[#intermed]] Intermediate Editing Topics%0a* [[Markup master index]] - {MarkupMasterIndex$:Summary}%0a%0a* [[Uploads]] - {Uploads$:Summary}%0a* [[Tables]] - {Tables$:Summary}%0a* [[Table directives]] - {TableDirectives$:Summary}%0a* [[Table of contents]] - {TableOfContents$:Summary}%0a* [[Wiki styles]] - {WikiStyles$:Summary}%0a** [[Wiki style examples]] - {WikiStyleExamples$:Summary}%0a%0a* [[Access keys]] - {AccessKeys$:Summary}%0a* [[Page directives]] - {PageDirectives$:Summary}%0a* [[Include other pages]] - {IncludeOtherPages$:Summary}%0a* [[InterMap]] links - {InterMap$:Summary}%0a* [[Conditional markup]] - {ConditionalMarkup$:Summary}%0a* [[Page variables]] - {PageVariables$:Summary}%0a* [[Page text variables]] - {PageTextVariables$:Summary}%0a* [[Markup expressions]] - {MarkupExpressions$:Summary}%0a* [[Forms]] - {Forms$:Summary}%0a%0a* [[Simultaneous edits]] - {SimultaneousEdits$:Summary}%0a%0a!! [[#struct]] Organizing and Protecting Pages%0a* [[Wiki structure]] - {WikiStructure$:Summary}%0a* [[Wiki group]]s - {WikiGroup$:Summary}%0a* [[Group headers]] - {GroupHeaders$:Summary}%0a* [[Wiki trails]] - {WikiTrails$:Summary}%0a* [[Page history]] - {PageHistory$:Summary}%0a%0a* [[Passwords]] - {Passwords$:Summary}%0a* [[Categories]] - {Categories$:Summary}%0a* [[Page lists]] - {PageLists$:Summary}%0a* %25%25 [[PageDirectives#attachlist|Attach lists]] - Get a list of files uploaded and attached to a group using [=(:attachlist:)=] [-({PageDirectives$:Summary})-]%0a* [[Deleting pages]] - {DeletingPages$:Summary}%0a* [[(PmWiki:)Wiki elements]] - {WikiElements$:Summary}%0a* [[(PmWiki:)Special pages]] - {SpecialPages$:Summary}%0a%0a!! [[#admin]] PmWiki Site Administration%0a!!! [[#install]]Installation and maintenance%0a* [[Installation]] - {Installation$:Summary}%0a* [[Initial setup tasks]] - {InitialSetupTasks$:Summary}%0a* [[Upgrades]] - {Upgrades$:Summary}%0a* [[Backup and Restore]] - {BackupAndRestore$:Summary}%0a* [[Uploads admin]]istration - {UploadsAdmin$:Summary}%0a* [[Security]] - {PmWiki/Security$:Summary}%0a%0a!!! [[#customise]] Customisation%0a* [[Custom markup]] - {CustomMarkup$:Summary}%0a* [[Custom wiki styles]] - {CustomWikiStyles$:Summary}%0a* [[Internationalizations]] - {Internationalizations$:Summary}%0a* [[Local customizations]] - {LocalCustomizations$:Summary}%0a* [[Group customizations]] - {GroupCustomizations$:Summary}%0a* [[Skins]] - {Skins$:Summary}%0a* [[Skin templates]] - {SkinTemplates$:Summary}%0a* [[Site Preferences]] - {SitePreferences$:Summary}%0a* [[Web feeds]] - {WebFeeds$:Summary}%0a* [[Wiki Farms]] - {WikiFarms$:Summary}%0a%0a!!! [[#troubleshoot]] Troubleshooting%0a* [[FAQ | Frequently answered questions]]%0a* [[(PmWiki:)AQ | Answers to some other questions]]%0a* [[(PmWiki:)FAQ Candidate]] - more answered questions%0a* [[(PmWiki:)Questions]]%0a* [[(PmWiki:)How to get assistance]]%0a* [[Troubleshooting]] - {Troubleshooting$:Summary}%0a* [[Available actions]] - documentation for developers%0a%0a!!! [[#security]] Security%0a* [[AuthUser]] - {AuthUser$:Summary}%0a* [[Blocklist]] - {Blocklist$:Summary} %0a* [[Notify]] - {Notify$:Summary}%0a* [[Passwords admin]]istration - {PasswordsAdmin$:Summary}%0a* [[Ref count]] - {RefCount$:Summary}%0a* [[Url approvals]] - {UrlApprovals$:Summary}%0a%0a!! [[#development]] Development%0a* [[Cookbook:Module Guidelines]] - Guidelines for creating, distributing, and maintaining a recipe for the Cookbook. %0a* [[Variables]] - {Variables$:Summary}%0a* [[Functions]] - {Functions$:Summary}%0a* [[Page file format]] - {PageFileFormat$:Summary}%0a%0a!! [[#misc]] About PmWiki%0a* [[Audiences]] - {Audiences$:Summary}%0a* [[Contributors]] - {Contributors$:Summary}%0a* [[Mailing lists]] - {MailingLists$:Summary}%0a* [[PmWiki philosophy]] - {PmWikiPhilosophy$:Summary}%0a* [[Design notes]] - {DesignNotes$:Summary}%0a* [[Release notes]] - {PmWiki/ReleaseNotes$:Summary}%0a* [[Change log]] - {PmWiki/ChangeLog$:Summary}%0a%0a* [[(PmWiki:)References]] - References to PmWiki media coverage%0a* [[Glossary]] - {PmWiki/Glossary$:Summary}%0a%0a* [[Introduction]] %25item comment%25 loop trail%0a[[#trailend]]%0a%0a>>comment%3c%3c%0aNote: The following pages are listed here so that they can include a #faq section and have the questions appear on the FAQ page. %0a%0aThe problem is that these pages become part of the trail %0a%0a* [[Basic Variables]]%0a* [[Edit Variables]]%0a* [[File Permissions]]%0a* [[Fmt Page Name]]%0a* [[I18n Variables]]%0a* [[Layout Variables]]%0a* [[Link Variables]]%0a* [[Other Variables]]%0a* [[Pagelist Variables]]%0a* [[PageList Templates]]%0a* [[Path Variables]]%0a* [[Requirements]]%0a* [[Skin Templates]]%0a* [[Special Characters]]%0a* [[Upload Variables]]%0a* [[Wiki Administrator]]%0a* [[Wiki Page]]%0a* [[Wiki Wiki Web]]%0a* [[Wiki Word]] -time=1567159802 +rev=425 +targets=PmWiki.DocumentationIndex,PmWiki.DocumentationGuidelines,PmWiki.LayoutVariables,PmWiki.Introduction,PmWiki.BasicEditing,PmWiki.CreatingNewPages,PmWiki.Links,PmWiki.Images,PmWiki.TextFormattingRules,PmWiki.MarkupMasterIndex,PmWiki.Uploads,PmWiki.Tables,PmWiki.TableDirectives,PmWiki.TableOfContents,PmWiki.WikiStyles,PmWiki.WikiStyleExamples,PmWiki.AccessKeys,PmWiki.PageDirectives,PmWiki.IncludeOtherPages,PmWiki.InterMap,PmWiki.ConditionalMarkup,PmWiki.PageVariables,PmWiki.PageTextVariables,PmWiki.MarkupExpressions,PmWiki.Forms,PmWiki.SimultaneousEdits,PmWiki.WikiStructure,PmWiki.WikiGroup,PmWiki.GroupHeaders,PmWiki.WikiTrails,PmWiki.PageHistory,PmWiki.Passwords,PmWiki.Categories,PmWiki.PageLists,PmWiki.DeletingPages,PmWiki.WikiElements,PmWiki.SpecialPages,PmWiki.Installation,PmWiki.InitialSetupTasks,PmWiki.Upgrades,PmWiki.BackupAndRestore,PmWiki.UploadsAdmin,PmWiki.Security,PmWiki.CustomMarkup,PmWiki.CustomWikiStyles,PmWiki.Internationalizations,PmWiki.LocalCustomizations,PmWiki.GroupCustomizations,PmWiki.Skins,PmWiki.SkinTemplates,PmWiki.SitePreferences,PmWiki.WebFeeds,PmWiki.WikiFarms,PmWiki.FAQ,PmWiki.AQ,PmWiki.FAQCandidate,PmWiki.Questions,PmWiki.HowToGetAssistance,PmWiki.Troubleshooting,PmWiki.AvailableActions,PmWiki.AuthUser,PmWiki.Blocklist,PmWiki.Notify,PmWiki.PasswordsAdmin,PmWiki.RefCount,PmWiki.UrlApprovals,Cookbook.ModuleGuidelines,PmWiki.Variables,PmWiki.Functions,PmWiki.PageFileFormat,PmWiki.Audiences,PmWiki.Contributors,PmWiki.MailingLists,PmWiki.PmWikiPhilosophy,PmWiki.DesignNotes,PmWiki.ReleaseNotes,PmWiki.ChangeLog,PmWiki.References,PmWiki.Glossary,PmWiki.BasicVariables,PmWiki.EditVariables,PmWiki.FilePermissions,PmWiki.FmtPageName,PmWiki.I18nVariables,PmWiki.LinkVariables,PmWiki.OtherVariables,PmWiki.PagelistVariables,PmWiki.PageListTemplates,PmWiki.PathVariables,PmWiki.Requirements,PmWiki.SpecialCharacters,PmWiki.UploadVariables,PmWiki.WikiAdministrator,PmWiki.WikiPage,PmWiki.WikiWikiWeb,PmWiki.WikiWord +text=(:title Documentation Index:)(:Summary: PmWiki documentation index:)%0a%0aThe pages below describe various aspects of [[#using|using]], [[#admin|administering]] and [[#troubleshoot|troubleshooting]] a PmWiki installation, as well as aspects of the [[#misc|PmWiki community]].%0a%0aAs you know, documentation is ''always'' incomplete. %0aFeel free to help yourself and others by contributing to it. %0aJust edit the pages on %25newwin%25[[PmWiki:DocumentationIndex|pmwiki.org]]%25%25. %0aYou might want to follow or contribute to the %25newwin%25[[PmWiki:DocumentationGuidelines | documentation guidelines]]%25%25.%0a%0a''PmWiki versions 2.3.x have a function which can highlight the syntax of the markup language and make the documentation easier to read. See $EnablePmSyntax if you want to enable it.''%0a%0a----%0a[[#trailstart]]%0a* [[Introduction]] %25item comment%25%0a%0a!! [[#using]] Beginner Topics for Creating and Editing Pages%0a%0a* [[Basic editing]] - {BasicEditing$:Summary}%0a* [[Creating new pages]] - {CreatingNewPages$:Summary}%0a* [[Links]] - {Links$:Summary}%0a* [[Images]] - {Images$:Summary}%0a* [[Text formatting rules]] - {TextFormattingRules$:Summary}%0a%0a!! [[#intermed]] Intermediate Editing Topics%0a* [[Markup master index]] - {MarkupMasterIndex$:Summary}%0a%0a* [[Uploads]] - {Uploads$:Summary}%0a* [[Tables]] - {Tables$:Summary}%0a* [[Table directives]] - {TableDirectives$:Summary}%0a* [[Table of contents]] - {TableOfContents$:Summary}%0a* [[Wiki styles]] - {WikiStyles$:Summary}%0a** [[Wiki style examples]] - {WikiStyleExamples$:Summary}%0a%0a* [[Access keys]] - {AccessKeys$:Summary}%0a* [[Page directives]] - {PageDirectives$:Summary}%0a* [[Include other pages]] - {IncludeOtherPages$:Summary}%0a* [[InterMap]] links - {InterMap$:Summary}%0a* [[Conditional markup]] - {ConditionalMarkup$:Summary}%0a* [[Page variables]] - {PageVariables$:Summary}%0a* [[Page text variables]] - {PageTextVariables$:Summary}%0a* [[Markup expressions]] - {MarkupExpressions$:Summary}%0a* [[Forms]] - {Forms$:Summary}%0a%0a* [[Simultaneous edits]] - {SimultaneousEdits$:Summary}%0a%0a!! [[#struct]] Organizing and Protecting Pages%0a* [[Wiki structure]] - {WikiStructure$:Summary}%0a* [[Wiki group]]s - {WikiGroup$:Summary}%0a* [[Group headers]] - {GroupHeaders$:Summary}%0a* [[Wiki trails]] - {WikiTrails$:Summary}%0a* [[Page history]] - {PageHistory$:Summary}%0a%0a* [[Passwords]] - {Passwords$:Summary}%0a* [[Categories]] - {Categories$:Summary}%0a* [[Page lists]] - {PageLists$:Summary}%0a* %25%25 [[PageDirectives#attachlist|Attach lists]] - Get a list of files uploaded and attached to a group using [=(:attachlist:)=] [-({PageDirectives$:Summary})-]%0a* [[Deleting pages]] - {DeletingPages$:Summary}%0a* [[(PmWiki:)Wiki elements]] - {WikiElements$:Summary}%0a* [[(PmWiki:)Special pages]] - {SpecialPages$:Summary}%0a%0a!! [[#admin]] PmWiki Site Administration%0a!!! [[#install]]Installation and maintenance%0a* [[Installation]] - {Installation$:Summary}%0a* [[Initial setup tasks]] - {InitialSetupTasks$:Summary}%0a* [[Upgrades]] - {Upgrades$:Summary}%0a* [[Backup and Restore]] - {BackupAndRestore$:Summary}%0a* [[Uploads admin]]istration - {UploadsAdmin$:Summary}%0a* [[Security]] - {PmWiki/Security$:Summary}%0a%0a!!! [[#customise]] Customisation%0a* [[Custom markup]] - {CustomMarkup$:Summary}%0a* [[Custom wiki styles]] - {CustomWikiStyles$:Summary}%0a* [[Internationalizations]] - {Internationalizations$:Summary}%0a* [[Local customizations]] - {LocalCustomizations$:Summary}%0a* [[Group customizations]] - {GroupCustomizations$:Summary}%0a* [[Skins]] - {Skins$:Summary}%0a* [[Skin templates]] - {SkinTemplates$:Summary}%0a* [[Site Preferences]] - {SitePreferences$:Summary}%0a* [[Web feeds]] - {WebFeeds$:Summary}%0a* [[Wiki Farms]] - {WikiFarms$:Summary}%0a%0a!!! [[#troubleshoot]] Troubleshooting%0a* [[FAQ | Frequently answered questions]]%0a* [[(PmWiki:)AQ | Answers to some other questions]]%0a* [[(PmWiki:)FAQ Candidate]] - more answered questions%0a* [[(PmWiki:)Questions]]%0a* [[(PmWiki:)How to get assistance]]%0a* [[Troubleshooting]] - {Troubleshooting$:Summary}%0a* [[Available actions]] - documentation for developers%0a%0a!!! [[#security]] Security%0a* [[AuthUser]] - {AuthUser$:Summary}%0a* [[Blocklist]] - {Blocklist$:Summary} %0a* [[Notify]] - {Notify$:Summary}%0a* [[Passwords admin]]istration - {PasswordsAdmin$:Summary}%0a* [[Ref count]] - {RefCount$:Summary}%0a* [[Url approvals]] - {UrlApprovals$:Summary}%0a%0a!! [[#development]] Development%0a* [[Cookbook:Module Guidelines]] - Guidelines for creating, distributing, and maintaining a recipe for the Cookbook. %0a* [[Variables]] - {Variables$:Summary}%0a* [[Functions]] - {Functions$:Summary}%0a* [[Page file format]] - {PageFileFormat$:Summary}%0a%0a!! [[#misc]] About PmWiki%0a* [[Audiences]] - {Audiences$:Summary}%0a* [[Contributors]] - {Contributors$:Summary}%0a* [[Mailing lists]] - {MailingLists$:Summary}%0a* [[PmWiki philosophy]] - {PmWikiPhilosophy$:Summary}%0a* [[Design notes]] - {DesignNotes$:Summary}%0a* [[Release notes]] - {PmWiki/ReleaseNotes$:Summary}%0a* [[Change log]] - {PmWiki/ChangeLog$:Summary}%0a%0a* [[(PmWiki:)References]] - References to PmWiki media coverage%0a* [[Glossary]] - {PmWiki/Glossary$:Summary}%0a%0a* [[Introduction]] %25item comment%25 loop trail%0a[[#trailend]]%0a%0a>>comment%3c%3c%0aNote: The following pages are listed here so that they can include a #faq section and have the questions appear on the FAQ page. %0a%0aThe problem is that these pages become part of the trail %0a%0a* [[Basic Variables]]%0a* [[Edit Variables]]%0a* [[File Permissions]]%0a* [[Fmt Page Name]]%0a* [[I18n Variables]]%0a* [[Layout Variables]]%0a* [[Link Variables]]%0a* [[Other Variables]]%0a* [[Pagelist Variables]]%0a* [[PageList Templates]]%0a* [[Path Variables]]%0a* [[Requirements]]%0a* [[Skin Templates]]%0a* [[Special Characters]]%0a* [[Upload Variables]]%0a* [[Wiki Administrator]]%0a* [[Wiki Page]]%0a* [[Wiki Wiki Web]]%0a* [[Wiki Word]] +time=1641626475 title=Documentation Index blob - 4a33953a434ce06668f9e7f41bd1ec4b6a646850 blob + cf1f1c202edbb803c3b442d3ba027c2045d7fa43 --- wikilib.d/PmWiki.EditVariables +++ wikilib.d/PmWiki.EditVariables @@ -1,9 +1,9 @@ -version=pmwiki-2.2.118 ordered=1 urlencoded=1 +version=pmwiki-2.3.17 ordered=1 urlencoded=1 author=Petko charset=UTF-8 -csum=no such page Edit toolbar +csum=$EnableGUIButtons require php-json (+224) name=PmWiki.EditVariables -rev=94 -targets=Cookbook.NotSavedWarning,PmWiki.EditVariables,Cookbook.EditHelp,Cookbook.EditTemplates,PmWiki.SecurityVariables,PmWiki.Drafts,Cookbook.FixURL,Cookbook.PreviewChanges,PmWiki.BasicVariables,Cookbook.ROSPatterns,Category.PmWikiDeveloper -text=(:Summary:variables used when editing pages:)%0aTo set many of the variables below specify them in @@config.php@@.%0a%0a:$EnableNotSavedWarning: Set to 1 to warn the editors if they are about to leave the edit form without saving their changes. Based on Cookbook:NotSavedWarning. By default this is disabled. If you enable it, please disable any addons that may provide a similar feature, notably an older version of Cookbook:NotSavedWarning.%0a: : @@ $EnableNotSavedWarning = 1; @@ # enable warning, default 0 (disabled)%0a%0a:$EnableEditAutoText: Set to 1 to enable basic predictive editing like automatically inserted list bullets, see Cookbook:EditHelp. By default this is disabled. If you enable it, please disable any addons that may provide a similar feature, notably an older version of Cookbook:EditHelp.%0a: : @@ $EnableEditAutoText = 1;@@%0a%0a:$AutoCreate:Used in conjunction with the AutoCreateTargets edit function, this array records any sets of pages which should be created automatically if they don't exist. The syntax is[@%0a $AutoCreate[REGEXP] = PAGE_PARAMETERS;%0a@]where @@REGEXP@@ is a regular expression which will identify the pages to be autocreated, and @@PAGE_PARAMETERS@@ is an array of attributes for the page to be created. For example[@%0a $AutoCreate['/^Category\\./'] = array('ctime' => $Now);%0a@]will create a blank page with a current creation time for any missing Category page.%0a%0a:$DefaultPageTextFmt:The text that should be displayed when browsing non-existent pages. As default PmWiki uses the contents of Site.PageNotFound:[@%0a $DefaultPageTextFmt = '(:include $[{$SiteGroup}.PageNotFound]:)';@] %0a%0a:$DeleteKeyPattern:The pattern used to determine if a page should be deleted. The default is to remove pages that contain only the single word "delete" (and optional spaces).[@%0a## Change delete word to "remove":%0a$DeleteKeyPattern = "^\\s*remove\\s*$";%0a## Delete any page with no visible text, i.e., empty:%0a$DeleteKeyPattern = "^\\s*$";@]%0a%0a:$DiffKeepDays:The $DiffKeepDays variable sets the minimum length of time that a page's revision history is kept. By default it is set to 3650 days, or a little less than ten years. You can change this value in a customization file to be something smaller, e.g.:[@%0a $DiffKeepDays = 30; # keep revisions at least 30 days%0a@]If you want to suppress a page's revision history, you can insert into a customization file [@%0a $DiffKeepDays = $DiffKeepNum = -1; # suppress revision history %0a@]Note that a specific page revision isn't removed from the page until the first edit after the time specified by $DiffKeepDays has elapsed. Thus, it's still possible for some pages to have revisions older than $DiffKeepDays -- such revisions will be removed the next time those pages are edited.%0a%0a:$DiffKeepNum:This variable contains the minimum number of changes to be kept in the page history, even if some of them are older than the limit defined by $DiffKeepDays. It prevents lost history of pages that are older, but have few changes.[@%0a $DiffKeepNum = 50; # keep at least 50 revisions (default is 20)%0a@]To suppress page's revision history with [@$DiffKeepNum = -1@] see $DiffKeepDays above.%0a%0a:$DraftActionsPattern:The actions which allow full loading of the draft.php functionality for custom actions. Default is 'edit'. You can enable drafts for other actions like:[@%0a $DraftActionsPattern = 'edit|pmform|translate';%0a # Enable drafts for actions 'edit', 'pmform' and 'translate'.@]%0a%0a:$DraftSuffix:The suffix to use for draft versions of pages (default "-Draft").%0a%0a:$EditFunctions: This array contains the sequence of functions that are called when a page is edited. It can be customized to provide additional functions to be called as part of the editing process. The standard setting is:[@%0a$EditFunctions = array('EditTemplate', 'RestorePage', 'ReplaceOnSave',%0a 'SaveAttributes', 'PostPage', 'PostRecentChanges', 'AutoCreateTargets', 'PreviewPage');%0a%0a@]Many recipes manipulate this array, so it is recommended, instead of redefining the complete array to add your custom functions, to use functions like array_unshift(), array_push() and array_splice().%0a%0a:$EditRedirectFmt: The page to which an author is sent after pressing "Save" or "Cancel" from an edit form. Defaults to "$FullName", which sends the author to the page just edited, but can be changed to specify another page.[@%0a## Redirect to Main.HomePage:%0a$EditRedirectFmt = 'Main.HomePage';%0a## Redirect to HomePage of current group:%0a$EditRedirectFmt = '{$Group}.HomePage';@]%0a%0a:$EditTemplatesFmt:Name of the page (or an array of names) to be used as the default text for any newly created pages.[@%0a## Use 'Main.NewPageTemplate' as default text of all new pages:%0a $EditTemplatesFmt = 'Main.NewPageTemplate';%0a## Use 'Template' in the current group for new pages:%0a $EditTemplatesFmt = '$Group.Template';%0a## Use 'Template' in the current group if it exists, otherwise%0a## use 'Main.NewPageTemplate':%0a $EditTemplatesFmt = array('$Group.Template', 'Main.NewPageTemplate');@]%0a-> See [[Cookbook:EditTemplates]] for more information.%0a%0a%0a:$EnableDrafts:When set to '1', enables the "Save draft" button and built-in handling of "draft" versions of pages, where: %0a## Initial "Save draft" of an existing page ("PageName") saves changes to a new name ("PageName-Draft").%0a## Subsequent attempts to edit PageName causes PageName-Draft to be edited.%0a## Subsequent selections of "Save draft" cause PageName-Draft to be saved.%0a## Pressing "Publish" causes PageName-Draft to be posted to PageName, and deleted.%0a-> Turn on draft edits:[@%0a $EnableDrafts = 1;@]%0a-> A related variable, $EnablePublishAttr, adds a new "publish" authorization level to distinguish editing of drafts from publishing them.%0a%0a:$EnableDraftAtomicDiff:When set to 1, "publishing" a draft version will clear the "draft" history, leaving a single "diff" between the latest and the previous "published" versions. Note that this will delete the author names, dates and contributions of the intermediate, unpublished versions. ([[Drafts]] need to be enabled, see $EnableDrafts.)%0a%0a:$EnableGUIButtons:When set to '1', turns on the graphical buttons in the "Edit Page" form.[@%0a## Turn on graphical edit buttons:%0a$EnableGUIButtons = 1;@]%0a%0a:$EnableGuiEditFixUrl: Enables an icon "%252" that can help encoding special characters in URL links, see Cookbook:FixURL. $EnableGUIButtons need to be enabled.%0a: : @@$EnableGuiEditFixUrl = 2000;@@ # place the button near the end of the Edit toolbar.%0a%0a:$EnablePreviewChanges:When set to '1', the "Preview" function will show the highlighted changes in the wiki markup before the rendered page preview. See Cookbook:PreviewChanges.[@%0a $EnablePreviewChanges = 1;@]%0a%0a:$EnablePostAuthorRequired:When set to '1', posting of pages (and uploading files since 2.2.117) requires the author to provide an author name. Otherwise, authors can post without a name.[@%0a## Require authors to provide a name:%0a$EnablePostAuthorRequired = 1;@] %0a%0a:$EnableUploadAuthorRequired:Whether uploading files requires the name of the uploader to be entered (added in 2.2.117). If unset, will use the value of $EnablePostAuthorRequired. %0a%0a:$EnableRevUserAgent:When set to '1', the page history will store the "User agent" string from the browser of the writer (by default this feature is disabled). This can be useful for tracking bugs in custom applications, by examining the disk files in wiki.d.[@%0a## Store browser user agent with page diffs:%0a $EnableRevUserAgent = 1; @]%0a%0a:$GUIButtons:Allows the configuration of the buttons which appear at the top of the text area when editing a page. See scripts/guiedit.php for the default definition. Note that the 5th element can be HTML code rather than just the url of a gif - this allows more flexibility in defining the related JavaScript.%0a%0a:$HandleEditFmt: Like $HandleBrowseFmt, this specifies the entire output format for [@?action=edit@] for a page.%0a%0a:$IsPagePosted: Set to a true value if the page is actually saved (e.g., this is used to tell the RecentChanges handlers if they need to update).%0a %0a:$PageEditFmt: By default, this is the HTML to be displayed for an edit form.%0a%0a:$PageEditForm: Specifies the edit form for [@?action=edit@]. Defaults to '$SiteGroup.EditForm'.%0a%0a:$ROEPatterns: With this array you can add a pattern as ''key'' and set a text ''value'' which replace it on every edit request, using preg_replace function. Specifically it is replaced when the page is loaded into the editform, whenever a preview is done, and when the page is saved (from PmWiki 2.2.0beta45). See Cookbook:ROSPatterns for examples.%0a%0a:$ROSPatterns: With this array you can add patterns as ''key'' and set a text ''value'' which will replace it when the edited page is posted (as signaled by $EnablePost). It is not replaced when the page is loaded into the editform nor when a preview is done, but it is replaced only when the page is saved. See Cookbook:ROSPatterns for examples.%0a%0a:$EnableROSEscape: If set to 1, the $ROEPatterns and $ROSPatterns replacements will skip escaped text (surrounded by [@[=...=]@] or @@[=[@...@]=]@@). If not set, or if set to 0, the replacements will happen even inside escaped text.%0a%0a%0aCategories: [[!PmWiki Developer]] -time=1567148785 +rev=103 +targets=PmWiki.Functions,PmWiki.EditVariables,Cookbook.NotSavedWarning,Cookbook.EditHelp,Cookbook.EditTemplates,PmWiki.SecurityVariables,PmWiki.Drafts,Cookbook.FixURL,Cookbook.PreviewChanges,PmWiki.IncludeOtherPages,PmWiki.PageTextVariables,PmWiki.BasicVariables,Cookbook.ROSPatterns,Category.PmWikiDeveloper,!PmWikiDeveloper +text=(:Summary:variables used when editing pages:)%0aTo set many of the variables below specify them in @@config.php@@.%0a%0a:$EnableReadOnly: Set to 1 to disable editing. Note this doesn't automatically prevent changes to the wiki by recipes, unless they use the [[Functions#Lock|core Lock() function]] correctly.%0a: : %25hlt php%25@@ $EnableReadOnly = 1; # disable editing@@%0a%0a:$EnableNotSavedWarning: Set to 1 to warn the editors if they are about to leave the edit form without saving their changes. Based on Cookbook:NotSavedWarning. By default this is disabled. If you enable it, please disable any addons that may provide a similar feature, notably an older version of Cookbook:NotSavedWarning.%0a: : %25hlt php%25@@ $EnableNotSavedWarning = 0; # disable warning, default 1 (enabled, since 2.3.0)@@%0a%0a:$EnableEditAutoText: Set to 1 to enable basic predictive editing like automatically inserted list bullets, see Cookbook:EditHelp. By default this is disabled. If you enable it, please disable any addons that may provide a similar feature, notably an older version of Cookbook:EditHelp.%0a: : %25hlt php%25@@ $EnableEditAutoText = 1;@@%0a%0a:$AutoCreate:Used in conjunction with the AutoCreateTargets edit function, this array records any sets of pages which should be created automatically if they don't exist. The syntax is %25hlt php%25[@%0a $AutoCreate[REGEXP] = PAGE_PARAMETERS;%0a@]where @@REGEXP@@ is a regular expression which will identify the pages to be autocreated, and @@PAGE_PARAMETERS@@ is an array of attributes for the page to be created. For example %25hlt php%25[@%0a $AutoCreate['/^Category\\./'] = array('ctime' => $Now);%0a@]will create a blank page with a current creation time for any missing Category page.%0a%0a:$DefaultPageTextFmt:The text that should be displayed when browsing non-existent pages. As default PmWiki uses the contents of Site.PageNotFound: %25hlt php%25[@%0a $DefaultPageTextFmt = '(:include $[{$SiteGroup}.PageNotFound]:)';@] %0a%0a:$DeleteKeyPattern:The pattern used to determine if a page should be deleted. The default is to remove pages that contain only the single word "delete" (and optional spaces). %25hlt php%25[@%0a## Change delete word to "remove":%0a$DeleteKeyPattern = "^\\s*remove\\s*$";%0a## Delete any page with no visible text, i.e., empty:%0a$DeleteKeyPattern = "^\\s*$";@]%0a%0a:$DiffKeepDays:The $DiffKeepDays variable sets the minimum length of time that a page's revision history is kept. By default it is set to 3650 days, or a little less than ten years. You can change this value in a customization file to be something smaller, e.g.: %25hlt php%25[@%0a $DiffKeepDays = 30; # keep revisions at least 30 days%0a@]If you want to suppress a page's revision history, you can insert into a customization file %25hlt php%25[@%0a $DiffKeepDays = $DiffKeepNum = -1; # suppress revision history %0a@]Note that a specific page revision isn't removed from the page until the first edit after the time specified by $DiffKeepDays has elapsed. Thus, it's still possible for some pages to have revisions older than $DiffKeepDays -- such revisions will be removed the next time those pages are edited.%0a%0a:$DiffKeepNum:This variable contains the minimum number of changes to be kept in the page history, even if some of them are older than the limit defined by $DiffKeepDays. It prevents lost history of pages that are older, but have few changes. %25hlt php%25[@%0a $DiffKeepNum = 50; # keep at least 50 revisions (default is 20)%0a@]To suppress page's revision history with [@$DiffKeepNum = -1@] see $DiffKeepDays above.%0a%0a:$DraftActionsPattern:The actions which allow full loading of the draft.php functionality for custom actions. Default is 'edit'. You can enable drafts for other actions like: %25hlt php%25[@%0a $DraftActionsPattern = 'edit|pmform|translate';%0a # Enable drafts for actions 'edit', 'pmform' and 'translate'.@]%0a%0a:$DraftSuffix:The suffix to use for draft versions of pages (default "-Draft").%0a%0a:$EditFunctions: This array contains the sequence of functions that are called when a page is edited. It can be customized to provide additional functions to be called as part of the editing process. The standard setting is: %25hlt php%25[@%0a$EditFunctions = array('EditTemplate', 'RestorePage', 'ReplaceOnSave',%0a 'SaveAttributes', 'PostPage', 'PostRecentChanges', 'AutoCreateTargets', 'PreviewPage');%0a%0a@]Many recipes manipulate this array, so it is recommended, instead of redefining the complete array to add your custom functions, to use functions like %25hlt php%25@@array_unshift()@@, @@array_push()@@ and @@array_splice()@@.%0a%0a:$EditRedirectFmt: The page to which an author is sent after pressing "Save" or "Cancel" from an edit form. Defaults to "$FullName", which sends the author to the page just edited, but can be changed to specify another page. %25hlt php%25[@%0a## Redirect to Main.HomePage:%0a$EditRedirectFmt = 'Main.HomePage';%0a## Redirect to HomePage of current group:%0a$EditRedirectFmt = '{$Group}.HomePage';@]%0a%0a:$EditTemplatesFmt:Name of the page (or an array of names) to be used as the default text for any newly created pages. %25hlt php%25[@%0a## Use 'Main.NewPageTemplate' as default text of all new pages:%0a $EditTemplatesFmt = 'Main.NewPageTemplate';%0a## Use 'Template' in the current group for new pages:%0a $EditTemplatesFmt = '$Group.Template';%0a## Use 'Template' in the current group if it exists, otherwise%0a## use 'Main.NewPageTemplate':%0a $EditTemplatesFmt = array('$Group.Template', 'Main.NewPageTemplate');@]%0a-> See [[Cookbook:EditTemplates]] for more information.%0a%0a%0a:$EnableDrafts:When set to '1', enables the "Save draft" button and built-in handling of "draft" versions of pages, where: %0a## Initial "Save draft" of an existing page ("PageName") saves changes to a new name ("PageName-Draft").%0a## Subsequent attempts to edit PageName causes PageName-Draft to be edited.%0a## Subsequent selections of "Save draft" cause PageName-Draft to be saved.%0a## Pressing "Publish" causes PageName-Draft to be posted to PageName, and deleted.%0a-> Turn on draft edits: %25hlt php%25[@%0a $EnableDrafts = 1;@]%0a-> A related variable, $EnablePublishAttr, adds a new "publish" authorization level to distinguish editing of drafts from publishing them.%0a%0a:$EnableDraftAtomicDiff:When set to 1, "publishing" a draft version will clear the "draft" history, leaving a single "diff" between the latest and the previous "published" versions. Note that this will delete the author names, dates and contributions of the intermediate, unpublished versions. ([[Drafts]] need to be enabled, see $EnableDrafts.)%0a%0a:$EnableGUIButtons:When set to '1', turns on the graphical buttons in the "Edit Page" form. %25hlt php%25[@%0a## Turn on graphical edit buttons:%0a$EnableGUIButtons = 1;@]%0a%0a:$EnableGuiEditFixUrl: Enables an icon "%252" that can help encoding special characters in URL links, see Cookbook:FixURL. $EnableGUIButtons need to be enabled.%0a: : %25hlt php%25@@$EnableGuiEditFixUrl = 2000; # place the button near the end of the Edit toolbar@@%0a%0a:$EnablePreviewChanges:When set to '1', the "Preview" function will show the highlighted changes in the wiki markup before the rendered page preview. See Cookbook:PreviewChanges. %25hlt php%25[@%0a $EnablePreviewChanges = 1;@]%0a%0a:$EnableListIncludedPages: When set to '1', inserts in the edit form a list with pages included in the currently edited page either via the [[IncludeOtherPages|include markup]], or via [[page text variables]] (and any nested pages and variables). The list appears in a collapsed %25hlt html%25@@%3cdetails>@@ element between the text area and the summary field.%0a%0a:$EnablePostAuthorRequired:When set to '1', posting of pages (and uploading files since 2.2.117) requires the author to provide an author name. Otherwise, authors can post without a name. %25hlt php%25[@%0a## Require authors to provide a name:%0a$EnablePostAuthorRequired = 1;@] %0a%0a:$EnableUploadAuthorRequired:Whether uploading files requires the name of the uploader to be entered (added in 2.2.117). If unset, will use the value of $EnablePostAuthorRequired. %0a%0a:$EnableRevUserAgent:When set to '1', the page history will store the "User agent" string from the browser of the writer (by default this feature is disabled). This can be useful for tracking bugs in custom applications, by examining the disk files in wiki.d. %25hlt php%25[@%0a## Store browser user agent with page diffs:%0a $EnableRevUserAgent = 1; @]%0a%0a:$GUIButtons:Allows the configuration of the buttons which appear at the top of the text area when editing a page. See @@scripts/guiedit.php@@ for the default definition. Note that the 5th element can be HTML code rather than just the url of a gif - this allows more flexibility in defining the related JavaScript.%0a%0a:$HandleEditFmt: Like $HandleBrowseFmt, this specifies the entire output format for [@?action=edit@] for a page.%0a%0a:$IsPagePosted: Set to a true value if the page is actually saved (e.g., this is used to tell the RecentChanges handlers if they need to update).%0a %0a:$PageEditFmt: By default, this is the HTML to be displayed for an edit form.%0a%0a:$PageEditForm: Specifies the edit form for [@?action=edit@]. Defaults to '@@$SiteGroup.EditForm@@'.%0a%0a:$ROEPatterns: With this array you can add a pattern as ''key'' and set a text ''value'' which replace it on every edit request, using %25hlt php%25@@preg_replace ()@@ function. Specifically it is replaced when the page is loaded into the editform, whenever a preview is done, and when the page is saved (from PmWiki 2.2.0beta45). See Cookbook:ROSPatterns for examples.%0a%0a:$ROSPatterns: With this array you can add patterns as ''key'' and set a text ''value'' which will replace it when the edited page is posted (as signaled by $EnablePost). It is not replaced when the page is loaded into the editform nor when a preview is done, but it is replaced only when the page is saved. See Cookbook:ROSPatterns for examples.%0a%0a:$EnableROSEscape: If set to 1, the $ROEPatterns and $ROSPatterns replacements will skip escaped text (surrounded by %25pmhlt%25[@[=...=]@] or @@[=[@...@]=]@@). If not set, or if set to 0, the replacements will happen even inside escaped text.%0a%0a%0aCategories: [[!PmWiki Developer]] +time=1671285454 blob - 7364b79cf8bf2f876c5ddc76b3ce11130fd70673 blob + 39baa3ee420ddfdefe5cea17e77cab9dfa061829 --- wikilib.d/PmWiki.FilePermissions +++ wikilib.d/PmWiki.FilePermissions @@ -1,10 +1,9 @@ -version=pmwiki-2.2.30 ordered=1 urlencoded=1 -agent=Mozilla/5.0 (X11; Linux x86_64; rv:5.0) Gecko/20100101 Firefox/5.0 -author=simon +version=pmwiki-2.3.14 ordered=1 urlencoded=1 +author=MFWolff charset=UTF-8 -csum=see also Cookbook/DirectoryAndFilePermissions +csum=typo (+0) name=PmWiki.FilePermissions -rev=29 -targets= -text=(:Summary: PmWiki's settings for file and directory permissions in a typical Unix environment:)%0a%0aThis page briefly describes PmWiki's settings for file and directory permissions in a typical Unix environment.%0a%0a!! Simple installation (out of the box)%0a%0aFirst, let's look at PmWiki without any cookbook scripts loaded. PmWiki needs to be able to write into the%0a* ''wiki.d/'' directory to be able to save pages%0a* ''uploads/'' directory to save uploads. %0aThose are the *only* directories that need to be writable by the webserver. %0aIt doesn't matter to PmWiki who owns or creates those directories, as long as it has write permission to them.%0a%0aEverything else should be owned by the account holder, and readable by the webserver account (but normally not writable by the webserver account).%0a%0aThat's it -- everything else depends on the specific PHP configuration and running environment, which is detailed below (and which is why there isn't a definitive answer that applies to every situation). But the above two rules are absolute and answer 95%25 of the questions about directory permissions. %0a%0aOn a Unix host the webserver typically runs with a userid and groupid that is different from the account holder. Usually the webserver account is something like "nobody", "apache", "www", or "httpd". Thus, in a standard installation, the account holder manually creates the wiki.d/ and uploads/ directories, and sets the permissions on the directories to be world-writable in order for PmWiki (running as the webserver account) to be able to create files there.%0a%0a-> [@%0a$ pwd%0a/home/pmichaud/public_html/pmwiki%0a$ mkdir uploads%0a$ mkdir wiki.d%0a$ chmod 777 uploads wiki.d %0a$ ls -ld . uploads wiki.d%0adrwxr-xr-x 12 pmichaud pmichaud 1024 Feb 10 11:51 . %0adrwxrwxrwx 8 pmichaud pmichaud 1024 Jan 23 11:58 uploads %0adrwxrwxrwx 2 pmichaud pmichaud 54272 Feb 10 15:29 wiki.d %0a@]%0a%0a!! Avoiding world-write directories%0a%0aHowever, lots of people don't like having those world-writable (rwx) permissions on the directories. The only practical way to eliminate the world write permissions is if we can get the webserver and account holder to be the owner and group of the directories and the files within them. Since Unix typically doesn't allow non-superusers to change ownerships of files or directories that already exist, we have to make sure they are created with the correct ownerships in the first place.%0a%0aTo get the directories to be owned by the webserver account, we let PmWiki take care of creating them. This means we temporarily grant write permission to the parent, and then execute PmWiki to allow it to create the directories. However, we also want the newly created directories to have the same group as the account holder, so the account holder can remove or manipulate files in the directories. Therefore, we use Unix's ''setgid'' capability (2777 or 'rws' permissions) to cause all newly created files to inherit the same group as the parent.%0a%0aTo avoid world-write directories, use the following instructions '''instead of''' the instructions above. If you already have created the ''wiki.d/'' and ''uploads/'' directories, use chown and chmod to match the following results.%0a%0a-> [@%0a$ pwd%0a/home/pmichaud/public_html/pmwiki%0a$ chmod 2777 . %0a$ ls -ld .%0adrwxrwsrwx 10 pmichaud pmichaud 4096 May 28 09:55 .%0a# %3c-- execute pmwiki.php script from web browser -->%0a$ ls -ld . uploads wiki.d%0adrwxrwsrwx 10 pmichaud pmichaud 4096 May 28 09:55 .%0adrwxrwsr-x 2 nobody pmichaud 4096 May 28 09:55 uploads%0adrwxrwsr-x 2 nobody pmichaud 4096 May 28 09:55 wiki.d%0a$ chmod 755 .%0adrwxr-xr-x 10 pmichaud pmichaud 4096 May 28 09:55 .%0adrwxrwsr-x 2 nobody pmichaud 4096 May 28 09:55 uploads%0adrwxrwsr-x 2 nobody pmichaud 4096 May 28 09:55 wiki.d%0a@]%0a%0aNow the two directories are owned by 'nobody', which means the webserver can write to them. We don't have world-writable permissions on the directories, and the account holder (pmichaud) still has write permissions to the files and directories by virtue of the group ownership and permissions. The setgid bit also ensures that any files or subdirectories created within ''uploads/'' or ''wiki.d/'' will belong to the same (pmichaud) group.%0a%0a!! Safe mode%0aHOWEVER, if a site is running in PHP's "%25newwin%25[[http://php.net/features.safe-mode|safe_mode]]", then the "let PmWiki create the directories" solution doesn't work, as PHP will only create files in directories that are owned by the same user that owns the pmwiki.php script itself. Thus, PmWiki (apache) ''cannot'' create the directories in this case, or safe_mode will complain when PmWiki attempts to write a file into those directories. The *only* way for things to work in safe_mode is to manually create the needed directories and set their permissions to 777, as outlined at the beginning of this section.%0a%0a!! PHP running as script owner%0a%0aThere are some webservers and PHP installations that are configured to run a PHP script with the same identity as the owner of the script. This is often called "suexec PHP" or even just "suPHP". In this case, since the PmWiki script ends up running with the same identity as the account holder, then everything "just works" out of the box without doing anything manually. PmWiki creates any directories and files as needed, each owned by the account holder, and permissions aren't generally an issue at all.%0a%0a!! Cookbook scripts%0aOkay, now let's look at cookbook scripts. %0aIf a cookbook script has files that it wants to make available to browsers, such files should generally be placed somewhere within the 'pub/' hierarchy and referenced via '$PubDirUrl'. %0a%0aIf a cookbook recipe needs to *write* files to disk, then the same rules apply to that directory as for the wiki.d/ and uploads/ directories above, with the exact ownerships and permissions depending on the webserver and PHP configuration. In general the cookbook recipe should do the same as PmWiki, and just call PmWiki's mkdirp($dir) function. PmWiki will then take care of creating the directory (if it can) or prompting for its creation as appropriate.%0a%0aFor example, if cookbook recipe 'frobot' wants to distribute a .css file, then that file should go somewhere like pub/css/frobot.css or pub/frobot/frobot.css. The directories and files in this case should be created and owned by the account owner, since the cookbook recipe doesn't need to create or modify any of the files when it runs. %0a%0aAs an alternate example, the Cookbook:MimeTeX recipe wants to be able to create cached images for the math markup, and those images need to be available to the browser. Thus, `MimeTeX uses a pub/cache/ directory, which should be created in whatever manner was used to create the wiki.d/ and uploads/ directories (i.e., according to the webserver and PHP configuration). Again, Cookbook:MimeTeX just solves this by calling mkdirp("pub/cache"), and letting that function create the directory or prompt the administrator for the appropriate action based upon the server settings encountered.%0a%0a!! See also%0a* [[Cookbook:Directory and file permissions]] [- {Cookbook/DirectoryAndFilePermissions$:Summary} -]%0a%0a -time=1315670897 +rev=34 +targets=PmWiki.PathVariables,Cookbook.MimeTeX,Cookbook.DirectoryAndFilePermissions +text=(:Summary: PmWiki's settings for file and directory permissions in a typical Unix environment:)%0a%0aThis page briefly describes PmWiki's settings for file and directory permissions in a typical Unix environment.%0a%0a!! Simple installation (out of the box)%0a%0aFirst, let's look at PmWiki without any cookbook scripts loaded. PmWiki needs to be able to write into the%0a* ''wiki.d/'' directory to be able to save pages%0a* ''uploads/'' directory to save uploads. %0aThose are the *only* directories that need to be writable by the webserver. %0aIt doesn't matter to PmWiki who owns or creates those directories, as long as it has write permission to them.%0a%0aEverything else should be owned by the account holder, and readable by the webserver account (but normally not writable by the webserver account).%0a%0aThat's it -- everything else depends on the specific PHP configuration and running environment, which is detailed below (and which is why there isn't a definitive answer that applies to every situation). But the above two rules are absolute and answer 95%25 of the questions about directory permissions. %0a%0aOn a Unix host the webserver typically runs with a userid and groupid that is different from the account holder. Usually the webserver account is something like "nobody", "apache", "www", or "httpd". Thus, in a standard installation, the account holder manually creates the @@wiki.d/@@ and @@uploads/@@ directories, and sets the permissions on the directories to be world-writable in order for PmWiki (running as the webserver account) to be able to create files there.%0a-> %25hlt cmd%25[@%0a$ pwd%0a/home/pmichaud/public_html/pmwiki%0a$ mkdir uploads%0a$ mkdir wiki.d%0a$ chmod 777 uploads wiki.d %0a$ ls -ld . uploads wiki.d%0adrwxr-xr-x 12 pmichaud pmichaud 1024 Feb 10 11:51 . %0adrwxrwxrwx 8 pmichaud pmichaud 1024 Jan 23 11:58 uploads %0adrwxrwxrwx 2 pmichaud pmichaud 54272 Feb 10 15:29 wiki.d %0a@]%0a%0a!! Avoiding world-write directories%0a%0aHowever, lots of people don't like having those world-writable (rwx) permissions on the directories. The only practical way to eliminate the world write permissions is if we can get the webserver and account holder to be the owner and group of the directories and the files within them. Since Unix typically doesn't allow non-superusers to change ownerships of files or directories that already exist, we have to make sure they are created with the correct ownerships in the first place.%0a%0aTo get the directories to be owned by the webserver account, we let PmWiki take care of creating them. This means we temporarily grant write permission to the parent, and then execute PmWiki to allow it to create the directories. However, we also want the newly created directories to have the same group as the account holder, so the account holder can remove or manipulate files in the directories. Therefore, we use Unix's ''setgid'' capability (2777 or 'rws' permissions) to cause all newly created files to inherit the same group as the parent.%0a%0aTo avoid world-write directories, use the following instructions '''instead of''' the instructions above. If you already have created the ''wiki.d/'' and ''uploads/'' directories, use chown and chmod to match the following results.%0a-> %25hlt cmd%25[@%0a$ pwd%0a/home/pmichaud/public_html/pmwiki%0a$ chmod 2777 . %0a$ ls -ld .%0adrwxrwsrwx 10 pmichaud pmichaud 4096 May 28 09:55 .%0a# %3c-- execute pmwiki.php script from web browser -->%0a$ ls -ld . uploads wiki.d%0adrwxrwsrwx 10 pmichaud pmichaud 4096 May 28 09:55 .%0adrwxrwsr-x 2 nobody pmichaud 4096 May 28 09:55 uploads%0adrwxrwsr-x 2 nobody pmichaud 4096 May 28 09:55 wiki.d%0a$ chmod 755 .%0adrwxr-xr-x 10 pmichaud pmichaud 4096 May 28 09:55 .%0adrwxrwsr-x 2 nobody pmichaud 4096 May 28 09:55 uploads%0adrwxrwsr-x 2 nobody pmichaud 4096 May 28 09:55 wiki.d%0a@]%0a%0aNow the two directories are owned by 'nobody', which means the webserver can write to them. We don't have world-writable permissions on the directories, and the account holder (pmichaud) still has write permissions to the files and directories by virtue of the group ownership and permissions. The setgid bit also ensures that any files or subdirectories created within ''uploads/'' or ''wiki.d/'' will belong to the same (pmichaud) group.%0a%0a!! PHP running as script owner%0a%0aThere are some webservers and PHP installations that are configured to run a PHP script with the same identity as the owner of the script. This is often called "suexec PHP" or even just "suPHP". In this case, since the PmWiki script ends up running with the same identity as the account holder, then everything "just works" out of the box without doing anything manually. PmWiki creates any directories and files as needed, each owned by the account holder, and permissions aren't generally an issue at all.%0a%0a!! Cookbook scripts%0aOkay, now let's look at cookbook scripts. %0aIf a cookbook script has files that it wants to make available to browsers, such files should generally be placed somewhere within the 'pub/' hierarchy and referenced via '$PubDirUrl'. %0a%0aIf a cookbook recipe needs to *write* files to disk, then the same rules apply to that directory as for the @@wiki.d/@@ and @@uploads/@@ directories above, with the exact ownerships and permissions depending on the webserver and PHP configuration. In general the cookbook recipe should do the same as PmWiki, and just call PmWiki's mkdirp($dir) function. PmWiki will then take care of creating the directory (if it can) or prompting for its creation as appropriate.%0a%0aFor example, if cookbook recipe 'frobot' wants to distribute a .css file, then that file should go somewhere like @@pub/css/frobot.css@@ or @@pub/frobot/frobot.css@@. The directories and files in this case should be created and owned by the account owner, since the cookbook recipe doesn't need to create or modify any of the files when it runs. %0a%0aAs an alternate example, the Cookbook:MimeTeX recipe wants to be able to create cached images for the math markup, and those images need to be available to the browser. Thus, `MimeTeX uses a @@pub/cache/@@ directory, which should be created in whatever manner was used to create the @@wiki.d/@@ and @@uploads/@@ directories (i.e., according to the webserver and PHP configuration). Again, Cookbook:MimeTeX just solves this by calling %25hlt php%25@@mkdirp("pub/cache")@@, and letting that function create the directory or prompt the administrator for the appropriate action based upon the server settings encountered.%0a%0a!! See also%0a* [[Cookbook:Directory and file permissions]] [- {Cookbook/DirectoryAndFilePermissions$:Summary} -]%0a%0a +time=1668929754 blob - 08098f81b8ca686d05cc0bf021586653ad668bcd blob + 1fb9394d4f6c4808a05584f7c2e70bc0473d0a68 --- wikilib.d/PmWiki.FmtPageName +++ wikilib.d/PmWiki.FmtPageName @@ -1,10 +1,9 @@ -version=pmwiki-2.2.30 ordered=1 urlencoded=1 -agent=Mozilla/5.0 (X11; Linux x86_64; rv:5.0) Gecko/20100101 Firefox/5.0 -author=Peter Bowers +version=pmwiki-2.3.14 ordered=1 urlencoded=1 +author=simon charset=UTF-8 -csum=add comment re PV form in #6 +csum=pm hlt, hlt php (+184) name=PmWiki.FmtPageName -rev=44 -targets=PmWiki.Functions,PmWiki.Variables,PmWiki.Internationalizations,PmWiki.PageVariables,Cookbook.Functions -text=(:Summary: Documentation for the PmWiki internal function [@FmtPageName()@] :)%0a(:Audience: admins (advanced) :)%0aThis page describes an internal function in PmWiki's engine called [=FmtPageName()=]. %0aThe contents are not intended for those with a weak heart%0a;-)%0a%0aAlso see: [[PmWiki.Functions]]%0a%0a!! [[#FmtPageName]] [@FmtPageName@]($fmt, $pagename)%0a%0a[[#FmtPageName-desc]]Returns [@$fmt@], with $variable and $[internationalisation] substitutions performed, under the assumption that the current page is [@pagename@]. As a rule is used to pre-process all variables which by convention have a "Fmt" suffix (like $GroupFooterFmt), but also other strings that require %25newwin%25[[Wikipedia:Variable_%2528programming%2529#Interpolation | interpolation]], notably the page template (.tmpl) file. See [[PmWiki.Variables]] for an (incomplete) list of available variables, [[PmWiki.Internationalizations]] for internationalisation.%0a%0aThe function [@FmtPageName()@] applies internationalization-substitutions%0aand $Variable-substitions to the string $fmt under the assumption that the%0acurrent page is $pagename.%0a%0aThe substitutions go as follows:%0a%0a# Replace any sequences of the form [@$XyzFmt@] with value of any \%0a corresponding global variable.%0a# Process the string for any [@$[...]@] phrases (internationalized phrase), \%0a using the currently loaded translation tables.%0a# Replace any instances of [@{$ScriptUrl}@] with [@$ScriptUrl@] \%0a (to defer processing to the URI processing phase)%0a# Replace any instances of standard [[PmWiki/PageVariables|Page Variables]] \%0a (beginning with an upper case letter, followed by at least one word character) \%0a with their values. %25green%25Note that PVs of the form [@{Group.Page$Var}@] are '''not''' replaced.%25%25\%0a If there are no more $-sequences, then return the formatted string and exit the function%0a# Perform any pattern replacements from the array $FmtP. Typically \%0a this is used to handle things like $Name and $Group etc that are \%0a specific to the name of the current page. %25green%25''?? Appears to be used in robots.php to hide actions from robots.''%0a# Replace any remaining instances of Page Variables with their values. \%0a %25green%25Note that these variables are in the form [@$Var@] rather than the usual PV form of [@{$Var}@].%25%25%0a# If $EnablePathInfo isn't set, convert [@URIs@] to use the syntax \%0a $ScriptUrl?n=%3cGroup>.%3cName> instead of $ScriptUrl/%3cGroup>/%3cName>. \%0a In any case, replace $ScriptUrl with its value. \%0a If there are no more $-sequences, then return the formatted string and exit the function%0a# Replace any $-sequences with global variables (caching as needed) \%0a of the same name (in reverse alphabetical order, and filtering out any unsafe globals) *%0a# Replace any $-sequences with values out of the array $FmtV.%0a%0aNote that [@FmtPageName@]() is automatically aware of any global%0avariables. However, since modifying global variables may be expensive, the%0aarray $FmtV exists as a way to avoid rebuilding the variable cache for%0avalues that change frequently.%0a%0a!! Security%0a%0aAccording to PM, as a general rule it's unwise to be calling FmtPageName() on strings that are coming from page markup, as this exposes the ability for people to view the values of variables that perhaps they shouldn't see. This is also why page variables (which come from markup) use PageVar() and PageTextVar() and don't go through FmtPageName().%0a%0a!! Availability of Variables in FmtPageName%0a%0aTo be very specific, here's what Pm wrote regarding different ways of%0adefining a variable that can be used by FmtPageName (when it is formatting a%0astring):%0a%0a* Set a global variable. FmtPageName() automatically performs \%0a substitution on all global variables that aren't arrays. \%0a If the variable is going to change value over repeated calls \%0a to FmtPageName, it's probably better to use $FmtV as in the next item.%0a%0a* Set a value in the $FmtV array. $FmtV['$MyVariable']='something' \%0a means to replace instances of '$MyVariable' with 'something'. \%0a Use this for variables that change value frequently over \%0a multiple calls to FmtPageName. %0a%0a* Set a pattern/replacement in the $FmtP array. This is normally \%0a done for substitutions that have to be dynamic somehow based on \%0a the pagename being referenced, such as '$Title', '$Group', '$Name', \%0a '$PageUrl', etc.%0a%0aAlso see: [[Cookbook:Functions#FmtPageName]]%0a%0aFinally, here's something else Pm wrote that is related and explains%0awhy we have this function:%0a%0a-> In order to produce its output, PmWiki has to do a variety of string \%0a substitutions:%0a%0a## Generating the full name, group, title, or url of a page \%0a (other than the currently displayed page)%0a## Substituting the values of global variables%0a## Performing internationalization substitutions%0a## Converting $ScriptUrl/$Group/$Name to $ScriptUrl?n=$Group.$Name \%0a for sites that cannot handle PATH_INFO urls%0a## Other substitutions needed by specific functions%0a %0a-> PmWiki centralizes all of that substitute-a-dynamic-value-in-a-string \%0a into the FmtPageName() subroutine. Because some things are extremely \%0a dynamic, such as the url or group for an arbitrary page that is not the \%0a current one, those things cannot be simple global PHP variables. Or, if \%0a they do become global variables, they're variables that cannot be \%0a trusted to hold a value for very long because some other routine (that \%0a may happen to be formatting a string for a different page) will come \%0a along and change that global variable for whatever it happens to be doing.%0a%0a-> A limited set of $-substitutions -- basically anything that \%0a corresponds to a page attribute -- are not PHP variables and \%0a are only available through the FmtPageName() subroutine. \%0a The complete set of these special substitutions is $Group, \%0a $Name, $FullName, $PageUrl, $Title, $Titlespaced, $Namespaced, \%0a $Groupspaced, $LastModifiedBy, $LastModifiedHost, and $LastModified. \%0a These items cannot just be standard PHP variables because often\%0a PmWiki needs to obtain the url, name, group, title, etc. of a page \%0a other than the one currently being viewed by a browser.%0a%0a-> At the moment, $Title, $LastModified, $LastModifiedBy, and \%0a $LastModifiedHost can only work if the page's attributes have been \%0a loaded and cached using the `PCache function. So, to get\%0a at these values one must typically do:%0a%0a-> [@%0a$page = ReadPage($pagename);%0aPCache($pagename, $page);%0a$ptitle = FmtPageName('$Title', $pagename);%0a$pauthor = FmtPageName('$LastModifiedBy', $pagename);%0a@]%0a -time=1315670897 +rev=45 +targets=PmWiki.Functions,PmWiki.Variables,PmWiki.Internationalizations,PmWiki.LayoutVariables,PmWiki.BasicVariables,PmWiki.PageVariables,PmWiki.OtherVariables,PmWiki.PathVariables,Cookbook.Functions +text=(:Summary: Documentation for the PmWiki internal function [@FmtPageName()@] :)%0a(:Audience: admins (advanced) :)%0aThis page describes an internal function in PmWiki's engine called %25hlt php%25[@FmtPageName()@]. %0aThe contents are not intended for those with a weak heart%0a;-)%0a%0aAlso see: [[PmWiki.Functions]]%0a%0a!! [[#FmtPageName]] %25hlt php%25[@FmtPageName($fmt, $pagename)@]%0a%0a[[#FmtPageName-desc]]Returns [@$fmt@], with @@$variable@@ and @@$[internationalisation]@@ substitutions performed, under the assumption that the current page is [@pagename@]. As a rule is used to pre-process all variables which by convention have a "Fmt" suffix (like $GroupFooterFmt), but also other strings that require %25newwin%25[[Wikipedia:Variable_%2528programming%2529#Interpolation | interpolation]], notably the page template (.tmpl) file. See [[PmWiki.Variables]] for an (incomplete) list of available variables, [[PmWiki.Internationalizations]] for internationalisation.%0a%0aThe function %25hlt php%25[@FmtPageName()@] applies internationalization-substitutions%0aand $Variable-substitions to the string @@$fmt@@ under the assumption that the%0acurrent page is @@$pagename@@.%0a%0aThe substitutions go as follows:%0a%0a# Replace any sequences of the form [@$XyzFmt@] with value of any \%0a corresponding global variable.%0a# Process the string for any %25pmhlt%25[@$[...]@] phrases (internationalized phrase), \%0a using the currently loaded translation tables.%0a# Replace any instances of %25pmhlt%25[@{$ScriptUrl}@] with [@$ScriptUrl@] \%0a (to defer processing to the URI processing phase)%0a# Replace any instances of standard [[PmWiki/PageVariables|Page Variables]] \%0a (beginning with an upper case letter, followed by at least one word character) \%0a with their values. %25green%25Note that PVs of the form %25pmhlt%25[@{Group.Page$Var}@] are '''not''' replaced.%25%25\%0a If there are no more $-sequences, then return the formatted string and exit the function%0a# Perform any pattern replacements from the array $FmtP. Typically \%0a this is used to handle things like $Name and $Group etc that are \%0a specific to the name of the current page. %25green%25''?? Appears to be used in @@robots.php@@ to hide actions from robots.''%0a# Replace any remaining instances of Page Variables with their values. \%0a %25green%25Note that these variables are in the form %25pmhlt%25[@$Var@] rather than the usual PV form of [@{$Var}@].%25%25%0a# If $EnablePathInfo isn't set, convert [@URIs@] to use the syntax \%0a @@$ScriptUrl?n=%3cGroup>.%3cName> instead of $ScriptUrl/%3cGroup>/%3cName>@@. \%0a In any case, replace $ScriptUrl with its value. \%0a If there are no more $-sequences, then return the formatted string and exit the function%0a# Replace any $-sequences with global variables (caching as needed) \%0a of the same name (in reverse alphabetical order, and filtering out any unsafe globals) *%0a# Replace any $-sequences with values out of the array $FmtV.%0a%0aNote that %25hlt php%25[@FmtPageName()@] is automatically aware of any global%0avariables. However, since modifying global variables may be expensive, the%0aarray $FmtV exists as a way to avoid rebuilding the variable cache for%0avalues that change frequently.%0a%0a!! Security%0a%0aAccording to PM, as a general rule it's unwise to be calling %25hlt php%25@@FmtPageName()@@ on strings that are coming from page markup, as this exposes the ability for people to view the values of variables that perhaps they shouldn't see. This is also why page variables (which come from markup) use @@PageVar()@@ and @@PageTextVar()@@ and don't go through @@FmtPageName()@@.%0a%0a!! Availability of Variables in FmtPageName%0a%0aTo be very specific, here's what Pm wrote regarding different ways of%0adefining a variable that can be used by FmtPageName (when it is formatting a%0astring):%0a%0a* Set a global variable. %25hlt php%25@@FmtPageName()@@ automatically performs \%0a substitution on all global variables that aren't arrays. \%0a If the variable is going to change value over repeated calls \%0a to @@FmtPageName()@@, it's probably better to use $FmtV as in the next item.%0a%0a* Set a value in the $FmtV array. %25hlt php%25@@$FmtV['$MyVariable']='something'@@ \%0a means to replace instances of '$MyVariable' with 'something'. \%0a Use this for variables that change value frequently over \%0a multiple calls to FmtPageName. %0a%0a* Set a pattern/replacement in the $FmtP array. This is normally \%0a done for substitutions that have to be dynamic somehow based on \%0a the pagename being referenced, such as '$Title', '$Group', '$Name', \%0a '$PageUrl', etc.%0a%0aAlso see: [[Cookbook:Functions#FmtPageName]]%0a%0aFinally, here's something else Pm wrote that is related and explains%0awhy we have this function:%0a%0a-> In order to produce its output, PmWiki has to do a variety of string \%0a substitutions:%0a%0a## Generating the full name, group, title, or url of a page \%0a (other than the currently displayed page)%0a## Substituting the values of global variables%0a## Performing internationalization substitutions%0a## Converting @@$ScriptUrl/$Group/$Name to $ScriptUrl?n=$Group.$Name@@ \%0a for sites that cannot handle PATH_INFO urls%0a## Other substitutions needed by specific functions%0a %0a-> PmWiki centralizes all of that substitute-a-dynamic-value-in-a-string \%0a into the %25hlt php%25@@FmtPageName()@@ subroutine. Because some things are extremely \%0a dynamic, such as the url or group for an arbitrary page that is not the \%0a current one, those things cannot be simple global PHP variables. Or, if \%0a they do become global variables, they're variables that cannot be \%0a trusted to hold a value for very long because some other routine (that \%0a may happen to be formatting a string for a different page) will come \%0a along and change that global variable for whatever it happens to be doing.%0a%0a-> A limited set of $-substitutions -- basically anything that \%0a corresponds to a page attribute -- are not PHP variables and \%0a are only available through the %25hlt php%25@@FmtPageName()@@ subroutine. \%0a The complete set of these special substitutions is $Group, \%0a $Name, $FullName, $PageUrl, $Title, $Titlespaced, $Namespaced, \%0a $Groupspaced, $LastModifiedBy, $LastModifiedHost, and $LastModified. \%0a These items cannot just be standard PHP variables because often\%0a PmWiki needs to obtain the url, name, group, title, etc. of a page \%0a other than the one currently being viewed by a browser.%0a%0a-> At the moment, $Title, $LastModified, $LastModifiedBy, and \%0a $LastModifiedHost can only work if the page's attributes have been \%0a loaded and cached using the `PCache function. So, to get\%0a at these values one must typically do:%0a%0a-> %25hlt php%25[@%0a$page = ReadPage($pagename);%0aPCache($pagename, $page);%0a$ptitle = FmtPageName('$Title', $pagename);%0a$pauthor = FmtPageName('$LastModifiedBy', $pagename);%0a@]%0a +time=1668802181 blob - e12b2f538f02f8437e126a288ea4bdbbddd30f69 blob + 79d87c082eb2e2a4fe533ecc0bbd4c07d1673d67 --- wikilib.d/PmWiki.Forms +++ wikilib.d/PmWiki.Forms @@ -1,10 +1,10 @@ -version=pmwiki-2.2.122 ordered=1 urlencoded=1 +version=pmwiki-2.3.5 ordered=1 urlencoded=1 author=Petko charset=UTF-8 -csum=formnovalidate +csum=+lang input attribute (+6) ctime=1181479161 name=PmWiki.Forms -rev=80 +rev=85 targets=Cookbook.InputDefault,PmWiki.OtherVariables,Cookbook.FormValidation,Cookbook.FormExtensions,Cookbook.InputFormsAndJavaScript,PmWiki.PageLists,Cookbook.PmForm,Cookbook.Fox,Cookbook.Input,Cookbook.WikiForms,Cookbook.ProcessForm -text=(:Summary:How you can embed input forms into wiki pages:)%0aThis page explains how you can embed input forms into wiki pages. Input forms don't actually handle processing of the form data -- the feature simply allows creation of forms inside wiki pages. Forms processing can be found in the Cookbook (see below).%0a%0a!! Markup%0aTwo directives are used to begin and end forms:%0a%0a [=(:input=] form "''url''" ''method'':)%0a ...%0a [=(:input end:)=]%0a%0aThe [@(:input form:)@] directive starts a form that will post to ''url'' (optional ''action=''url) using the supplied ''method'' (optional ''method=''method). The ''url'' must be in quotes if not specified via ''action=''. If the url is omitted, then the current page is assumed. If ''method'' is omitted then "POST" is assumed. An optional [@name="FormName"@] argument can be used to name the form. You can explicitly state @@action=url@@ or @@method=get@@ or you can simply use them as positional parameters.%0a%0aIf your site uses ?n=Group.Page to specify the pagename then having a field [@(:input hidden name=n value={$FullName}:)@] will allow your form to post to the current page as an alternative to fully specifying the action=url.%0a%0aThe [@(:input end:)@] directive ends the current form.%0a%0aNote that this feature doesn't ensure that the form output is correct HTML -- it assumes the author knows a little bit of what he or she is doing. Notably, [=(:input form:) and (:input end:)=] shouldn't appear inside tables, and all form fields and controls should be inside an [=(:input form:)...(:input end:)=] block.%0a%0a[[#standardinputcontrols]]%0a!!Standard input controls%0aThe standard input controls are:%0a%0a [=(:input=] text ''name'' ''value'' size=''n'':)%0a [=(:input=] hidden ''name'' ''value'':)%0a [=(:input=] password ''name'' ''value'':)%0a [=(:input=] search ''name'' ''value'':)%0a [=(:input=] number ''name'' ''value'' min=x max=y step=z:)%0a [=(:input=] email ''name'' ''value'':)%0a [=(:input=] tel ''name'' ''value'':)%0a [=(:input=] url ''name'' ''value'':)%0a [=(:input=] date ''name'' ''value'':)%0a [=(:input=] radio ''name'' ''value'' ''label'' checked=checked:)%0a [=(:input=] checkbox ''name'' ''value'' ''label'' checked=checked:)%0a [=(:input=] [[#select|select]] ''name'' ''value'' ''label'':)%0a [=(:input=] [[#datalist|datalist]] ''id'' ''value'':)%0a [=(:input=] [[Cookbook:InputDefault|default]] ''default-name'' ''default-value'':) %0a [=(:input=] textarea ''name'' ''[@[=value=]@]'' rows=''n'' cols=''n'':)%0a [=(:input=] file ''name'' ''label'':)%0a [=(:input=] image ''name'' ''"src"'' ''alt'':)%0a [=(:input=] reset ''name'' ''label'':)%0a [=(:input=] button ''name'' ''value'':)%0a [=(:input=] submit ''name'' ''value'':)%0a%0aWhere ''name'' and ''value'' are in the HTML syntax: name="addr" value="808 W Franklin".%0a%0aFor most controls the markup has the form:%0a%0a [=(:input=] ''type'' ''name'' ''value'' ''parameter=value'':)%0a%0awhere ''type'' is the type of input element (described below), ''name'' is the name of the control, ''value'' is its initial value, and parameters are used to specify additional attributes to the control. If ''value'' contains spaces, enclose it in quotes; if it contains newlines (for textarea and hidden elements), enclose it in [@[=...=]@]. %0a%0aFor example, the following creates a text input control with a size of 30 characters:%0a%0a(:markup:)%0a(:input text authorid "Jane Doe" size=30:)%0a(:markupend:)%0a%0aFor convenience, an author can also specify name and value arguments directly using [@name=@] and [@value=@] attributes (same as HTML):%0a%0a(:markup:) %0a(:input text name=authorid value="Jane Doe" size=30:)%0a(:markupend:)%0a%0aFor the @@textarea@@ control a value can be set from PmWiki 2.2.0beta45 onwards. Enclose the value in [@[=...=]@] if it contains spaces or new lines.%0a%0aThe [@submit@] control will more often be written as:%0a%0a [=(:input=] submit value=''label'':)%0a%0aHere's a more complete example, e.g., for a login prompt:%0a%0a(:markup:) [=%0a(:input form "http://www.example.com":)%0a(:input hidden action login:)%0a|| Name:||(:input text username:) ||%0a|| Password:||(:input password password:) ||%0a|| ||(:input checkbox terms yes "Accept Terms":) ||%0a|| ||(:input submit value="Log In":) ||%0a(:input end:)%0a=]%0a%0a[[#field_attributes]]%0a!! General form field attributes%0a* [@(:input ... focus=1:)@] Setting @@focus=1@@ causes that field to receive the initial focus when the form is first opened.%0a%0a* The following advanced HTML attributes are supported: @@name, value, id, class, rows, cols, size, maxlength, action, method, accesskey, tabindex, multiple, checked, disabled, readonly, enctype, src, alt, title, required, placeholder, autocomplete, min, max, step, pattern, list, formnovalidate@@. For a more detailed description, see their counterparts in the [[https://www.w3.org/TR/html5/forms.html#common-input-element-attributes|w3c reference: HTML5 form attributes]] (not all of them can be used for all types of form fields).%0a%0a* For checkboxes and radio inputs, the "label" attribute text will be displayed ''after'' the input as a %3clabel> element. Clicking on it will check or uncheck the input. The label can only be plain text (no inline formatting like bold or links).%0a%0a* In addition to these, the following attributes can be used for accessibility enhancements: @@role, aria-label, aria-labelledby, aria-describedby, aria-expanded, aria-pressed, aria-current, aria-hidden@@.%0a%0a* In addition to the default attributes, you can use custom data attributes like @@data-some-variable=value@@ or @@data-other="Some data"@@ (usable by custom JavaScript, CSS or by some libraries). The attribute must start with "data-" and only contain lowercase Latin letters [a-z] and dashes [-].\\%0aThis can be disabled in config.php with the line @@$EnableInputDataAttr = 0;@@%0a%0a* Any unsupported attributes in the wiki markup will not be included in the HTML output.%0a%0a[[#select]]%0a!![@(:input select ... :)@]%0a%0aThe basic form of a select box is a sequence of options:%0a%0a(:markup:) [=%0a(:input form:)%0a(:input select name=abc value=1 label=alpha :)%0a(:input select name=abc value=2 label=beta :)%0a(:input select name=abc value=3 label=gamma :)%0a(:input submit:)%0a(:input end:)%0a=]%0a%0aThe values can be specified positionally:%0a [=(:input select abc 1 alpha :)=]%0a%0aWe can specify the size of the selection box:%0a [=(:input select abc 1 alpha size=3 :)=]%0a%0aYou can specify a multiple select box (only the first item needs to have "size=3 multiple" attributes):%0a [=(:input select abc 1 alpha size=3 multiple:)=]%0a%0aTo have an element selected, use @@selected=selected@@:%0a [=(:input select abc 2 beta selected=selected:)=]%0a%0aNote that to have two select boxes inline, not only should you give them different @@name=@@ parameters, but also place a separator, like a character, [@ @] or even the null sequence [@[==]@] between them:%0a(:markup:)%0a(:input form:)%0a(:input select name=FIRST value=1:)(:input select name=FIRST value=2:)[==]%0a(:input select name=SECOND value=3:)(:input select name=SECOND value=4:)%0a(:input end:)%0a(:markupend:)%0a%0a%25note%25 Note, in the HTML output, only the attributes @@label@@, @@value@@ and @@selected@@ are applied to the [@%3coption>@] HTML tag. Any other attributes, including @@name@@, @@id@@, @@class@@ and @@title@@ are applied to the wrapping [@%3cselect>@] HTML tag, and later definitions replace previous ones.%0a%0a%0a[[#datalist]]%0a!![@(:input datalist ... :)@]%0aThis allows a number of values (suggestions) to appear in a drop-down menu allowing the user to select one of the values or to fill a new, different value. The markup accepts named or positional attributes:%0a%0a [@(:@]input datalist ''id'' ''value'':)%0a [@(:@]input datalist id=''id'' value=''value'':)%0a%0aAn existing [@(:input text:)@] field needs to have an attribute @@list=id_of_the_datalist@@ to attach the suggestions.%0a%0aThe datalist element is invisible and can be anywhere in the page. The suggestion menu appears when the user starts typing in the attached text field and filters the suggested values that contain the letters typed in the text field.%0a%0a(:markup:) [=%0aType a browser name: (:input text browsers list=dlist_id :)%0a(:input datalist dlist_id Firefox:)%0a(:input datalist dlist_id Chrome:)%0a(:input datalist dlist_id Safari:)%0a(:input datalist dlist_id Edge:)%0a(:input datalist dlist_id MSIE:)%0a(:input datalist dlist_id Opera:)%0a(:input datalist dlist_id Lynx:)%0a=]%0a%0aThis is a recent addition to the HTML standard, see https://caniuse.com/#feat=datalist for current browser support.%0a%0aNote that if you have a datalist element immediately following another datalist element, not only should you give them different @@id=@@ attributes, but also place a separator, like a character, [@ @] or the null sequence [@[==]@] between them: [@%0a(:input datalist dl_1 First:)%0a(:input datalist dl_1 Second:)[==]%0a(:input datalist dl_2 First:)%0a(:input datalist dl_2 Second:)%0a@]%0a%0a!! See Also%0a*[[Cookbook:Input Default]] {Cookbook.InputDefault$:Summary}%0a*[[Cookbook:Form Validation]] {Cookbook.FormValidation$:Summary}%0a*[[Cookbook:Form Extensions]] {Cookbook.FormExtensions$:Summary}%0a*[[Cookbook:Input Forms and JavaScript]] {Cookbook.InputFormsAndJavaScript$:Summary}%0a*[[PageLists#searchbox]] The [@(:searchbox:)@] directive creates a form to search the wiki%0a%0aCompatible recipes:%0a* [[Cookbook:PmForm]] {Cookbook/PmForm$:Summary}%0a* [[Cookbook:Fox]] {Cookbook.Fox$:Summary}%0a* [[Cookbook:Wiki Forms]] {Cookbook/WikiForms$:Summary}%0a* [[Cookbook:ProcessForm]] {Cookbook/ProcessForm$:Summary}%0a%0a -time=1574430525 +text=(:Summary:How you can embed input forms into wiki pages:)%0aThis page explains how you can embed input forms into wiki pages. Input forms don't actually handle processing of the form data -- the feature simply allows creation of forms inside wiki pages. Forms processing can be found in the Cookbook (see below).%0a%0a!! Markup%0aTwo directives are used to begin and end forms:%0a%0a %25pmhlt%25[@(:input form "url" method:)@]%0a ...%0a %25pmhlt%25[@(:input end:)@]%0a%0aThe %25pmhlt%25[@(:input form:)@] directive starts a form that will post to ''url'' (optional ''action=''url) using the supplied ''method'' (optional ''method=''method). The ''url'' must be in quotes if not specified via ''action=''. If the url is omitted, then the current page is assumed. If ''method'' is omitted then "POST" is assumed. An optional [@name="FormName"@] argument can be used to name the form. You can explicitly state @@action=url@@ or @@method=get@@ or you can simply use them as positional parameters.%0a%0aIf your site uses ?n=Group.Page to specify the pagename then having a field %25pmhlt%25[@(:input hidden name=n value={$FullName}:)@] will allow your form to post to the current page as an alternative to fully specifying the action=url.%0a%0aThe %25pmhlt%25[@(:input end:)@] directive ends the current form.%0a%0a%25pmhlt%25Note that this feature doesn't ensure that the form output is correct HTML -- it assumes the author knows a little bit of what he or she is doing. Notably, [@(:input form:)@] and [@(:input end:)@] shouldn't appear inside tables, and all form fields and controls should be inside an [@(:input form:)...(:input end:)@] block.%0a%0a[[#standardinputcontrols]]%0a!!Standard input controls%0aThe standard input controls are:%0a%0a %25pmhlt%25[@(:input text name "value" size=n:) @]%0a %25pmhlt%25[@(:input hidden name "value":) @]%0a %25pmhlt%25[@(:input password name "value":) @]%0a %25pmhlt%25[@(:input search name "value":) @]%0a %25pmhlt%25[@(:input number name "value" min=x max=y step=z:) @]%0a %25pmhlt%25[@(:input email "name "value":) @]%0a %25pmhlt%25[@(:input tel name "value":) @]%0a %25pmhlt%25[@(:input url name "value":) @]%0a %25pmhlt%25[@(:input date name "value":) @]%0a %25pmhlt%25[@(:input radio name "value" "label" checked=checked:) @]%0a %25pmhlt%25[@(:input checkbox name "value" "label" checked=checked:) @]%0a %25pmhlt%25[@(:input select name "value" "label":) @] - see [[#select|select]]%0a %25pmhlt%25[@(:input datalist id "value":) @] - see [[#datalist|datalist]]%0a %25pmhlt%25[@(:input default default-name "default-value":) @] - see [[Cookbook:InputDefault|default]]%0a %25pmhlt%25[@(:input textarea name [=value=] rows=n cols=n:) @]%0a %25pmhlt%25[@(:input file name "label":) @]%0a %25pmhlt%25[@(:input image name "src" "alt":) @]%0a %25pmhlt%25[@(:input reset name "label":) @]%0a %25pmhlt%25[@(:input button name "value":) @]%0a %25pmhlt%25[@(:input submit name "value":) @]%0a%0aWhere ''name'' and ''value'' are in the HTML syntax: name="addr" value="808 W Franklin".%0a%0aFor most controls the markup has the form:%0a%0a %25pmhlt%25[@(:input type name "value" parameter="value":) @]%0a%0awhere ''type'' is the type of input element (described below), ''name'' is the name of the control, ''value'' is its initial value, and parameters are used to specify additional attributes to the control. If ''value'' contains spaces, enclose it in quotes; if it contains newlines (for textarea and hidden elements), enclose it in %25pmhlt%25[@[=...=]@]. %0a%0aFor example, the following creates a text input control with a size of 30 characters:%0a%0a(:markup:)%0a(:input text authorid "Jane Doe" size=30:)%0a(:markupend:)%0a%0aFor convenience, an author can also specify name and value arguments directly using %25pmhlt%25[@name=@] and [@value=@] attributes (same as HTML):%0a%0a(:markup:) %0a(:input text name=authorid value="Jane Doe" size=30:)%0a(:markupend:)%0a%0aFor the @@textarea@@ control a value can be set from PmWiki 2.2.0beta45 onwards. Enclose the value in %25pmhlt%25[@[=...=]@] if it contains spaces or new lines.%0a%0aThe %25pmhlt%25[@submit@] control will more often be written as:%0a%0a %25pmhlt%25[@(:input submit value="label":) @]%0a%0aHere's a more complete example, e.g., for a login prompt:%0a%0a(:markup:) [=%0a(:input form "https://www.example.com":)%0a(:input hidden action login:)%0a|| Name:||(:input text username:) ||%0a|| Password:||(:input password password:) ||%0a|| ||(:input checkbox terms yes "Accept Terms" required=required:) ||%0a|| ||(:input submit value="Log In":) ||%0a(:input end:)%0a=]%0a%0a[[#field_attributes]]%0a!! General form field attributes%0a* %25pmhlt%25[@(:input ... focus=1:)@] Setting @@focus=1@@ causes that field to receive the initial focus when the form is first opened.%0a%0a* The following advanced HTML attributes are supported: @@name, value, id, class, rows, cols, size, maxlength, action, method, accesskey, tabindex, multiple, checked, disabled, readonly, enctype, src, alt, title, required, placeholder, autocomplete, min, max, step, pattern, list, formnovalidate, accept, autofocus, lang@@. For a more detailed description, see their counterparts in the [[https://www.w3.org/TR/html5/forms.html#common-input-element-attributes|w3c reference: HTML5 form attributes]] (not all of them can be used for all types of form fields).%0a%0a* For checkboxes and radio inputs, the "label" attribute text will be displayed ''after'' the input as a %3clabel> element. Clicking on it will check or uncheck the input. The label can only be plain text (no inline formatting like bold or links).%0a%0a* In addition to these, the following attributes can be used for accessibility enhancements: @@role, aria-label, aria-labelledby, aria-describedby, aria-expanded, aria-pressed, aria-current, aria-hidden@@.%0a%0a* In addition to the default attributes, you can use custom data attributes like @@data-some-variable=value@@ or @@data-other="Some data"@@ (usable by custom JavaScript, CSS or by some libraries). The attribute must start with "data-" and only contain lowercase Latin letters [a-z] and dashes [-].\\%0aThis can be disabled in @@config.php@@ with the line @@$EnableInputDataAttr = 0;@@%0a%0a* Any unsupported attributes in the wiki markup will not be included in the HTML output.%0a%0a[[#select]]%0a!! ([=:=]input select ... :)%0a%0aThe basic form of a select box is a sequence of options:%0a%0a(:markup:) [=%0a(:input form:)%0a(:input select name=abc value=1 label=alpha :)%0a(:input select name=abc value=2 label=beta :)%0a(:input select name=abc value=3 label=gamma :)%0a(:input submit:)%0a(:input end:)%0a=]%0a%0aThe values can be specified positionally:%0a %25pmhlt%25[@(:input select abc 1 alpha :)@]%0a%0aWe can specify the size of the selection box:%0a %25pmhlt%25[@(:input select abc 1 alpha size=3 :)@]%0a%0aYou can specify a multiple select box (only the first item needs to have "size=3 multiple" attributes):%0a %25pmhlt%25[@(:input select abc 1 alpha size=3 multiple:)@]%0a%0aTo have an element selected, use @@selected=selected@@:%0a %25pmhlt%25[@(:input select abc 2 beta selected=selected:)@]%0a%0aNote that to have two select boxes inline, not only should you give them different @@name=@@ parameters, but also place a separator, like a character, %25pmhlt%25[@ @] or even the null sequence [@[==]@] between them:%0a(:markup:)%0a(:input form:)%0a(:input select name=FIRST value=1:)(:input select name=FIRST value=2:)[==]%0a(:input select name=SECOND value=3:)(:input select name=SECOND value=4:)%0a(:input end:)%0a(:markupend:)%0a%0a%25note pmhlt%25 Note, in the HTML output, only the attributes @@label@@, @@value@@ and @@selected@@ are applied to the [@%3coption>@] HTML tag. Any other attributes, including @@name@@, @@id@@, @@class@@ and @@title@@ are applied to the wrapping [@%3cselect>@] HTML tag, and later definitions replace previous ones.%0a%0a%0a[[#datalist]]%0a!! ([=:=]input datalist ... :)%0aThis allows a number of values (suggestions) to appear in a drop-down menu allowing the user to select one of the values or to fill a new, different value. The markup accepts named or positional attributes:%0a%0a %25pmhlt%25[@(:input datalist id "value":) @]%0a %25pmhlt%25[@(:input datalist id=id value="value":) @]%0a%0aAn existing %25pmhlt%25[@(:input text:)@] field needs to have an attribute @@list=id_of_the_datalist@@ to attach the suggestions.%0a%0aThe datalist element is invisible and can be anywhere in the page. The suggestion menu appears when the user starts typing in the attached text field and filters the suggested values that contain the letters typed in the text field.%0a%0a(:markup:) [=%0aType a browser name: (:input text browsers list=dlist_id :)%0a(:input datalist dlist_id Firefox:)%0a(:input datalist dlist_id Chrome:)%0a(:input datalist dlist_id Safari:)%0a(:input datalist dlist_id Edge:)%0a(:input datalist dlist_id MSIE:)%0a(:input datalist dlist_id Opera:)%0a(:input datalist dlist_id Lynx:)%0a=]%0a%0aThis is a recent addition to the HTML standard, see https://caniuse.com/#feat=datalist for current browser support.%0a%0a%25pmhlt%25Note that if you have a datalist element immediately following another datalist element, not only should you give them different @@id=@@ attributes, but also place a separator, like a character, [@ @] or the null sequence [@[==]@] between them: [@%0a(:input datalist dl_1 First:)%0a(:input datalist dl_1 Second:)[==]%0a(:input datalist dl_2 First:)%0a(:input datalist dl_2 Second:)%0a@]%0a%0a!! See Also%0a*[[Cookbook:Input Default]] {Cookbook.InputDefault$:Summary}%0a*[[Cookbook:Form Validation]] {Cookbook.FormValidation$:Summary}%0a*[[Cookbook:Form Extensions]] {Cookbook.FormExtensions$:Summary}%0a*[[Cookbook:Input Forms and JavaScript]] {Cookbook.InputFormsAndJavaScript$:Summary}%0a*[[PageLists#searchbox]] The [@(:searchbox:)@] directive creates a form to search the wiki%0a%0aCompatible recipes:%0a* [[Cookbook:PmForm]] {Cookbook/PmForm$:Summary}%0a* [[Cookbook:Fox]] {Cookbook.Fox$:Summary}%0a* [[Cookbook:Wiki Forms]] {Cookbook/WikiForms$:Summary}%0a* [[Cookbook:ProcessForm]] {Cookbook/ProcessForm$:Summary}%0a%0a +time=1653658241 blob - f52af8b5c3854d3fbad5e347491b0a4b08fffe9c blob + 5484dacfa560f34e1ec93ee70b72db5fbb3a6a1d --- wikilib.d/PmWiki.Functions +++ wikilib.d/PmWiki.Functions @@ -1,9 +1,9 @@ -version=pmwiki-2.2.118 ordered=1 urlencoded=1 +version=pmwiki-2.3.18 ordered=1 urlencoded=1 author=Petko charset=UTF-8 -csum=clearly the manual toc is better: (:notoc:) +csum=$FmtV['$LinkDownload'] (+122) name=PmWiki.Functions -rev=146 -targets=Cookbook.Functions,PmWiki.CustomMarkup,PmWiki.CustomActions,PmWiki.SecurityVariables,Cookbook.PccfToPcfOverride,PmWiki.LinkVariables,PmWiki.OtherVariables,PmWiki.EditVariables,PmWiki.UploadVariables,PmWiki.Functions,PmWiki.BasicVariables,PmWiki.Variables,PmWiki.Internationalizations,PmWiki.FmtPageName,PmWiki.MakeLink,PmWiki.ConditionalMarkup,PmWiki.Drafts,PmWiki.UpdatePage,Cookbook.MarkupExpressionSamples,Category.PmWikiDeveloper -text=(:Summary: How some of the functions in pmwiki.php work:)%0a(:Audience: admins (advanced) :)(:notoc:)%0a%0a>>rframe font-size:smaller clear:right%3c%3c%0a!! [[#contents]] Table of Contents%0a*[[#pmcrypt|pmcrypt()]]%0a*[[#pmsetcookie|pmsetcookie()]]%0a*[[#PCCF|PCCF()]] %25red%25(deprecated)%25%25%0a*[[#PPRA|PPRA()]]%0a*[[#PPRE|PPRE()]] %25red%25(deprecated)%25%25%0a*[[#Qualify|Qualify()]]%0a*[[#PHSC|PHSC()]]%0a*[[#PSS|PSS()]]%0a*[[#stripmagic|stripmagic()]]%0a*[[#FmtPageName|FmtPageName()]]%0a*[[#Markup|Markup()]]%0a*[[#mkdirp|mkdirp()]]%0a*[[#MakeLink|MakeLink()]]%0a*[[#MakeUploadName|MakeUploadName()]]%0a*[[#SessionAuth|SessionAuth()]]%0a*[[#IsAuthorized|IsAuthorized()]]%0a*[[#CondAuth|CondAuth()]]%0a*[[#RetrieveAuthPage|RetrieveAuthPage()]]%0a*[[#RetrieveAuthSection|RetrieveAuthSection()]]%0a*[[#UpdatePage|UpdatePage()]]%0a>>%3c%3c%0a%0aThis page describes some of the internal workings of PmWiki by explaining how some of the functions in pmwiki.php work. For a more brief list/overview on functions useful to for instance cookbook writers, see Cookbook:Functions. %0a%0aTo use this functions you have to make sure that all relevant internal variables have been initialized correctly. See [[Custom Markup]] and [[(PmWiki:)Custom Actions]] for more information on how these functions are typically called via [@Markup()@] or [@$HandleActions[]@].%0a%0a!! [[#pmcrypt]] [@pmcrypt($password, $salt = null)@]%0aThe pmcrypt() function is intended to be a safe replacement for the [[http://php.net/crypt|PHP 5.6+ crypt() function]] without providing a $salt, which would raise a notice. If a salt is provided, crypt() is called to check an existing password. If a salt is not provided, [[http://php.net/password_hash|password_hash()]] will be called to create a cryptographically strong password hash.%0a%0a!! [[#pmsetcookie]] [@pmsetcookie($name, $val="", $exp=0, $path="", $dom="", $secure=null, $httponly=null)@]%0a%0aThis function is intended as a replacement for [[http://php.net/setcookie|setcookie()]]. It will automatically set the $secure and $httponly arguments if they are not set by the caller function and if $EnableCookieSecure and $EnableCookieHTTPOnly are enabled.%0a%0a!![[#PCCF]] [@PCCF($php_code, $callback_template='default', $callback_arguments = '$m')@] %25red%25 Deprecated since PHP 7.2%25%25%0aThe PCCF() function (''PmWiki Create Callback Function'') can be used to create callback functions used with [[(http://php.net/)preg_replace_callback]]. It is required for PHP 5.5, but will also work with earlier PHP versions.%0a%0aThe first argument is the PHP code to be evaluated. %0a%0aThe second argument (optional) is the callback template, a key from the global $CallbackFnTemplates array. There are two templates that can be used by recipe authors: %0a* 'default' will pass $php_code as a function code%0a* 'return' will wrap $php_code like "return $php_code;" (since PmWiki 2.2.62)%0a%0aThe third argument (optional) is the argument of the callback function. Note that PmWiki uses the '$m' argument to pass the matches of a regular expression search, but your function can use other argument(s).%0a%0aPCCF() will create an anonymous (lambda) callback function containing the supplied code, and will cache it. On subsequent calls with the same $php_code, PCCF() will return the cached function name.%0a%0aSee http://php.net/create_function.%0a%0a>>font-style=italic%3c%3c%0aPHP 7.2 deprecates create_function() and future versions will remove it. If you need to migrate older code that used PCCF(), you can usually write regular functions and pass the function name where you previously passed the result of PCCF(). For example, suppose you had a pattern like this:%0a '/(?%3c=^| )([a-z])/' => PCCF("return strtoupper(\$m[1]);"),%0a%0aFor PHP 7.2 compatibility, you can write a callback function:%0a function %25green%25my_callback%25%25($m) { return strtoupper($m[1]); }%0a%0athen change the pattern to look like this:%0a '/(?%3c=^| )([a-z])/' => '%25green%25my_callback%25%25',%0a%0aSee also: the recipe [[(Cookbook:)PccfToPcfOverride]] allows existing recipes to run on PHP 7 without causing deprecated create_function() messages.%0a>>%3c%3c%0a%0a!![[#PPRA]] [@PPRA($array_search_replace, $string)@]%0aThe PPRA() function (''PmWiki preg_replace array'') can be used to perform a regular expression replacement with or without evaluation, for PHP 5.5 compatibility. %0a%0aSince PmWiki 2.2.56, PmWiki uses this function to process the following arrays: $MakePageNamePatterns, $FmtP, $QualifyPatterns, $ROEPatterns, $ROSPatterns, $SaveAttrPatterns, $MakeUploadNamePatterns. Any custom settings should continue to work for PHP 5.4 and earlier, but wikis running on PHP 5.5 may need to make a few changes.%0a%0aThe first argument contains the 'search'=>'replace' pairs, the second is the "haystack" string to be manipulated.%0a%0aThe 'replace' parts of the array can be strings or function names. If the 'replace' part is a callable function name, it will be called with the array of matches as a first argument via preg_replace_callback(). If not a callable function, a simple preg_replace() will be performed.%0a%0aPreviously, PmWiki used such constructs:%0a $fmt = preg_replace(array_keys($FmtP), array_values($FmtP), $fmt);%0a%0aIt is now possible to use simply this:%0a $fmt = PPRA($FmtP, $fmt);%0a%0aNote that since PHP 5.5, the search patterns cannot have an /e evaluation flag. When creating the $array_search_replace array, before PHP 5.5 we could use something like (eg. for $MakePageNamePatterns):%0a '/(?%3c=^| )([a-z])/e' => "strtoupper('$1')",%0a%0aSince PHP 5.5, we should use this (will also work in PHP 5.4 and earlier):%0a '/(?%3c=^| )([a-z])/' => PCCF("return strtoupper(\$m[1]);"),%0a%0aNote that the /e flag should be now omitted, instead of '$0', '$1', '$2', we should use $m[0], $m[1], $m[2], etc. in the replacement code, and there is no need to call PSS() in the replacement code, as backslashes are not automatically added.%0a%0a>>font-style=italic%3c%3c%0aFor PHP 7.2 and newer, instead of using PCCF() to create anonymous functions, we add a real function in our add-on, and then pass the function name as the pattern replacement (see example at [[#PCCF|PCCF]], which will also work on PHP 4 and 5):%0a '/(?%3c=^| )([a-z])/' => '%25green%25my_callback%25%25',%0a>>%3c%3c%0a%0a!![[#PPRE]] [@PPRE($search_pattern, $replacement_code, $string)@] %25red%25 Deprecated since PHP 7.2%25%25%0aThe PPRE() function (''PmWiki preg_replace evaluate'') can be used to perform a regular expression replacement with evaluation.%0a%0aSince PHP 5.5, the preg_replace() function has deprecated the /e evaluation flag, and displays warnings when the flag is used. The PPRE() function automatically creates a callback function with the replacement code and calls it.%0a%0aBefore PHP 5.5, it was possible to use such calls:%0a $fmt = preg_replace('/\\$([A-Z]\\w*Fmt)\\b/e','$GLOBALS["$1"]',$fmt);%0a%0aSince PHP 5.5, it is possible to replace the previous snippet with the following (also works before PHP 5.5):%0a $fmt = PPRE('%25green%25/\\$([A-Z]\\w*Fmt)\\b/%25%25','$GLOBALS[$m[1]]',$fmt);%0a%0aNote that the /e flag should be now omitted, instead of '$0', '$1', '$2', we should use $m[0], $m[1], $m[2], etc. in the replacement code, and there is no need to call PSS() in the replacement code, as backslashes are not automatically added.%0a%0a>>font-style=italic%3c%3c%0aFor PHP 7.2 and newer, calling this function will raise "deprecated" notices. You need to rewrite your code to use [[(http://php.net/)preg_replace_callback]], by moving the code into real functions:%0a%0a $fmt = preg_replace_callback('%25green%25/\\$([A-Z]\\w*Fmt)\\b/%25%25', 'my_global_var_callback',$fmt);%0a function my_global_var_callback($m) { return $GLOBALS[$m[1]]; }%0a%0ainstead of using PCCF() to create anonymous functions, we add a real function in our add-on, and then pass the function name as the pattern replacement (see example at [[#PCCF|PCCF]], which will also work on PHP 4 and 5):%0a '/(?%3c=^| )([a-z])/' => '%25green%25my_callback%25%25',%0a>>%3c%3c%0a%0a!![[#Qualify]] [@Qualify($pagename, $text)@]%0aQualify() applies $QualifyPatterns to convert relative links and references into absolute equivalents.%0aThis function is called by usual wiki markups that include text from other pages.%0aIt will rewrite links like [@[[Page]]@] into [@[[Group/Page]]@], and page (text) variables like [@{$Title}@] into [@{Group.Page$Title}@]%0aso that they work the same way in the source page and in the including page.%0aSee also $QualifyPatterns and @@[[({$Name}#)RetrieveAuthSection]]()@@.%0a%0a%0a!![[#PHSC]] [@PHSC($string_or_array, $flags=ENT_COMPAT, $encoding=null, $double_encode=true)@]%0aThe PHSC() function (''PmWiki HTML special characters'') is a replacement for the PHP function [[(http://php.net/)htmlspecialchars]]. %0a%0aThe htmlspecialchars() function was modified since PHP 5.4 in two ways: it now requires a valid string for the supplied encoding, and it changes the default encoding to UTF-8. This can cause sections of the page to become blank/empty on many sites using the ISO-8859-1 encoding without having set the third argument ($encoding) when calling htmlspecialchars().%0a%0aThe PHSC() function calls htmlspecialchars() with an 8-bit encoding as third argument, whatever the encoding of the wiki (unless you supply an encoding). This way the string never contains invalid characters.%0a%0aIt should be safe for recipe developers to replace all calls to htmlspecialchars() with calls to PHSC(). Only the first argument is required when calling PHSC(), although authors may wish to call PHSC($string_or_array, ENT_QUOTES).%0a%0aUnlike htmlspecialchars(), the PHSC() function can process arrays recursively (only the values are converted, not the keys of the array).%0a%0a!![[#PSS]] [@PSS($string)@]%0a%0aThe PSS() function (''PmWiki Strip Slashes'') removes the backslashes that are%0aautomatically inserted in front of quotation marks by%0athe /e option of PHP's preg_replace function. PSS() is%0amost commonly used in replacement arguments to Markup(),%0awhen the pattern specifies /e and one or more of the %0aparenthesized subpatterns could contain a quote or backslash. %0a("PSS" stands for "PmWiki Strip Slashes".)%0a-->From PM: PmWiki expects PSS() to always occur inside of double-quoted strings and to contain single quoted strings internally. The reason for this is that we don't want the $1 or $2 to accidentally contain characters that would then be interpreted inside of the double-quoted string when the PSS is evaluated.%0a--->@@Markup('foo', 'inline', '/(something)/e', 'Foo(PSS("$1"))'); # wrong@@%0a--->@@Markup('foo', 'inline', '/(something)/e', "Foo(PSS('$1'))"); # right@@%0a%0a%25note%25 Note, the extra slashes are only added by @@preg_replace@@ with an @@/e@@ modifier. The markup definitions with @@Markup_e()@@ do NOT need to use PSS() in the replacement strings. The new-type markup definitions with @@Markup()@@ and a simple function name as a replacement do NOT need to use PSS() inside the replacement function. If you migrate old markup rules to the new format, delete the @@PSS()@@ calls.%0a%0a!!! Example%0aThis is a fictitious example where PSS() should be used.%0aLet us assume that you wish to define a directive [@(:example:)@]%0asuch that [@(:example "A horse":)@] results in the HTML%0a-> [@%3cdiv>"A horse"%3c/div>@].%0aHere is how the markup rule can be created:%0a-> [@%0aMarkup('example', 'directives',%0a '/\\(:example\\s(.*?):\\)/e',%0a "Keep('%3cdiv>'.PSS('$1').'%3c/div>')");%0a@]%0aWe need to use PSS() around the '$1' because the matched text%0acould contain quotation marks, and the /e will add backslashes%0ain front of them.%0a%0a!![[#stripmagic]] [@stripmagic($string)@]%0a%0aThis function should be used when processing the contents of [@$_POST@] or [@_GET@] variables when they could contain quotes or backslashes. It verifies [@get_magic_quotes()@], if true, strips the automatically inserted escapes from the string.%0a%0aThe function can process arrays recursively (only the values are processed).%0a%0a!![[#FmtPageName]] [@FmtPageName@]($fmt, $pagename)%0a%0a[[#FmtPageName-desc]]Returns [@$fmt@], with $variable and [=$[internationalisation]=] substitutions performed, under the assumption that the current page is [@pagename@]. See [[PmWiki.Variables]] for an (incomplete) list of available variables, [[PmWiki.Internationalizations]] for internationalisation. Security: not to be run on user-supplied data.%0a%0aThis is one of the major functions in PmWiki, see [[PmWiki.FmtPageName]] for%0alots of details.%0a%0a%0a!![[#Markup]] [@Markup@]($name, $when, $pattern, $replace)%0a%0a[[#Markup-desc]]Adds a new markup to the conversion table. Described in greater detail at [[PmWiki.CustomMarkup]].%0a%0aThis function is used to insert translation rules into the PmWiki's%0atranslation engine. The arguments to [@Markup()@] are all strings, where:%0a%0a:[@$name@]: The string names the rule that is inserted. If a rule of the same name already exists, then this rule is ignored.%0a:[@$when@]: This string is used to control ''when'' a rule is to be applied relative to other rules. A specification of "[@%3cxyz@]" says to apply this rule prior to the rule named "xyz", while "[@>xyz@]" says to apply this rule after the rule "xyz". See [[(PmWiki:)CustomMarkup]] for more details on the order of rules.%0a:[@$pattern@]: This string is a [[regular expression -> http://www.php.net/preg_replace]] that is used by the translation engine to look for occurences of this rule in the markup source.%0a:[@$replace@]: This string will replace the matched text when a match occurs, or the function name that will return the replacement text.%0a%0aAlso see: [[PmWiki.CustomMarkup]] and [[Cookbook:Functions#Markup]]%0a%0a!![[#MarkupToHTML]] [@MarkupToHTML@]($pagename, $str)%0a%0a[[#MarkupToHTML-desc]] Converts the string [@$str@] containing PmWiki markup into the corresponding HTML code, assuming the current page is [@$pagename@].%0a%0aAlso see: [[Cookbook:Functions#MarkupToHTML]]%0a%0a!![[#mkdirp]] [@mkdirp@]($dir)%0a%0aThe function [@mkdirp@]($dir) creates a directory, [@$dir@], if it doesn't%0aalready exist, including any parent directories that might be needed. For%0aeach directory created, it checks that the permissions on the directory are%0asufficient to allow PmWiki scripts to read and write files in that%0adirectory. This includes checking for restrictions imposed by PHP's%0asafe_mode setting. If [@mkdirp@]() is unable to successfully create a%0aread/write directory, [@mkdirp@]() aborts with an error message telling the%0aadministrator the steps to take to either create $dir manually or give%0aPmWiki sufficient permissions to be able to do it.%0a%0a!![[#MakeLink]] [@MakeLink@]($pagename, $target, $txt, $suffix, $fmt)%0a%0aThe function [@MakeLink@]($pagename, $target, $txt, $suffix, $fmt) returns an html-formatted anchor link. Its arguments are as follows:%0a $pagename is the source page%0a $target is where the link should go%0a $txt is the value to use for '$LinkText' in the output %0a $suffix is any suffix string to be added to $txt%0a $fmt is a format string to use%0a%0aIf $txt is NULL or not specified, then it is automatically computed from $target.%0a%0aIf $fmt is NULL or not specified, then MakeLink uses the default%0aformat as specified by the type of link. For page links this%0ameans the $LinkPageExistsFmt and $LinkPageCreateFmt variables,%0afor intermap-style links it comes from either the $IMapLinkFmt%0aarray or from $UrlLinkFmt. Inside of the formatting strings,%0a$LinkUrl is replaced by the resolved url for the link, $LinkText%0ais replaced with the appropriate text, and $LinkAlt is replaced%0aby any "title" (alternate text) information associated with the%0alink.%0a%0aAlso see: [[PmWiki:MakeLink]] and [[Cookbook:Functions#MakeLink]]%0a%0a!![[#MakeUploadName]] [@MakeUploadName@]($pagename, $x)%0a%0a@@MakeUploadName()@@ simply takes a string @@$x@@ (representing an attachment's%0aname) and converts it to a valid name by removing any unwanted characters.%0aIt also requires the name to begin and end with an alphanumeric character,%0aand as of 2.0.beta28 it forces any file extensions to lowercase.%0aThis function is defined in @@scripts/upload.php@@ and only used when uploads%0aare enabled.%0a%0a!![[#SessionAuth]] [@SessionAuth@]($pagename, $auth=NULL)%0a%0a@@SessionAuth()@@ manages keeping authentication via cookie-sessions. Session contains%0aever password or vaidated id and associated groups from previous calls.It adds%0aelements passed by @@$auth@@ to session. It also writes every element%0asaved in session to @@$AuthPw@@(passwords) and @@$AuthList@@(ids and groups).%0a%0a!![[#IsAuthorized]] [@IsAuthorized@]($chal, $source, &$from)%0a@@IsAuthorized@@ takes a pageattributesstring (e. g. "id:user1 $1$Ff3w34HASH...") in @@$chal@@.%0a@@$source@@ is simply returned and used for building the authcascade (pageattributes - groupattributes - %0a@@$DefaultPassword@@). @@$from@@ will be returned if @@$chal@@ is empty, because it is not checked %0abefore calling @@IsAuthorized()@@, this is needed for the authcascade. @@IsAuthorized()@@ returns an array%0awith three values: @@$auth@@ @@1@@ - authenticated, @@0@@ - not authenticated, @@-1@@ - refused; @@$passwd@@; %0a@@$source@@ from the parameter list.%0a%0a!![[#CondAuth]] [@CondAuth@] ($pagename, 'auth level')%0a[@CondAuth@] implements the [[ConditionalMarkup]] for [@(:if auth level:)@]. For instance [@ CondAuth($pagename,'edit')@] is true if authorization level is 'edit'. Use inside local configuration files to build conditionals with a check of authorization level, similar to using [@(:if auth level:)@] on a wiki page.%0a%0aNote that CondAuth() should be called after all authorization levels and passwords have been defined. For example, if you use it with [[Drafts]], you should include the draft.php script before calling CondAuth():%0a[@%0a $EnableDrafts = 1;%0a $DefaultPasswords['publish'] = pmcrypt('secret');%0a include_once("$FarmD/scripts/draft.php");%0a if (! CondAuth($pagename, 'edit')) { /* whatever */ }%0a@]%0aBest is to use CondAuth() near the bottom of your config.php script.%0a%0a!! [[#RetrieveAuthPage]] @@RetrieveAuthPage($pagename, $level, $authprompt=true, $since=0)@@%0a%25comment%25 Pm words as said in http://article.gmane.org/gmane.comp.web.wiki.pmwiki.user/12493/match=retrieveauthpage%25%25%0awhere:%0a%0a $pagename - name of page to be read%0a $level - authorization level required (read/edit/auth/upload)%0a $authprompt - true if user should be prompted for a password if needed%0a $since - how much of the page history to read%0a 0 == read entire page including all of history%0a READPAGE_CURRENT == read page without loading history%0a timestamp == read history only back through timestamp%0a%0aThe $since parameter allows PmWiki to stop reading from a page file%0aas soon as it has whatever information is needed -- i.e., if an operation%0asuch as browsing isn't going to need the page's history, then specifying%0aREADPAGE_CURRENT can result in a much faster loading time. (This can be %0aespecially important for things such as searching and page listings.)%0aHowever, if combined with UpdatePage, the updated page will have no history.%0a%0aUse e.g. [@$page = @RetrieveAuthPage('Main.MyPage', 'read')@] to obtain a page object that contains all the information of the correspondent file in separate keys, e.g. [@$page['text']@] will contain a string with the current wiki markup of Main.MyPage. Use this generally in preference to the alternative function [@ReadPage($pagename, $since=0)@] since it respects the authorisation of the user, i.e. it checks the authorisation level before loading the page, or it can be set to do so. [@ReadPage()@] reads a page regardless of permission.%0a%0aPassing 'ALWAYS' as the authorization level (instead of 'read', 'edit', etc.) will cause RetrieveAuthPage to always read and return the page, even if it happens to be protected by a read password.%0a%0a%0a!! [[#RetrieveAuthSection]] @@RetrieveAuthSection($pagename, $pagesection, $list=NULL, $auth='read')@@%0aRetrieveAuthSection extracts a section of text from a page. If $pagesection starts with anything other than '#', the text before the first '#' (or all of it, if there is no '#') identifies the page to extract text from. Otherwise RetrieveAuthSection looks in the pages given by $list (should be an array), or in $pagename if $list is not specified. %0a* The selected page is placed in the global $RASPageName variable. %0a* The caller is responsible for calling Qualify() as needed, i.e. if you need to control how unqualified page and variable names shall be resolved.%0a** To have them act as in the original text, let @@Qualify()@@ resolve them relative to the source page.%0a** If the imported text was not meant as wikitext but as some other kind of markup that might happen to contain double pairs of square brackets, (:comment %3c-- not: pairs of 〚double square brackets〛 = U+301A/U+301B:) or dollar signs inside curly brackets, you probably don't want to @@Qualify()@@ them. If you output them into wikitext, you'll probably need to @@Keep()@@ the text (:comment %3c-- translators: conceptually this means to have Keep() pack the text in a container that marks it as "final".:) (in case of HTML, XML, RSS or similar output, @@PHSC()@@ first!), to prevent later stages of processing from interpreting the apparent wiki markups in context of the target page.%0a** If your code produces wikitext for an auxiliary page that is meant to be included by another page higher up in the inclusion chain, and want links and variables to work as if they were in the auxiliary page, use the auxiliary page's "GroupName.PageName" as the $pagename argument for @@Qualify()@@.%0a%0aProvides a way to limit the array that is returned by ReadPage, so that it only pulls the content up to a specific section marker. For example, pulling from start of page to '##blogend':%0a->[@%0afunction FeedText($pagename, &$page, $tag) {%0a $text = RetrieveAuthSection($pagename, '##blogend');%0a $content = MarkupToHTML($pagename, $text);%0a return "%3c$tag>%3c![CDATA[$content]]>%3c/$tag>";%0a}%0a@]%0a%0aThe '##blogend' argument says to read from the beginning of the page to just before the line containing the [[#blogend]] marker. See%0a[[http://www.pmwiki.org/wiki/PmWiki/IncludeOtherPages | IncludeOtherPages]] for more information about the section specifications.%0a%0aThis version won't read text from pages that are read-protected; if you want to get text even from read-protected pages, then %0a->[@%0a $text = RetrieveAuthSection($pagename, '##blogend', NULL, 'ALWAYS');%0a@]%0a%0a%0a!! [[#UpdatePage]] @@UpdatePage($pagename, $old (page object), $new (page object));@@%0a''[[PmWiki:UpdatePage|More Technical Notes]]''%0a%0a[@UpdatePage()@] allows cookbook recipes to mimic the behavior of editing wiki pages via the browser. Internally, PmWiki does several house keeping tasks which are accessible via this function (preserving history/diff information, updating page revision numbers, updating RecentChanges pages, sending email notifications, etc._%0a* "Page object" refers to an array pulled from [@RetrieveAuthPage($pagename, $level, $authprompt=true, $since=0);@] (preferred), or [@ReadPage($pagename); @] (disregards page security). Note that $new['text'] should contain all page data for the new version of the page. %0a* If a page doesn't exist, UpdatePage() will attempt to create it.%0a* Ignoring $old (e.g. [@UpdatePage($pagename, '', $new);@]) will erase all historical page data---a ''tabula rasa''.%0a** If you retrieved $old using RetrieveAuthPage($pagename,$auth,$prompt,READPAGE_CURRENT) and set $new=$old, then UpdatePage will also erase all historical data%0a@@UpdatePage()@@ cannot be called directly from config.php because there are necessary initializations which occur later in pmwiki.php. It is not enough to just load stdconfig.php. If you want to use @@UpdatePage()@@ you will need to do it within a [[PmWiki:CustomMarkup | custom markup]], a [[Cookbook:MarkupExpressionSamples | custom markup expression]], or a [[PmWiki:CustomActions | custom action]].%0a%0aCategories: [[!PmWiki Developer]] -time=1567168359 +rev=195 +targets=Cookbook.Functions,PmWiki.CustomMarkup,PmWiki.CustomActions,PmWiki.BasicVariables,PmWiki.LayoutVariables,PmWiki.SecurityVariables,Cookbook.PccfToPcfOverride,PmWiki.LinkVariables,PmWiki.OtherVariables,PmWiki.EditVariables,PmWiki.UploadVariables,PmWiki.Functions,PmWiki.Variables,PmWiki.Internationalizations,PmWiki.FmtPageName,PmWiki.MakeLink,PmWiki.ConditionalMarkup,PmWiki.Drafts,PmWiki.IncludeOtherPages,PmWiki.UpdatePage,Cookbook.MarkupExpressionSamples,Cookbook.ParseArgs,Category.PmWikiDeveloper,!PmWikiDeveloper +text=(:Summary: How some of the functions in pmwiki.php work:)%0a(:Audience: admins (advanced) :)%0a%0aThis page describes some of the internal workings of PmWiki by explaining how some of the functions in @@pmwiki.php@@ work. For a more brief list/overview on functions useful to for instance cookbook writers, see Cookbook:Functions. %0a%0aTo use this functions you have to make sure that all relevant internal variables have been initialized correctly. See [[Custom Markup]] and [[(PmWiki:)Custom Actions]] for more information on how these functions are typically called via %25hlt php%25[@Markup()@] or [@$HandleActions[]@].%0a%0a!! [[#PSFT]] PSFT()%0a%0a%25hlt php%25[@PSFT($format, $timestamp=null, $locale=null, $tz=null)@]%0a%0aThe %25hlt php%25@@PSFT()@@ function (''PmWiki String Format Time'', added in 2.3.0) is intended to be a safe replacement for the very widely used PHP functions @@[[https://www.php.net/strftime|strftime()]]@@ and @@[[https://www.php.net/gmstrftime|gmtstrftime()]]@@ which became deprecated in PHP 8.1.%0a%0aUnlike %25hlt php%25@@strftime()@@, @@PSFT()@@ accepts 2 additional arguments @@$locale@@ and @@$tz@@, which allow to set a different language or timezone.%0a%0aPmWiki 2.3.0 uses this function in all cases where it previously used %25hlt php%25@@strftime()@@, including the %25pmhlt%25[@{(ftime)}@] Markup Expression. If your local customizations and recipes use %25hlt php%25@@strftime()@@, you should be able to safely replace all calls to @@strftime()@@ with @@PSFT()@@, without changing the arguments. Any calls to @@gmtstrftime($fmt, $stamp)@@ can be replaced with @@PSFT($fmt, $stamp, null, 'GMT')@@.%0a%0aThe old functions were deprecated by the PHP developers because they behaved inconsistently on different platforms, and were dependent on installed system locales (i.e. a language would only work if the system had its locale installed). The new function uses the PHP class [[https://www.php.net/manual/en/class.intldateformatter.php|IntlDateFormatter]] and should be better. Unfortunately, it is not always enabled by hosting providers. %0a%0aSo depending on your installation, a specific language may be available with %25hlt php%25@@strftime()@@ and/or with @@IntlDateFormatter@@.%0a%0aIn addition, some rarely used shortcut percent-formats [@%25c, %25x, %25X@] also behave inconsistently on different platforms, and the new formatter may show a slightly different output. You can always replace these shortcut formats with the full formats you require.%0a%0aFor these reasons, %25hlt php%25@@PSFT()@@ is currently a compromise, by default reusing @@strftime()@@ for PHP 8.0 or earlier. Updating your calls from @@strftime()@@ shouldn't cause any changes in your outputs.%0a%0aYou can set in @@config.php@@ the variable %25hlt php%25@@$EnableFTimeNew = 1;@@ for @@PSFT()@@ to try using @@IntlDateFormatter@@ before PHP 8.1. If @@IntlDateFormatter@@ is not available, it will show the month and day names in English. Check what works.%0a%0aSince the %25hlt php%25@@strftime()@@ function is deprecated, it is unlikely for it to add new formats. We have added 2 custom formats:%0a* [@%25o@] for the "ordinal suffix" of the date, as "st" in "January 1st". If @@IntlDateFormatter@@ is not available, it will show the suffix in English%0a* [@%25L@] for a human-readable timestamp of the format %25pmhlt%25[@@2022-09-25T11:49:08Z@]%25%25 which will be displayed formatted either as $TimeFmt or in the local time zone of the visitor, see $EnableLocalTimes.%0a%0a>>frame%3c%3c%0aA difference between %25hlt php%25@@strftime($format, $stamp)@@ and @@PSFT($format, $stamp)@@ is how they interpret a false, empty or non-numeric @@$stamp@@ argument.%0a|| class=simpletable%0a||! @@$stamp@@ argument ||! @@strftime($format, $stamp)@@ ||! @@PSFT($format, $stamp)@@ ||%0a|| numeric || the stamp || the stamp ||%0a|| missing or ''null'' || current time || current time ||%0a|| ''false'' || 1970-01-01 || current time ||%0a|| "" (empty string) \\%0aother non-numeric || 1970-01-01 or ''false'' (older PHP versions) \\%0a ''Warning: TypeError'' (PHP 7.4+) || current time ||%0aFor PmWiki, it seemed reasonable to make empty strings and other non-numeric values default to the current time. If your %25hlt php%25@@$stamp@@ variable may be empty or ''false'', and your recipes rely on @@strftime()@@ returning "1970-01-01", you can cast the stamp to integer:%0a%25hlt php%25[@%0a PSFT($format, intval($stamp));%0a@]%0a>>%3c%3c%0a%0a!! [[#pmcrypt]] pmcrypt()%0a%25hlt php%25[@pmcrypt($password, $salt = null)@]%0a%0aThe %25hlt php%25@@pmcrypt()@@ function is intended to be a safe replacement for the [[https://www.php.net/crypt|PHP 5.6+ crypt() function]] without providing a $salt, which would raise a notice. If a salt is provided, crypt() is called to check an existing password. If a salt is not provided, [[https://www.php.net/password_hash|password_hash()]] will be called to create a cryptographically strong password hash.%0a%0a!! [[#pmsetcookie]] pmsetcookie()%0a%25hlt php%25[@pmsetcookie($name, $val="", $exp=0, $path="", $dom="", $secure=null, $httponly=null)@]%0a%0aThis function is intended as a replacement for [[https://www.php.net/setcookie|setcookie()]]. It will automatically set the $secure and $httponly arguments if they are not set by the caller function and if $EnableCookieSecure and $EnableCookieHTTPOnly are enabled.%0a%0a!![[#PCCF]] PCCF() %25red%25 Deprecated since PHP 7.2%25%25%0a%25hlt php%25[@PCCF($php_code, $callback_template='default', $callback_arguments = '$m')@] %0a%0aThe %25hlt php%25@@PCCF()@@ function (''PmWiki Create Callback Function'') can be used to create callback functions used with [[https://www.php.net/preg_replace_callback|preg_replace_callback]]. It is required for PHP 5.5, but will also work with earlier PHP versions.%0a%0aThe first argument is the PHP code to be evaluated. %0a%0aThe second argument (optional) is the callback template, a key from the global @@$CallbackFnTemplates@@ array. There are two templates that can be used by recipe authors: %0a* 'default' will pass @@$php_code@@ as a function code%0a* 'return' will wrap @@$php_code@@ like "@@return $php_code;@@" (since PmWiki 2.2.62)%0a%0aThe third argument (optional) is the argument of the callback function. Note that PmWiki uses the '$m' argument to pass the matches of a regular expression search, but your function can use other argument(s).%0a%0a%25hlt php%25@@PCCF()@@ will create an anonymous (lambda) callback function containing the supplied code, and will cache it. On subsequent calls with the same @@$php_code@@, @@PCCF()@@ will return the cached function name.%0a%0aSee the [[https://www.php.net/create_function | PHP create function]].%0a%0a>>font-style=italic%3c%3c%0aPHP 7.2 deprecates %25hlt php%25@@create_function()@@ and future versions will remove it. If you need to migrate older code that used @@PCCF()@@, you can usually write regular functions and pass the function name where you previously passed the result of PCCF(). For example, suppose you had a pattern like this:%0a-> %25hlt php%25@@'/(?%3c=^| )([a-z])/' => PCCF("return strtoupper(\$m[1]);"),@@%0a%0aFor PHP 7.2 compatibility, you can write a callback function:%0a-> %25hlt php%25@@function @@%25green%25my_callback%25hlt php%25@@($m) { return strtoupper($m[1]); }@@%0a%0athen change the pattern to look like this:%0a-> %25hlt php%25@@'/(?%3c=^| )([a-z])/' => '%25green%25my_callback%25%25',@@%0a%0aSee also: the recipe [[(Cookbook:)PccfToPcfOverride]] allows existing recipes to run on PHP 7 without causing deprecated @@create_function()@@ messages.%0a>>%3c%3c%0a%0a!![[#PPRA]] PPRA()%0a%25hlt php%25[@PPRA($array_search_replace, $string)@]%0a%0aThe %25hlt php%25@@PPRA()@@ function (''PmWiki Preg Replace Array'') can be used to perform a regular expression replacement with or without evaluation, for PHP 5.5 compatibility. %0a%0aSince PmWiki 2.2.56, PmWiki uses this function to process the following arrays: $MakePageNamePatterns, $FmtP, $QualifyPatterns, $ROEPatterns, $ROSPatterns, $SaveAttrPatterns, $MakeUploadNamePatterns. Any custom settings should continue to work for PHP 5.4 and earlier, but wikis running on PHP 5.5 may need to make a few changes.%0a%0aThe first argument contains the 'search'=>'replace' pairs, the second is the "haystack" string to be manipulated.%0a%0aThe 'replace' parts of the array can be strings or function names. If the 'replace' part is a callable function name, it will be called with the array of matches as a first argument via %25hlt php%25@@preg_replace_callback()@@. If not a callable function, a simple @@preg_replace()@@ will be performed.%0a%0aPreviously, PmWiki used such constructs:%0a-> %25hlt php%25@@$fmt = preg_replace(array_keys($FmtP), array_values($FmtP), $fmt);@@%0a%0aIt is now possible to use simply this:%0a-> %25hlt php%25@@$fmt = PPRA($FmtP, $fmt);@@%0a%0aNote that since PHP 5.5, the search patterns cannot have an /e evaluation flag. When creating the $array_search_replace array, before PHP 5.5 we could use something like (eg. for $MakePageNamePatterns):%0a-> %25hlt php%25@@'/(?%3c=^| )([a-z])/e' => "strtoupper('$1')",@@%0a%0aSince PHP 5.5, we should use this (will also work in PHP 5.4 and earlier):%0a-> %25hlt php%25@@'/(?%3c=^| )([a-z])/' => PCCF("return strtoupper(\$m[1]);"),@@%0a%0aNote that the @@/e@@ flag should be now omitted, instead of @@'$0', '$1', '$2',@@ we should use @@$m[0], $m[1], $m[2],@@ etc. in the replacement code, and there is no need to call @@PSS()@@ in the replacement code, as backslashes are not automatically added.%0a%0a>>font-style=italic%3c%3c%0aFor PHP 7.2 and newer, instead of using %25hlt php%25@@PCCF()@@ to create anonymous functions, we add a real function in our add-on, and then pass the function name as the pattern replacement (see example at [[#PCCF|PCCF]], which will also work on PHP 4 and 5):%0a-> %25hlt php%25@@'/(?%3c=^| )([a-z])/' => '%25green%25my_callback%25%25',@@%0a>>%3c%3c%0a%0a!![[#PPRE]] PPRE() %25red%25 Deprecated since PHP 7.2%25%25%0a%25hlt php%25[@PPRE($search_pattern, $replacement_code, $string)@]%0a%0aThe %25hlt php%25@@PPRE()@@ function (''PmWiki Preg Replace Evaluate'') can be used to perform a regular expression replacement with evaluation.%0a%0aSince PHP 5.5, the %25hlt php%25@@preg_replace()@@ function has deprecated the /e evaluation flag, and displays warnings when the flag is used. The @@PPRE()@@ function automatically creates a callback function with the replacement code and calls it.%0a%0aBefore PHP 5.5, it was possible to use such calls:%0a-> %25hlt php%25@@$fmt = preg_replace('/\\$([A-Z]\\w*Fmt)\\b/e','$GLOBALS["$1"]',$fmt);@@%0a%0aSince PHP 5.5, it is possible to replace the previous snippet with the following (also works before PHP 5.5):%0a-> %25hlt php%25@@$fmt = PPRE('@@%25green%25/\\$([A-Z]\\w*Fmt)\\b/%25hlt php%25@@','$GLOBALS[$m[1]]',$fmt);@@%0a%0aNote that the @@/e@@ flag should be now omitted, instead of @@'$0', '$1', '$2',@@ we should use @@$m[0], $m[1], $m[2],@@ etc. in the replacement code, and there is no need to call @@PSS()@@ in the replacement code, as backslashes are not automatically added.%0a%0a>>font-style=italic%3c%3c%0aFor PHP 7.2 and newer, calling this function will raise "deprecated" notices. You need to rewrite your code to use [[https://www.php.net/preg_replace_callback|preg_replace_callback]], by moving the code into real functions:%0a%0a-> %25hlt php%25@@$fmt = preg_replace_callback('@@%25green%25/\\$([A-Z]\\w*Fmt)\\b/%25hlt php%25@@', 'my_global_var_callback',$fmt);@@%0a-> %25hlt php%25@@function my_global_var_callback($m) { return $GLOBALS[$m[1]]; }@@%0a%0ainstead of using %25hlt php%25@@PCCF()@@ to create anonymous functions, we add a real function in our add-on, and then pass the function name as the pattern replacement (see example at [[#PCCF|PCCF]], which will also work on PHP 4 and 5):%0a=> %25hlt php%25@@'/(?%3c=^| )([a-z])/' => '%25green%25my_callback%25%25',@@%0a>>%3c%3c%0a%0a(:if false:)(:comment Needs review and may change:)%0a!![[#PRCB]] PRCB()%0a%25hlt php%25[@PRCB($pat, $repl, $subj, $vars=null, $limit=-1, &$count=null, $flags=0)@]%0a%0aThe %25hlt php%25@@PRCB()@@ function (''PmWiki Regex Replace Callback'') makes it simple to pass variables to a named callback function with [[https://php.net/preg_replace_callback|preg_replace_callback()]].%0a%0aIf you need to use preg_replace_callback() and pass some variables to the callback function, you can do something like:%0a%0a%25hlt php%25[@$result = PRCB($patern, 'my_callback', $subject, $pagename);@]%0a%0aThen your function will be called this way: %25hlt php%25[@my_callback($matches, $pagename);@]. You can pass multiple varibles with an array.%0a%0aThe function can also be used without passing variables, just shorter than @@preg_replace_callback()@@:%0a%0a%25hlt php%25[@$result = PRCB($patern, 'my_callback', $subject);@]%0a%0a(:ifend:)%0a%0a!![[#Qualify]] Qualify()%0a%25hlt php%25[@Qualify($pagename, $text)@]%0a%0a%25hlt php%25@@Qualify()@@ applies $QualifyPatterns to convert relative links and references into absolute equivalents.%0aThis function is called by usual wiki markups that include text from other pages.%0aIt will rewrite links like %25pmhlt%25[@[[Page]]@] into [@[[Group/Page]]@], and page (text) variables like [@{$Title}@] into [@{Group.Page$Title}@]%0aso that they work the same way in the source page and in the including page.%0aSee also $QualifyPatterns and %25pmhlt%25@@[[({$Name}#)RetrieveAuthSection]]()@@.%0a%0a%0a!![[#PHSC]] PHSC()%0a%25hlt php%25[@PHSC($string_or_array, $flags=ENT_COMPAT, $encoding=null, $double_encode=true)@]%0a%0aThe %25hlt php%25@@PHSC()@@ function (''PmWiki HTML Special Characters'') is a replacement for the PHP function [[https://www.php.net/htmlspecialchars|htmlspecialchars]]. %0a%0aThe %25hlt php%25@@htmlspecialchars()@@ function was modified since PHP 5.4 in two ways: it now requires a valid string for the supplied encoding, and it changes the default encoding to UTF-8. This can cause sections of the page to become blank/empty on many sites using the ISO-8859-1 encoding without having set the third argument ($encoding) when calling @@htmlspecialchars()@@.%0a%0aThe %25hlt php%25@@PHSC()@@ function calls @@htmlspecialchars()@@ with an 8-bit encoding as third argument, whatever the encoding of the wiki (unless you supply an encoding). This way the string never contains invalid characters.%0a%0aIt should be safe for recipe developers to replace all calls to %25hlt php%25@@htmlspecialchars()@@ with calls to @@PHSC()@@. Only the first argument is required when calling @@PHSC()@@, although authors may wish to call @@PHSC($string_or_array, ENT_QUOTES)@@.%0a%0aUnlike %25hlt php%25@@htmlspecialchars()@@, the @@PHSC()@@ function can process arrays recursively (only the values are converted, not the keys of the array).%0a%0a!![[#PSS]] PSS()%0a%25hlt php%25[@PSS($string)@]%0a%0aThe %25hlt php%25@@PSS()@@ function (''PmWiki Strip Slashes'') removes the backslashes that are automatically inserted in front of quotation marks by the /e option of PHP's preg_replace function. @@PSS()@@ is%0amost commonly used in replacement arguments to @@Markup()@@, when the pattern specifies /e and one or more of the parenthesized subpatterns could contain a quote or backslash. %0a("PSS" stands for "PmWiki Strip Slashes".)%0a->From PM: PmWiki expects %25hlt php%25@@PSS()@@ to always occur inside of double-quoted strings and to contain single quoted strings internally. The reason for this is that we don't want the @@$1@@ or @@$2@@ to accidentally contain characters that would then be interpreted inside of the double-quoted string when the PSS is evaluated.%0a-->%25hlt php%25@@Markup('foo', 'inline', '/(something)/e', 'Foo(PSS("$1"))'); # wrong@@%0a-->%25hlt php%25@@Markup('foo', 'inline', '/(something)/e', "Foo(PSS('$1'))"); # right@@%0a%0a%25note%25 Note, the extra slashes are only added by %25hlt php%25@@preg_replace()@@ with an @@/e@@ modifier. The markup definitions with @@Markup_e()@@ do NOT need to use @@PSS()@@ in the replacement strings. The new-type markup definitions with @@Markup()@@ and a simple function name as a replacement do NOT need to use @@PSS()@@ inside the replacement function. If you migrate old markup rules to the new format, delete the @@PSS()@@ calls.%0a%0a!!! Example %25block notoc%25%0aThis is a fictitious example where %25hlt php%25@@PSS()@@ should be used.%0aLet us assume that you wish to define a directive %25pmhlt%25[@(:example:)@]%0asuch that %25pmhlt%25[@(:example "A horse":)@] results in the HTML%0a-> %25hlt html%25[@%3cdiv>"A horse"%3c/div>@].%0aHere is how the markup rule can be created:%0a-> %25hlt php%25[@%0aMarkup('example', 'directives',%0a '/\\(:example\\s(.*?):\\)/e',%0a "Keep('%3cdiv>'.PSS('$1').'%3c/div>')");%0a@]%0aWe need to use %25hlt php%25@@PSS()@@ around the '@@$1@@' because the matched text could contain quotation marks, and the @@/e@@ will add backslashes in front of them.%0a%0a!![[#stripmagic]] stripmagic()%0a%25hlt php%25[@stripmagic($string)@]%0a%0aThis function should be used when processing the contents of %25hlt php%25[@$_POST@] or [@$_GET@] variables when they could contain quotes or backslashes. It verifies [@get_magic_quotes()@], if true, strips the automatically inserted escapes from the string.%0a%0aThe function can process arrays recursively (only the values are processed).%0a%0a!![[#FmtPageName]] FmtPageName()%0a%0a%25hlt php%25[@FmtPageName($fmt, $pagename)@]%0a%0a[[#FmtPageName-desc]]Returns %25hlt php%25[@$fmt@], with @@$variable@@ and [=$[internationalisation]=] substitutions performed, under the assumption that the current page is [@pagename@]. See [[PmWiki.Variables]] for an (incomplete) list of available variables, [[PmWiki.Internationalizations]] for internationalisation. Security: not to be run on user-supplied data.%0a%0aThis is one of the major functions in PmWiki, see [[PmWiki.FmtPageName]] for%0alots of details.%0a%0a%0a!![[#Markup]] Markup()%0a%25hlt php%25[@Markup($name, $when, $pattern, $replace)@]%0a%0a[[#Markup-desc]]Adds a new markup to the conversion table. Described in greater detail at [[PmWiki.CustomMarkup]].%0a%0aThis function is used to insert translation rules into the PmWiki's translation engine. The arguments to %25hlt php%25[@Markup()@] are all strings, where:%0a%0a:%25hlt php%25[@$name@]: The string names the rule that is inserted. If a rule of the same name already exists, then this rule is ignored.%0a:%25hlt php%25[@$when@]: This string is used to control ''when'' a rule is to be applied relative to other rules. A specification of "[@%3cxyz@]" says to apply this rule prior to the rule named "xyz", while "[@>xyz@]" says to apply this rule after the rule "xyz". See [[(PmWiki:)CustomMarkup]] for more details on the order of rules.%0a:%25hlt php%25[@$pattern@]: This string is a [[regular expression -> https://www.php.net/preg_replace]] that is used by the translation engine to look for occurrences of this rule in the markup source.%0a:%25hlt php%25[@$replace@]: This string will replace the matched text when a match occurs, or the function name that will return the replacement text.%0a%0aAlso see: [[PmWiki.CustomMarkup]] and [[Cookbook:Functions#Markup]]%0a%0a!![[#MarkupToHTML]] MarkupToHTML()%0a%0a%25hlt php%25[@MarkupToHTML($pagename, $str)@]%0a%0a[[#MarkupToHTML-desc]] Converts the string %25hlt php%25[@$str@] containing PmWiki markup into the corresponding HTML code, assuming the current page is [@$pagename@].%0a%25hlt php%25@@MarkupToHTML()@@ replaces @@\n\n@@ sequences by @@%3c:vspace>@@ first thing when text is passed to it. Subsequently @@%3c:vspace>@@ is processed by the markup rules:%0a-> '@@!vspace@@' removes @@%3c:vspace>@@ after headings.%0a-> '@@%3cvspace>%3cp>@@' replaces @@%3c:vspace>%3cp>@@ with @@%3cp class='vspace'>@@%0a-> '@@%3cvspace>@@' replaces %3c:vspace> with @@%3cdiv class='vspace'>@@%0a-> and finally%0a-> '@@^%3c:@@' removes any remaining @@%3c:vspace>@@, mostly from restored [=[=]=escaped text=].%0a%0aAlso see: [[Cookbook:Functions#MarkupToHTML]]%0a%0a!![[#mkdirp]] mkdirp()%0a%25hlt php%25[@mkdirp($dir)@]%0a%0aThe function %25hlt php%25[@mkdirp($dir)@] creates a directory, [@$dir@], if it doesn't already exist, including any parent directories that might be needed. For each directory created, it checks that the permissions on the directory are sufficient to allow PmWiki scripts to read and write files in that directory. This includes checking for restrictions imposed by PHP's safe_mode setting. If [@mkdirp()@] is unable to successfully create a read/write directory, [@mkdirp()@] aborts with an error message telling the administrator the steps to take to either create @@$dir@@ manually or give PmWiki sufficient permissions to be able to do it.%0a%0a!![[#Lock]] Lock()%0a%25hlt php%25[@Lock(0)@]%0a%0aThis function is used to make sure only one instance of PmWiki is running when files are being written. It does not "lock pages" for editing.%0a%0aFrom a recipe, use:%0a* %25hlt php%25[@Lock(2);@] to acquire an ''exclusive'' lock, so that no other PHP processes can modify files. This can be used when your function is writing files on the server.%0a* %25hlt php%25[@Lock(1);@] to acquire a ''shared'' lock. This may be used when your function is reading files from the server, in case another process is writing them at the same time.%0a* %25hlt php%25[@Lock(0);@] to ''release'' a previous exclusive or shared lock. Use this immediately after your function finishes reading or writing the files.%0a%0aIf you don't release an acquired lock, it should be automatically released at the end of the processing.%0a%0a%0a!![[#MakeLink]] MakeLink()%0a%25hlt php%25[@MakeLink($pagename, $target, $txt, $suffix, $fmt)@]%0a%0aThe function %25hlt php%25[@MakeLink($pagename, $target, $txt, $suffix, $fmt)@] returns an html-formatted anchor link. Its arguments are as follows:%0a $pagename is the source page%0a $target is where the link should go%0a $txt is the value to use for '$LinkText' in the output %0a $suffix is any suffix string to be added to $txt%0a $fmt is a format string to use%0a%0aIf $txt is NULL or not specified, then it is automatically computed from $target.%0a%0aIf $fmt is NULL or not specified, then MakeLink uses the default%0aformat as specified by the type of link. For page links this%0ameans the $LinkPageExistsFmt and $LinkPageCreateFmt variables,%0afor intermap-style links it comes from either the $IMapLinkFmt%0aarray or from $UrlLinkFmt. Inside of the formatting strings,%0a$LinkUrl is replaced by the resolved url for the link, $LinkText%0ais replaced with the appropriate text, and $LinkAlt is replaced%0aby any "title" (alternate text) information associated with the%0alink.%0a%0aAlso see: [[PmWiki:MakeLink]] and [[Cookbook:Functions#MakeLink]]%0a%0a!![[#MakeUploadName]] MakeUploadName()%0a%25hlt php%25@@MakeUploadName($pagename, $x)@@%0a%0a%25hlt php%25@@MakeUploadName()@@ simply takes a string @@$x@@ (representing an attachment's%0aname) and converts it to a valid name by removing any unwanted characters.%0aIt also requires the name to begin and end with an alphanumeric character,%0aand as of 2.0.beta28 it forces any file extensions to lowercase.%0aThis function is defined in @@scripts/upload.php@@ and only used when uploads%0aare enabled.%0a%0a!![[#DownloadUrl]] DownloadUrl()%0a%25hlt php%25@@DownloadUrl($pagename, $path)@@%0a%0aThis function returns the public URL of an attached file. The arguments are as follow:%0a* $pagename - the currently processed page%0a* %25hlt php%25@@$path@@ - the file path, as in @@file.ext@@ or @@OtherPage/file.ext@@ or @@Group/OtherPage/file.ext@@%0a%0aIf the file doesn't exist, the function returns false. The global variable %25hlt php%25@@$FmtV['$LinkUpload']@@ contains the URL to the upload form, for a file with such a name to be attached. The global variable %25hlt php%25@@$FmtV['$LinkDownload']@@ contains the URL to the file, as if it were uploaded to the wiki.%0a%0aThe function calls [[#MakeUploadName|%25hlt php%25@@MakeUploadName()@@]] on the @@$path@@ argument so you don't need to do it before calling it.%0a%0aThe returned URL respects $UploadPrefixFmt and $EnableDirectDownload of the wiki.%0a%0a%0a!![[#SessionAuth]] SessionAuth()%0a%25hlt php%25[@SessionAuth($pagename, $auth=NULL)@]%0a%0a%25hlt php%25@@SessionAuth()@@ manages keeping authentication via cookie-sessions. Session contains every password or validated id and associated groups from previous calls. It adds elements passed by @@$auth@@ to session. It also writes every element saved in session to @@$AuthPw(passwords)@@ and @@$AuthList(ids and groups)@@.%0a%0a!![[#IsAuthorized]] IsAuthorized()%0a%25hlt php%25[@IsAuthorized($chal, $source, &$from)@]%0a%0a%25hlt php%25@@IsAuthorized()@@ takes a pageattributesstring (e. g. "id:user1 $1$Ff3w34HASH...") in @@$chal@@.%0a%0a%25hlt php%25@@$source@@ is simply returned and used for building the authcascade (pageattributes - groupattributes - @@$DefaultPassword@@).%0a%0a%25hlt php%25@@$from@@ will be returned if @@$chal@@ is empty, because it is not checked before calling @@IsAuthorized()@@, this is needed for the authcascade. %0a%25hlt php%25@@IsAuthorized()@@ returns an array with three values: @@$auth@@ @@1@@ - authenticated, @@0@@ - not authenticated, @@-1@@ - refused; @@$passwd@@; @@$source@@ from the parameter list.%0a%0a!![[#CondAuth]] CondAuth()%0a%25hlt php%25[@CondAuth($pagename, 'auth level')@]%0a%0a%25hlt php%25[@CondAuth()@] implements the [[ConditionalMarkup]] for [@(:if auth level:)@]. For instance [@ CondAuth($pagename,'edit')@] is true if authorization level is 'edit'. Use inside local configuration files to build conditionals with a check of authorization level, similar to using [@(:if auth level:)@] on a wiki page.%0a%0aNote that %25hlt php%25@@CondAuth()@@ should be called after all authorization levels and passwords have been defined. For example, if you use it with [[Drafts]], you should include the @@draft.php@@ script before calling @@CondAuth()@@:%0a%25hlt php%25[@%0a $EnableDrafts = 1;%0a $DefaultPasswords['publish'] = pmcrypt('secret');%0a include_once("$FarmD/scripts/draft.php");%0a if (! CondAuth($pagename, 'edit')) { /* whatever */ }%0a@]%0aBest is to use %25hlt php%25@@CondAuth()@@ near the bottom of your @@config.php@@ script.%0a%0a!! [[#RetrieveAuthPage]] RetrieveAuthPage()%0a%25hlt php%25@@RetrieveAuthPage($pagename, $level, $authprompt=true, $since=0)@@%0a%0aPm words as said in https://www.pmwiki.org/pipermail/pmwiki-users/2005-April/012804.html %0awhere:%0a%0a $pagename - name of page to be read%0a $level - authorization level required (read/edit/auth/upload)%0a $authprompt - true if user should be prompted for a password if needed%0a $since - how much of the page history to read%0a 0 == read entire page including all of history%0a READPAGE_CURRENT == read page without loading history%0a timestamp == read history only back through timestamp%0a%0aThe @@$since@@ parameter allows PmWiki to stop reading from a page file%0aas soon as it has whatever information is needed -- i.e., if an operation%0asuch as browsing isn't going to need the page's history, then specifying%0aREADPAGE_CURRENT can result in a much faster loading time. (This can be %0aespecially important for things such as searching and page listings.)%0aHowever, if combined with %25hlt php%25@@UpdatePage()@@, the updated page will have no history.%0a%0aUse e.g. %25hlt php%25[@$page = @RetrieveAuthPage('Main.MyPage', 'read')@] to obtain a page object that contains all the information of the correspondent file in separate keys, e.g. [@$page['text']@] will contain a string with the current wiki markup of Main.MyPage. Use this generally in preference to the alternative function [@ReadPage($pagename, $since=0)@] since it respects the authorisation of the user, i.e. it checks the authorisation level before loading the page, or it can be set to do so. [@ReadPage()@] reads a page regardless of permission.%0a%0aPassing 'ALWAYS' as the authorization level (instead of 'read', 'edit', etc.) will cause %25hlt php%25@@RetrieveAuthPage()@@ to always read and return the page, even if it happens to be protected by a read password.%0a%0a%0a!! [[#RetrieveAuthSection]] RetrieveAuthSection()%0a%25hlt php%25@@RetrieveAuthSection($pagename, $pagesection, $list=NULL, $auth='read')@@%0a%0a%25hlt php%25@@RetrieveAuthSection()@@ extracts a section of text from a page. If @@$pagesection@@ starts with anything other than '@@#@@', the text before the first '@@#@@' (or all of it, if there is no '@@#@@') identifies the page to extract text from. Otherwise @@RetrieveAuthSection()@@ looks in the pages given by @@$list@@ (should be an array), or in @@$pagename@@ if @@$list@@ is not specified. %0a* The selected page is placed in the global @@$RASPageName@@ variable. %0a* The caller is responsible for calling %25hlt php%25@@Qualify()@@ as needed, i.e. if you need to control how unqualified page and variable names shall be resolved.%0a** To have them act as in the original text, let %25hlt php%25@@Qualify()@@ resolve them relative to the source page.%0a** If the imported text was not meant as wikitext but as some other kind of markup that might happen to contain double pairs of square brackets, (:comment %3c-- not: pairs of 〚double square brackets〛 = U+301A/U+301B:) or dollar signs inside curly brackets, you probably don't want to %25hlt php%25@@Qualify()@@ them. If you output them into wikitext, you'll probably need to @@Keep()@@ the text (:comment %3c-- translators: conceptually this means to have Keep() pack the text in a container that marks it as "final".:) (in case of HTML, XML, RSS or similar output, @@PHSC()@@ first!), to prevent later stages of processing from interpreting the apparent wiki markups in context of the target page.%0a** If your code produces wikitext for an auxiliary page that is meant to be included by another page higher up in the inclusion chain, and want links and variables to work as if they were in the auxiliary page, use the auxiliary page's "GroupName.PageName" as the $pagename argument for %25hlt php%25@@Qualify()@@.%0a%0aProvides a way to limit the array that is returned by ReadPage, so that it only pulls the content up to a specific section marker. For example, pulling from start of page to '##blogend':%0a->%25hlt php%25[@%0afunction FeedText($pagename, &$page, $tag) {%0a $text = RetrieveAuthSection($pagename, '##blogend');%0a $content = MarkupToHTML($pagename, $text);%0a return "%3c$tag>%3c![CDATA[$content]]>%3c/$tag>";%0a}%0a@]%0a%0aThe '##blogend' argument says to read from the beginning of the page to just before the line containing the [[#blogend]] marker. See%0a[[PmWiki:IncludeOtherPages | IncludeOtherPages]] for more information about the section specifications.%0a%0aThis version won't read text from pages that are read-protected; if you want to get text even from read-protected pages, then %0a->%25hlt php%25[@%0a $text = RetrieveAuthSection($pagename, '##blogend', NULL, 'ALWAYS');%0a@]%0a%0a%0a!! [[#UpdatePage]] UpdatePage()%0a%25hlt php%25@@UpdatePage($pagename, $old (page object), $new (page object));@@%0a%0a''[[PmWiki:UpdatePage|More Technical Notes]]''%0a%0a%25hlt php%25[@UpdatePage()@] allows cookbook recipes to mimic the behavior of editing wiki pages via the browser. Internally, PmWiki does several house keeping tasks which are accessible via this function (preserving history/diff information, updating page revision numbers, updating RecentChanges pages, sending email notifications, etc._%0a* "Page object" refers to an array pulled from %25hlt php%25[@RetrieveAuthPage($pagename, $level, $authprompt=true, $since=0);@] (preferred), or [@ReadPage($pagename); @] (disregards page security). Note that @@$new['text']@@ should contain all page data for the new version of the page. %0a* If a page doesn't exist, %25hlt php%25@@UpdatePage()@@ will attempt to create it.%0a* Ignoring @@$old@@ (e.g. %25hlt php%25[@UpdatePage($pagename, '', $new);@]) will erase all historical page data---a ''tabula rasa''.%0a** If you retrieved @@$old@@ using %25hlt php%25@@RetrieveAuthPage($pagename,$auth,$prompt,READPAGE_CURRENT)@@ and set @@$new=$old@@, then @@UpdatePage()@@ will also erase all historical data%0a%25hlt php%25@@UpdatePage()@@ cannot be called directly from @@config.php@@ because there are necessary initializations which occur later in @@pmwiki.php@@. It is not enough to just load @@stdconfig.php@@. If you want to use @@UpdatePage()@@ you will need to do it within a [[PmWiki:CustomMarkup | custom markup]], a [[Cookbook:MarkupExpressionSamples | custom markup expression]], or a [[PmWiki:CustomActions | custom action]].%0a%0a%0a!! [[#DisableSkinParts]] DisableSkinParts()%0a%25hlt php%25@@DisableSkinParts('parts to disable');@@%0a%0aThis function allows easy disabling of the skin sections header, footer, title, actions, and sidebars, like the corresponding directives %25pmhlt%25@@[=(:notitle:) (:noleft:)=]@@ etc. In your function, use something like:%0a->%25hlt php%25[@%0a DisableSkinParts('Left Header Footer Action Title');%0a@]%0a%0a!! [[#ParseArgs]] ParseArgs()%0aSee Cookbook:ParseArgs. %0a%0a!! [[#Redirect]] Redirect()%0a%0a!! [[#PageIndexTerms]] PageIndexTerms()%0a%0a!! AsSpacedUTF8(), AsSpaced()%0a%25hlt php%25@@AsSpaced()@@ is declared in @@pmwiki.php@@ \\%0a%25hlt php%25@@AsSpaced()@@ converts a string with WikiWords into a spaced version of that string.%0a%25hlt php%25It can be overridden via $AsSpacedFunction, as it is in @@AsSpacedUTF8()@@. \\%0a%25hlt php%25@@AsSpacedUTF8()@@ is declared in the @@xlpage-utf-8.php@@ script. \\%0a%0aCategories: [[!PmWiki Developer]] +time=1675763214 blob - 07e0e763f847e4dcb5ef91888573e98cd44e5a0f blob + 2a0d43b8661c39df4b38c2b5ebc8e32f1c2617a5 --- wikilib.d/PmWiki.Glossary +++ wikilib.d/PmWiki.Glossary @@ -1,10 +1,9 @@ -version=pmwiki-2.2.30 ordered=1 urlencoded=1 -agent=Mozilla/5.0 (X11; Linux x86_64; rv:5.0) Gecko/20100101 Firefox/5.0 +version=pmwiki-2.3.8 ordered=1 urlencoded=1 author=simon charset=UTF-8 -csum=trail +csum=pm hlt, http+s (+58) name=PmWiki.Glossary -rev=29 -targets=PmWiki.WikiFarmTerminology -text=(:Summary: Terms related to PmWiki:)%0a%0aThis page describes various terms related to PmWiki.%0a%0a:Author: Any user with privileges to write to the wiki.%0a%0a:Admin: The person (or people) who controls access to the wiki, configures the wiki, and generally is the person who installed the wiki.%0a%0a:Configuration file: A specially-named PHP script file where local customizations can take place for a farm, a wiki, a group, or a page.%0a%0a:Default configuration: The way Pm has chosen to set all settings, or an individual setting, by default. For example, $EnablePathInfo is disabled by default. A wiki with no ''local/config.php'' file is using the default configuration. Likewise, a farm that only defines $FarmPubDirUrl in ''farmconfig.php'' is using the default configuration.%0a%0a[[#farm]]%0a:Farm: A group of wikis that share code. Content and formats may or may not be shared. For more farm-related terms, including several which have been deprecated, see [[WikiFarmTerminology]]%0a%0a:Farm-wide configuration file: A WikiFarm's ''local/farmconfig.php'' file, where any settings (besides $FarmPubDirUrl) customize the default configuration for all of the wikis in a farm.%0a%0a:Full page name: The ''full page name'' consists of a group and a name, e.g. [@Main.WikiSandbox@]. The variable for the full page name is [@{$FullName}@], which for this page is @@{$FullName}@@. Similarly, the variable for the group is [@{$Group}@] which here is @@{$Group}@@.%0a%0a:Group: A collection of associated wiki pages; by default this appears in the page name as "Group.PageName". Attributes can be set on all pages in the group simultaneously. The variable for the group is [@{$Group}@], which here is @@{$Group}@@.%0a%0a:Local configuration file: A specially-named PHP script where local customizations can take place for an individual wiki. For an entire wiki it's named ''local/config.php''. Individual groups and pages can also have their own local configuration files.%0a%0a:Local customization: Any deviation from the default configuration. A related phrase is "farm-wide customization".%0a%0a:Page file name: The ''page file name'' is the name of the file that normally stores the data of a page in the directory [@wiki.d/@]. This file name is normally built directly from the page name.%0a%0a:Page link: A ''page link'' is something that is used to generate a link to a page. For example, the markup [@[[wiki sandbox]]@], [@[[(wiki) sandbox]]@], [@WikiSandbox@], [@Main/WikiSandbox@], [@[[Main/wiki sandbox]]@], [@[[Main.WikiSandbox | click here]]@], etc all specify a link to the page '[=Main.WikiSandbox=]'. In each case PmWiki uses the context of the link to generate a page name from the page link -- normally by capitalizing each word found in the link and stripping any characters that aren't considered valid in page names.%0a%0a:Page name: The ''page name'' is a string that PmWiki uses to refer to a page - i.e. it ''names the page''. This could also be considered a ''handle'' for the page. The variable for the page name is simply called [@{$Name}@], which for this page is @@{$Name}@@.%0a-> Note that there is no whitespace in page names, and by default PmWiki capitalizes each word in a page's name. There is however a variable [@{$Namespaced}@] where spaces have been inserted, e.g. for the page [=WikiSandbox=] this variable would be [@Wiki Sandbox@].%0a-> Note that PmWiki also uses the page name to locate per-group and per-page customization files in the [@local/@] subdirectory. For example, browsing [=Main.WikiSandbox=] would cause [@local/Main.WikiSandbox.php@] and [@local/Main.php@] to be loaded if these files existed.%0a%0a:Page title: A ''page title'' is the title element of a page, i.e. what is usually shown above the page and in the browser window's name. This title is normally set via the directive [@(:title:)@], but if no such directive is given the title will be automatically generated from the page name. The title of a page is accessed via either the variable [@{$Title}@] or the variable [@{$Titlespaced}@]. The latter differs in that it uses the spaced version of the name.%0a%0a:Page URI: Page names are used in `URIs to tell PmWiki which page is to be loaded or acted upon. The normal form of a page URI is usually one of these two%0a--> [@http://www.example.com/pmwiki/pmwiki.php?n=Main.WikiSandbox@]%0a--> [@http://www.example.com/pmwiki/pmwiki.php/Main.WikiSandbox@]%0a-> Note that various aliasing and rewriting tricks can be used to modify this, but PmWiki expects to obtain a page name from the parameter 'n' or from the [@PATH_INFO@] component following the URI of the script ([@pmwiki.php@]).%0a-> Note that the parameter 'n' takes precedence over [@PATH_INFO@] if both are available.%0a%0a:Wikifarm:Synonymous for "[[#farm | farm]]".%0a%0a -time=1315670897 +rev=30 +targets=PmWiki.LayoutVariables,PmWiki.PathVariables,PmWiki.WikiFarmTerminology +text=(:Summary: Terms related to PmWiki:)%0a%0aThis page describes various terms related to PmWiki.%0a%0a:Author: Any user with privileges to write to the wiki.%0a%0a:Admin: The person (or people) who controls access to the wiki, configures the wiki, and generally is the person who installed the wiki.%0a%0a:Configuration file: A specially named PHP script file where local customizations can take place for a farm, a wiki, a group, or a page.%0a%0a:Default configuration: The way Pm has chosen to set all settings, or an individual setting, by default. For example, $EnablePathInfo is disabled by default. A wiki with no @@''local/config.php''@@ file is using the default configuration. Likewise, a farm that only defines $FarmPubDirUrl in @@''farmconfig.php''@@ is using the default configuration.%0a%0a[[#farm]]%0a:Farm: A group of wikis that share code. Content and formats may or may not be shared. For more farm-related terms, including several which have been deprecated, see [[Wiki Farm Terminology]]%0a%0a:Farm-wide configuration file: A WikiFarm's @@''local/farmconfig.php''@@ file, where any settings (besides $FarmPubDirUrl) customize the default configuration for all of the wikis in a farm.%0a%0a:Full page name: The ''full page name'' consists of a group and a name, e.g. %25pmhlt%25[@Main.WikiSandbox@]. The variable for the full page name is [@{$FullName}@], which for this page is @@{$FullName}@@. Similarly, the variable for the group is [@{$Group}@] which here is @@{$Group}@@.%0a%0a:Group: A collection of associated wiki pages; by default this appears in the page name as @@"Group.PageName"@@. Attributes can be set on all pages in the group simultaneously. The variable for the group is %25pmhlt%25[@{$Group}@], which here is @@{$Group}@@.%0a%0a:Local configuration file: A specially named PHP script where local customizations can take place for an individual wiki. For an entire wiki it's named @@''local/config.php''@@. Individual groups and pages can also have their own local configuration files.%0a%0a:Local customization: Any deviation from the default configuration. A related phrase is "farm-wide customization".%0a%0a:Page file name: The ''page file name'' is the name of the file that normally stores the data of a page in the directory [@wiki.d/@]. This file name is normally built directly from the page name.%0a%0a:Page link: A ''page link'' is something that is used to generate a link to a page. For example, the markup %25pmhlt%25[@[[wiki sandbox]]@], [@[[(wiki) sandbox]]@], [@WikiSandbox@], [@Main/WikiSandbox@], [@[[Main/wiki sandbox]]@], [@[[Main.WikiSandbox | click here]]@], etc all specify a link to the page '[@Main.WikiSandbox@]'. In each case PmWiki uses the context of the link to generate a page name from the page link -- normally by capitalizing each word found in the link and stripping any characters that aren't considered valid in page names.%0a%0a:Page name: The ''page name'' is a string that PmWiki uses to refer to a page - i.e. it ''names the page''. This could also be considered a ''handle'' for the page. The variable for the page name is simply called %25pmhlt%25[@{$Name}@], which for this page is @@{$Name}@@.%0a-> Note that there is no whitespace in page names, and by default PmWiki capitalizes each word in a page's name. There is however a variable %25pmhlt%25[@{$Namespaced}@] where spaces have been inserted, e.g. for the page [@WikiSandbox@] this variable would be [@Wiki Sandbox@].%0a-> Note that PmWiki also uses the page name to locate per-group and per-page customization files in the [@local/@] subdirectory. For example, browsing [@Main.WikiSandbox@] would cause [@local/Main.WikiSandbox.php@] and [@local/Main.php@] to be loaded if these files existed.%0a%0a:Page title: A ''page title'' is the title element of a page, i.e. what is usually shown above the page and in the browser window's name. This title is normally set via the directive %25pmhlt%25[@(:title:)@], but if no such directive is given the title will be automatically generated from the page name. The title of a page is accessed via either the variable [@{$Title}@] or the variable [@{$Titlespaced}@]. The latter differs in that it uses the spaced version of the name.%0a%0a:Page URI: Page names are used in `URIs to tell PmWiki which page is to be loaded or acted upon. The normal form of a page URI is usually one of these two%0a--> [@https://example.com/pmwiki/pmwiki.php?n=Main.WikiSandbox@]%0a--> [@https://example.com/pmwiki/pmwiki.php/Main.WikiSandbox@]%0a-> Note that various aliasing and rewriting tricks can be used to modify this, but PmWiki expects to obtain a page name from the parameter 'n' or from the [@PATH_INFO@] component following the URI of the script ([@pmwiki.php@]).%0a-> Note that the parameter 'n' takes precedence over [@PATH_INFO@] if both are available.%0a%0a:Wikifarm:Synonymous for "[[#farm | farm]]".%0a%0a +time=1660025044 blob - 120cb9d9bb36562ebea5d5ef97f56d6fa21d0bb6 blob + 37e1db3e632297412a0996dfa0924ba4062b0913 --- wikilib.d/PmWiki.GroupCustomizations +++ wikilib.d/PmWiki.GroupCustomizations @@ -1,10 +1,10 @@ -version=pmwiki-2.2.122 ordered=1 urlencoded=1 -author=Petko +version=pmwiki-2.3.7 ordered=1 urlencoded=1 +author=MFWolff charset=UTF-8 -csum=%25hlt php%25, See also $WikiPageCSSFmt and Cookbook:LocalCSS. +csum=forgotten @@ (+4) ctime=1250689504 name=PmWiki.GroupCustomizations -rev=16 -targets=PmWiki.WikiGroup,PmWiki.WikiAdministrator,PmWiki.LocalCustomizations,PmWiki.GroupHeaders,PmWiki.Passwords,PmWiki.PasswordsAdmin,PmWiki.SecurityVariables,PmWiki.WikiCascades,PmWiki.GroupName,Cookbook.LocalCSS,PmWiki.LayoutVariables,PmWiki.BasicVariables,PmWiki.GroupAttributes,PmWiki.WikiFarms,PmWiki.HierarchicalGroups -text=(:Summary: How to customize a subset of your wiki:)%0a(:Audience: administrators (intermediate) :)%0aOne of the purposes of [[Wiki Group]]s is to allow a [[Wiki Administrator]] to customize the features of PmWiki on a per-group basis. Here is where ''per group customizations'' come into play.%0a%0a!! Group-specific PHP and CSS %0a%0aThe ''local/'' subdirectory is used to hold local configuration files. %0a%0aThe ''pub/css/'' subdirectory is used to hold local css files.%0a%0aTo perform [[local customizations]] for a particular WikiGroup, %0a* place the customizations in a file called "''%3cgroupname>.php''" (where ''%3cgroupname>'' is the actual name of the page group in question) in the ''local/'' subdirectory %0a* place the CSS customizations in a file called "''%3cgroupname>.css''" (where ''%3cgroupname>'' is the actual name of the page group in question) in the ''pub/css/'' subdirectory.%0aThese files will be automatically processed after processing any local customizations in the ''config.php'' and ''local.css'' files.%0a%0aFor example, to change the image displayed in the upper-left corner of pages in the "GroupName" WikiGroup, one could create ''local/GroupName.php'' containing%0a->%25hlt php%25 [@%0a%3c?php%0a $PageLogoUrl = "/myimages/chess.gif";%0a@]%0aThe example's effect would cause all pages in the GroupName [[Wiki Group]] to use "/myimages/chess.gif" as the logo image instead of the default.%0a%0aTo add markup to the beginning or end of each page in a wiki group, see [[Group headers]].%0a%0a!! Per-page customizations%0a[[#PerPage]] PmWiki also allows per-page customizations; simply use the full name of the page to be customized instead of the group. For example, one can use the file ''local/Chess.`HomePage.php'' to set local customizations for Chess.`HomePage.%0a%0aAlmost any customization that would be placed in ''config.php'' can be used as a per-group or per-page customization. %0a%0aAn important exception to this is setting '''per-group or per-page customizations for recipe scripts''' included in config.php. Most recipe scripts would need any customization variables defined before the script is included. Instead of using a per-group or per-page customization php file, use a per-group or per-page conditional statement in config.php, before including the recipe script. Example:%0a%0a->%25hlt php%25[@%0a## Inclusion of per-page and per-group local php scripts%0a$pagename = ResolvePageName($pagename);%0ainclude_once("$FarmD/scripts/pgcust.php");%0a%0a$page = PageVar($pagename, '$FullName');%0a$group = PageVar($pagename, '$Group');%0a//per-group customizations:%0aif($group=='GroupName') {%0a $RecipeVariable = 'valueA';%0a etc. ...%0a}%0a//per-page customizations:%0aif($page=='GroupName.PageName') {%0a $RecipeVariable = 'valueB';%0a etc. ...%0a}%0a//include recipe after variables are set:%0ainclude_once('cookbook/recipescript.php');@]%0a''Required reading: [[LocalCustomizations#configphp-order|Order of the commands in config.php]].''%0a%0a%25red%25 Note that this method cannot be used to set $DefaultPasswords, you should use Group or Page attributes. See [[Passwords]] and [[PasswordsAdmin]] for more information.%0a%0a[[#processingorder]]%0a!! Processing order%0aFor all local customizations, PmWiki first processes the ''local/config.php'' file, and then looks for a per-page customization file in the ''local/'' subdirectory to process, followed by any per-group customization file. If no per-page or per-group customizations are loaded, then PmWiki loads ''local/default.php''. If a per-page customization wants to have the per-group customizations loaded first, it can do so directly by using PHP's [@include_once()@] function.%0aFor more information see [[(PmWiki:)wiki cascades]].%0a%0a!! Custom CSS styles per group or per-page%0aTo apply CSS styles to pages of a specific group named [[Group Name]], create a file named ''GroupName.css'' in the ''pub/css/'' directory and add the CSS style rules there. To apply styles to a specific page, create a file ''GroupName.PageName.css'' in this directory with your style rules. Any CSS rules to be applied for all wiki pages can be put into ''pub/css/local.css''.%0a%0a->%25hlt css%25[@%0a body { background: #F4C4B4; }%0a@]%0a%0aSee also $WikiPageCSSFmt and Cookbook:LocalCSS.%0a%0a!! Preventing group-Level configurations%0aAny customization file can set $EnablePGCust=0; to prevent later page/group/default customizations from being automatically loaded. If a per-page customization needs to have the per-group customizations loaded first, it can do so directly by using PHP's [@include_once()@] function.%0a%0a!! Authentication%0aAny passwords required for a group should be set in the group's [[Group Attributes]] page (see [[Passwords Admin]]istration) and not in a group customization file.%0a%0a!! Consider Wiki Farms%0a[[Wiki Group]]s are an easy way to host multiple sites in a single PmWiki installation by giving each site its own group. Another approach is to use [[Wiki Farms]], which allows each site to have its own set of [[Wiki Group]] and local customization files.%0a%0aIf you are looking for nested group levels, you may want to consider [[PmWiki:HierarchicalGroups|Pm's design considerations on hierarchical groups]].%0a%0a!! FAQ%0a>>faq%3c%3c [[#faq]]%0aQ: How can I apply CSS styles to a particular group or page?%0a%0aA: Simply create a ''pub/css/Group.css'' or ''pub/css/Group.Page.css'' file containing the custom CSS styles for that group or page. See also Cookbook:LocalCSS.%0a%0aQ: Why shouldn't passwords be set in group (or page) customization files? Why shouldn't group or page passwords be set in config.php?%0a%0aA: The reason for this advice is that per-group customization files are only loaded for the current page. So, if @@[=$DefaultPasswords['read']=]@@ is set in ''local/GroupA.php'', then someone could use a page in another group to view the contents of pages in GroupA. For example, Main.WikiSandbox could contain:%0a%0a--> [=(:include GroupA.SomePage:)=]%0a%0aand because the ''GroupA.php'' file wasn't loaded (we're looking at Main.WikiSandbox --> ''local/Main.php''), there's no read password set.%0a%0aThe same is true for page customization files.%0a%0aQ: Isn't that processing order strange? Why not load per page configuration last (that is after global configuration an per group configuration)?%0a%0aA: Many times what we want to do is to enable a certain capability for a group of pages, but disable it on a specific page, as if it was never enabled. If the per-group config file is processed first, then it becomes very difficult/tedious for the per-page one to "undo" the effects of the per-group page. So, we load the per-page file before the per-group.%0a%0aIf a per-page customization wants the per-group customizations to be performed first, it can use the techniques given [[#processingorder|above]] (using ''include_once()'' or setting @@[=$EnablePGCust = 0;=]@@).%0a -time=1574411830 +rev=18 +targets=PmWiki.WikiGroup,PmWiki.WikiAdministrator,PmWiki.LocalCustomizations,PmWiki.GroupHeaders,PmWiki.Passwords,PmWiki.PasswordsAdmin,PmWiki.SecurityVariables,PmWiki.WikiCascades,Cookbook.LocalCSS,PmWiki.LayoutVariables,PmWiki.BasicVariables,PmWiki.GroupAttributes,PmWiki.WikiFarms,PmWiki.HierarchicalGroups +text=(:Summary: How to customize a subset of your wiki:)%0a(:Audience: administrators (intermediate) :)%0aOne of the purposes of [[Wiki Group]]s is to allow a [[Wiki Administrator]] to customize the features of PmWiki on a per-group basis. Here is where ''per group customizations'' come into play.%0a%0a!! Group-specific PHP and CSS %0a%0aThe ''@@local/@@'' subdirectory is used to hold local configuration files. %0a%0aThe ''@@pub/css/@@'' subdirectory is used to hold local css files.%0a%0aTo perform [[local customizations]] for a particular WikiGroup, %0a* place the customizations in a file called "''@@%3cgroupname>.php@@''" (where ''@@%3cgroupname>@@'' is the actual name of the page group in question) in the ''@@local/@@'' subdirectory %0a* place the CSS customizations in a file called "''@@%3cgroupname>.css@@''" (where ''@@%3cgroupname>@@'' is the actual name of the page group in question) in the ''@@pub/css/@@'' subdirectory.%0aThese files will be automatically processed after processing any local customizations in the ''@@config.php@@'' and ''@@local.css@@'' files.%0a%0aFor example, to change the image displayed in the upper-left corner of pages in the "@@GroupName@@" WikiGroup, one could create ''@@local/GroupName.php@@'' containing%0a->%25hlt php%25 [@%0a%3c?php%0a $PageLogoUrl = "/myimages/chess.gif";%0a@]%0aThe example's effect would cause all pages in the @@`GroupName@@ [[Wiki Group]] to use "@@/myimages/chess.gif@@" as the logo image instead of the default.%0a%0aTo add markup to the beginning or end of each page in a wiki group, see [[Group headers]].%0a%0a!! Per-page customizations%0a[[#PerPage]] PmWiki also allows per-page customizations; simply use the full name of the page to be customized instead of the group. For example, one can use the file ''@@local/Chess.`HomePage.php@@'' to set local customizations for Chess.`HomePage.%0a%0aAlmost any customization that would be placed in ''@@config.php@@'' can be used as a per-group or per-page customization. %0a%0aAn important exception to this is setting '''per-group or per-page customizations for recipe scripts''' included in @@config.php@@. Most recipe scripts would need any customization variables defined before the script is included. Instead of using a per-group or per-page customization php file, use a per-group or per-page conditional statement in @@config.php@@, before including the recipe script. Example:%0a%0a->%25hlt php%25[@%0a## Inclusion of per-page and per-group local php scripts%0a$pagename = ResolvePageName($pagename);%0ainclude_once("$FarmD/scripts/pgcust.php");%0a%0a$page = PageVar($pagename, '$FullName');%0a$group = PageVar($pagename, '$Group');%0a//per-group customizations:%0aif($group=='GroupName') {%0a $RecipeVariable = 'valueA';%0a etc. ...%0a}%0a//per-page customizations:%0aif($page=='GroupName.PageName') {%0a $RecipeVariable = 'valueB';%0a etc. ...%0a}%0a//include recipe after variables are set:%0ainclude_once('cookbook/recipescript.php');@]%0a''Required reading: [[LocalCustomizations#configphp-order|Order of the commands in @@config.php@@]].''%0a%0a%25red%25 Note that this method cannot be used to set $DefaultPasswords, you should use Group or Page attributes. See [[Passwords]] and [[PasswordsAdmin]] for more information.%0a%0a[[#processingorder]]%0a!! Processing order%0aFor all local customizations, PmWiki first processes the ''@@local/config.php@@'' file, and then looks for a per-page customization file in the ''@@local/@@'' subdirectory to process, followed by any per-group customization file. If no per-page or per-group customizations are loaded, then PmWiki loads ''@@local/default.php@@''. If a per-page customization wants to have the per-group customizations loaded first, it can do so directly by using PHP's %25hlt php%25[@include_once()@] function.%0aFor more information see [[(PmWiki:)wiki cascades]].%0a%0a!! Custom CSS styles per group or per-page%0aTo apply CSS styles to pages of a specific group named [@Group Name@], create a file named ''@@GroupName.css@@'' in the ''@@pub/css/@@'' directory and add the CSS style rules there. To apply styles to a specific page, create a file ''@@GroupName.PageName.css@@'' in this directory with your style rules. Any CSS rules to be applied for all wiki pages can be put into ''@@pub/css/local.css@@''.%0a%0a->%25hlt css%25[@%0a body { background: #F4C4B4; }%0a@]%0a%0aSee also $WikiPageCSSFmt and Cookbook:LocalCSS.%0a%0a!! Preventing group-Level configurations%0aAny customization file can set $EnablePGCust=0; to prevent later page/group/default customizations from being automatically loaded. If a per-page customization needs to have the per-group customizations loaded first, it can do so directly by using PHP's %25hlt php%25[@include_once()@] function.%0a%0a!! Authentication%0aAny passwords required for a group should be set in the group's [[Group Attributes]] page (see [[Passwords Admin]]istration) and not in a group customization file.%0a%0a!! Consider Wiki Farms%0a[[Wiki Group]]s are an easy way to host multiple sites in a single PmWiki installation by giving each site its own group. Another approach is to use [[Wiki Farms]], which allows each site to have its own set of [[Wiki Group]] and local customization files.%0a%0aIf you are looking for nested group levels, you may want to consider [[PmWiki:HierarchicalGroups|Pm's design considerations on hierarchical groups]].%0a%0a!! FAQ%0a>>faq%3c%3c [[#faq]]%0aQ: How can I apply CSS styles to a particular group or page?%0a%0aA: Simply create a ''@@pub/css/Group.css@@'' or ''@@pub/css/Group.Page.css@@'' file containing the custom CSS styles for that group or page. See also Cookbook:LocalCSS.%0a%0aQ: Why shouldn't passwords be set in group (or page) customization files? Why shouldn't group or page passwords be set in @@config.php@@?%0a%0aA: The reason for this advice is that per-group customization files are only loaded for the current page. So, if %25hlt php%25@@[=$DefaultPasswords['read']=]@@ is set in ''@@local/GroupA.php@@'', then someone could use a page in another group to view the contents of pages in GroupA. For example, Main.WikiSandbox could contain:%0a%0a--> %25pmhlt%25[@(:include GroupA.SomePage:)@]%0a%0aand because the ''@@GroupA.php@@'' file wasn't loaded (we're looking at Main.WikiSandbox --> ''@@local/Main.php@@''), there's no read password set.%0a%0aThe same is true for page customization files.%0a%0aQ: Isn't that processing order strange? Why not load per page configuration last (that is after global configuration an per group configuration)?%0a%0aA: Many times what we want to do is to enable a certain capability for a group of pages, but disable it on a specific page, as if it was never enabled. If the per-group config file is processed first, then it becomes very difficult/tedious for the per-page one to "undo" the effects of the per-group page. So, we load the per-page file before the per-group.%0a%0aIf a per-page customization wants the per-group customizations to be performed first, it can use the techniques given [[#processingorder|above]] (using %25hlt php%25@@include_once()@@ or setting @@[=$EnablePGCust = 0;=]@@).%0a +time=1657950414 blob - 8afe7666af64d581d0d369efdd13c6e1abdd65ff blob + fbe61fcf2afe5e1a04d670a4c25d0e58ac5b2c65 --- wikilib.d/PmWiki.GroupFooter +++ wikilib.d/PmWiki.GroupFooter @@ -1,11 +1,10 @@ -version=pmwiki-2.2.30 ordered=1 urlencoded=1 -agent=Mozilla/5.0 (X11; Linux x86_64; rv:5.0) Gecko/20100101 Firefox/5.0 -author=SchreyP +version=pmwiki-2.3.15 ordered=1 urlencoded=1 +author=Petko charset=UTF-8 -csum=Add "|+" after Documentation index link so translation is shown +csum= (+24) ctime=1219202352 name=PmWiki.GroupFooter -rev=62 -targets=PmWiki.DocumentationIndex,PmWiki.Variables,PmWiki.GroupF -text=(:Summary:Trail and talk page links:)%0a[[#trailstart]] (:comment included in PmWiki localisation headers and footers :)%0a(:if ontrail {*$Group}.DocumentationIndex#trailstart#trailend {*$Name}:) %0a(:div style="clear:right; float:right; font-size:smaller; background-color:#eee;":)%0a%3c|[[{*$Group}/Documentation index(#trailstart#trailend)|+]]|> %25%25%0a(:divend:)%0a(:ifend:)%0a(:if ontrail {*$Group}.Variables {*$Name}:) %0a(:div style="clear:right; float:right; font-size:smaller; background-color:#ddd;":)%0a%3c|[[{*$Group}/Variables]]|> %25%25%0a(:divend:)%0a(:ifend:)%0a[[#trailend]]%0a[[%3c%3c]]%0a>>bgcolor=#ffe border-top="1px solid black" font-size=.8em%3c%3c%0a(:if name *-Talk:)%0aThis is a talk page for improving [[{(substr "{*$FullName}" 0 -5)}]].%0a(:else:)%0aThis page may have %25commentout-pmwikiorg%25 a more recent version on [[(http://www.)pmwiki.org]]: [[PmWiki:{*$Name}]], and %25%25 a talk page: [[PmWiki:{*$Name}-Talk]].%0a(:ifend:)%0a>>%3c%3c%0a -time=1315670897 +rev=69 +targets=PmWiki.DocumentationIndex,PmWiki.Variables,PmWiki.GroupF,PmWiki.GroupFooter,PmWiki.GroupFooter-Talk +text=(:Summary:Trail and talk page links:)%0a[[#trailstart]] (:comment included in PmWiki localisation headers and footers :)%0a(:if ontrail {*$Group}.DocumentationIndex#trailstart#trailend {*$Name}:) %0a>>rfloat clear=right font-size=smaller background-color=#eee%3c%3c%0a%3c|[[{*$Group}/DocumentationIndex(#trailstart#trailend)|+]]|> %25%25%0a>>%3c%3c%0a(:ifend:)%0a(:if ontrail {*$Group}.Variables {*$Name}:) %0a>>rfloat clear=right font-size=smaller background-color=#ddd%3c%3c%0a%3c|[[{*$Group}/Variables]]|> %25%25%0a>>%3c%3c%0a(:ifend:)%0a[[#trailend]]%0a[[%3c%3c]]%0a>>bgcolor=#ffe border-top="1px solid black" font-size=.8em margin-top=1em%3c%3c%0a(:if name *-Talk:)%0aThis is a talk page for improving [[{(substr "{*$FullName}" 0 -5)}]].%0a(:else:)%0aThis page may have %25commentout-pmwikiorg%25 a more recent version on [[(https://www.)pmwiki.org]]: [[PmWiki:{*$Name}]], and %25%25 a talk page: [[PmWiki:{*$Name}-Talk]].%0a(:ifend:)%0a>>%3c%3c%0a +time=1669285533 blob - 261143476662437fdfb03be66219c0dbb0a3beda blob + b5d879022d1049b662341790952e4e9d6fefe478 --- wikilib.d/PmWiki.GroupHeader +++ wikilib.d/PmWiki.GroupHeader @@ -1,10 +1,9 @@ -version=pmwiki-2.2.30 ordered=1 urlencoded=1 -agent=Mozilla/5.0 (X11; Linux x86_64; rv:5.0) Gecko/20100101 Firefox/5.0 -author=Simon +version=pmwiki-2.3.15 ordered=1 urlencoded=1 +author=Petko charset=UTF-8 -csum=restore +csum=typo (+1) name=PmWiki.GroupHeader -rev=63 +rev=67 targets= -text=(:Summary: PmWiki group header. Includes styles and trail.:)%0a%25define=note font-style=italic color=green%25\%0a%25define=important block bgcolor=#fcc border='1px solid black' padding=5px%25\%0a%25define=audience class='frame rfloat' font-size:smaller bgcolor=#ffffcc clear:right%25(:comment please leave the multiple style definitions concatenated as a single line. Linebreaks do appear in the output when the wiki is configured with linebreaks enabled -- thanks!:)%0a(:include PmWiki.GroupFooter#trailstart#trailend:)%0a(:if ! equal "{*$:Audience} "" :)(:div style="clear:right;":)%25audience%25{*$:Audience}%25%25%0a(:divend:)(:ifend:) -time=1315670897 +text=(:Summary: PmWiki group header. Includes styles and trail.:)%0a%25define=note font-style=italic color=green%25\%0a%25define=important block bgcolor=#fcc border='1px solid black' padding=5px%25\%0a%25define=audience class='frame rfloat' font-size:smaller bgcolor=#ffffcc clear=right%25(:comment please leave the multiple style definitions concatenated as a single line. Linebreaks do appear in the output when the wiki is configured with linebreaks enabled -- thanks!:)%0a(:include PmWiki.GroupFooter#trailstart#trailend:)%0a(:if ! equal "{*$:Audience}" "" :)%0a>>audience%3c%3c%0a{*$:Audience}%0a>>%3c%3c%0a(:ifend:) +time=1669299012 blob - 7d4bcce7ca7ecb32232f2970ada21268deeb5a19 blob + 205e0f90bf9e287105e4d1803ca03b21e6b85966 --- wikilib.d/PmWiki.GroupHeaders +++ wikilib.d/PmWiki.GroupHeaders @@ -1,10 +1,10 @@ -version=pmwiki-2.2.48 ordered=1 urlencoded=1 -author=Petko +version=pmwiki-2.3.8 ordered=1 urlencoded=1 +author=MFWolff charset=UTF-8 -csum=title GroupHeaders and GroupFooters +csum=typo (+0) name=PmWiki.GroupHeaders -rev=72 +rev=74 targets=PmWiki.WikiGroup,PmWiki.WikiStyles,PmWiki.PageDirectives,PmWiki.WikiAdministrator,PmWiki.IncludeOtherPages,PmWiki.LayoutVariables,Cookbook.AllGroupHeader,Cookbook.WikiFooter -text=(:Summary: Group Header and Group Footer page usage:)(:title GroupHeaders and GroupFooters:)%0a(:Audience: authors (intermediate) :)%0aEvery [[WikiGroup]] can have `GroupHeader and `GroupFooter pages that contain markup that should be included at the beginning or end of each page within the group. This feature is useful for:%0a%0a* adding a disclaimer or heading to all of the pages of a group%0a* defining custom [[WikiStyles]] that may be used for all pages in a group%0a* replacing the default headers and/or footers for pages in a group (e.g., using [@(:noheader:)@] and or [@(:nofooter:)@] -- see [[PageDirectives]]).%0a%0aTo create a group header, just create a new page called [@YourGroup.GroupHeader@]. Group headers allow authors to create groups with custom headers and footers without having to coordinate with a [[wiki administrator]]. %0a%0aThe default `GroupHeader or `GroupFooter can be suppressed on an individual page (such as a group's `HomePage) by using the [@(:nogroupheader:)@] and [@(:nogroupfooter:)@] markups ''on that page''.%0a%0aIf a generic `GroupHeader is used in one wikigroup (say, the Site wikigroup), then the code can be easily duplicated in the `GroupHeader of any other group by using %0a[@(:include Site.GroupHeader:)@]. See [[IncludeOtherPages]].%0a%0aIf you want a header or footer to appear when you print a page (action '''print'''), simply create a page called [@YourGroup.GroupPrintHeader@] or [@YourGroup.GroupPrintFooter@] and fill it with your markup.%0a%0aYou can also set the variable [[LayoutVariables#GroupPrintHeaderFmt | [@$GroupPrintHeaderFmt@]]] and [[LayoutVariables#GroupPrintFooterFmt | [@$GroupPrintFooterFmt@]]] in the same way as [@$GroupHeaderFmt@] and [@GroupFooterFmt@] in order to change the header used when [@action=print@]. %0a%0aSee also%0a* [[Cookbook:All group header]] [- {Cookbook/AllGroupHeader$:Summary} -]%0a* [[Cookbook:Wiki footer]] [- {Cookbook/Wikifooter$:Summary} -]%0a%0a%0a>>faq%3c%3c [[#faq]]%0a%0aQ: How do I set the same header or footer for all pages/groups?%0aA: The header and footer for each page are controlled by the variables $GroupHeaderFmt and $GroupFooterFmt. If your site-wide header and footer pages are Site.SiteHeader and Site.SiteFooter, you can add this in config.php:%0a%0a->[@%0a### If you use Site.SiteHeader and Group.GroupHeader%0a$GroupHeaderFmt = '(:include {$SiteGroup}.SiteHeader'%0a . ' basepage={*$FullName}:)(:nl:)' . $GroupHeaderFmt;%0a%0a### If you use Site.SiteHeader instead of Group.GroupHeader%0a$GroupHeaderFmt = '(:include {$SiteGroup}.SiteHeader'%0a . ' basepage={*$FullName}:)(:nl:)';%0a%0a### If you use Site.SiteFooter and Group.GroupFooter%0a$GroupFooterFmt .= '(:nl:)(:include {$SiteGroup}.SiteFooter'%0a . ' basepage={*$FullName}:)';%0a%0a### If you use Site.SiteFooter instead of Group.GroupFooter%0a$GroupFooterFmt = '(:nl:)(:include {$SiteGroup}.SiteFooter'%0a . ' basepage={*$FullName}:)';%0a@]%0a%0aNote that single quotes must be used in the lines above.%0a%0aSee also the Cookbook:AllGroupHeader recipe.%0a%0aA: Instead of using an additional page, you could set any wiki text in $GroupHeaderFmt, for example:%0a%0a->[@$GroupHeaderFmt .= "Global message here.";@]%0a -time=1361895313 +text=(:Summary: Group Header and Group Footer page usage:)(:title GroupHeaders and GroupFooters:)%0a(:Audience: authors (intermediate) :)%0aEvery [[WikiGroup]] can have @@`GroupHeader@@ and @@`GroupFooter@@ pages that contain markup that should be included at the beginning or end of each page within the group. This feature is useful for:%0a%0a* adding a disclaimer or heading to all of the pages of a group%0a* defining custom [[WikiStyles]] that may be used for all pages in a group%0a* replacing the default headers and/or footers for pages in a group (e.g., using %25pmhlt%25[@(:noheader:)@] and or [@(:nofooter:)@] -- see [[Page Directives]]).%0a%0aTo create a group header, just create a new page called [@YourGroup.GroupHeader@]. Group headers allow authors to create groups with custom headers and footers without having to coordinate with a [[wiki administrator]]. %0a%0aThe default @@`GroupHeader@@ or @@`GroupFooter@@ can be suppressed on an individual page (such as a group's @@`HomePage@@) by using the %25pmhlt%25[@(:nogroupheader:)@] and [@(:nogroupfooter:)@] markups ''on that page''.%0a%0aIf a generic @@`GroupHeader@@ is used in one wikigroup (say, the Site wikigroup), then the code can be easily duplicated in the @@`GroupHeader@@ of any other group by using %0a%25pmhlt%25[@(:include Site.GroupHeader:)@]. See [[Include Other Pages]].%0a%0aIf you want a header or footer to appear when you print a page (action '''print'''), simply create a page called [@YourGroup.GroupPrintHeader@] or [@YourGroup.GroupPrintFooter@] and fill it with your markup.%0a%0aYou can also set the variable %25pmhlt%25[[LayoutVariables#GroupPrintHeaderFmt | [@$GroupPrintHeaderFmt@]]] and [[LayoutVariables#GroupPrintFooterFmt | [@$GroupPrintFooterFmt@]]] in the same way as [@$GroupHeaderFmt@] and [@GroupFooterFmt@] in order to change the header used when [@action=print@]. %0a%0aSee also%0a* [[Cookbook:All group header]] [- {Cookbook/AllGroupHeader$:Summary} -]%0a* [[Cookbook:Wiki footer]] [- {Cookbook/Wikifooter$:Summary} -]%0a%0a%0a>>faq%3c%3c [[#faq]]%0a%0aQ: How do I set the same header or footer for all pages/groups?%0aA: The header and footer for each page are controlled by the variables $GroupHeaderFmt and $GroupFooterFmt. If your site-wide header and footer pages are @@Site.SiteHeader@@ and @@Site.SiteFooter@@, you can add this in @@config.php@@:%0a%0a->%25hlt php%25[@%0a### If you use Site.SiteHeader and Group.GroupHeader%0a$GroupHeaderFmt = '(:include {$SiteGroup}.SiteHeader'%0a . ' basepage={*$FullName}:)(:nl:)' . $GroupHeaderFmt;%0a%0a### If you use Site.SiteHeader instead of Group.GroupHeader%0a$GroupHeaderFmt = '(:include {$SiteGroup}.SiteHeader'%0a . ' basepage={*$FullName}:)(:nl:)';%0a%0a### If you use Site.SiteFooter and Group.GroupFooter%0a$GroupFooterFmt .= '(:nl:)(:include {$SiteGroup}.SiteFooter'%0a . ' basepage={*$FullName}:)';%0a%0a### If you use Site.SiteFooter instead of Group.GroupFooter%0a$GroupFooterFmt = '(:nl:)(:include {$SiteGroup}.SiteFooter'%0a . ' basepage={*$FullName}:)';%0a@]%0a%0aNote that single quotes must be used in the lines above.%0a%0aSee also the Cookbook:AllGroupHeader recipe.%0a%0aA: Instead of using an additional page, you could set any wiki text in $GroupHeaderFmt, for example:%0a%0a->%25hlt php%25[@$GroupHeaderFmt .= "Global message here.";@]%0a +time=1660040875 title=GroupHeaders and GroupFooters blob - a7086500265dd5a1bcb28da5a4615e06f75d961f blob + b2ed4a66f28a75f91662c78c2c30d52bc931acac --- wikilib.d/PmWiki.I18nVariables +++ wikilib.d/PmWiki.I18nVariables @@ -1,9 +1,9 @@ -version=pmwiki-2.2.90 ordered=1 urlencoded=1 -author=HaganFox +version=pmwiki-2.3.15 ordered=1 urlencoded=1 +author=simon charset=UTF-8 -csum=$DefaultPageCharset +csum=pmhlt (+15) name=PmWiki.I18nVariables -rev=17 -targets=PmWiki.Internationalizations,Site.Preferences -text=(:Summary:variables used for internationalization (i18n):)%0a%0aThis page describes the variables used by PmWiki for [[Internationalizations]] (i18n).%0a%0a(:if ! equal '{$DefaultPageCharset}' '':)%0a%25rfloat%25Variable value "{$DefaultPageCharset}"%0a(:ifend:)%0a:$DefaultPageCharset: Fix and correctly handle some pages with missing or wrong attributes when UTF-8 is enabled.%0a%0a:$EnableXLPageScriptLoad:This variable, if set to 0, will disable the 'xlpage-i18n' parameter in XLPage definitions and thus it will prevent editors from (accidentally) loading scripts and changing the website encoding. Note that if you use this variable, you should include the required scripts, eg. xlpage-utf-8.php, from config.php.%0a%0a:$VarPagesFmt:An array which contains the PageNames where you can find lists (trails) of pages containing variable definitions. To be modified when documentation is not in English. See ''scripts/vardoc.php''.%0a%0a:@@%25blue%25$XL%25%25@@:An array (hash) which contains pairs of language identifiers and translation hashes. Each translation hash maps a given lookup key (or phrase) into a corresponding text string for the given language. Thus, it is essentially a multi-lingual dictionary used for phrase translation. It is also used for handling user preference mappings. Thus, the 'e_row' value that one finds on the [[Site.Preferences]] page is loaded into $XL during preference processing.%0a%0a:$XLLangs:An array that contains the names of the currently active language definitions. Only dictionaries in $XL that are named in $XLLangs are used by the [=$[...]=] markup when performing a translation.%0a%0aSee also:%0a* $TimeFmt%0a -time=1473815007 +rev=18 +targets=PmWiki.Internationalizations,PmWiki.I18nVariables,Site.Preferences,PmWiki.BasicVariables +text=(:Summary:variables used for internationalization (i18n):)%0a%0aThis page describes the variables used by PmWiki for [[Internationalizations]] (i18n).%0a%0a(:if ! equal '{$DefaultPageCharset}' '':)%0a%25rfloat%25Variable value "{$DefaultPageCharset}"%0a(:ifend:)%0a:$DefaultPageCharset: Fix and correctly handle some pages with missing or wrong attributes when UTF-8 is enabled.%0a%0a:$EnableXLPageScriptLoad:This variable, if set to 0, will disable the 'xlpage-i18n' parameter in XLPage definitions and thus it will prevent editors from (accidentally) loading scripts and changing the website encoding. Note that if you use this variable, you should include the required scripts, eg. @@xlpage-utf-8.php@@, from @@config.php@@.%0a%0a:$VarPagesFmt:An array which contains the PageNames where you can find lists (trails) of pages containing variable definitions. To be modified when documentation is not in English. See ''scripts/vardoc.php''.%0a%0a:@@%25blue%25$XL%25%25@@:An array (hash) which contains pairs of language identifiers and translation hashes. Each translation hash maps a given lookup key (or phrase) into a corresponding text string for the given language. Thus, it is essentially a multi-lingual dictionary used for phrase translation. It is also used for handling user preference mappings. Thus, the 'e_row' value that one finds on the [[Site.Preferences]] page is loaded into $XL during preference processing.%0a%0a:$XLLangs:An array that contains the names of the currently active language definitions. Only dictionaries in $XL that are named in $XLLangs are used by the %25pmhlt%25[@$[...]@] markup when performing a translation.%0a%0aSee also:%0a* $TimeFmt%0a +time=1669576711 blob - fad6454a0bb68fefc391fa9c217b805b876035cd blob + 085dc71b814909f9a0255ae901222be9d77e64db --- wikilib.d/PmWiki.Images +++ wikilib.d/PmWiki.Images @@ -1,10 +1,10 @@ -version=pmwiki-2.2.129 ordered=1 urlencoded=1 -author=Petko +version=pmwiki-2.3.15 ordered=1 urlencoded=1 +author=simon charset=UTF-8 -csum=correction (+8) +csum=another pm hlt (+14) keywords=graphics, pictures, photos name=PmWiki.Images -rev=210 +rev=218 targets=PmWiki.DocumentationIndex,PmWiki.Links,PmWiki.Uploads,PmWiki.InterMap,PmWiki.WikiStyles,Cookbook.Images,Cookbook.RelativeLinks,PmWiki.LinkVariables -text=(:Summary:Placing images in pages:)%0aHere you can find how to embed pictures in your wiki pages, either uploaded to the wiki, or on external websites.%0a!! Basic usage%0aTo place an image into a page, [[PmWiki.Uploads|upload]] the image using the "[@Attach:@]" markup, or enter the address (url) of the image into the markup text. %0aAny ''alternate text'' (used for tooltips and for browsers that do not display images) is placed in double quotes immediately following the image url.%0aA caption can follow separated by a vertical bar (|), and may include simple formatting%0a(:markup class=horiz:)%0ahttps://pmichaud.com/img/misc/pc.jpg"Paper clips" | [- %25newwin%25 [[ Wikipedia:Paper_clips | Paper clips ]] are ''fun'' to work with. -]%0a(:markupend:)%0a%0aImages can also be specified as [[upload(s)]]ed files (i.e., [@Attach:image.jpeg@]) and using [[InterMap]] links. %0aBy default PmWiki supports the following image types for embedding into the page:%0a gif, jpg, jpeg, png, svg, svgz%0a%0a%25note%25 (See also [[PmWiki/Uploads]] and [[#notes|Notes]] below for image files that lack extensions.)%0a%0aTo create a [[link(s)]] to an image (like [[https://pmichaud.com/img/misc/pc.jpg]] as opposed to displaying the image itself), use double brackets to mark the link, as in [@[[https://pmichaud.com/img/misc/pc.jpg]]@] or [@[[Attach:image.jpeg]]@].%0a%0aTo have an image link to another location, use the image as the link text as in %0a(:markup class=horiz:)%0a[[http://pmwiki.org/ | https://pmichaud.com/img/misc/pc.jpg"PmWiki"]]%0a(:markupend:)%0aor [@[[http://example.com|Attach:Groupname./image.jpeg]]@].%0a%0a[[#tooltips]]%0a!! Tool tips or alternate text%0aA tool tip, or alternate text, can be displayed when the cursor hovers over the image by placing the description in double quotes directly following the image's URL.%0aThe description cannot contain any formatting.%0a(:markup class=horiz:)%0ahttps://pmichaud.com/img/misc/pc.jpg"Coloured paper clips"%0a(:markupend:)%0a%0a%0a[[#captions]]%0a!! Captions%0aA caption can be added to an image using a vertical bar and the caption text.%0a(:markup class=horiz:)%0ahttps://pmichaud.com/img/misc/pc.jpg | '''Figure 1'''%0a(:markupend:)%0a%0a[[#inline]]%0a!! Image alignment%0aNormally, images are displayed "in line" with the surrounding text.%0a%0aUse [@%25center%25@] to center an image on its own paragraph, [@%25right%25@] to align it to the right. %0a(:markup class=horiz:)%0aLorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat.%0a%0a%25center%25https://pmichaud.com/img/misc/pc.jpg"Paper clips"%25%25%0a(:markupend:) %0a%0a%0a[[#floating]]%0a!! Floating images%0aTo left or right-align an image with text wrapping around it, use the [@%25lfloat%25@] or [@%25rfloat%25@] [[wiki styles]]. %0a(:markup class=horiz:)%0a%25lfloat text-align=center margin-top=5px margin-right=25px margin-bottom=5px margin-left=25px%25 https://pmichaud.com/img/misc/gem.jpg | '''Rock on!'''%0a'''The image is left-aligned, with margins set; the caption is centered; the text wraps on the right side of the image.'''%0a%0aLorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. %0a(:markupend:)%0a%0aThe [@[[%3c%3c]]@] markup breaks floating text, and the text continues at the bottom of the image.%0a%0a(:markup class=horiz:) %0a%25lfloat%25 https://pmichaud.com/img/misc/gem.jpg%0a'''The image is left-aligned, and the text wraps on the right side of the image. The text after the ''[@[[%3c%3c]]@]'' markup continues below the image.'''%0a[[%3c%3c]]%0aLorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. %0a(:markupend:)%0a%0aUse the [@%25lframe%25@] or [@%25rframe%25@] styles to float an image and place a frame around the image and its caption. The frame can be formatted via wikistyles:%0a%0a(:markup class=horiz:) %0a%25rframe%25 https://pmichaud.com/img/misc/gem.jpg | '''Rock on!'''%0a'''The image is right-aligned, and the text wraps on the left side of the image.'''%0a%0aLorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua.%0a(:markupend:)%0a%0a(:markup class=horiz:) %0a%25cframe width=100px bgcolor=lightblue border='3px solid red' padding=20px%25 https://pmichaud.com/img/misc/gem.jpg%0a(:markupend:)%0aExample to show failure to fully apply width setting:-%0a(:markup class=horiz:) %0a%25cframe width=50px bgcolor=lightblue border='3px solid red' padding=20px%25 https://pmichaud.com/img/misc/gem.jpg%0a(:markupend:)%0a%0aUse [@%25block rframe%25@] to set off multiple images and caption text to be stacked vertically in a right-floating frame.%0a%0a(:markup:) %0a%25block rframe width=300px%25https://pmichaud.com/img/misc/gem.jpg\\%0aLorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua.\\\%0ahttps://pmichaud.com/img/misc/bubble.jpg\\%0aLorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua.%25%25%0a%0aText subsequent to the defined block wraps to the left of the frame. Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua.%0a(:markupend:)%0a%0a!!Resizing images [[#resizing]]%0a%0aTo resize an image via wikistyles, use [@%25width=50px%25@] or [@%25height=50px%25@] in front of an image. The [@%25thumb%25@] wikistyle is a helpful shortcut for [@%25width=100px%25@].%0a%0a(:markup:)%0a%25width=50px%25 https://pmichaud.com/img/misc/bubble.jpg \%0a%25height="50px"%25 https://pmichaud.com/img/misc/bubble.jpg \%0a%25width=10pct%25 https://pmichaud.com/img/misc/bubble.jpg %25comment%25 pct is "percent" in pmwiki \%0a%25thumb%25 https://pmichaud.com/img/misc/bubble.jpg %25comment%25[@ %25thumb%25 is shortcut for %25width=100px%25 @]%0a(:markupend:)%0a%0aNote: Resizing an image via wikistyles only affects how it is displayed in a browser; it does not reduce the transfer size of the image itself - hence resizing via wikistyles is not an acceptable method of generating a page-full of images, or 'gallery'.%0a%0aIf you want a resized image within a link, you have to specify the size before the link as well as close it off with a [=%25%25=].%0a%0a(:markup:)%0a%25width=60%25[[http://pmwiki.org/ | https://pmichaud.com/img/misc/pc.jpg"PmWiki"]]%25%25 \%0a%25height=60%25[[http://pmwiki.org/ | https://pmichaud.com/img/misc/pc.jpg"PmWiki"]]%25%25 \%0a(:markupend:)%0a%0aTo open the link in new window, you place [=%25newwin%25=] before the size specification.%0a%0a(:markup:)%0a%25newwin%25[[http://pmwiki.org/ | https://pmichaud.com/img/misc/pc.jpg"PmWiki"]]%25%25%0a(:markupend:)%0a%0aResized images using [@%25thumb%25@] can also be floated with frames, as well as made into links.%0a%0a(:markup:) %0a%25lframe thumb%25 [[https://pmichaud.com/img/misc/bubble.jpg | https://pmichaud.com/img/misc/bubble.jpg"Burst the bubble"]] | [-Bubble-]%0a%25lframe thumb%25 https://pmichaud.com/img/misc/pc.jpg"Clip the ticket" | [-Paper Clips-]%0a%25lframe thumb%25 [[DocumentationIndex | https://pmichaud.com/img/misc/gem.jpg"Visit the Documentation Index"]] | [[DocumentationIndex | [-Rock On-]]]%0a(:markupend:)%0a%0a[[#links]]%0a!! Images as [[PmWiki/links]]%0aTo use an image as a link specify an image instead of text in the [[PmWiki/link(s)]] markup.%0a(:markup:)%0a[[PmWiki/Links | https://pmichaud.com/img/2003/atc-1.gif"Information about wiki links"]]%0a(:markupend:)%0a%0a[[#notes]]%0a!!Notes%0a* '''An image file that lacks a correct extension''' can be displayed by addition of a "false" extension to the URL. For example, if the url is [@http://example.com/script/tux@], add a fake query string on the end with the desired extension (e.g., [@http://example.com/script/tux?format=.png@]). If query strings are unsuitable, a fragment identifier should work, e.g. [@http://example.com/script/tux#file.png@].%0a%0a* Relative width is possible by using percentages.%0a(:markup:)%0a%25width=10pct%25 https://pmichaud.com/img/misc/bubble.jpg \%0a%25height=30pct%25 https://pmichaud.com/img/misc/bubble.jpg %0a(:markupend:)%0a%0a* '''Flowing text is possible, like captions, within a frame'''%0a(:markup:)%0a>>lframe width=130px%3c%3c%0a%25thumb width=130%25 [[https://pmichaud.com/img/misc/bubble.jpg | https://pmichaud.com/img/misc/bubble.jpg"Burst the bubble"]] | [--Long caption for an image like [[https://pmichaud.com/img/misc/bubble.jpg | the bubble]]. This is just to show some text flowing within the frame.--]%0a>>%3c%3c%0a(:markupend:)%0a%0a%0a%0a!!See also%0a* [[Cookbook:Images]] - adding image galleries, automatic thumbnails, background images and more. %0a%0a!!Credits%0aThe images on this page were obtained from https://flickr.com and are redistributed under a Creative Commons License.%0a%0a(:keywords graphics, pictures, photos:)%0a[[%3c%3c]]%0a!! FAQ [[#FAQ]]%0a>>faq%3c%3c [[#faq]]%0a%0aQ: Is it possible to link an image on PmWiki without using a fully qualified URL?%0aA: Yes. For images that are attachments, the general format is [@Attach:Groupname./image.gif@]. To link to an image that is on the same server, use @@[=Path:=]/path/to/image.gif@@ where "Path:" replaces the server name like "[=https://www.example.com=]".%0a%0aQ: Can I attach a client image file on PmWiki?%0aA: Yes, see [[PmWiki/Uploads]] .%0a%0aQ: How can I include a page from another group that contains an attached image?%0aA: Include the page in the normal way, ie [@(:include GroupName.Pagename:)@]. In the page to be included (that contains the image) change [@Attach:filename.ext@] to [@Attach:{$Group}./filename.ext@]. %0a%0aQ: Why, if I put an image with rframe or rfloat and immediatly after that I open a new page section with ! the section title row is below the image instead of on the left side?%0aA: Because the CSS for '''headings''' such as ! contains an element '''clear:both''' which forces this behaviour. Redefine the CSS locally if you want to stop this happening, but I think the bottom border (that underlines the heading) would need further re-definition. I just use bolding for the title, and 4 dashes below [=-=]--- to separate a new section, and it saves the effort of fiddling with the core definitions.%0a%0aUnlike the '''lframe''' and '''rframe''' directives, '''cframe''' does not fully honour the width setting. While the frame itself resizes to match the request, the enclosed image does not, and retains its original width. Effect is the same in IE and Fx. I've added an example beneath the standard example above.%0a%0aQ: Is it possible to disallow all images? I already disabled uploads but I also want to disallow external images from being shown on my wiki pages.%0a%0aA: Yes, add to config.php:%0a->[@%0aDisableMarkup('img');%0a$ImgExtPattern = "$^";%0a@]%0a%0aQ: How can I make it so that when I place an image in a page, the block of text it is in is a %3cp> (paragraph) rather than a %3cdiv> (division)?%0a%0aA: If you just want it to happen for a single image (instead of all), then%0atry putting [@[==]@] at the beginning of the line, as in:%0a%0a->[@[==] https://www.pmwiki.org/pub/pmwiki/pmwiki-32.gif@]%0a%0aHaving [@[==]@] at the beginning of a line forces whatever follows to%0abe part of a paragraph.%0a%0aQ: Is there any way to use relative paths for images?%0aA: See Cookbook:RelativeLinks and $EnableLinkPageRelative.%0a%0aQ: Is there a way to attach a BMP and have it display rather than link?%0aA: Add to config.php the following line:\\%0a @@$ImgExtPattern = "(?:$ImgExtPattern|\\.bmp|\\.BMP)";@@\\%0a %0aNote that BMP images are uncompressed and quite heavy. You may wish to convert them to PNG (lossless) or JPG (lossy) format, and thus reduce 5-20 times their filesizes.%0a%0aQ: How do I add an image type to @@$ImgExtPattern@@ and yet have it include any future default image types added in PmWiki?%0aA: You can append the extensions to the @@$ImgExtPattern@@ variable this way:\\%0a @@$ImgExtPattern = "(?:$ImgExtPattern|\\.webp|\\.WEBP)";@@%0a %0aQ: Is there a way to have a table to the left or right of an image?%0aA: Yes, see [[(https://www.pmwiki.org/wiki/Test/)TableAndImage]].%0a -time=1590291045 +text=(:Summary:Placing images in pages:)%0aHere you can find how to embed pictures in your wiki pages, either uploaded to the wiki, or on external websites.%0a!! Basic usage%0aTo place an image into a page, [[PmWiki.Uploads|upload]] the image using the "%25pmhlt%25[@Attach:@]" markup, or enter the address (url) of the image into the markup text. %0aAny ''alternate text'' (used for tooltips and for browsers that do not display images) is placed in double quotes immediately following the image url.%0aA caption can follow separated by a vertical bar (|), and may include simple formatting%0a(:markup class=horiz:)%0ahttps://pmichaud.com/img/misc/pc.jpg"Paper clips" | [- %25newwin%25 [[ Wikipedia:Paper_clips | Paper clips ]] are ''fun'' to work with. -]%0a(:markupend:)%0a%0aImages can also be specified as [[upload(s)]]ed files (i.e., %25pmhlt%25[@Attach:image.jpeg@]) and using [[InterMap]] links. %0aBy default PmWiki supports the following image types for embedding into the page:%0a gif, jpg, jpeg, png, svg, svgz%0a%0a%25note%25 (See also [[PmWiki/Uploads]] and [[#notes|Notes]] below for image files that lack extensions.)%0a%0aTo create a [[link(s)]] to an image (like [[https://pmichaud.com/img/misc/pc.jpg]] as opposed to displaying the image itself), use double brackets to mark the link, as in %25pmhlt%25[@[[https://pmichaud.com/img/misc/pc.jpg]]@] or [@[[Attach:image.jpeg]]@].%0a%0aTo have an image link to another location, use the image as the link text as in %0a(:markup class=horiz:)%0a[[https://pmwiki.org/ | https://pmichaud.com/img/misc/pc.jpg"PmWiki"]]%0a(:markupend:)%0aor %25pmhlt%25[@[[https://example.com|Attach:Groupname./image.jpeg]]@].%0a%0a[[#tooltips]]%0a!! Tool tips or alternate text%0aA tool tip, or alternate text, can be displayed when the cursor hovers over the image by placing the description in double quotes directly following the image's URL.%0aThe description cannot contain any formatting.%0a(:markup class=horiz:)%0ahttps://pmichaud.com/img/misc/pc.jpg"Coloured paper clips"%0a(:markupend:)%0a%0a%0a[[#captions]]%0a!! Captions%0aA caption can be added to an image using a vertical bar and the caption text.%0a(:markup class=horiz:)%0ahttps://pmichaud.com/img/misc/pc.jpg | '''Figure 1'''%0a(:markupend:)%0a%0a[[#inline]]%0a!! Image alignment%0aNormally, images are displayed "in line" with the surrounding text.%0a%0aUse %25pmhlt%25[@%25center%25@] to center an image on its own paragraph, [@%25right%25@] to align it to the right. %0a(:markup class=horiz:)%0aLorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat.%0a%0a%25center%25https://pmichaud.com/img/misc/pc.jpg"Paper clips"%25%25%0a(:markupend:) %0a%0a%0a[[#floating]]%0a!! Floating images%0aTo left or right-align an image with text wrapping around it, use the %25pmhlt%25[@%25lfloat%25@] or [@%25rfloat%25@] [[wiki styles]]. %0a(:markup class=horiz:)%0a%25lfloat text-align=center margin-top=5px margin-right=25px margin-bottom=5px margin-left=25px%25 https://pmichaud.com/img/misc/gem.jpg | '''Rock on!'''%0a'''The image is left-aligned, with margins set; the caption is centered; the text wraps on the right side of the image.'''%0a%0aLorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. %0a(:markupend:)%0a%0aThe %25pmhlt%25[@[[%3c%3c]]@] markup breaks floating text, and the text continues at the bottom of the image.%0a%0a(:markup class=horiz:) %0a%25lfloat%25 https://pmichaud.com/img/misc/gem.jpg%0a'''The image is left-aligned, and the text wraps on the right side of the image. The text after the ''[@[[%3c%3c]]@]'' markup continues below the image.'''%0a[[%3c%3c]]%0aLorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. %0a(:markupend:)%0a%0aUse the %25pmhlt%25[@%25lframe%25@] or [@%25rframe%25@] styles to float an image and place a frame around the image and its caption. The frame can be formatted via wikistyles:%0a%0a(:markup class=horiz:) %0a%25rframe%25 https://pmichaud.com/img/misc/gem.jpg | '''Rock on!'''%0a'''The image is right-aligned, and the text wraps on the left side of the image.'''%0a%0aLorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua.%0a(:markupend:)%0a%0a(:markup class=horiz:) %0a%25cframe width=100px bgcolor=lightblue border='3px solid red' padding=20px%25 https://pmichaud.com/img/misc/gem.jpg%0a(:markupend:)%0aExample to show failure to fully apply width setting:-%0a(:markup class=horiz:) %0a%25cframe width=50px bgcolor=lightblue border='3px solid red' padding=20px%25 https://pmichaud.com/img/misc/gem.jpg%0a(:markupend:)%0a%0aUse %25pmhlt%25[@%25block rframe%25@] to set off multiple images and caption text to be stacked vertically in a right-floating frame.%0a%0a(:markup:) %0a%25block rframe width=300px%25https://pmichaud.com/img/misc/gem.jpg\\%0aLorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua.\\\%0ahttps://pmichaud.com/img/misc/bubble.jpg\\%0aLorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua.%25%25%0a%0aText subsequent to the defined block wraps to the left of the frame. Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua.%0a(:markupend:)%0a%0a!!Resizing images [[#resizing]]%0a%0aTo resize an image via wikistyles, use %25pmhlt%25[@%25width=50px%25@] or [@%25height=50px%25@] in front of an image. The [@%25thumb%25@] wikistyle is a helpful shortcut for [@%25width=100px%25@].%0a%0a(:markup:)%0a%25width=50px%25 https://pmichaud.com/img/misc/bubble.jpg \%0a%25height="50px"%25 https://pmichaud.com/img/misc/bubble.jpg \%0a%25width=10pct%25 https://pmichaud.com/img/misc/bubble.jpg %25comment%25 pct is "percent" in pmwiki \%0a%25thumb%25 https://pmichaud.com/img/misc/bubble.jpg %25comment%25[@ %25thumb%25 is shortcut for %25width=100px%25 @]%0a(:markupend:)%0a%0aNote: Resizing an image via wikistyles only affects how it is displayed in a browser; it does not reduce the transfer size of the image itself - hence resizing via wikistyles is not an acceptable method of generating a page-full of images, or 'gallery'.%0a%0aIf you want a resized image within a link, you have to specify the size before the link as well as close it off with a %25pmhlt%25[@%25%25@].%0a%0a(:markup:)%0a%25width=60%25[[https://pmwiki.org/ | https://pmichaud.com/img/misc/pc.jpg"PmWiki"]]%25%25 \%0a%25height=60%25[[https://pmwiki.org/ | https://pmichaud.com/img/misc/pc.jpg"PmWiki"]]%25%25 \%0a(:markupend:)%0a%0aTo open the link in new window, you place %25pmhlt%25[@%25newwin%25@] before the size specification.%0a%0a(:markup:)%0a%25newwin%25[[https://pmwiki.org/ | https://pmichaud.com/img/misc/pc.jpg"PmWiki"]]%25%25%0a(:markupend:)%0a%0aResized images using %25pmhlt%25[@%25thumb%25@] can also be floated with frames, as well as made into links.%0a%0a(:markup:) %0a%25lframe thumb%25 [[https://pmichaud.com/img/misc/bubble.jpg | https://pmichaud.com/img/misc/bubble.jpg"Burst the bubble"]] | [-Bubble-]%0a%25lframe thumb%25 https://pmichaud.com/img/misc/pc.jpg"Clip the ticket" | [-Paper Clips-]%0a%25lframe thumb%25 [[DocumentationIndex | https://pmichaud.com/img/misc/gem.jpg"Visit the Documentation Index"]] | [[DocumentationIndex | [-Rock On-]]]%0a(:markupend:)%0a%0a[[#links]]%0a!! Images as [[PmWiki/links]]%0aTo use an image as a link specify an image instead of text in the [[PmWiki/link(s)]] markup.%0a(:markup:)%0a[[PmWiki/Links | https://pmichaud.com/img/2003/atc-1.gif"Information about wiki links"]]%0a(:markupend:)%0a%0a[[#notes]]%0a!!Notes%0a* '''An image file that lacks a correct extension''' can be displayed by addition of a "false" extension to the URL. For example, if the url is %25pmhlt%25[@https://example.com/script/tux@], add a fake query string on the end with the desired extension (e.g., [@https://example.com/script/tux?format=.png@]). If query strings are unsuitable, a fragment identifier should work, e.g. [@https://example.com/script/tux#file.png@].%0a%0a* Relative width is possible by using percentages.%0a(:markup:)%0a%25width=10pct%25 https://pmichaud.com/img/misc/bubble.jpg \%0a%25height=30pct%25 https://pmichaud.com/img/misc/bubble.jpg %0a(:markupend:)%0a%0a* '''Flowing text is possible, like captions, within a frame'''%0a(:markup:)%0a>>lframe width=130px%3c%3c%0a%25thumb width=130%25 [[https://pmichaud.com/img/misc/bubble.jpg | https://pmichaud.com/img/misc/bubble.jpg"Burst the bubble"]] | [--Long caption for an image like [[https://pmichaud.com/img/misc/bubble.jpg | the bubble]]. This is just to show some text flowing within the frame.--]%0a>>%3c%3c%0a(:markupend:)%0a%0a%0a%0a!!See also%0a* [[Cookbook:Images]] - adding image galleries, automatic thumbnails, background images and more. %0a%0a!!Credits%0aThe images on this page were obtained from https://flickr.com and are redistributed under a Creative Commons License.%0a%0a(:keywords graphics, pictures, photos:)%0a[[%3c%3c]]%0a!! FAQ [[#FAQ]]%0a>>faq%3c%3c [[#faq]]%0aQ: %25id=hotlink%25 Why are some external images correctly embedded, and others aren't?%25%25%0aA: If the current page is on a secure URL with the "[=https://=]" protocol, some browsers will refuse to load pictures from insecure URLs (the other way around is allowed). Also, some webmasters configure their servers to disallow [[Wikipedia:Hotlink|hotlinking]].%0a%0aQ: Is it possible to link an image on PmWiki without using a fully qualified URL?%0aA: Yes. For images that are attachments, the general format is %25pmhlt%25[@Attach:Groupname./image.gif@]. To link to an image that is on the same server, use @@[=Path:=]/path/to/image.gif@@ where "Path:" replaces the server name like "[=https://www.example.com=]".%0a%0aQ: Can I attach a client image file on PmWiki?%0aA: Yes, see [[PmWiki/Uploads]] .%0a%0aQ: How can I include a page from another group that contains an attached image?%0aA: Include the page in the normal way, ie %25pmhlt%25[@(:include GroupName.Pagename:)@]. In the page to be included (that contains the image) change [@Attach:filename.ext@] to [@Attach:{$Group}./filename.ext@]. %0a%0aQ: Why, if I put an image with rframe or rfloat and immediatly after that I open a new page section with ! the section title row is below the image instead of on the left side?%0aA: Because the CSS for '''headings''' such as ! contains an element '''clear:both''' which forces this behaviour. Redefine the CSS locally if you want to stop this happening, but I think the bottom border (that underlines the heading) would need further re-definition. I just use bolding for the title, and 4 dashes below %25pmhlt%25[@----@] to separate a new section, and it saves the effort of fiddling with the core definitions.%0a%0aUnlike the '''lframe''' and '''rframe''' directives, '''cframe''' does not fully honour the width setting. While the frame itself resizes to match the request, the enclosed image does not, and retains its original width. Effect is the same in IE and Fx. I've added an example beneath the standard example above.%0a%0aQ: Is it possible to disallow all images? I already disabled uploads but I also want to disallow external images from being shown on my wiki pages.%0a%0aA: Yes, add to @@config.php@@:%0a->%25hlt php%25[@%0aDisableMarkup('img');%0a$ImgExtPattern = "$^";%0a@]%0a%0aQ: How can I make it so that when I place an image in a page, the block of text it is in is a @@%3cp>@@ (paragraph) rather than a @@%3cdiv>@@ (division)?%0a%0aA: If you just want it to happen for a single image (instead of all), then%0atry putting %25pmhlt%25[@[==]@] at the beginning of the line, as in:%0a%0a->[@[==] https://www.pmwiki.org/pub/pmwiki/pmwiki-32.gif@]%0a%0aHaving %25pmhlt%25[@[==]@] at the beginning of a line forces whatever follows to%0abe part of a paragraph.%0a%0aQ: Is there any way to use relative paths for images?%0aA: See Cookbook:RelativeLinks and $EnableLinkPageRelative.%0a%0aQ: Is there a way to attach a BMP and have it display rather than link?%0aA: Add to @@config.php@@ the following line:\\%0a %25hlt php%25@@$ImgExtPattern = "(?:$ImgExtPattern|\\.bmp|\\.BMP)";@@\\%0a %0aNote that BMP images are uncompressed and quite heavy. You may wish to convert them to PNG (lossless) or JPG (lossy) format, and thus reduce 5-20 times their filesizes.%0a%0aQ: How do I add an image type to @@$ImgExtPattern@@ and yet have it include any future default image types added in PmWiki?%0aA: You can append the extensions to the @@$ImgExtPattern@@ variable this way:\\%0a %25hlt php%25@@$ImgExtPattern = "(?:$ImgExtPattern|\\.webp|\\.WEBP)";@@%0a %0aQ: Is there a way to have a table to the left or right of an image?%0aA: Yes, see [[(https://www.pmwiki.org/wiki/Test/)TableAndImage]].%0a +time=1669576946 blob - de1239320e26f545f4fb5b4fd8b9dc31361b7e26 blob + 7b258f6a7ba3cfa0b5dcf9c5a4342198575b54d3 --- wikilib.d/PmWiki.IncludeOtherPages +++ wikilib.d/PmWiki.IncludeOtherPages @@ -1,9 +1,9 @@ -version=pmwiki-2.2.118 ordered=1 urlencoded=1 +version=pmwiki-2.3.2 ordered=1 urlencoded=1 author=Petko charset=UTF-8 -csum=mv !Styling note in !Notes, !See also before FAQ +csum= (-6) name=PmWiki.IncludeOtherPages -rev=136 +rev=140 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 [@(: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* [=(:=]include PageName:) \\%0awith pagename includes the full page from the same group.%0a* [={Group/PageName$:=][[#includeptv|PTVar]]}:\\%0aincludes a [[PageTextVariables|named variable]] from a page, [[(Wiki)Group]] and PageName are options%0a%0aThe full syntax is%0a* [=(:=]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[@(: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 [=(: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||[@(:include PageName#from#to:)@] ||include lines from ''`PageName'' between the [@[[#from]]@] and [@[[#to]]@] [[Links#anchors|anchors]]%0a||[@(:include PageName#from#:)@] ||include all lines after [@[[#from]]@] to the end of the page%0a||[@(:include PageName##to:)@] ||include all lines from the start of the page to [@[[#to]]@]%0a||[@(:include PageName#from:)@] ||include everything between [@[[#from]]@] and the next anchor%0a||[@(: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[@[[#start]]some text on the first line%0asome text on the last line [[#end]]@]%0a%25note%25The above, when included via [@(:include PageName#start:)@] will have the text on the first line but not the text on the last line.%0a%0a[@(:include Page1 Page2 #from#to:)@]%0a-> Include from the first available of Page1, Page2 between the [@[[#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[@(:include Page1#from1#to1 Page2#from2#to2:)@]%0a-> Include the first from the first available of Page1 (between the [@[[#from1]]@] and [@[[#to1]]@]) or Page2 (between the [@[[#from2]]@] and [@[[#to2]]@] ) %0a%0a%25green%25Note%25%25: Previous versions of PmWiki allowed whitespace between [@#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-> [@Markup('includeanchors', '%3cinclude', '/(\\(:include.*?#\\w+)\\s+(#\\w+)/', '$1$2');@]%0a%0a[[#includelines]]%0a!!! Lines=from..to%0a[@(:include PageName lines=10:)@]%0a[@(:include PageName lines=5..10:)@]%0a[@(: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[@(: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[@(: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 [@{$Name}@] and you want to prevent the directive from including the current page.%0a%0a[[#includeptv]]%0a!!! [[Page text variables]]%0a[@{Group/PageName$:Var}@]%0a-> Includes definition list values from an (optional) page as [[page text variables]]. These are defined using a definition list ([@:item:description@]), simple colon delimiter ([@item:description@]), or special markup ([@(:item:description:)@]).%0a%0a[[#includebasepage]]%0a!!! Basepage=%0a%0a[@(: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 [@TemplateName@] as%0a-> [@Name: {$:Name}%0aAddress: {$:Address}@]%0athen the directive%0a-> [@(:include TemplateName basepage=PageName:)@]%0awill retrieve the contents of [@TemplateName@], treating any page variables and links as being relative to [@PageName@]. %0aIn particular, the values for [@{$: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-> [@(:include SomeOtherPage basepage='' :)@]%0a -or-%0a-> [@(: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%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->[@(: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%3c%3c%0a [@(:include TemplatePage#abc basepage=DataPage :)@]%0a (:include TemplatePage#def basepage=DataPage :)%0a (:include TemplatePage#xyz basepage=DataPage :)%0a>>%3c%3c%0a%0aSo then [=TemplatePage=] can use a syntax like:%0a>>pre%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 (: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 [@{$$variable1}@] format:%0a-> [@(: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 @@[@{$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[@(:nl:)@] acts like a new line in the ''markup'', only if there isn't one already.%0a%0aThe purpose of [@(: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[@(: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 [@{$$...}@] 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 [@(: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 [@(: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->[@(: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->[@(:if some condition:)[[#section]]...[[#sectionend]](:ifend:)@]%0a[@(: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=1567165288 +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 blob - 7a14cedccfb6f47d17957119300c23b759cdabff blob + f592b50c9bf34ac68ba6dc536f9eec3dfb03a863 --- wikilib.d/PmWiki.InitialSetupTasks +++ wikilib.d/PmWiki.InitialSetupTasks @@ -1,9 +1,9 @@ -version=pmwiki-2.2.122 ordered=1 urlencoded=1 -author=Petko +version=pmwiki-2.3.15 ordered=1 urlencoded=1 +author=simon charset=UTF-8 -csum=direct link to the timezones starting page +csum=more hlt php (+62) name=PmWiki.InitialSetupTasks -rev=102 -targets=PmWiki.Installation,Site.Site,SiteAdmin.SiteAdmin,Site.SideBar,PmWiki.LayoutVariables,PmWiki.PathVariables,PmWiki.SecurityVariables,PmWiki.UploadVariables,Cookbook.ChangeTimeFormat,PmWiki.BasicVariables,PmWiki.Variables,PmWiki.PmWikiUsers,PmWiki.EditVariables,Cookbook.Cookbook,Cookbook.CleanUrls,PmWiki.UTF-8,Cookbook.UTF-8,PmWiki.Security,PmWiki.PasswordsAdmin,PmWiki.Upgrades,PmWiki.UploadsAdmin,Cookbook.PerGroupSubDirectories,Cookbook.CookbookBasics,PmWiki.LocalCustomizations,PmWiki.WikiFarms,PmWiki.MailingLists,PmWiki.WikiAdministrator -text=(:Summary:First steps following a fresh installation:)%0a(:Audience: administrators (basic) :)%0aOnce you have PmWiki running on your site (see [[Installation]]), you can customize it for your particular needs.%0a%0aMost PmWiki configuration is performed in files called ''local/config.php'' and ''pub/css/local.css''. %0aSome configuration is done on special pages in the [[{$SiteGroup}/]] and [[SiteAdmin/]] groups, such as the [[{$SiteGroup}.SideBar]] menu.%0a%0a!! The local configuration file (''local/config.php'')%0aWhen you first install PmWiki, the ''local/config.php'' file does not exist. Copy the ''sample-config.php'' file (in the ''docs/'' directory) to ''local/config.php'' and use it as a starting point. You could create ''local/config.php'' from scratch, but ''sample-config.php'' is already populated with many of the options you might want to adjust.%0a%0aHere is a simple ''config.php'' file:%0a%0a-> %25hlt php%25[@%0a%3c?php if (!defined('PmWiki')) exit();%0a$WikiTitle = "My New Wiki";%0a$PageLogoUrl = "http://example.com/mylogo.gif";%0a%0a# Uncomment and correct these if PmWiki fails to detect the browser-reachable URLs%0a#$ScriptUrl = 'http://example.com/pmwiki/pmwiki.php';%0a#$PubDirUrl = 'http://example.com/pmwiki/pub';%0a%0a$DefaultPasswords['admin'] = pmcrypt('onesecret');%0a%0a$EnableUpload = 1;%0a$DefaultPasswords['upload'] = pmcrypt('secrettwo');%0a%0a# Uncomment and change these if your server is not in your timezone%0a# date_default_timezone_set('America/New_York'); # if you run PHP 5.1 or newer%0a# putenv("TZ=EST5EDT"); # if you run PHP 5.0 or older%0a%0a$TimeFmt = '%25B %25d, %25Y, at %25I:%25M %25p %25Z';%0a@]%0a%0aNote that ''config.php'' begins with @@%3c?php@@ . The PHP end tag @@?>@@ is optional, and can be left off to improve compatibility with some operating systems. Be sure there aren't any blank lines or spaces before the @@%3c?php@@ or after any closing @@?>@@, or else you may get strange PHP error messages at the beginning of your wiki pages.%0a%0aThe ''config.php'' file above sets the value of PHP variables used by PmWiki:%0a* The $WikiTitle variable gives the name of your site as it will appear in a user's browser title bar.%0a* The @@$ScriptUrl@@ and @@$PubDirUrl@@ variables tell your wiki where it is located. Often pmwiki can guess, but if you have difficulty with links not working or skins not being found then try uncommenting these lines.%0a* The $PageLogoUrl variable specifies the URL of the icon image that will appear in the upper-left corner of each wiki page.%0a* The @@$DefaultPasswords['admin']@@ sets an administrative password.%0a* Setting $EnableUpload to "1" enables Uploads ("Attached files"). @@$DefaultPasswords['upload']@@ sets an upload password.%0a* The date_default_timezone_set tells PHP what the default time zone is (for the time stamps in RecentChanges, in the page histories and on user signatures). For a list of identifiers, see [[https://www.php.net/manual/en/timezones.php | the online PHP manual]].%0a** On PHP older than 5.1, use the TZ environment variable (see [[Cookbook:ChangeTimeFormat]]).%0a* The $TimeFmt variable defines the appearance of time strings (see [[Cookbook:ChangeTimeFormat]]).%0a%0aBy setting these (and other) variables in ''local/config.php'', you can change the look and feel of PmWiki from its default, sometimes substantially so. See [[PmWiki.Variables]] for a list of variables that PmWiki uses, and see PmWiki:PmWikiUsers for examples of sites that use PmWiki in customized ways.%0a%0a!!! Other common setup tasks%0aThe following [[variables]] are often requested when preparing a new wiki%0a* Author required when editing a page @@$EnablePostAuthorRequired = 1;@@ %0a* Set $DefaultGroup and the $DefaultPage.%0a%0aThese common [[(Cookbook:)Cookbook]] recipes are also often installed immediately%0a* [[(Cookbook:)Clean Urls]] - Remove the @@?n=Group.Page@@ arguments from the end of URLs%0a%0aIf you prepare an international wiki, potentially with characters in different alphabets (Cyrillic, Greek, Chinese) or many diacritical symbols (Czech + French), please look at [[PmWiki.UTF-8]] and Cookbook:UTF-8.%0a%0a!! Security%0aReview and set up any [[security]] required.%0a%0a!!!Setting an administrative password%0a%0aThe pages in the [[{$SiteGroup}/Site]] group (except the {$SiteGroup}.SideBar) are locked by default. In order to edit pages in this group you need to create a site-wide admin password in ''local/config.php''. To set the site-wide admin password to "@@mysecret@@", change the line to the following:%0a%0a->%25hlt php%25[@$DefaultPasswords['admin'] = pmcrypt('mysecret');@]%0a%0aYou must use the [@pmcrypt()@] function, but set the password to a value with meaning for you. See [[PasswordsAdmin]] for details about making the password more secure.%0a%0a!![[#dontmodify]]Don't modify or rename ''pmwiki.php''%0a%0aPmWiki has been designed so that all customizations can be made without changing the distribution files -- one of its design goals is to provide seamless upgrades. PmWiki never writes to files in the ''local/'' or ''cookbook/'' directories, so placing your customizations here makes it easier to track the changes and [[upgrades | upgrade PmWiki]] without losing the changes.%0a%0aWhen changing the configuration of your site, always change the ''local/config.php'' file or add files to the ''cookbook/'' or ''pub'' directories. Do not change ''pmwiki.php'' or the files in the ''scripts/'' directory because the files are supposed to be overwritten upon upgrading.%0a%0aYou shouldn't rename ''pmwiki.php'' either. If you rename the file it will not be overwritten during an upgrade of the software and there will be a version mismatch. Many administrators add an ''index.php'' "wrapper script" in the pmwiki directory that contains the following single line:%0a%0a->%25hlt php%25[@%3c?php include('pmwiki.php');@]%0a%0aJust make a text-file. Paste %3c?php include('pmwiki.php'); into it.%0aSave the file as index.php%0aSend it via FTP to the same directory where pmwiki.php is located. %0a%0a!! Other organisation%0a!!! Upload directories%0aBy default Pmwiki uses an upload directory for each group%0a(see [[Uploads admin(#uploaddirectoryconfiguration)]]istration.%0aDeciding on accepting the default, or choosing an alternative (eg one directory for the entire wiki, or one directory per page) is best done when setting up your wiki.%0a%0a!!! Page store directories%0aBy default Pmwiki uses a single page store directory (wiki.d).%0aDeciding on accepting the default (recommended), or choosing the alternative (one directory per group) is best done when setting up your wiki. '^[[Cookbook:PerGroupSubDirectories|#]]^'%0a%0a!!Other customization%0a%0aAfter setting up ''local/config.php'' file, you may wish to make other [[local customizations]]. See the [[Cookbook:CookbookBasics | PmWiki Cookbook]] for a large number of customizations that have been contributed. And don't fear Cookbook recipes - they're well prepared, so that most of them require only to download a single file, add a one-line include command to @@config.php@@, and ''voilà!'' - they're working!%0a%0aIf you (or others sharing your server) want to maintain more than one wiki on the same server, see [[Wiki Farms]].%0a%0a!!Now what?%0a%0aDon't forget to join a [[MailingLists | PmWiki mailing list]], where you can email other [[wiki administrator]]s for help on customizing PmWiki and participate in discussions about PmWiki improvements. Once you have your site operational, be sure to add it to PmWiki:PmWikiUsers so others will know about it!%0a -time=1577604456 +rev=104 +targets=PmWiki.Installation,Site.Site,SiteAdmin.SiteAdmin,Site.SideBar,PmWiki.LayoutVariables,PmWiki.PathVariables,PmWiki.SecurityVariables,PmWiki.UploadVariables,Cookbook.ChangeTimeFormat,PmWiki.BasicVariables,PmWiki.Variables,PmWiki.PmWikiUsers,PmWiki.EditVariables,Cookbook.Cookbook,Cookbook.CleanUrls,PmWiki.UTF-8,Cookbook.UTF-8,PmWiki.Security,PmWiki.PasswordsAdmin,PmWiki.Upgrades,PmWiki.UploadsAdmin,Cookbook.PerGroupSubDirectories,Category.GroupFooter,Cookbook.CookbookBasics,PmWiki.LocalCustomizations,PmWiki.WikiFarms,PmWiki.MailingLists,PmWiki.WikiAdministrator +text=(:Summary:First steps following a fresh installation:)%0a(:Audience: administrators (basic) :)%0aOnce you have PmWiki running on your site (see [[Installation]]), you can customize it for your particular needs.%0a%0aMost PmWiki configuration is performed in files called ''local/config.php'' and ''pub/css/local.css''. %0aSome configuration is done on special pages in the [[{$SiteGroup}/]] and [[SiteAdmin/]] groups, such as the [[{$SiteGroup}.SideBar]] menu.%0a%0a!! The local configuration file (''local/config.php'')%0aWhen you first install PmWiki, the ''local/config.php'' file does not exist. Copy the ''sample-config.php'' file (in the ''docs/'' directory) to ''local/config.php'' and use it as a starting point. You could create ''local/config.php'' from scratch, but ''sample-config.php'' is already populated with many of the options you might want to adjust.%0a%0aHere is a simple ''config.php'' file:%0a%0a-> %25hlt php%25[@%0a%3c?php if (!defined('PmWiki')) exit();%0a$WikiTitle = "My New Wiki";%0a$PageLogoUrl = "http://example.com/mylogo.gif";%0a%0a# Uncomment and correct these if PmWiki fails to detect the browser-reachable URLs%0a#$ScriptUrl = 'http://example.com/pmwiki/pmwiki.php';%0a#$PubDirUrl = 'http://example.com/pmwiki/pub';%0a%0a$DefaultPasswords['admin'] = pmcrypt('onesecret');%0a%0a$EnableUpload = 1;%0a$DefaultPasswords['upload'] = pmcrypt('secrettwo');%0a%0a# Uncomment and change these if your server is not in your timezone%0a# date_default_timezone_set('America/New_York'); # if you run PHP 5.1 or newer%0a# putenv("TZ=EST5EDT"); # if you run PHP 5.0 or older%0a%0a$TimeFmt = '%25B %25d, %25Y, at %25I:%25M %25p %25Z';%0a@]%0a%0aNote that ''config.php'' begins with @@%3c?php@@ . The PHP end tag @@?>@@ is optional, and can be left off to improve compatibility with some operating systems. Be sure there aren't any blank lines or spaces before the @@%3c?php@@ or after any closing @@?>@@, or else you may get strange PHP error messages at the beginning of your wiki pages.%0a%0aThe ''config.php'' file above sets the value of PHP variables used by PmWiki:%0a* The $WikiTitle variable gives the name of your site as it will appear in a user's browser title bar.%0a* The @@$ScriptUrl@@ and @@$PubDirUrl@@ variables tell your wiki where it is located. Often pmwiki can guess, but if you have difficulty with links not working or skins not being found then try uncommenting these lines.%0a* The $PageLogoUrl variable specifies the URL of the icon image that will appear in the upper-left corner of each wiki page.%0a* The %25hlt php%25@@$DefaultPasswords['admin']@@ sets an administrative password.%0a* Setting $EnableUpload to "1" enables Uploads ("Attached files"). %25hlt php%25@@$DefaultPasswords['upload']@@ sets an upload password.%0a* The date_default_timezone_set tells PHP what the default time zone is (for the time stamps in RecentChanges, in the page histories and on user signatures). For a list of identifiers, see [[https://www.php.net/manual/en/timezones.php | the online PHP manual]].%0a** On PHP older than 5.1, use the TZ environment variable (see [[Cookbook:ChangeTimeFormat]]).%0a* The $TimeFmt variable defines the appearance of time strings (see [[Cookbook:ChangeTimeFormat]]).%0a%0aBy setting these (and other) variables in ''local/config.php'', you can change the look and feel of PmWiki from its default, sometimes substantially so. See [[PmWiki.Variables]] for a list of variables that PmWiki uses, and see PmWiki:PmWikiUsers for examples of sites that use PmWiki in customized ways.%0a%0a!!! Other common setup tasks%0aThe following [[variables]] are often requested when preparing a new wiki%0a* Author required when editing a page %25hlt php%25@@$EnablePostAuthorRequired = 1;@@ %0a* Set $DefaultGroup and the $DefaultPage.%0a%0aThese common [[(Cookbook:)Cookbook]] recipes are also often installed immediately%0a* [[(Cookbook:)Clean Urls]] - Remove the @@?n=Group.Page@@ arguments from the end of URLs%0a%0aIf you prepare an international wiki, potentially with characters in different alphabets (Cyrillic, Greek, Chinese) or many diacritical symbols (Czech + French), please look at [[PmWiki.UTF-8]] and Cookbook:UTF-8.%0a%0a!! Security%0aReview and set up any [[security]] required.%0a%0a!!!Setting an administrative password%0a%0aThe pages in the [[{$SiteGroup}/Site]] group (except the @@{$SiteGroup}.SideBar@@) are locked by default. In order to edit pages in this group you need to create a site-wide admin password in ''local/config.php''. To set the site-wide admin password to "@@mysecret@@", change the line to the following:%0a%0a->%25hlt php%25[@$DefaultPasswords['admin'] = pmcrypt('mysecret');@]%0a%0aYou must use the %25hlt php%25[@pmcrypt()@] function, but set the password to a value with meaning for you. See [[PasswordsAdmin]] for details about making the password more secure.%0a%0a!![[#dontmodify]]Don't modify or rename ''pmwiki.php''%0a%0aPmWiki has been designed so that all customizations can be made without changing the distribution files -- one of its design goals is to provide seamless upgrades. PmWiki never writes to files in the ''local/'' or ''cookbook/'' directories, so placing your customizations here makes it easier to track the changes and [[upgrades | upgrade PmWiki]] without losing the changes.%0a%0aWhen changing the configuration of your site, always change the ''local/config.php'' file or add files to the ''cookbook/'' or ''pub'' directories. Do not change ''pmwiki.php'' or the files in the ''scripts/'' directory because the files are supposed to be overwritten upon upgrading.%0a%0aYou shouldn't rename ''pmwiki.php'' either. If you rename the file it will not be overwritten during an upgrade of the software and there will be a version mismatch. Many administrators add an ''index.php'' "wrapper script" in the pmwiki directory that contains the following single line:%0a%0a->%25hlt php%25[@%3c?php include('pmwiki.php');@]%0a%0aJust make a text-file. Paste %25hlt php%25@@%3c?php include('pmwiki.php');@@ into it.%0aSave the file as @@index.php@@.%0aSend it via FTP to the same directory where @@pmwiki.php@@ is located. %0a%0a!! Other organisation%0a!!! Upload directories%0aBy default Pmwiki uses an upload directory for each group%0a(see [[Uploads admin(#uploaddirectoryconfiguration)]]istration.%0aDeciding on accepting the default, or choosing an alternative (eg one directory for the entire wiki, or one directory per page) is best done when setting up your wiki.%0a%0a!!! Page store directories%0aBy default Pmwiki uses a single page store directory (wiki.d).%0aDeciding on accepting the default (recommended), or choosing the alternative (one directory per group) is best done when setting up your wiki. '^[[Cookbook:PerGroupSubDirectories|#]]^'%0a%0a!!! Category GroupFooter%0aFor a new wiki the page [[Category.GroupFooter]] can be updated to%0a->%25pmhlt%25[@(:pagelist category={*$Name} list=normal:)@]%0aso that only categorised or tagged pages, i.e. those with %25pmhlt%25[@[[!tag]]@] markup are displayed,%0aand pages that link to categories i.e. those with %25pmhlt%25[@[[Category.tag]]@] markup are hidden.%0a%0a!!Other customization%0a%0aAfter setting up ''local/config.php'' file, you may wish to make other [[local customizations]]. See the [[Cookbook:CookbookBasics | PmWiki Cookbook]] for a large number of customizations that have been contributed. And don't fear Cookbook recipes - they're well prepared, so that most of them require only to download a single file, add a one-line include command to @@config.php@@, and ''voilà!'' - they're working!%0a%0aIf you (or others sharing your server) want to maintain more than one wiki on the same server, see [[Wiki Farms]].%0a%0a!!Now what?%0a%0aDon't forget to join a [[MailingLists | PmWiki mailing list]], where you can email other [[wiki administrator]]s for help on customizing PmWiki and participate in discussions about PmWiki improvements. Once you have your site operational, be sure to add it to PmWiki:PmWikiUsers so others will know about it!%0a +time=1669577363 blob - b2b43dc0129e7332231851b8d1b14011d644f84c blob + e360793e0c24dff359eef94a3029f1f90808032d --- wikilib.d/PmWiki.Installation +++ wikilib.d/PmWiki.Installation @@ -1,10 +1,10 @@ -version=pmwiki-2.2.78 ordered=1 urlencoded=1 -author=Petko +version=pmwiki-2.3.7 ordered=1 urlencoded=1 +author=simon charset=UTF-8 -csum= +csum=hlt php (-29) name=PmWiki.Installation -rev=431 -targets=PmWiki.Requirements,PmWiki.Upgrades,PmWiki.WikiFarms,PmWiki.ChangeLog,PmWiki.ReleaseNotes,PITS.PITS,PmWiki.MailingLists,PmWiki.Subversion,Cookbook.Cookbook,PmWiki.Skins,PmWiki.FilePermissions,PmWiki.InitialSetupTasks,PmWiki.Internationalizations,Group.Name,Cookbook.SimultaneousEdits,PmWiki.SimultaneousEdits,PmWiki.Troubleshooting,Cookbook.PHP,Cookbook.InstallOnIIS,Cookbook.CleanUrls,Cookbook.Standalone,Cookbook.WikiOnAStick -text=(:title PmWiki Installation :)%0a(:Summary: Obtaining and installing PmWiki:)%0a(:Audience: administrators:)%0aThis page explains how to download and install PmWiki 2.1 and 2.2. %0aHere's a list of related pages:%0a%0a* [[Requirements]] - {Requirements$:Summary}%0a* [[Upgrades]] - {Upgrades$:Summary}%0a* [[Wiki Farms]] - {WikiFarms$:Summary}%0a* [[Change Log]] - {ChangeLog$:Summary}%0a%0a'''Improvements''' to these instructions are always appreciated. Just report any problems you encounter to the pmwiki-users [[mailing list(s)]] or use the [[PITS:PITS |PmWiki Issue Tracking System]].%0a%0a!! Installing PmWiki%0aIf you upgrade, please read the page [[Upgrades]] and [[Release notes]].%0a%0a!!! 1. Download%0aDownload the latest ''stable'' version of PmWiki as a%0a* zip archive ([[(http://pmwiki.org/pub/pmwiki/)pmwiki-latest.zip]]), or a%0a* gzipped tarball ([[(http://pmwiki.org/pub/pmwiki/)pmwiki-latest.tgz]]) from [[http://pmwiki.org/pub/pmwiki/]], or%0aDownload the latest ''beta'' version from the [[PmWiki:Subversion]] page.%0a%0a%0a!!! [[#unpack]] 2. Unpack%0aUnpack the archive ([@tar zxvf pmwiki-latest.tgz@] or [@unzip pmwiki-latest.zip@]). This will create a ''pmwiki-x.y.z'' directory containing the PmWiki software. For example, the current "latest" should unpack to a directory named ''{$Version}''. The files in this directory include:%0a>>pre%3c%3c%0a README.txt An introductory document%0a pmwiki.php The main PmWiki script%0a local/ Configuration scripts (local configuration files)%0a cookbook/ Recipes (add-ons) from the [[(Cookbook:)Cookbook]]%0a docs/ Brief documentation, sample configuration scripts%0a pub/ Publicly accessible files%0a pub/css/ Extra CSS stylesheet files '^[[PmWiki/Skins#further|#]]^'%0a pub/guiedit/%0a pub/skins/ Layout templates for [[http://www.pmwiki.org/wiki/Skins/Skins|custom]] look and feel%0a scripts/ Scripts that are part of PmWiki%0a wikilib.d/ Bundled default PmWiki pages%0a>>%3c%3c%0a%0aThe ''pmwiki-x.y.z'' directory needs to be placed into a location accessible by your webserver (e.g., in a ''public_html'' directory of some sort). You can place files and directories using a number of methods -- FTP, or a Unix [@mv@] or [@cp@] command generally does the job.%0a%0a->%25note%25 Note: It is recommended to change the "''pmwiki-x.y.z''" directory name to be simply "''pmwiki''" or just "''wiki''".%0a%0a!!! [[#directories]] 3. Create directories%0a[[#dirsetup]]In most cases PmWiki will do this for you.%0aOpen a web browser to the ''pmwiki.php'' script on the server (i.e., not the one on your local computer or accessed using a [=file://...=] URL). PmWiki will then analyze your system configuration and provide instructions (if needed) for creating the ''wiki.d/'' directory which will be used to hold the pages created for your site. %0a%0aOtherwise, there are two ways to achieve this. (Use %25newwin%25[[http://filezilla-project.org/download.php|Filezilla]] or [[http://winscp.net/eng/download.php|WinSCP]] to change FTP file/folder permissions.)%0a%0a->3a. You can create the ''wiki.d/'' directory manually, and then give it full write permissions (i.e., "[@chmod 777 wiki.d@]"). Use this method when "safe mode" is activated in the server's PHP installation.%0a%0a->3b. On some systems you can let PmWiki create ''wiki.d/'' by temporarily changing the permissions on the directory containing the ''pmwiki.php'' file to 2777. In Unix this is commonly done by changing to the directory containing ''pmwiki.php'' and executing the command%0a%0a->@@chmod 2777 .@@%0a%0a->(note the dot at the end). The [@chmod@] command also works in many FTP programs. Creating ''wiki.d/'' in this manner will (1) make the directory writable so the web server can create the data directory it needs for the wiki files, (2) preserve group ownership of the directory so the installer account can manipulate the files created in this directory, and (3) make it more difficult for other accounts on the same server to access the files in ''wiki.d/''.%0a%0aAfter establishing directory permissions, try opening a browser to the ''pmwiki.php'' script again. If all is well, the ''wiki.d'' directory will have been created and you'll see the default home page.%0a%0a%25red%25'''Important:''' If you used method 3b, you should reset permissions by executing "[@chmod 755 .@]" in the directory containing pmwiki.php.%25%25%0a%0aSee also [[FilePermissions]].%0a%0a[[#dirsetupend]]%0a!!! 4. Initialize%0aCheck out [[Initial Setup Tasks]] for other tasks you may want to perform to begin customizing your PmWiki installation. You might also want to peruse the [[Release Notes]] for further information.%0a%0a%0a!!! 5. Set language%0aIf you want to use PmWiki in a different language download the [[Internationalizations|international]] language pack as zip archive ([[(http://pmwiki.org/pub/pmwiki/i18n/)i18n-all.zip]]) from [[http://pmwiki.org/pub/pmwiki/i18n/]]. Then extract it and copy the files into the ''wikilib.d/'' directory as described above. Besides the ''-all'' file you can also download your country localization file only.%0a%0aLanguages available are:%0a(:pagelist fmt=#listlanguage name=PmWiki* list=normal order=$:Language $:Language=- :)%0a(:if false:)%0a[[#listlanguage]]%0a(:template first:)%0a->%0a(:template each:)%0a[[{=$Group}/{=$Name} | {=$:Language} ]]%0a[[#listlanguageend]]%0a(:ifend:)%0a%0aThere are two directories in the decompressed i18n archive, ''scripts'' and ''wikilib.d''. Copy the files respectively contained in these directories to the ''scripts'' and ''wikilib.d'' of your PmWiki directory. For example, for French localization, PmWikiFr.* and PmWiki.* must be contained in the '''same''' directory.%0a%0aThen, enable localization by adding an instruction to local/config.php to load the language translation page of your choice. For instance, [@XLPage('fr','PmWikiFr.XLPage');@] loads the French language page PmWikiFr.XLPage.%0a%0aRead more about this on [[Internationalizations]].%0a%0a!! [[#notes]] Notes%0a%0a* [[#indexphp]] The PmWiki distribution deliberately doesn't include an ''index.php'' file. You can easily add your own "wrapper script" in the same directory as ''pmwiki.php''. Create a new file called ''index.php'' with the following single line of text (missing a closing "[@ ?>@]" tag deliberately):%0a%0a-->[@%3c?php include_once('pmwiki.php');@]%0a%0aResist the temptation to rename ''pmwiki.php'' to ''index.php'' because if you rename the file it will not be overwritten during an upgrade.%0a%0a* If using the Unix ''tar'' command to unpack the archive in step 2 above, be sure that the files are created with sufficient permissions for the webserver to be able to access them. Usually you can ensure this by typing @@umask 002@@ on the command line before unpacking the tar file.%0a%0a* When installing on Windows you should take a look at [[Cookbook:SimultaneousEdits]] to enable [[simultaneous edits]] on that platform.%0a%0a* Additional tips can be found at [[Troubleshooting]].%0a%0aSee also:%0a* [[Cookbook:PHP]] {Cookbook/PHP$:Summary}%0a* [[Cookbook:InstallOnIIS]] {Cookbook/InstallOnIIS$:Summary}%0a%0a%0a%0a>>faq%3c%3c [[#faq]]%0aQ: Should I rename pmwiki.php to index.php?%0aA: Renaming pmwiki.php is not recommended. Instead, create an ''index.php'' file that contains this single line%0a%0a->[@%3c?php include_once('pmwiki.php');@]%0a%0aQ: How do I make pmwiki.php the default page for a website?%0aA: Create an ''index.php'' file that runs PmWiki from a subdirectory (''pmwiki/'' for example) and place it in the site's web document root (the main directory for the website).%0a%0a->[@%3c?php chdir('pmwiki'); include_once('pmwiki.php');@]%0a%0aNote: You will also need to explicitly set the $PubDirUrl variable (e.g. to [@"http://example.com/pmwiki/pub"@]) in ''local/config.php'' .%0a%0aQ: How do I enable "Clean URLs" that are shorter and look like paths to my wiki pages? Why does pmwiki.org appear to have a directory structure rather than "?n=pagename" in URLs?%0aA: See [[Cookbook:CleanUrls]].%0a%0aQ: How can I run PmWiki on a standalone (offline, portable) machine ?%0aA: See [[Cookbook:Standalone]] or [[Cookbook:WikiOnAStick]].%0a -time=1439331935 +rev=482 +targets=PITS.PITS,PmWiki.MailingLists,PmWiki.Upgrades,PmWiki.ReleaseNotes,PmWiki.Subversion,Cookbook.Cookbook,PmWiki.Skins,PmWiki.FilePermissions,PmWiki.InitialSetupTasks,PmWiki.Internationalizations,Group.Name,Cookbook.SimultaneousEdits,PmWiki.SimultaneousEdits,PmWiki.Troubleshooting,Cookbook.PHP,Cookbook.InstallOnIIS,PmWiki.PathVariables,Cookbook.CleanUrls,Cookbook.Standalone,Cookbook.WikiOnAStick +text=(:title PmWiki Installation :)%0a(:Summary: Obtaining and installing PmWiki:)%0a(:Audience: administrators:)%0aThis page explains how to download and install PmWiki 2.1 to 2.3. %0aHere's a list of related pages:%0a(:pagelist group=pmwiki name=Requirements,Upgrades,WikiFarms,ChangeLog fmt=#titlesummary:)%0a%0a'''Improvements''' to these instructions are always appreciated. Just report any problems you encounter to the pmwiki-users [[mailing list(s)]] or use the [[PITS:PITS |PmWiki Issue Tracking System]].%0a%0a!! Installing PmWiki%0aIf you upgrade, please read carefully the pages [[Upgrades]] and [[Release notes]].%0a%0a!!! 1. Download%0aDownload the latest ''stable'' version of PmWiki as a%0a* zip archive ([[(https://pmwiki.org/pub/pmwiki/)pmwiki-latest.zip]]), or a%0a* gzipped tarball ([[(https://pmwiki.org/pub/pmwiki/)pmwiki-latest.tgz]]) from [[https://pmwiki.org/pub/pmwiki/]], or%0aDownload the latest ''beta'' version from the [[PmWiki:Subversion]] page.%0a%0a%0a!!! [[#unpack]] 2. Unpack%0aUnpack the archive ([@tar zxvf pmwiki-latest.tgz@] or [@unzip pmwiki-latest.zip@]). This will create a ''pmwiki-x.y.z'' directory containing the PmWiki software. For example, the current "latest" should unpack to a directory named ''{$Version}''. The files in this directory include:%0a>>pre%3c%3c%0a README.txt An introductory document%0a pmwiki.php The main PmWiki script%0a local/ Configuration scripts (local configuration files)%0a cookbook/ Recipes (add-ons) from the [[(Cookbook:)Cookbook]]%0a docs/ Brief documentation, sample configuration scripts%0a pub/ Publicly accessible files%0a pub/css/ Extra CSS stylesheet files '^[[PmWiki/Skins#further|#]]^'%0a pub/guiedit/%0a pub/skins/ Layout templates for [[https://www.pmwiki.org/wiki/Skins/Skins|custom]] look and feel%0a scripts/ Scripts that are part of PmWiki%0a wikilib.d/ Bundled default PmWiki pages%0a>>%3c%3c%0a%0aThe ''pmwiki-x.y.z'' directory needs to be placed into a location accessible by your webserver (e.g., in a ''public_html'' directory of some sort). You can place files and directories using a number of methods -- FTP, or a Unix [@mv@] or [@cp@] command generally does the job.%0a%0a->%25note%25 Note: It is recommended to change the "''pmwiki-x.y.z''" directory name to be simply "''pmwiki''" or just "''wiki''".%0a%0a!!! [[#directories]] 3. Create directories%0a[[#dirsetup]]In most cases PmWiki will do this for you.%0aOpen a web browser to the ''pmwiki.php'' script on the server (i.e., not the one on your local computer or accessed using a [=file://...=] URL). PmWiki will then analyze your system configuration and provide instructions (if needed) for creating the ''wiki.d/'' directory which will be used to hold the pages created for your site. %0a%0aOtherwise, there are two ways to achieve this. (Use %25newwin%25[[https://filezilla-project.org/download.php|Filezilla]] or [[https://winscp.net/eng/download.php|WinSCP]] to change FTP file/folder permissions.)%0a%0a->3a. You can create the ''wiki.d/'' directory manually, and then give it full write permissions (i.e., "[@chmod 777 wiki.d@]"). Use this method when "safe mode" is activated in the server's PHP installation.%0a%0a->3b. On some systems you can let PmWiki create ''wiki.d/'' by temporarily changing the permissions on the directory containing the ''pmwiki.php'' file to 2777. In Unix this is commonly done by changing to the directory containing ''pmwiki.php'' and executing the command%0a%0a->@@chmod 2777 .@@%0a%0a->(note the dot at the end). The [@chmod@] command also works in many FTP programs. Creating ''wiki.d/'' in this manner will (1) make the directory writable so the web server can create the data directory it needs for the wiki files, (2) preserve group ownership of the directory so the installer account can manipulate the files created in this directory, and (3) make it more difficult for other accounts on the same server to access the files in ''wiki.d/''.%0a%0aAfter establishing directory permissions, try opening a browser to the ''pmwiki.php'' script again. If all is well, the ''wiki.d'' directory will have been created and you'll see the default home page.%0a%0a%25red%25'''Important:''' If you used method 3b, you should reset permissions by executing "[@chmod 755 .@]" in the directory containing pmwiki.php.%25%25%0a%0aSee also [[FilePermissions]].%0a%0a[[#dirsetupend]]%0a!!! 4. Initialize%0aCheck out [[Initial Setup Tasks]] for other tasks you may want to perform to begin customizing your PmWiki installation. You might also want to peruse the [[Release Notes]] for further information.%0a%0a%0a!!! 5. Set language%0aIf you want to use PmWiki in a different language download the [[Internationalizations|international]] language pack as zip archive ([[(https://pmwiki.org/pub/pmwiki/i18n/)i18n-all.zip]]) from [[https://pmwiki.org/pub/pmwiki/i18n/]]. Then extract it and copy the files into the ''wikilib.d/'' directory as described above. Besides the ''-all'' file you can also download your country localization file only.%0a%0aLanguages available are:%0a(:pagelist fmt=#listlanguage name=PmWiki* list=normal order=$:Language $:Language=- :)%0a(:if false:)%0a[[#listlanguage]]%0a(:template first:)%0a->%0a(:template each:)%0a[[{=$Group}/{=$Name} | {=$:Language} ]]%0a[[#listlanguageend]]%0a(:ifend:)%0a%0aThere are two directories in the decompressed i18n archive, ''scripts'' and ''wikilib.d''. Copy the files respectively contained in these directories to the ''scripts'' and ''wikilib.d'' of your PmWiki directory. For example, for French localization, PmWikiFr.* and PmWiki.* must be contained in the '''same''' directory.%0a%0aThen, enable localization by adding an instruction to @@local/config.php@@ to load the language translation page of your choice. For instance, %25hlt php%25[@XLPage('fr','PmWikiFr.XLPage');@] loads the French language page @@PmWikiFr.XLPage@@.%0a%0aRead more about this on [[Internationalizations]].%0a%0a!! [[#notes]] Notes%0a%0a* [[#indexphp]] The PmWiki distribution deliberately doesn't include an ''index.php'' file. You can easily add your own "wrapper script" in the same directory as ''pmwiki.php''. Create a new file called ''index.php'' with the following single line of text (missing a closing "[@ ?>@]" tag deliberately):%0a%0a-->%25hlt php%25[@%3c?php include_once('pmwiki.php');@]%0a%0aResist the temptation to rename ''pmwiki.php'' to ''index.php'' because if you rename the file it will not be overwritten during an upgrade.%0a%0a* If using the Unix ''tar'' command to unpack the archive in step 2 above, be sure that the files are created with sufficient permissions for the webserver to be able to access them. Usually you can ensure this by typing @@umask 002@@ on the command line before unpacking the tar file.%0a%0a* When installing on Windows you should take a look at [[Cookbook:SimultaneousEdits]] to enable [[simultaneous edits]] on that platform.%0a%0a* Additional tips can be found at [[Troubleshooting]].%0a%0aSee also:%0a* [[Cookbook:PHP]] {Cookbook/PHP$:Summary}%0a* [[Cookbook:InstallOnIIS]] {Cookbook/InstallOnIIS$:Summary}%0a%0a%0a%0a>>faq%3c%3c [[#faq]]%0aQ: Should I rename pmwiki.php to index.php?%0aA: Renaming pmwiki.php is not recommended. Instead, create an ''index.php'' file that contains this single line%0a%0a->%25hlt php%25[@%3c?php include_once('pmwiki.php');@]%0a%0aQ: How do I make pmwiki.php the default page for a website?%0aA: Create an ''index.php'' file that runs PmWiki from a subdirectory (''pmwiki/'' for example) and place it in the site's web document root (the main directory for the website).%0a%0a->%25hlt php%25[@%3c?php chdir('pmwiki'); include_once('pmwiki.php');@]%0a%0aNote: You will also need to explicitly set the $PubDirUrl variable (e.g. to [@"https://example.com/pmwiki/pub"@]) in ''local/config.php'' .%0a%0aQ: How do I enable "Clean URLs" that are shorter and look like paths to my wiki pages? Why does pmwiki.org appear to have a directory structure rather than "?n=pagename" in URLs?%0aA: See [[Cookbook:CleanUrls]].%0a%0aQ: How can I run PmWiki on a standalone (offline, portable) machine ?%0aA: See [[Cookbook:Standalone]] or [[Cookbook:WikiOnAStick]].%0a +time=1658470944 title=PmWiki Installation blob - 9ce024ec11dbcd525232bafd1bd7694329980657 blob + 934c128835d3d696a02fbffb51aece5daacf6ad8 --- wikilib.d/PmWiki.InterMap +++ wikilib.d/PmWiki.InterMap @@ -1,9 +1,9 @@ -version=pmwiki-2.2.107 ordered=1 urlencoded=1 -author=simon +version=pmwiki-2.3.16 ordered=1 urlencoded=1 +author=Petko charset=UTF-8 -csum=update to use https (please update intermap.txt) +csum=generic example.org example, pmhlt (+23) name=PmWiki.InterMap -rev=58 +rev=65 targets=PmWiki.WikiWikiWeb,Site.InterMap,PmWiki.Variables,Cookbook.RelativeUrls,Cookbook.RelativeLinks,PmWiki.LinkSchemes,PmWiki.WikiFarms,PmWiki.Upgrades,PmWiki.LinkVariables,PmWiki.BasicVariables,PmWiki.PathVariables -text=(:Summary: Interwiki links definition and use:)%0a(:Audience: author (intermediate) :)%0a%0aThe InterMap (also called InterWiki in some other wikis) is a system for defining links between [[WikiWikiWeb]] sites that was first developed by UseMod and Meatball (see UseMod:InterWiki and Meatball:InterWiki). The method is to use a word shortcut that stands for a defined path. InterMap links have the form [@MapPrefix:PagePath@], where the host prefix is converted to a partial URL based on entries in the site's ''intermap.txt'' and ''localmap.txt'' files.%0a%0a[[#custominclude]]%0a!! The default intermap.txt%0a%0aThe default ''intermap.txt'' distributed with PmWiki (in the ''scripts/'' directory) includes the following InterMap entries:%0a>>pre%3c%3c%0a PmWiki: https://www.pmwiki.org/wiki/PmWiki/ %0a Cookbook: https://www.pmwiki.org/wiki/Cookbook/ %0a Wiki: http://www.c2.com/cgi/wiki? %0a UseMod: http://www.usemod.com/cgi-bin/wiki.pl? %0a Meatball: http://www.usemod.com/cgi-bin/mb.pl? %0a Wikipedia: https://en.wikipedia.org/wiki/ %0a PITS: https://www.pmwiki.org/wiki/PITS/ %0a PmL10n: https://www.pmwiki.org/wiki/Localization/%0a Path:%0a>>%3c%3c%0a%0a!! The page [[{$SiteGroup}.InterMap]]%0a(:if exists {$SiteGroup}.InterMap:)%0a[[{$SiteGroup}.InterMap]] includes the following entries:%0a(:include {$SiteGroup}.InterMap#include#includeend:)%0a(:else:)%0aYou can map your own prefixes in your local page [[{$SiteGroup}.InterMap]].%0a(:ifend:)%0a[[#customincludeend]]%0a%0aThus, "PmWiki:Variables" becomes "https://www.pmwiki.org/wiki/PmWiki/" + "Variables", a link to the [[PmWiki.Variables->https://www.pmwiki.org/wiki/PmWiki/Variables]] page on the official PmWiki web site, Wiki:FrontPage is a link to the front page of the first WikiWikiWeb, and Wikipedia:Stonehenge takes you to the Wikipedia article about the famous megaliths in England. %0a%0a!! Usage in a wiki page%0a%0aLike other links, you can use the double-bracket syntax to get different link text:%0a(:markup class=horiz:)%0a* [[Meatball:StartingPoints | starting points]] over at Meatball%0a* [[starting points -> Meatball:StartingPoints]] over at Meatball%0a(:markupend:)%0a%0aIf you want to link just to what the intermap says (e.g. https://www.wikipedia.com/wiki/ for Wikipedia), then do [@[[Wikipedia:. | Wikipedia's main page]]@], which produces [[Wikipedia:. | Wikipedia's main page]]. Note the . (period) after the Map: reference.%0a%0a[[#path]]%0aThe special [@Path:@] InterMap entry can be used to create "[[Cookbook:RelativeUrls|relative urls]]" in [[Cookbook:RelativeLinks|links]].%0a%0a!! Custom InterMap prefixes%0aThe actual set of InterMap links at any site is defined by the site administrator via the [[Site.InterMap]] page and the ''local/localmap.txt'' file.%0a%0aAn intermap entry takes the following format:%0a%0a-> [@%0aMapPrefix: https://example.com/partial/url/%0a@]%0a%0aThe InterMap entry can be for any of the [[(PmWiki:)link schemes]] supported by PmWiki.%0a[[%3c%3c]]%0aYou can create your own InterMap links by doing one or more of the following:%0a%0a* Modify the page called ''[[{$SiteGroup}.InterMap]]'' and place entries like the ones above in it.%0a* Create a file called ''local/localmap.txt'' and place entries like the ones above in it.%0a* In a [[WikiFarm(s)]] installation you can create a file called%0a ''local/farmmap.txt'' and there place entries like the ones above in it.%0a These prefixes will be common to all the wikis in the farm.%0a* Ensure that there is a space after the colon.%0a%0aDo not edit the file ''scripts/intermap.txt'' directly! If you do, you'll%0alose your changes when you [[PmWiki/upgrade(s)]] PmWiki.%0a%0a%0a!! Variables and InterMap links%0a%0aIt's possible to use variables within your InterMap entries. The following%0aentries create [@ThisWiki:@] and [@ThisPage:@] shortcuts:%0a%0a-> [@%0aThisWiki: $ScriptUrl%0aThisPage: {$PageUrl}%0a@]%0a%0aYou can also define InterMap entries where the text of the entry is%0asubstituted into the middle of the URL. Just include '$1' in the URL where%0ayou want the substitution to take place. For example:%0a%0a->[@Jargon: http://catb.org/~esr/jargon/html/$1.html@]%0a%0awould cause [@Jargon:F/feature-creep@] to be converted to [@http://catb.org/~esr/jargon/html/F/feature-creep.html@].%0a%0a%0a!! Tips and tricks%0a%0aIt is possible to document your intermap prefixes directly in the page%0a[[Site.InterMap]]. The extra text will not cause a performance penalty, nor%0awill it break the definition of prefixes. However, be aware that anything%0amatching a line starting with a word and a colon (''':''') will be%0aconsidered to define a prefix.%0a%0aThe order in which various sources are checked for definitions of prefixes%0ais controlled by the variable $InterMapFiles. Currently the precedence%0a(highest to lowest is as follows):%0a* ''local/localmap.txt''%0a* ''$SiteGroup.InterMap''%0a* ''$FarmD/local/farmmap.txt''%0a* ''$FarmD/scripts/intermap.txt''%0a%0a%0a>>faq%3c%3c [[#faq]]%0a%0aQ: Are InterMap names case sensitive?%0aA: Yes, thus [@eAdmin:@] is a different InterMap link than [@EAdmin:@].%0a%0aQ: How can I achieve a ''localmap.txt'' mapping with the effect of [@Pics: Path:/somepathto/pics/@]?%0aA: Use the following:%0a->[@Pics: /somepathto/pics/@]%0a%0a%0aQ: How can I define an InterMap in PHP?%0aA: Use the following:%0a->[@%0a $LinkFunctions['PmWikiHome:'] = 'LinkIMap';%0a $IMap['PmWikiHome:'] = 'https://pmwiki.org/wiki/$1';%0a@]%0a -time=1526552645 +text=(:Summary: Interwiki links definition and use:)%0a(:Audience: author (intermediate) :)%0a%0aThe InterMap (also called InterWiki in some other wikis) is a system for defining links between [[WikiWikiWeb]] sites that was first developed by UseMod and Meatball (see UseMod:InterWiki and Meatball:InterWiki). The method is to use a word shortcut that stands for a defined path. InterMap links have the form [@MapPrefix:PagePath@], where the host prefix is converted to a partial URL based on entries in the site's ''intermap.txt'' and ''localmap.txt'' files.%0a%0a[[#custominclude]]%0a!! The default intermap.txt%0a%0aThe default ''intermap.txt'' distributed with PmWiki (in the ''scripts/'' directory) includes the following InterMap entries:%0a>>pre%3c%3c%0a PmWiki: https://www.pmwiki.org/wiki/PmWiki/ %0a Cookbook: https://www.pmwiki.org/wiki/Cookbook/ %0a Wiki: http://www.c2.com/cgi/wiki? %0a UseMod: http://www.usemod.com/cgi-bin/wiki.pl? %0a Meatball: http://www.usemod.com/cgi-bin/mb.pl? %0a Wikipedia: https://en.wikipedia.org/wiki/ %0a PITS: https://www.pmwiki.org/wiki/PITS/ %0a PmL10n: https://www.pmwiki.org/wiki/Localization/%0a Path:%0a>>%3c%3c%0a%0a!! The page [[{$SiteGroup}.InterMap]]%0a(:if exists {$SiteGroup}.InterMap:)%0a[[{$SiteGroup}.InterMap]] includes the following entries:%0a(:include {$SiteGroup}.InterMap#include#includeend:)%0a(:else:)%0aYou can map your own prefixes in your local page [[{$SiteGroup}.InterMap]].%0a(:ifend:)%0a[[#customincludeend]]%0a%0aThus, "PmWiki:Variables" becomes "https://www.pmwiki.org/wiki/PmWiki/" + "Variables", a link to the [[PmWiki.Variables->https://www.pmwiki.org/wiki/PmWiki/Variables]] page on the official PmWiki web site, Wiki:FrontPage is a link to the front page of the first WikiWikiWeb, and Wikipedia:Stonehenge takes you to the Wikipedia article about the famous megaliths in England. %0a%0a!! Usage in a wiki page%0a%0aLike other links, you can use the double-bracket syntax to get different link text:%0a(:markup class=horiz:)%0a* [[Meatball:StartingPoints | starting points]] over at Meatball%0a* [[starting points -> Meatball:StartingPoints]] over at Meatball%0a(:markupend:)%0a%0aIf you want to link just to what the intermap says (e.g. https://en.wikipedia.com/wiki/ for Wikipedia), then do %25pmhlt%25[@[[Wikipedia:. | Wikipedia's main page]]@], which produces [[Wikipedia:. | Wikipedia's main page]]. Note the . (period) after the Map: reference.%0a%0a[[#path]]%0aThe special [@Path:@] InterMap entry can be used to create "[[Cookbook:RelativeUrls|relative urls]]" in [[Cookbook:RelativeLinks|links]].%0a%0a!! Custom InterMap prefixes%0aThe actual set of InterMap links at any site is defined by the site administrator via the [[Site.InterMap]] page and the ''local/localmap.txt'' file.%0a%0aAn intermap entry takes the following format:%0a%0a-> [@%0aMapPrefix: https://example.com/partial/url/%0a@]%0a%0aThe InterMap entry can be for any of the [[(PmWiki:)link schemes]] supported by PmWiki.%0a[[%3c%3c]]%0aYou can create your own InterMap links by doing one or more of the following:%0a%0a* Modify the page called ''[[{$SiteGroup}.InterMap]]'' and place entries like the ones above in it.%0a* Create a file called ''local/localmap.txt'' and place entries like the ones above in it.%0a* In a [[WikiFarm(s)]] installation you can create a file called%0a ''local/farmmap.txt'' and there place entries like the ones above in it.%0a These prefixes will be common to all the wikis in the farm.%0a* Ensure that there is a space after the colon.%0a%0aDo not edit the file ''scripts/intermap.txt'' directly! If you do, you'll%0alose your changes when you [[PmWiki/upgrade(s)]] PmWiki.%0a%0a%0a!! Variables and InterMap links%0a%0aIt's possible to use variables within your InterMap entries. The following%0aentries create [@ThisWiki:@] and [@ThisPage:@] shortcuts:%0a%0a-> [@%0aThisWiki: $ScriptUrl%0aThisPage: {$PageUrl}%0a@]%0a%0aYou can also define InterMap entries where the text of the entry is%0asubstituted into the middle of the URL. Just include '$1' in the URL where%0ayou want the substitution to take place. For example:%0a%0a->[@Jargon: http://catb.org/~esr/jargon/html/$1.html@]%0a%0awould cause [@Jargon:F/feature-creep@] to be converted to [@http://catb.org/~esr/jargon/html/F/feature-creep.html@].%0a%0a%0a!! Tips and tricks%0a%0aIt is possible to document your intermap prefixes directly in the page%0a[[Site.InterMap]]. The extra text will not cause a performance penalty, nor%0awill it break the definition of prefixes. However, be aware that anything%0amatching a line starting with a word and a colon (''':''') will be%0aconsidered to define a prefix.%0a%0aThe order in which various sources are checked for definitions of prefixes%0ais controlled by the variable $InterMapFiles. Currently the precedence%0a(highest to lowest is as follows):%0a* ''local/localmap.txt''%0a* ''$SiteGroup.InterMap''%0a* ''$FarmD/local/farmmap.txt''%0a* ''$FarmD/scripts/intermap.txt''%0a%0a%0a>>faq%3c%3c [[#faq]]%0a%0aQ: Are InterMap names case sensitive?%0aA: Yes, thus [@eAdmin:@] is a different InterMap link than [@EAdmin:@].%0a%0aQ: How can I achieve a ''localmap.txt'' mapping with the effect of [@Pics: Path:/somepathto/pics/@]?%0aA: Use the following:%0a->[@Pics: /somepathto/pics/@]%0a%0a%0aQ: How can I define an InterMap in PHP?%0aA: Use the following:%0a->%25hlt php%25[@%0a $LinkFunctions['PmWikiHome:'] = 'LinkIMap';%0a $IMap['PmWikiHome:'] = 'https://pmwiki.org/wiki/$1';%0a@]%0a%0aQ: How can I define an InterMap link that lets me refer to files at the server "root"?%0aA: From the page %25pmhlt%25@@[=https://example.org/index.php/Main/HomePage=]@@ I want to create a relative link to a directory at the "root" level of the site. The fully qualified URL is @@[=https://example.org/commoninfo/infoaboutu.php=]@@. I want to do this because the domain name will change, which would break an absolute link.%0a%0a->Create an InterMap link like so:%0a Root /%0a->Then your relative link can be:%0a Root:commoninfo/infoaboutu.php%0a%0aA: Or, you can use the predefined "Path:" prefix, as in %25pmhlt%25[@Path:/commoninfo/infoaboutu.php@].%0a +time=1670584765 blob - 677faa3a910bfb5887487d03080fa5224d91752a blob + 74d14acf05f3b1375aaa9bec9c19d10468bc0429 --- wikilib.d/PmWiki.Internationalizations +++ wikilib.d/PmWiki.Internationalizations @@ -1,9 +1,9 @@ -version=pmwiki-2.2.120 ordered=1 urlencoded=1 -author=bttr +version=pmwiki-2.3.17 ordered=1 urlencoded=1 +author=simon charset=UTF-8 -csum=Fix markup +csum=add a pm hlt (+29) name=PmWiki.Internationalizations -rev=125 -targets=Group.Group,Group.XLPage,Group.XLPageLocal,PmWiki.OtherLanguages,PmWiki.UTF-8,PmWikiFr.XLPage,PmWiki.PathVariables,PmWiki.WikiGroup,PmWiki.GroupCustomizations,Cookbook.MultiLanguage,Cookbook.MultiLanguageViews,PmWiki.PmWiki,Localization.Localization,PmWiki.I18nVariables -text=(:Summary: Language internationalisation of web pages:)%0a[[#include]]%0aPmWiki supports internationalization (internationalisation) of web pages, allowing accented characters to appear in page names and almost complete customization of PmWiki's prompts. %0a[[#includeend]]%0aMost customization is provided via the XLPage() function in PmWiki, which loads a set of translation variables from a wiki page (typically named XLPage, but it can be named anything you wish).%0a%0aThe rest of this page is devoted to the installation, configuration and usage of other language(s) support. If you are looking for tools and help to ''localize'' PmWiki in your language, or how you can improve the existing translations, start on pmwiki.org with the page [[(http://www.pmwiki.org/wiki/Localization/)Localization]] - The Translation Portal.%0a%0a>>rframe font-size:smaller clear:right%3c%3c%0a(:pagelist fmt=#languagelist2 trail=PmWiki.OtherLanguages order=name:)%0a(:if4 false:)%0a[[#languagelist2]]%0a(:template each:)%0a-%3c [[{=$Group}/]] {{=$Group}.{=$Group}$:Language} ~ [-[[{=$Group}/XLPage]]-] (:if exists {=$Group}.XLPageLocal:) [-[[{=$Group}/XLPageLocal]]-] (:ifend:)%0a[[#languagelistend]]%0a(:if4end:)%0a>>%3c%3c%0a!! [[#LoadingTranslationPages]] Loading Translation Pages%0a%0aPages for many [[(PmWiki:)other languages]] have already been created and maintained at the pmichaud.com site. You can download an archive of these translations from http://www.pmwiki.org/pub/pmwiki/i18n/ . Simply download the appropriate language archive(s), and unpack the archive(s) into the directory containing your ''pmwiki.php'' installation. Each archive contains a number of page files that are placed in your ''wikilib.d/'' directory, and some special scripts for translations that use a character set other than iso-8859-1 (PmWiki's default). You can also use [[UTF-8]] charset.%0a%0aOnce the translation pages are installed, you enable a language by adding a call to `XLPage() in your ''config.php'' file. For example, to select French language prompts, one would specify%0a%0a->[@%0ainclude_once("scripts/xlpage-utf-8.php"); # optional%0aXLPage('fr','PmWikiFr.XLPage');@]%0a%0awhich says to load the translations for French ('fr') from the page [[PmWikiFr.XLPage]]. The include_once line is recommended if you start a new wiki, and it should be placed ''before'' the XLPage line (for languages with alphabets other than the Latin, the include_once line is required). These lines should be placed near the beginning of config.php, ''but after any $WikiDir and $WikiLibDirs setting (if you have such setting)''.%0a%0aIt's possible to load multiple pages; so if you want to create your own local translations without changing the ones you got from an i18n archive, just create another page (see below) and load it first. Be sure that you load first the page with your local changes:%0a%0a-> [@%0aXLPage('fr','PmWikiFr.XLPageLocal'); # my local translations%0aXLPage('fr','PmWikiFr.XLPage'); # from i18n.tgz%0a@]%0a%0aIf your intention is to offer multiple languages on your site, and use [[Wiki Group]]s as language selectors, you may want to place this code in local customizations files (see [[Group Customizations]]). For example, if your site is published in French and English, and the French pages are in a group called Fr, you could create a file named Fr.php in the ''local/'' directory which contains:%0a%0a-> [@%0a%3c?php if (!defined('PmWiki')) exit();%0a##change to French language%0aXLPage('fr','PmWikiFr.XLPage');%0a@]%0a%0aYou may wish to create a page called ''PmwikiFr.php'' with the same content to access the French documentation in the PmwikiFr group. ''En.php'' is not necessary in this case since English is the default language.%0a%0aAn alternative to the above would be to add to ''config.php'' the following, which tests if there is an XLPage in a group, and if it finds one it gets loaded (any language):%0a%0a-> [@ %0a$xlpage = FmtPageName('$Group.XLPage', $pagename);%0aif (PageExists($xlpage)) XLPage($xlpage, $xlpage); %0a@]%0a%0aWith this method you would need to copy any relevant XLPage into any group which needs the different language support.%0a%0aAnother way (advanced) would be insert into config.php this script, it asks to the web server the headers received from the user's browser and select a language; example with spanish and english:%0a%0a-> [@ %0a$lang = substr($_SERVER['HTTP_ACCEPT_LANGUAGE'], 0, 2);%0aswitch ($lang){%0a case "es":%0a XLPage('es','PmWikiEs.XLPage');%0a break;%0a case "en":%0a XLPage('en','PmWikiEn.XLPage');%0a break;%0a default:%0a XLPage('en','PmWikiEn.XLPage');%0a break;%0a}%0a@]%0a%0aSee also %0a* [[Cookbook:MultiLanguage]] {Cookbook/MultiLanguage$:Summary}%0a* [[Cookbook:MultiLanguageViews]] {Cookbook/MultiLanguageViews$:Summary}%0a%0a!![[#CreatingNewTranslations]]Creating New Translations%0a%0aIf language pages don't exist for your desired language, it's easy to create one! An XLPage translation file simply contains lines of the form%0a%0a->[@'phrase' => 'translated phrase',@]%0a%0awhere "phrase" is an internationalized phrase (denoted by [@$[phrase]@]) in PmWiki's $...Fmt variables, and "translated phrase" is what should be printed in your particular language. For example, the line (in [@PmWikiFr.XLPage@])%0a%0a->[@'Search' => 'Rechercher',@]%0a%0aconverts "[@$[Search]@]" to "Rechercher" on output. The file [[http://www.pmwiki.org/wiki/Localization/XLPageTemplate|Localization:XLPageTemplate]] is a good starting point for creating a new XLPage and has most of PmWiki's key phrases already listed in it. %0a%0aIf you create new versions of PmWiki pages in other languages, please consider adding them to the [[PmWiki:PmWiki | main PmWiki site]] so that they can be made available to others in the i18n archives! (Be sure to check out [[Localization/Localization|The Localization Portal]] for further information on effectively internationalizing PmWiki.)%0a%0a->%25note%25 The term "i18n" is commonly used as an abbreviation for the English word "internationalization". The abbreviation is derived from the fact that there are 18 letters between the "i" and the final "n" and few people want to type them all out.%0a%0a!! Enabling "Special" Characters in WikiLinks%0a%0aTo enable "special" characters like for example German umlauts in WikiLinks, it is necessary to configure the server locale to ensure that PmWiki uses the proper character set definition.%0a%0aIf this is not possible due to limited access to the server configuration, PmWiki can be configured to use a specific locale by using the XLPage options (see [[(http://www.pmwiki.org/wiki/Localization/)XLPageTemplate]]).%0a%0aFor German umlauts, you'd need for example:%0a%0a*[@'Locale' => 'deu',@] %3c- for Windows servers, see [[http://msdn.microsoft.com/en-us/library/39cwe7zf.aspx|MSDN List of locale identifiers]]%0a*[@'Locale' => 'de_DE',@] %3c- for Linux servers; for the UTF-8 encoding, on some installations you may need to set @@'de_DE.utf8'@@ or @@'de_DE.UTF-8'@@.%0a%0aNote that the locale identifier depends on the operation system and perhaps on the specific installation.%0a%0a[[#notes]]%0a!! Notes%0a%0a%0a>>faq%3c%3c [[#faq]]%0a%0aQ: If my wiki is internationalized by ''config.php'', how do I revert a specific group to English?%0a%0aA: Use [@$XLLangs = array('en');@] in the group's [[ group customization(s)]] file.%0a%0aQ: If my wiki is in English and I want just one page, or group, in Spanish do I say [@XLPage('es','PmWikiEs.XLPage');@] in the group or page configuration file?%0a%0aA: Yes, that is usually the best method. If you were doing this with many scattered pages, or with several languages, you might find it easier to maintain if you load the translations all in config.php like this:%0a%0a XLPage('es','PmWikiEs.XLPage');%0a XLPage('fr','PmWikiFr.XLPage');%0a XLPage('ru','PmWikiRu.XLPage');%0a $XLLangs = array('en');%0a%0aA: Then in each group or page configuration file, you'd just use $XLLangs = array('es'); to set the language to use (in this case, Spanish). Note that though this method is easier to maintain, its somewhat slower because it loads all the dictionaries for each page view, even if they won't be used.%0a%0aQ: What does the first parameter of this function stand for? How can it be used?%0a%0aA: The XLPage mechanism allows multiple sets of translations to be loaded,%0aand the first parameter is used to distinguish them. %0a%0aFor example, suppose I want to have translations for both normal French%0aand "Canadian" French. Rather than maintain two entirely separate sets%0aof pages, I could do:%0a%0a XLPage('fr-ca', 'PmWikiFrCa.XLPage');%0a XLPage('fr', 'PmWikiFr.XLPage');%0a%0aPmWikiFr.XLPage would contain all of the standard French translations,%0awhile PmWikiFrCA.XLPage would only need to contain "Canada-specific"%0atranslations -- i.e., those that are different from the ones in the%0aFrench page.%0a%0aThe first parameter distinguishes the two sets of translations.%0aIn addition, a ''config.php'' script can use the $XLLangs variable%0ato adjust the order of translation, so if there was a group or%0apage where I only wanted the standard French translation, I%0acan set%0a%0a $XLLangs = array('fr', 'en');%0a%0aand PmWiki will use only the 'fr' and 'en' translations (in that order),%0ano matter how many translations have been loaded with XLPage().%0a%0a[[#xlsdv]]%0aQ: How can I add a translation for an individual string in a PHP file?%0a%0aA: Use the XLSDV() function to provide a translation for a specific (English) string. For instance, with this in config.php%0a%0a XLSDV('nl', array('my English expression'=>'mijn Nederlandse uitdrukking'));%0a%0aany instance of the variable expression [@$[my English expression]@] in wiki mark-up will be displayed as ''my English expression'' in default (English) context, but as ''mijn Nederlandse uitdrukking'' in Dutch (nl) context, i.e. when [@XLPage('nl',...)@] has been called for that page in config.php or a cookbook recipe.%0a%0aIf you need to get a translation in a PHP file, use the [@XL()@] function:%0a $local_string = XL("my English expression");%0a%0aBut beware: XLPage() uses XLSDV() internally for its translation pairs, too, and only the first definition is accepted! Thus, if the Dutch XLPage already contains a translation and you want to override that, you need to use your XLSDV('nl',...) ''before'' calling the correspondent XLPage('nl',...). Otherwise, by using XLSDV() ''after'' XLPage() - e.g. within a recipe that is included later in config.php - your translation will only work as long nobody defines 'my English expression' in that XLPage.%0a%0a -time=1574023541 +rev=129 +targets=Localization.Localization,Group.Group,Group.XLPage,Group.XLPageLocal,PmWiki.OtherLanguages,PmWiki.UTF-8,PmWikiFr.XLPage,PmWiki.PathVariables,PmWiki.WikiGroup,PmWiki.GroupCustomizations,Cookbook.MultiLanguage,Cookbook.MultiLanguageViews,Localization.XLPageTemplate,PmWiki.PmWiki,PmWiki.I18nVariables +text=(:Summary: Language internationalisation of web pages:)%0a[[#include]]%0aPmWiki supports internationalization (internationalisation) of web pages, allowing accented characters to appear in page names and almost complete customization of PmWiki's prompts. %0a[[#includeend]]%0aMost customization is provided via the %25hlt php%25@@XLPage()@@ function in PmWiki, which loads a set of translation variables from a wiki page (typically named XLPage, but it can be named anything you wish).%0a%0aThe rest of this page is devoted to the installation, configuration and usage of other language(s) support. If you are looking for tools and help to ''localize'' PmWiki in your language, or how you can improve the existing translations, start on pmwiki.org with the page [[Localization/Localization]] - The Translation Portal.%0a%0a>>rframe font-size:smaller clear:right%3c%3c%0a(:pagelist fmt=#languagelist2 trail=PmWiki.OtherLanguages order=name:)%0a(:if4 false:)%0a[[#languagelist2]]%0a(:template each:)%0a-%3c [[{=$Group}/]] {{=$Group}.{=$Group}$:Language} ~ [-[[{=$Group}/XLPage]]-] (:if exists {=$Group}.XLPageLocal:) [-[[{=$Group}/XLPageLocal]]-] (:ifend:)%0a[[#languagelistend]]%0a(:if4end:)%0a>>%3c%3c%0a!! [[#LoadingTranslationPages]] Loading Translation Pages%0a%0aPages for many [[(PmWiki:)other languages]] have already been created and maintained at the [[(https://)pmichaud.com]] site. You can download an archive of these translations from [[https://www.pmwiki.org/pub/pmwiki/i18n/]]. Simply download the appropriate language archive(s), and unpack the archive(s) into the directory containing your ''@@pmwiki.php@@'' installation. Each archive contains a number of page files that are placed in your ''@@wikilib.d/@@'' directory, and some special scripts for translations that use a character set other than iso-8859-1 (PmWiki's default). You can also use [[UTF-8]] charset.%0a%0aOnce the translation pages are installed, you enable a language by adding a call to %25hlt php%25@@XLPage()@@ in your ''@@config.php@@'' file. For example, to select French language prompts, one would specify%0a%0a->%25hlt php%25[@%0ainclude_once("scripts/xlpage-utf-8.php"); # optional%0aXLPage('fr','PmWikiFr.XLPage');@]%0a%0awhich says to load the translations for French ('fr') from the page [[PmWikiFr.XLPage]]. The include_once line is recommended if you start a new wiki, and it should be placed ''before'' the XLPage line (for languages with alphabets other than the Latin, the @@include_once@@ line is required). These lines should be placed near the beginning of @@config.php@@, ''but after any $WikiDir and $WikiLibDirs setting (if you have such setting)''.%0a%0aIt's possible to load multiple pages; so if you want to create your own local translations without changing the ones you got from an i18n archive, just create another page (see below) and load it first. Be sure that you load first the page with your local changes:%0a%0a-> %25hlt php%25[@%0aXLPage('fr','PmWikiFr.XLPageLocal'); # my local translations%0aXLPage('fr','PmWikiFr.XLPage'); # from i18n.tgz%0a@]%0a%0aIf your intention is to offer multiple languages on your site, and use [[Wiki Group]]s as language selectors, you may want to place this code in local customizations files (see [[Group Customizations]]). For example, if your site is published in French and English, and the French pages are in a group called Fr, you could create a file named @@Fr.php@@ in the ''@@local/@@'' directory which contains:%0a%0a-> %25hlt php%25[@%0a%3c?php if (!defined('PmWiki')) exit();%0a##change to French language%0aXLPage('fr','PmWikiFr.XLPage');%0a@]%0a%0aYou may wish to create a page called ''@@PmwikiFr.php@@'' with the same content to access the French documentation in the PmwikiFr group. ''@@En.php@@'' is not necessary in this case since English is the default language.%0a%0aAn alternative to the above would be to add to ''@@config.php@@'' the following, which tests if there is an XLPage in a group, and if it finds one it gets loaded (any language):%0a%0a-> %25hlt php%25[@$xlpage = FmtPageName('$Group.XLPage', $pagename);%0aif (PageExists($xlpage)) XLPage($xlpage, $xlpage); %0a@]%0a%0aWith this method you would need to copy any relevant XLPage into any group which needs the different language support.%0a%0aAnother way (advanced) would be insert into @@config.php@@ this script, it asks to the web server the headers received from the user's browser and select a language; example with spanish and english:%0a%0a-> %25hlt php%25[@ %0a$lang = substr($_SERVER['HTTP_ACCEPT_LANGUAGE'], 0, 2);%0aswitch ($lang){%0a case "es":%0a XLPage('es','PmWikiEs.XLPage');%0a break;%0a case "en":%0a XLPage('en','PmWikiEn.XLPage');%0a break;%0a default:%0a XLPage('en','PmWikiEn.XLPage');%0a break;%0a}%0a@]%0a%0aSee also %0a* [[Cookbook:MultiLanguage]] {Cookbook/MultiLanguage$:Summary}%0a* [[Cookbook:MultiLanguageViews]] {Cookbook/MultiLanguageViews$:Summary}%0a%0a!![[#CreatingNewTranslations]]Creating New Translations%0a%0aIf language pages don't exist for your desired language, it's easy to create one! An XLPage translation file simply contains lines of the form%0a%0a->%25hlt php%25[@'phrase' => 'translated phrase',@]%0a%0awhere "phrase" is an internationalized phrase (denoted by %25pmhlt%25[@$[phrase]@]) in PmWiki's @@$...Fmt@@ variables, and "translated phrase" is what should be printed in your particular language. For example, the line (in [@PmWikiFr.XLPage@])%0a%0a->%25hlt php%25[@'Search' => 'Rechercher',@]%0a%0aconverts "%25pmhlt%25[@$[Search]@]" to "Rechercher" on output. The file [[Localization/XLPageTemplate|Localization:XLPageTemplate]] is a good starting point for creating a new XLPage and has most of PmWiki's key phrases already listed in it. %0a%0aIf you create new versions of PmWiki pages in other languages, please consider adding them to the [[PmWiki:PmWiki | main PmWiki site]] so that they can be made available to others in the i18n archives! (Be sure to check out [[Localization/Localization|The Localization Portal]] for further information on effectively internationalizing PmWiki.)%0a%0a->%25note%25 The term "i18n" is commonly used as an abbreviation for the English word "internationalization". The abbreviation is derived from the fact that there are 18 letters between the "i" and the final "n" and few people want to type them all out.%0a%0a!! Enabling "Special" Characters in WikiLinks%0a%0aTo enable "special" characters like for example German umlauts in WikiLinks, it is necessary to configure the server locale to ensure that PmWiki uses the proper character set definition.%0a%0aIf this is not possible due to limited access to the server configuration, PmWiki can be configured to use a specific locale by using the XLPage options (see [[(Localization/XLPageTemplate]]).%0a%0aFor German umlauts, you'd need for example:%0a%0a*%25hlt php%25[@'Locale' => 'deu',@] %3c- for Windows servers, see [[https://docs.microsoft.com/en-us/cpp/c-runtime-library/language-strings|Language strings]]%0a*%25hlt php%25[@'Locale' => 'de_DE',@] %3c- for Linux servers; for the UTF-8 encoding, on some installations you may need to set @@'de_DE.utf8'@@ or @@'de_DE.UTF-8'@@.%0a%0aNote that the locale identifier depends on the operation system and perhaps on the specific installation.%0a%0a[[#notes]]%0a!! Notes%0a%0a%0a>>faq%3c%3c [[#faq]]%0a%0aQ: If my wiki is internationalized by ''@@config.php@@'', how do I revert a specific group to English?%0a%0aA: Use %25hlt php%25[@$XLLangs = array('en');@] in the group's [[ group customization(s)]] file.%0a%0aQ: If my wiki is in English and I want just one page, or group, in Spanish do I say %25hlt php%25[@XLPage('es','PmWikiEs.XLPage');@] in the group or page configuration file?%0a%0aA: Yes, that is usually the best method. If you were doing this with many scattered pages, or with several languages, you might find it easier to maintain if you load the translations all in @@config.php@@ like this:%0a->%25hlt php%25[@%0a XLPage('es','PmWikiEs.XLPage');%0a XLPage('fr','PmWikiFr.XLPage');%0a XLPage('ru','PmWikiRu.XLPage');%0a $XLLangs = array('en');@]%0a%0aA: Then in each group or page configuration file, you'd just use %25hlt php%25@@$XLLangs = array('es');@@ to set the language to use (in this case, Spanish). Note that though this method is easier to maintain, its somewhat slower because it loads all the dictionaries for each page view, even if they won't be used.%0a%0aQ: What does the first parameter of this function stand for? How can it be used?%0a%0aA: The XLPage mechanism allows multiple sets of translations to be loaded,%0aand the first parameter is used to distinguish them. %0a%0aFor example, suppose I want to have translations for both normal French%0aand "Canadian" French. Rather than maintain two entirely separate sets%0aof pages, I could do:%0a->%25hlt php%25[@%0a XLPage('fr-ca', 'PmWikiFrCa.XLPage');%0a XLPage('fr', 'PmWikiFr.XLPage');@]%0a%0aPmWikiFr.XLPage would contain all of the standard French translations,%0awhile PmWikiFrCA.XLPage would only need to contain "Canada-specific"%0atranslations -- i.e., those that are different from the ones in the%0aFrench page.%0a%0aThe first parameter distinguishes the two sets of translations.%0aIn addition, a ''@@config.php@@'' script can use the $XLLangs variable%0ato adjust the order of translation, so if there was a group or%0apage where I only wanted the standard French translation, I%0acan set%0a%0a-> %25hlt php%25@@$XLLangs = array('fr', 'en');@@%0a%0aand PmWiki will use only the 'fr' and 'en' translations (in that order),%0ano matter how many translations have been loaded with XLPage().%0a%0a[[#xlsdv]]%0aQ: How can I add a translation for an individual string in a PHP file?%0a%0aA: Use the XLSDV() function to provide a translation for a specific (English) string. For instance, with this in @@config.php@@%0a%0a-> %25hlt php%25@@XLSDV('nl', array('my English expression'=>'mijn Nederlandse uitdrukking'));@@%0a%0aany instance of the variable expression [@$[my English expression]@] in wiki mark-up will be displayed as ''my English expression'' in default (English) context, but as ''mijn Nederlandse uitdrukking'' in Dutch (nl) context, i.e. when [@XLPage('nl',...)@] has been called for that page in @@config.php@@ or a cookbook recipe.%0a%0aIf you need to get a translation in a PHP file, use the [@XL()@] function:%0a-> %25hlt php%25@@$local_string = XL("my English expression");@@%0a%0aBut beware: %25hlt php%25@@XLPage()@@ uses @@XLSDV()@@ internally for its translation pairs, too, and only the first definition is accepted! Thus, if the Dutch XLPage already contains a translation and you want to override that, you need to use your @@XLSDV('nl',...)@@ ''before'' calling the correspondent @@XLPage('nl',...)@@. Otherwise, by using @@XLSDV()@@ ''after'' @@XLPage()@@ - e.g. within a recipe that is included later in @@config.php@@ - your translation will only work as long nobody defines 'my English expression' in that XLPage.%0a%0a +time=1671438916 blob - 88de2ae6a0911f73b4ffebaf3187c143822f47ae blob + 95f5f6d5efea44ec4a682a71b2ea484a3ddac697 --- wikilib.d/PmWiki.LayoutVariables +++ wikilib.d/PmWiki.LayoutVariables @@ -1,9 +1,9 @@ -version=pmwiki-2.2.126 ordered=1 urlencoded=1 -author=Petko +version=pmwiki-2.3.18 ordered=1 urlencoded=1 +author=MFWolff charset=UTF-8 -csum=$EnableAutoSkinList, $PageSkinList: see Skins:SkinChange. (+380) +csum=typo (-2) name=PmWiki.LayoutVariables -rev=140 -targets=PmWiki.LayoutVariables,PmWiki.BasicVariables,PmWiki.PageDirectives,PmWiki.PageHistory,PmWiki.WikiStyles,PmWiki.SkinTemplates,PmWiki.WikiGroup,PmWiki.Questions,Cookbook.RecentUploadsLog,PmWiki.CustomWikiStyles,Cookbook.LocalCSS,PmWiki.TableOfContents,Cookbook.ToggleNext,PmWiki.PathVariables,PmWiki.Tables,PITS.00638,Cookbook.RowspanInSimpleTables,PmWiki.TableDirectives,PmWiki.Skins,Skins.SkinChange,PmWiki.OtherVariables,PmWiki.EditVariables -text=(:Summary:variables that control page layout:)%0aVariable substitutions in the skin template are all managed by the `FmtPageName() function from pmwiki.php. Pmwiki variable substitutions available on pages are managed by the {$var} substitutions from stdmarkup.php or superseded in local/config files. %0a%0a:$ActionSkin:This array is used to override the current skin when performing a given action. The most common use is to set @@$ActionSkin['print']='foo'@@ to use the 'foo' skin when printing, regardless of what the @@$Skin@@ variable is set to.%0a%0a:$WikiTitle:A variable which contains the Wiki title as displayed in the browser tab and at the top of the browser window.%0a%0a:$EnablePageTitlePriority:A variable defining how to treat multiple @@ [=(:title ...:)=] @@ [[page directives]] (added in PmWiki 2.2.9).%0a: : @@$EnablePageTitlePriority = 0;@@ # PmWiki default, last encountered title wins (the title may be changed from included pages or GroupFooter).%0a: : @@$EnablePageTitlePriority = 1;@@ # First title wins; if a title is defined in the page, directives from included pages cannot change it.%0a%0a:$EnableDiffInline:If set to 0, this variable switches off the word-level highlighting on the markup in the [[page history]].%0a: : @@$EnableDiffInline = 0;@@ # Disable colors, show plain text differences%0a%0a:$EnableRCDiffBytes:If set to 1, (All)RecentChanges pages will display the difference in bytes of the page content from the previous version like %25diffmarkup%25{+(+123)+} or {-(-42)-}%25%25%0a: : @@$EnableRCDiffBytes = 1;@@ # Show bytes difference from previous version%0a%0a: : The colors are the same as those in the page history; if your skin doesn't provide them, add to ''pub/css/local.css'' something like:%0a%0a-->[@%0a.diffmarkup { font-family: monospace; font-size: 0.9em; } %0a.diffmarkup del { background: #ff9; text-decoration: none; }%0a.diffmarkup ins { background: #9f9; text-decoration: none; }@]%0a%0a:$EnableHighlight:If set to 1, enables compatibility with the [[https://github.com/highlightjs/highlight.js|highlight.js]] library to highlight program code. In addition, you need to include the library and mark your code blocks with the wikistyle [@%25highlight%25@], see [[WikiStyles#highlight]].%0a%0a:$HTMLTagAttr:A string containing attributes of the @@%3chtml...>@@ tag in the skin template, default empty. For example, to add a "lang" attribute, set in config.php: [@%0a$HTMLTagAttr = 'lang="en" xml:lang="en"';@]%0a: : For this variable to work in a custom skin, add it in the template file, for example:[@%0a%3chtml xmlns="http://www.w3.org/1999/xhtml" $HTMLTagAttr>@]%0a%0a:$HTMLStylesFmt:An array of CSS statements to be included in the page's output along with other HTML headers. This array provides an easy place for scripts to add custom CSS statements.%0a%0a:$HTMLHeaderFmt:An array of HTML text to be included in the page's %3chead> section, at the point where the [[skin template(s)]] specifies a [@%3c!--HTMLHeader-->@] directive. This array provides an easy place for scripts to add custom HTML headers.%0a%0a->For example, if you want to specify a logo for all the pages of your wiki (a png image for Firefox (and others...), an ico for Internet Explorer):%0a-->[@ %0a$HTMLHeaderFmt['logo'] =%0a '%3clink href="http://path/to/logo.png" type="image/png" rel="icon" />%0a %3clink href="http://path/to/logo.ico" type="image/x-icon" rel="shortcut icon" />';%0a@]%0a%0a->Another example, if you want to get the RSS notification on some browsers (the RSS icon in Firefox for instance):%0a-->[@ %0a$HTMLHeaderFmt['rss'] =%0a '%3clink rel="alternate" type="application/rss+xml" title="Rss All recent Changes" %0a href="$ScriptUrl/Site/AllRecentChanges?action=rss" />';%0a@]%0a%0a:$HTMLFooterFmt:Like $HTMLHeaderFmt above, this contains an array of HTML text to be included near the end of an HTML document, at the point where the [[skin template(s)]] specifies a [@%3c!--HTMLFooter-->@] directive (usually just before a closing %3c/body> tag). Primarily used by scripts to add custom HTML output after the body of the page output. %0a%0a:$MetaRobots:Sets the value of the [@%3cmeta name='robots' ... />@] tag generated by PmWiki to control search engine robots accessing the site. PmWiki's default setting tells robots to not index anything but the normal page view, and to not index pages in the PmWiki [[wiki group]]. Explicitly setting $MetaRobots overrides this default.%0a # never index this site%0a $MetaRobots = 'noindex,nofollow';%0a # disable the robots tag entirely%0a $MetaRobots = '';%0a%0a:$MessagesFmt:An array of HTML text to be displayed at the point of any [@(:messages:)@] markup. Commonly used for displaying messages with respect to editing pages.%0a%0a:$RecentChangesFmt:An array specifying the format of the RecentChanges listing.%0a%0a->The key of the array specifies the page where changes will be logged, as in%0a-->[@%0a$RecentChangesFmt['$SiteGroup.AllRecentChanges']%0a@]%0a->The value of the array specifies the format in which the changes will be logged, as in%0a-->[@%0a'* [[{$Group}.{$Name}]] . . . $CurrentTime $[by] $AuthorLink: [=$ChangeSummary=]'%0a@]%0a->Note the two consecutive spaces before the three dots (@@. . .@@). The two spaces separate two parts of the format: the first part doesn't change (e.g. a link to the changed page) and the second part does change (e.g. the date and author of the change). Upon saving a page, PmWiki removes a line that matches the first part and adds a line with the current format before the first line with 2 spaces. This way, any line without two consecutive spaces stays at the top of the recent changes page.%0a%0a->You can use and adapt the following to change the format (put it in config.php):%0a-->[@%0a$RecentChangesFmt['$SiteGroup.AllRecentChanges'] = %0a '* [[{$Group}.{$Name}]] . . . $CurrentTime $[by] $AuthorLink: [=$ChangeSummary=]';%0a$RecentChangesFmt['$Group.RecentChanges'] =%0a '* [[{$Group}/{$Name}]] . . . $CurrentTime $[by] $AuthorLink: [=$ChangeSummary=]';%0a@]%0a%0a->Note that changes made to the format will only affect new edits. In other words, you will need to edit a page for your new format to be visible. Note also that you need to have two spaces between the page name and the other information about the edit.%0a%0a->Also note that this variable has other uses, such as not reporting at all to RecentChanges and AllRecentChanges as found here [[PmWiki:Questions|PmWiki Questions]].%0a%0a:$RecentUploadsFmt:An array specifying the format for uploaded files at the RecentChanges listing. It is similar to $RecentChangesFmt. If enabled, newly uploaded files will be logged to the RecentChanges pages. Default is disabled. See Cookbook:RecentUploadsLog for more information.%0a%0a:$DraftRecentChangesFmt:An array specifying the format of the RecentChanges listing when saving Draft pages.%0a%0a->$RecentChangesFmt is set to $DraftRecentChangesFmt when a Draft page is saved. For example, you could save drafts in a separate Recent Draft Changes page and not list in the normal group's Recent Changes page:%0a-->[@%0a$DraftRecentChangesFmt['$Group.RecentDraftChanges'] =%0a '* [[{$Group}/{$Name}]] . . . $CurrentTime $[by] $AuthorLink: [=$ChangeSummary=]';%0a$DraftRecentChangesFmt['$Group.RecentChanges'] = '';%0a@]%0a%0a:$RCLinesMax:The maximum number of lines to be stored in RecentChanges pages. The default is zero, meaning "no limit".%0a $RCLinesMax = 1000; # maintain at most 1000 recent changes%0a%0a:$PageRedirectFmt:The text to be used when a page is redirected via the [@(:redirect:)@] markup.%0a-->[@%0a$PageRedirectFmt = '%3cp>%3ci>redirected from $FullName%3c/p>';%0a$PageRedirectFmt = '';%0a@]%0a->For display options, see also the FAQ on [[(PmWiki:)PageDirectives(#faq)]].%0a%0a:$WikiStyle:An array which contains the predefined WikiStyles which can be used on a textpage.[[%3c%3c]]See: [[PmWiki.CustomWikiStyles]]%0a%0a:$WikiStyleApply:An array which defines the scope of wiki styling per HTML element. Default settings are:%0a->[@%0a'item' => 'li|dt',%0a'list' => 'ul|ol|dl',%0a'div' => 'div',%0a'pre' => 'pre',%0a'img' => 'img',%0a'block' => 'p(?!\\sclass=)|div|ul|ol|dl|li|dt|pre|h[1-6]',%0a'p' => 'p(?!\\sclass=)'%0a@]%0a%0a->This defines that we can apply wiki styling on:%0a* LI elements using the ''item'' keyword%0a* UL, OL, DL elements using the ''list'' keyword%0a* etc.%0a%0a->An example of applying scope to an LI element is below. For more information refer to [[PmWiki/WikiStyles#Scope | WikiStyle scope]].%0a(:markup class=horiz:) %0a* %25apply=item red%25Here is a red styled list item%0a* This item would not be styled.%0a(:markupend:)%0a%0a->You can [[PmWiki.WikiStyles#WikiStyleApply | add additional HTML elements to $WikiStyleApply]] to apply wiki styles to other HTML elements. For example to allow styling on table rows, or anchor tags.%0a%0a:$WikiPageCSSFmt: This variable holds a page name where you can add CSS rules applied to specific page patterns (default disabled). See Cookbook:LocalCSS as an example.%0a: : @@$WikiPageCSSFmt = 'Site.LocalCSS';@@ # global Site.LocalCSS page%0a: : @@$WikiPageCSSFmt = '[={$Group}=].LocalCSS';@@ # per-group LocalCSS pages%0a%0a:$WikiPageCSSVars: If a "wiki CSS page" is enabled with $WikiPageCSSFmt, this is an array with global PHP $variables available as pre-processor @variables in that page. By default the array contains: @@'FarmPubDirUrl', 'PubDirUrl', 'Skin', 'action', 'SkinDirUrl'@@.%0a%0a:$EnableSelfWikiPageCSS: If a "wiki CSS page" is enabled with $WikiPageCSSFmt, that specific page doesn't have CSS applied to itself when browsed or edited. In case a grave mistake is made in the styles and the site becomes unusable, this page will still be viewable and editable. People familiar with CSS can set this to 1 and the styles will be applied to the page itself, also in "Preview" mode:%0a: : @@$EnableSelfWikiPageCSS = 1; #@@ Apply styles to the "wiki CSS page" itself%0a%0a:$PmTOC: Enable and configure the built-in table of contents, see [[Table of contents]] (TOC).%0a: : @@$PmTOC['Enable'] = 1; @@ # Enable TOC; default is 0 (disabled).%0a%0a:$ToggleNextSelector: A CSS selector to enable interactive toggling of hidden sections, see Cookbook:ToggleNext. By default it is disabled.%0a%0a:$MaxIncludes:Controls the number of times that pages can be included via the [@(:include:)@] and other directives, used to control recursion and otherwise pose a sanity check on page contents. $MaxIncludes defaults to 50, but can be set to any value by the wiki administrator.%0a $MaxIncludes = 50; # default%0a $MaxIncludes = 1000; # allow lots of includes%0a $MaxIncludes = 0; # turn off includes%0a%0a:$Skin:Lists the name(s) of skins to load, unless overridden by $ActionSkin. Normally $Skin contains a single string which is the name of a skin directory, but it may also be an array of names, in which case the first skin found from the list is used.%0a%0a:$SkinDirUrl:Set by ''scripts/skins.php'' to be the base url of the current skin's directory (i.e., within a 'pub/skins/' directory). This variable is typically used inside of a skin .tmpl file to provide access to .css files and graphic images associated with the skin.%0a%0a:$SkinLibDirs:An array which, given the filesystem path (array key) to a skin (or a directory containing several skins), provides the corresponding URL (array value).%0a%0a->The array key is the directory containing the skin.tmpl and skin.php files, as seen by the PmWiki program. It does not have to be publicly accessible.%0a%0a-> The value is the URL (web address) of the directory containing the .css, .gif, and other files which appear in the HTML code sent by PMWiki to the browser. This directory must be publicly accessible.%0a%0a->By default $SkinLibDirs is set to:\\%0a[@%0a$SkinLibDirs = array(%0a "./pub/skins/\$Skin" => "$PubDirUrl/skins/\$Skin",%0a "$FarmD/pub/skins/\$Skin" => "$FarmPubDirUrl/skins/\$Skin");%0a@]%0a%0a->Extra details: When PMWiki is searching for a skin it looks for a directory named for the skin in the array index/keys, and if it finds it then it will use the files in that directory and also the files in the matching array value url. The two sides normally point to the same publicly accessible directory, but they do not have to.%0a%0a:$SkinTemplateIncludeLevel: how many levels of inclusion are allowed for [[skin templates]] with the [@%3c!--IncludeTemplate:...-->@] directive. By default this directive is disabled. Setting it to 1 allows one level of inclusions, setting it to 2 allows included templates to include more templates. There can be up to 10 levels of inclusion. This variable can be defined either in local/config.php or in pub/skins/skinname/skinname.php (with SDV):[@%0a # in config.php, allow one level of inclusions%0a $SkinTemplateIncludeLevel = 1; %0a%0a # in skinname.php, allow 3 levels of inclusions%0a SDV($GLOBALS['SkinTemplateIncludeLevel'], 3); %0a@]%0a%0a:$PageLogoUrl: is the url that refers to a logo image which most skins display somewhere in the page's header (top left usually).%0a%0a:$EnablePathInfo:Changes the handling of the page URL. When set to @@1@@ page URL will be @@...wiki.php/Main/Main@@, when set to @@0@@ (default) it will be @@...wiki.php?n=Main.Main@@.%0a%0a:$EnableFixedUrlRedirect:When PmWiki is given a partial page name (e.g., just the name of a WikiGroup), it uses $PagePathFmt in order to make a complete page name from the partial one, then issues a "redirect" to the browser to tell it to reload the page with the correct full page name. Setting $EnableFixedUrlRedirect=0; blocks the redirect, so that PmWiki continues processing with the adjusted page name rather than issuing the redirect. %0a%0a:$GroupHeaderFmt:Defines the markup placed at the top of every page. Default value is:%0a [=$GroupHeaderFmt = '(:include {$Group}.GroupHeader self=0 basepage={*$FullName}:)(:nl:)';=]%0a%0a:$GroupPrintHeaderFmt:Defines the markup placed at the top of every page when [@action=print@]. Default value is:%0a [=SDV($GroupPrintHeaderFmt,'(:include $Group.GroupPrintHeader basepage={*$FullName}:)(:nl:)');=]%0a%0a:$GroupFooterFmt:Defines the markup placed at the bottom of every page. Default value is:%0a [=$GroupFooterFmt = '(:nl:)(:include {$Group}.GroupFooter self=0 basepage={*$FullName}:)';=]%0a%0a:$GroupPrintFooterFmt:Defines the markup placed at the bottom of every page when [@action=print@]. Default value is:%0a [=SDV($GroupPrintFooterFmt,'(:nl:)(:include $Group.GroupPrintFooter basepage={*$FullName}:)');=]%0a%0a:$PageNotFoundHeaderFmt:Specifies the HTTP header to send when attempting to browse a page that doesn't exist. Some webserver packages (notably Microsoft's "Personal Web Server") require that this variable be changed in order to work.%0a%0a-->[@%0a# default%0a$PageNotFoundHeaderFmt = 'HTTP/1.1 404 Not Found';%0a# return all pages as found%0a$PageNotFoundHeaderFmt = 'HTTP/1.1 200 Ok';%0a@]%0a%0a->Beware when expecting to return the content of a Group(header|footer) for an non existent page! By default PmWiki returns 404 (because the page does not exist), despite there is some content to show. Firefox shows the content, while Internet Explorer displays its default 404 page. $PageNotFoundHeaderFmt MUST be set to return 200 as described above in order to get the expected behaviour with all browsers.%0a%0a:$HTMLVSpace:Setting [@$HTMLVSpace = '';@] in a local customizationfile (e.g., [@local/config.php@]) prevents insertion of spacer paragraphs ([@%3cp class='vspace'>%3c/p>@]) in generated HTML code. To limit this change to a single skin, place the [@$HTMLVSpace = '';@] statement in a skin.php file, preceded by the statement [@global $HTMLVSpace;@].%0a%0a:$HTMLPNewline:This variable allows to enable linebreaks by default, i.e. without having the directive [=(:linebreaks:)=] in a page or in a GroupHeader. To enable line breaks, add to config.php such a line:\\%0a @@$HTMLPNewline = '%3cbr/>'; @@%0a%0a:$SimpleTableDefaultClassName:This variable can contain a CSS classname to be used for [[tables|simple tables]], if a "class=" attribute is not defined in the wiki page (default unset):\\%0a@@ $SimpleTableDefaultClassName = "wikisimpletable";@@\\%0aSee for sample code PITS:00638.%0a%0a:$EnableSimpleTableRowspan:If set to 1, will enable features replicating the recipe Cookbook:RowspanInSimpleTables (default disabled).\\%0a@@ $EnableSimpleTableRowspan = 1; @@ # See [[Cookbook:RowspanInSimpleTables|recipe]]%0a%0a:$EnableSortable:Set this variable to 1 to enable sortable tables, see [[Tables#sortable]] (default disabled):[@%0a$EnableSortable = 1; # Enable sortable tables@]%0a%0a:$TableCellAttrFmt:For [[Tables]], defines the HTML attributes given to each @@%3ctd>@@ or @@%3cth>@@ cell in the output. Can contain references to $TableCellCount which holds the horizontal column number of the current cell.%0a%0a:$TableCellAlignFmt:For [[Tables]], defines the HTML attributes for alignment of each @@%3ctd>@@ or @@%3cth>@@ cell. Default is @@" align='%25s'"@@ where %25s will be replaced with 'center', 'left' or 'right'. For a valid HTML5 output you may want to change this in config.php:\\%0a@@$TableCellAlignFmt = " class='%25s'";@@\\%0athen define the CSS classes td.center, td.right and td.left (also th).%0a%0a:$TableRowAttrFmt:For [[Tables]], defines the HTML attributes given to each @@%3ctr>@@ element in the output. Can contain references to $TableRowCount to give the absolute row number within the table, or $TableRowIndex to provide a repeating row index from 1 to $TableRowIndexMax.%0a # Give each row a unique CSS class based on row number (tr1, tr2, tr3, ... )%0a $TableRowAttrFmt = "class='tr\$TableRowCount'";%0a # Give each row alternating CSS classes (ti1, ti2, ti1, ti2, ti1, ... )%0a $TableRowIndexMax = 2;%0a $TableRowAttrFmt = "class='ti\$TableRowIndex'";%0a%0a:$TableRowIndexMax:The maximum value for $TableRowIndex in [[Tables]].%0a # Set rows indexes as 1, 2, 3, 1, 2, 3, 1, 2, ...%0a $TableRowIndexMax = 3;%0a%0a:$EnableTableAutoValignTop:[[TableDirectives|Advanced tables]] are intended for layout, and automatically insert the @@valign='top'@@ attribute if there is no @@valign@@ attribute defined in the markup source. Setting this variable to 0 in config.php will prevent the automatic addition.%0a $EnableTableAutoValignTop = 0; # disable automatic valign='top' attr%0a%0a:$EnableAutoSkinList:This variable enables the change of the [[PmWiki/skins|skin]] from the URL to any skin available on the wiki installation. See also $PageSkinList and Skins:SkinChange.%0a%0a:$PageSkinList:This is an array of allowed skins that can be changed by the visitor with @@?skin=@@ or @@?setskin=@@ URL query to the wiki. See also $EnableAutoSkinList and Skins:SkinChange.%0a%0a:$FmtV['$TableCellCount']:PMWiki internal variable - Horizontal column number of the current cell. For use in $TableCellAttrFmt and $TableRowAttrFmt. Administrators can use in $TableCellAttrFmt and/or $TableRowAttrFmt.%0a [@Example: $TableCellAttrFmt = 'class=col\$TableCellCount';@] %0a%0a:$FmtV['$TableRowCount']:PMWiki internal variable - Current row number. Administrators can use in $TableCellAttrFmt and/or $TableRowAttrFmt.%0a [@Example: TableRowAttrFmt = "class='row\$TableRowCount'";@] %0a%0a:$FmtV['$TableRowIndex']:PMWiki internal variable - Row index number derived from $TableRowIndexMax. (1,2,3,1,2,3,...). Administrators can use in $TableCellAttrFmt and/or $TableRowAttrFmt.%0a [@Example: $TableRowAttrFmt = "class='ind\$TableRowIndex'";@]%0a%0aSee also: [[Edit Variables]]%0a -time=1584989708 +rev=169 +targets=PmWiki.LayoutVariables,PmWiki.BasicVariables,PmWiki.PageDirectives,PmWiki.PageHistory,Cookbook.LocalTimes,Cookbook.PmSyntax,Cookbook.CustomSyntax,PmWiki.WikiStyles,PmWiki.SkinTemplates,PmWiki.WikiGroup,PmWiki.Questions,Cookbook.CustomRecentChanges,Cookbook.RecentUploadsLog,PmWiki.CustomWikiStyles,Cookbook.LocalCSS,PmWiki.TableOfContents,Cookbook.ToggleNext,PmWiki.PathVariables,PmWiki.Tables,PITS.00638,Cookbook.RowspanInSimpleTables,PmWiki.TableDirectives,PmWiki.Skins,Skins.SkinChange,PmWiki.OtherVariables,PmWiki.EditVariables +text=(:Summary:variables that control page layout:)%0aVariable substitutions in the skin template are all managed by the %25hlt php%25@@`FmtPageName()@@ %25%25function from @@pmwiki.php@@. Pmwiki variable substitutions available on pages are managed by the {$var} substitutions from @@stdmarkup.php@@ or superseded in @@local/config@@ files. %0a%0a:$ActionSkin:This array is used to override the current skin when performing a given action. The most common use is to set %25hlt php%25@@$ActionSkin['print']='foo'@@ to use the 'foo' skin when printing, regardless of what the @@$Skin@@ variable is set to.%0a%0a:$WikiTitle:A variable which contains the Wiki title as displayed in the browser tab and at the top of the browser window, e.g. "{$WikiTitle}"%0a%0a:$EnablePageTitlePriority:A variable defining how to treat multiple %25pmhlt%25[@(:title ...:)@] [[page directives]] (added in PmWiki 2.2.9).%0a: : %25hlt php%25@@$EnablePageTitlePriority = 0;@@ # PmWiki default, last encountered title wins (the title may be changed from included pages or GroupFooter).%0a: : %25hlt php%25@@$EnablePageTitlePriority = 1;@@ # First title wins; if a title is defined in the page, directives from included pages cannot change it.%0a%0a:$EnableDiffInline:If set to 0, this variable switches off the word-level highlighting on the markup in the [[page history]].%0a: : %25hlt php%25@@$EnableDiffInline = 0;@@ # Disable colors, show plain text differences%0a%0a:$EnableRCDiffBytes:If set to 1, @@(All)RecentChanges@@ pages will display the difference in bytes of the page content from the previous version like %25diffmarkup%25{+(+123)+} or {-(-42)-}%25%25%0a: : %25hlt php%25@@$EnableRCDiffBytes = 1;@@ # Show bytes difference from previous version%0a%0a: : The colors are the same as those in the page history; if your skin doesn't provide them, add to ''@@pub/css/local.css@@'' something like: %25hlt css%25[@%0a.diffmarkup { font-family: monospace; font-size: 0.9em; } %0a.diffmarkup del { background: #ff9; text-decoration: none; }%0a.diffmarkup ins { background: #9f9; text-decoration: none; }@]%0a%0a:$CurrentTime: This variable contains the current date and time formatted with $TimeFmt. It is used in @@RecentChanges@@ (before 2.3.0), and in user signatures.%0a%0a:$CurrentLocalTime: This variable contains the current date and time stamp, saved in @@RecentChanges@@ (since 2.3.0). This time stamp will be saved in the wiki source text in Greenwich Mean Time (UTC/GMT), but will be shown according to $TimeFmt in the timezone of the wiki. When $EnableLocalTimes is enabled, then it will be shown in the visitor's time zone. The same format is also saved in user signatures if $EnableLocalTimes is enabled.%0a%0a:$EnablePmUtils: This variable controls whether the script @@pub/pmwiki-utils.js@@ should be loaded or not. The script contains JavaScript utility functions for the table of contents, the syntax highlighting, the recent changes, and the email obfuscation. By default $EnablePmUtils is 1 (enabled), but its functions should be enabled individually ($EnableLocalTimes, $EnableHighlight, $PmTOC, $LinkFunctions['mailto:']). Set this variable to 0 to disable all these functions.%0a%0a:$EnableLocalTimes: (Default disabled) Enables the rewriting of date and time stamps into the timezone of the visitor, see documentation at Cookbook:LocalTimes. Dates affected are in RecentChanges pages, in page histories, and in user signatures.%0a: : %25hlt php%25@@ $EnableLocalTimes = 2; @@ Enables '''long''' local times, as in MM/DD/YYYY HH:MM:SS.%0a: : %25hlt php%25@@ $EnableLocalTimes = 1; @@ Enables '''compact''' local times, either HH:MM (within 24 hours), MM/DD or DD/MM (within 11 months), and MM/DD/YYYY or DD/MM/YYYY if earlier than 11 months. The long format appears in a tooltip title when the mouse is over the short format.%0a%0a:$EnablePmSyntax: (Not to be confused with $EnableHighlight) When set to 1, enables [[Cookbook:PmSyntax|PmSyntax]], a syntax highlighting for the PmWiki markup language, which makes the documentation easy to read (from 2.3.0). When set to 2, it also enables the experimental syntax highlighting in the basic edit form: %25hlt php%25[@%0a$EnablePmSyntax = 1; # highlight documentation blocks%0a$EnablePmSyntax = 2; # both documentation and edit form%0aif ($action=='edit') $EnablePmSyntax = 2; # only edit form@]%0a%0a:$CustomSyntax:(From 2.3.0) An array where custom rules for syntax highlighting can be defined. See documentation at Cookbook:CustomSyntax.%0a%0a:$EnableHighlight: (Not to be confused with $EnablePmSyntax) If set to 1, enables compatibility with the [[https://github.com/highlightjs/highlight.js|highlight.js]] library to highlight program code. In addition, you need to include the library and mark your code blocks with the wikistyle [@%25highlight%25@], see [[WikiStyles#highlight]].%0a%0a:$HTMLTagAttr:A string containing attributes of the %25hlt html%25@@%3chtml...>@@ tag in the skin template, default empty. For example, to add a "lang" attribute, set in @@config.php@@: %25hlt php%25[@%0a$HTMLTagAttr = 'lang="en" xml:lang="en"';@]%0a: : For this variable to work in a custom skin, add it in the template file, for example:%25hlt html%25[@%0a%3chtml xmlns="http://www.w3.org/1999/xhtml" $HTMLTagAttr>@]%0a%0a:$HTMLStylesFmt:An array of CSS statements to be included in the page's output along with other HTML headers. This array provides an easy place for scripts to add custom CSS statements.%0a%0a:$HTMLHeaderFmt:An array of HTML text to be included in the page's %25hlt html%25@@%3chead>@@ section, at the point where the [[skin template(s)]] specifies a [@%3c!--HTMLHeader-->@] directive. This array provides an easy place for scripts to add custom HTML headers.%0a%0a->For example, if you want to specify a [[Wikipedia:Favicon|favicon]] for all the pages of your wiki (a png image for Firefox (and others...), an ico for Internet Explorer):%0a-->%25hlt php%25[@ %0a$HTMLHeaderFmt['favicon'] =%0a'%3clink href="http://path/to/icon.png" type="image/png" rel="icon" />%0a %3clink href="http://path/to/icon.ico" type="image/x-icon" rel="shortcut icon" />';%0a@]%0a%0a->Another example, if you want to get the RSS notification on some browsers (the RSS icon in Firefox for instance):%0a-->%25hlt php%25[@ %0a$HTMLHeaderFmt['rss'] =%0a'%3clink rel="alternate" type="application/rss+xml" title="Rss All recent Changes" %0a href="$ScriptUrl/Site/AllRecentChanges?action=rss" />';%0a@]%0a%0a->Javascript example%0a-->%25hlt php%25[@%0a$HTMLHeaderFmt['the-javascript'] =%0a'%3cscript>%0a // the javascript code%0a %3c/script>';@]%0a%0a:$HTMLFooterFmt:Like $HTMLHeaderFmt above, this contains an array of HTML text to be included near the end of an HTML document, at the point where the [[skin template(s)]] specifies a %25hlt php%25[@%3c!--HTMLFooter-->@] directive (usually just before a closing @@%3c/body>@@ tag). Primarily used by scripts to add custom HTML output after the body of the page output. %0a%0a:$MetaRobots:Sets the value of the %25hlt php%25[@%3cmeta name='robots' ... />@] tag generated by PmWiki to control search engine robots accessing the site. PmWiki's default setting tells robots to not index anything but the normal page view, and to not index pages in the PmWiki [[wiki group]]. Explicitly setting $MetaRobots overrides this default.%0a--> %25hlt php%25[@# never index this site%0a$MetaRobots = 'noindex,nofollow';%0a# disable the robots tag entirely%0a$MetaRobots = ''; @]%0a%0a:$MessagesFmt:An array of HTML text to be displayed at the point of any %25pmhlt%25[@(:messages:)@] markup. Commonly used for displaying messages with respect to editing pages.%0a%0a:$RecentChangesFmt:An array specifying the format of the RecentChanges listing.%0a%0a->The key of the array specifies the page where changes will be logged, as in%0a-->%25hlt php%25[@%0a$RecentChangesFmt['$SiteGroup.AllRecentChanges']%0a@]%0a->The value of the array specifies the format in which the changes will be logged, as in%0a-->%25pmhlt%25[@%0a'* [[{$Group}.{$Name}]] . . . $CurrentTime $[by] $AuthorLink: [=$ChangeSummary=]'%0a@]%0a->Note the two consecutive spaces before the three dots (@@. . .@@). The two spaces separate two parts of the format: the first part doesn't change (e.g. a link to the changed page) and the second part does change (e.g. the date and author of the change). Upon saving a page, PmWiki removes a line that matches the first part and adds a line with the current format before the first line with 2 spaces. This way, any line without two consecutive spaces stays at the top of the recent changes page.%0a%0a->You can use and adapt the following to change the format (put it in config.php):%0a-->%25hlt php%25[@%0a$RecentChangesFmt['$SiteGroup.AllRecentChanges'] = %0a '* [[{$Group}.{$Name}]] . . . $CurrentTime $[by] $AuthorLink: [=$ChangeSummary=]';%0a$RecentChangesFmt['$Group.RecentChanges'] =%0a '* [[{$Group}/{$Name}]] . . . $CurrentTime $[by] $AuthorLink: [=$ChangeSummary=]';%0a@]%0a-> Since PmWiki 2.3.0, the format uses $CurrentLocalTime by default which shows exactly what $CurrentTime previously showed, but when $EnableLocalTimes is set, will rewrite the time and date in the local format and timezone of the visitor. %0a%0a->Note that changes made to the format will only affect new edits. In other words, you will need to edit a page for your new format to be visible. Note also that you need to have two spaces between the page name and the other information about the edit.%0a%0a->Also note that this variable has other uses, such as not reporting at all to RecentChanges and AllRecentChanges as found here [[PmWiki:Questions|PmWiki Questions]]. More informations on customizing RecentChanges pages here : [[Cookbook/CustomRecentChanges]].%0a%0a:$RecentUploadsFmt:An array specifying the format for uploaded files at the RecentChanges listing. It is similar to $RecentChangesFmt. If enabled, newly uploaded files will be logged to the RecentChanges pages. Default is disabled. See Cookbook:RecentUploadsLog for more information. See also $EnableRecentUploads.%0a%0a:$EnableRecentUploads: When set to 1, and when $RecentUploadsFmt is not set, it enables Recent uploads in a default format, only on the page Site.AllRecentChanges. This was added in 2.3.0 to easily enable the feature with some default settings that may be good enough for many wikis.%0a%0a:$DraftRecentChangesFmt:An array specifying the format of the RecentChanges listing when saving Draft pages.%0a%0a->$RecentChangesFmt is set to $DraftRecentChangesFmt when a Draft page is saved. For example, you could save drafts in a separate Recent Draft Changes page and not list in the normal group's Recent Changes page:%0a-->%25hlt php%25[@%0a$DraftRecentChangesFmt['$Group.RecentDraftChanges'] =%0a '* [[{$Group}/{$Name}]] . . . $CurrentTime $[by] $AuthorLink: [=$ChangeSummary=]';%0a$DraftRecentChangesFmt['$Group.RecentChanges'] = '';%0a@]%0a%0a:$RCLinesMax:The maximum number of lines to be stored in RecentChanges pages. The default is zero, meaning "no limit".%0a $RCLinesMax = 1000; # maintain at most 1000 recent changes%0a%0a:$PageRedirectFmt:The text to be used when a page is redirected via the [@(:redirect:)@] markup.%0a-->%25hlt php%25[@%0a$PageRedirectFmt = '%3cp>%3ci>redirected from $FullName%3c/p>';%0a$PageRedirectFmt = '';%0a@]%0a->For display options, see also the FAQ on [[(PmWiki:)PageDirectives(#faq)]].%0a%0a:$WikiStyle:An array which contains the predefined WikiStyles which can be used on a textpage.[[%3c%3c]]See: [[PmWiki.CustomWikiStyles]]%0a%0a:$WikiStyleApply:An array which defines the scope of wiki styling per HTML element. Default settings are:%0a->%25hlt php%25[@%0a'item' => 'li|dt',%0a'list' => 'ul|ol|dl',%0a'div' => 'div',%0a'pre' => 'pre',%0a'img' => 'img',%0a'block' => 'p(?!\\sclass=)|div|ul|ol|dl|li|dt|pre|h[1-6]',%0a'p' => 'p(?!\\sclass=)'%0a@]%0a%0a->This defines that we can apply wiki styling on:%0a* LI elements using the ''item'' keyword%0a* UL, OL, DL elements using the ''list'' keyword%0a* etc.%0a%0a->An example of applying scope to an LI element is below. For more information refer to [[PmWiki/WikiStyles#Scope | WikiStyle scope]].%0a(:markup class=horiz:) %0a* %25apply=item red%25Here is a red styled list item%0a* This item would not be styled.%0a(:markupend:)%0a%0a->You can [[PmWiki.WikiStyles#WikiStyleApply | add additional HTML elements to $WikiStyleApply]] to apply wiki styles to other HTML elements. For example to allow styling on table rows, or anchor tags.%0a%0a:$WikiPageCSSFmt: This variable holds a page name where you can add CSS rules applied to specific page patterns (default disabled). See Cookbook:LocalCSS as an example.%0a: : %25hlt php%25@@$WikiPageCSSFmt = 'Site.LocalCSS'; # global Site.LocalCSS page@@%0a: : %25hlt php%25@@$WikiPageCSSFmt = '[={$Group}=].LocalCSS'; # per-group LocalCSS pages@@%0a%0a:$WikiPageCSSVars: If a "wiki CSS page" is enabled with $WikiPageCSSFmt, this is an array with global PHP $variables available as pre-processor @variables in that page. By default the array contains: @@'FarmPubDirUrl', 'PubDirUrl', 'Skin', 'action', 'SkinDirUrl'@@.%0a%0a:$EnableSelfWikiPageCSS: If a "wiki CSS page" is enabled with $WikiPageCSSFmt, that specific page doesn't have CSS applied to itself when browsed or edited. In case a grave mistake is made in the styles and the site becomes unusable, this page will still be viewable and editable. People familiar with CSS can set this to 1 and the styles will be applied to the page itself, also in "Preview" mode:%0a: : %25hlt php%25@@$EnableSelfWikiPageCSS = 1; # Apply styles to the "wiki CSS page" itself@@%0a%0a:$PmTOC: Enable and configure the built-in table of contents, see [[Table of contents]] (TOC).%0a: : %25hlt php%25@@$PmTOC['Enable'] = 1; # Enable TOC; default is 0 (disabled).@@%0a%0a:$ToggleNextSelector: A CSS selector to enable interactive toggling of hidden sections, see Cookbook:ToggleNext. By default it is disabled.%0a%0a:$MaxIncludes:Controls the number of times that pages can be included via the %25pmhlt%25[@(:include:)@] and other directives, used to control recursion and otherwise pose a sanity check on page contents. $MaxIncludes defaults to 50, but can be set to any value by the wiki administrator.%0a--> %25hlt php%25[@$MaxIncludes = 50; # default%0a$MaxIncludes = 1000; # allow lots of includes%0a$MaxIncludes = 0; # turn off includes @]%0a%0a:$Skin:Lists the name(s) of skins to load, unless overridden by $ActionSkin. Normally $Skin contains a single string which is the name of a skin directory, but it may also be an array of names, in which case the first skin found from the list is used.%0a%0a:$SkinDirUrl:Set by ''@@scripts/skins.php@@'' to be the base url of the current skin's directory (i.e., within a '@@pub/skins/@@' directory). This variable is typically used inside of a skin @@.tmpl@@ file to provide access to @@.css@@ files and graphic images associated with the skin.%0a%0a:$SkinLibDirs:An array which, given the filesystem path (array key) to a skin (or a directory containing several skins), provides the corresponding URL (array value).%0a%0a->The array key is the directory containing the @@skin.tmpl@@ and @@skin.php@@ files, as seen by the PmWiki program. It does not have to be publicly accessible.%0a%0a-> The value is the URL (web address) of the directory containing the @@.css@@, @@.gif@@, and other files which appear in the HTML code sent by PMWiki to the browser. This directory must be publicly accessible.%0a%0a->By default $SkinLibDirs is set to:%0a--> %25hlt php%25[@%0a$SkinLibDirs = array(%0a "./pub/skins/\$Skin" => "$PubDirUrl/skins/\$Skin",%0a "$FarmD/pub/skins/\$Skin" => "$FarmPubDirUrl/skins/\$Skin");%0a@]%0a%0a->Extra details: When PMWiki is searching for a skin it looks for a directory named for the skin in the array index/keys, and if it finds it then it will use the files in that directory and also the files in the matching array value url. The two sides normally point to the same publicly accessible directory, but they do not have to.%0a%0a:$SkinTemplateIncludeLevel: how many levels of inclusion are allowed for [[skin templates]] with the %25hlt html%25[@%3c!--IncludeTemplate:...-->@]%25%25 directive. By default this directive is disabled. Setting it to 1 allows one level of inclusions, setting it to 2 allows included templates to include more templates. There can be up to 10 levels of inclusion. This variable can be defined either in @@local/config.php@@ or in @@pub/skins/skinname/skinname.php@@ (with SDV):%25hlt php%25[@%0a # in config.php, allow one level of inclusions%0a $SkinTemplateIncludeLevel = 1; %0a%0a # in skinname.php, allow 3 levels of inclusions%0a SDV($GLOBALS['SkinTemplateIncludeLevel'], 3); %0a@]%0a%0a:$PageLogoUrl: is the url that refers to a logo image which most skins display somewhere in the page's header (top left usually), e.g. "{$PageLogoUrl}"%0a%0a:$EnablePathInfo:Changes the handling of the page URL. When set to @@1@@ page URL will be @@...wiki.php/Main/Main@@, when set to @@0@@ (default) it will be @@...wiki.php?n=Main.Main@@.%0a%0a:$EnableFixedUrlRedirect:When PmWiki is given a partial page name (e.g., just the name of a WikiGroup), it uses $PagePathFmt in order to make a complete page name from the partial one, then issues a "redirect" to the browser to tell it to reload the page with the correct full page name. Setting %25hlt php%25@@$EnableFixedUrlRedirect=0;@@ blocks the redirect, so that PmWiki continues processing with the adjusted page name rather than issuing the redirect. %0a%0a:$GroupHeaderFmt:Defines the markup placed at the top of every page. Default value is:%0a [=$GroupHeaderFmt = '(:include {$Group}.GroupHeader self=0 basepage={*$FullName}:)(:nl:)';=]%0a%0a:$GroupPrintHeaderFmt:Defines the markup placed at the top of every page when [@action=print@]. Default value is:%0a [=SDV($GroupPrintHeaderFmt,'(:include $Group.GroupPrintHeader basepage={*$FullName}:)(:nl:)');=]%0a%0a:$GroupFooterFmt:Defines the markup placed at the bottom of every page. Default value is:%0a [=$GroupFooterFmt = '(:nl:)(:include {$Group}.GroupFooter self=0 basepage={*$FullName}:)';=]%0a%0a:$GroupPrintFooterFmt:Defines the markup placed at the bottom of every page when [@action=print@]. Default value is:%0a [=SDV($GroupPrintFooterFmt,'(:nl:)(:include $Group.GroupPrintFooter basepage={*$FullName}:)');=]%0a%0a:$PageNotFoundHeaderFmt:Specifies the HTTP header to send when attempting to browse a page that doesn't exist. Some webserver packages (notably Microsoft's "Personal Web Server") require that this variable be changed in order to work.%0a%0a-->%25hlt php%25[@%0a# default%0a$PageNotFoundHeaderFmt = 'HTTP/1.1 404 Not Found';%0a# return all pages as found%0a$PageNotFoundHeaderFmt = 'HTTP/1.1 200 Ok';%0a@]%0a%0a->Beware when expecting to return the content of a Group(header|footer) for an non existent page! By default PmWiki returns 404 (because the page does not exist), despite there is some content to show. Firefox shows the content, while Internet Explorer displays its default 404 page. $PageNotFoundHeaderFmt MUST be set to return 200 as described above in order to get the expected behaviour with all browsers.%0a%0a:$HTMLVSpace:Setting %25hlt php%25[@$HTMLVSpace = '';@]%25%25 in a local customizationfile (e.g., [@local/config.php@]) prevents insertion of spacer paragraphs (%25hlt html%25[@%3cp class='vspace'>%3c/p>@]%25%25) in generated HTML code. To limit this change to a single skin, place the %25hlt php%25[@$HTMLVSpace = '';@] statement in a @@skin.php@@ file, preceded by the statement %25hlt php%25[@global $HTMLVSpace;@].%0a%0a:$HTMLPNewline:This variable allows to enable linebreaks by default, i.e. without having the directive %25pmhlt%25[@(:linebreaks:)@] in a page or in a GroupHeader. To enable line breaks, add to @@config.php@@ such a line:\\%0a %25hlt php%25@@$HTMLPNewline = '%3cbr/>'; @@%0a%0a:$SimpleTableDefaultClassName:This variable can contain a CSS classname to be used for [[tables|simple tables]], if a "class=" attribute is not defined in the wiki page (default unset):\\%0a%25hlt php%25@@ $SimpleTableDefaultClassName = "wikisimpletable";@@\\%0aSee for sample code PITS:00638.%0a%0a:$EnableSimpleTableRowspan:If set to 1, will enable features replicating the recipe Cookbook:RowspanInSimpleTables (default disabled).\\%0a@@ $EnableSimpleTableRowspan = 1; @@ # See [[Cookbook:RowspanInSimpleTables|recipe]]%0a%0a:$EnableSortable:Set this variable to 1 to enable sortable tables, see [[Tables#sortable]] (default disabled):%25hlt php%25[@%0a$EnableSortable = 1; # Enable sortable tables@]%0a%0a:$TableCellAttrFmt:For [[Tables]], defines the HTML attributes given to each @@%3ctd>@@ or @@%3cth>@@ cell in the output. Can contain references to $TableCellCount which holds the horizontal column number of the current cell.%0a%0a:$TableCellAlignFmt:For [[Tables]], defines the HTML attributes for alignment of each @@%3ctd>@@ or @@%3cth>@@ cell. Default is @@" align='%25s'"@@ where %25s will be replaced with 'center', 'left' or 'right'. For a valid HTML5 output you may want to change this in @@config.php@@:\\%0a%25hlt php%25@@$TableCellAlignFmt = " class='%25s'";@@\\%0athen define the CSS classes td.center, td.right and td.left (also th).%0a%0a:$TableRowAttrFmt:For [[Tables]], defines the HTML attributes given to each @@%3ctr>@@ element in the output. Can contain references to $TableRowCount to give the absolute row number within the table, or $TableRowIndex to provide a repeating row index from 1 to $TableRowIndexMax.%0a-> %25hlt php%25[@# Give each row a unique CSS class based on row number (tr1, tr2, tr3, ... )%0a$TableRowAttrFmt = "class='tr\$TableRowCount'";%0a# Give each row alternating CSS classes (ti1, ti2, ti1, ti2, ti1, ... )%0a$TableRowIndexMax = 2;%0a$TableRowAttrFmt = "class='ti\$TableRowIndex'"; @]%0a%0a:$TableRowIndexMax:The maximum value for $TableRowIndex in [[Tables]].%0a-> %25hlt php%25[@# Set rows indexes as 1, 2, 3, 1, 2, 3, 1, 2, ...%0a$TableRowIndexMax = 3; @]%0a%0a:$EnableTableAutoValignTop:[[TableDirectives|Advanced tables]] are intended for layout, and automatically insert the @@valign='top'@@ attribute if there is no @@valign@@ attribute defined in the markup source. Setting this variable to 0 in config.php will prevent the automatic addition.%0a-> %25hlt php%25@@$EnableTableAutoValignTop = 0; # disable automatic valign='top' attr@@%0a%0a:$EnableAutoSkinList:This variable enables the change of the [[PmWiki/skins|skin]] from the URL to any skin available on the wiki installation. See also $PageSkinList and Skins:SkinChange.%0a%0a:$PageSkinList:This is an array of allowed skins that can be changed by the visitor with @@?skin=@@ or @@?setskin=@@ URL query to the wiki. See also $EnableAutoSkinList and Skins:SkinChange.%0a%0a:$FmtV['$TableCellCount']:PMWiki internal variable - Horizontal column number of the current cell. For use in $TableCellAttrFmt and $TableRowAttrFmt. Administrators can use in $TableCellAttrFmt and/or $TableRowAttrFmt.%0a-> Example: %25hlt php%25@@$TableCellAttrFmt = 'class=col\$TableCellCount';@@ %0a%0a:$FmtV['$TableRowCount']:PMWiki internal variable - Current row number. Administrators can use in $TableCellAttrFmt and/or $TableRowAttrFmt.%0a-> Example: %25hlt php%25@@TableRowAttrFmt = "class='row\$TableRowCount'";@@%0a%0a:$FmtV['$TableRowIndex']:PMWiki internal variable - Row index number derived from $TableRowIndexMax. (1,2,3,1,2,3,...). Administrators can use in $TableCellAttrFmt and/or $TableRowAttrFmt.%0a-> Example: %25hlt php%25@@$TableRowAttrFmt = "class='ind\$TableRowIndex'";@@%0a%0aSee also: [[Edit Variables]]%0a +time=1673862084 blob - 4431d7bd48d7697a29b14259c891b3fc61327f0a blob + acfdad366084d96144c603569245098f31490cda --- wikilib.d/PmWiki.LinkVariables +++ wikilib.d/PmWiki.LinkVariables @@ -1,9 +1,9 @@ -version=pmwiki-2.2.119 ordered=1 urlencoded=1 +version=pmwiki-2.2.133 ordered=1 urlencoded=1 author=Petko charset=UTF-8 -csum=grammar +csum=";" missing (+1) name=PmWiki.LinkVariables -rev=73 +rev=75 targets=PmWiki.LinkVariables,PmWiki.Links,PmWiki.PageVariables,Cookbook.PagePaths,PmWiki.BasicVariables,PmWiki.InterMap,Cookbook.DotsInLinks,PmWiki.PageDirectives,Category.PmWikiDeveloper -text=(:Summary:variables that control the display of links in pages:)%0a(:Audience: admins (advanced):)%0a:$EnableLinkPageRelative:When enabled, causes PmWiki to use relative urls for page links instead of absolute urls.%0a $EnableLinkPageRelative = 1;%0a%0a:$EnableLinkPlusTitlespaced: When enabled, a [[links|link]] written like [@[[Name|+]]@] will display the "Spaced Title". Default is to display the "Title" of the page. See the page [[PageVariables]] for [@{$Title}@] and [@{$Titlespaced}@].%0a%0a:$PagePathFmt: This array lists the order in which PmWiki looks for the page that you ''most likely'' are attempting to link to. The default is listed below. Look at Cookbook:PagePaths for some ideas.%0a [=array('{$Group}.$1', '$1.$1', '$1.{$DefaultName}')=]%0a%0a:$LinkPageExistsFmt:The (HTML) string to output for links to already existing wiki pages. Defaults to %0a [=%3ca class='wikilink' href='\$LinkUrl'>\$LinkText%3c/a>=]%0a%0a:$LinkPageCreateFmt:The (HTML) string to output for links to non-existent wiki pages. The default is to add a '?' after the link text with a link to the page edit/create form. Defaults to%0a [=%3ca class='createlinktext' href='\$PageUrl?action=edit'>\$LinkText%3c/a>=]%0a [=%3ca class='createlink' href='\$PageUrl?action=edit'>?%3c/a>=]%0a%0a:$LinkPageCreateSpaceFmt:Same as $LinkPageCreateFmt, but used when the link text has a space in it. %0a%0a:$LinkPageSelfFmt:The (HTML) string to output for self-referencing links (i.e. links to the page itself). Defaults to%0a [=%3ca class='selflink' href='\$LinkUrl'>\$LinkText%3c/a>=]%0a%0a:$LinkCategoryFmt:The (HTML) string to output for links to wiki category pages. Defaults to %0a [=%3ca class='categorylink' href='\$LinkUrl'>\$LinkText%3c/a>=]%0a%0a%0a:$UrlLinkFmt:The (HTML) string to output for URL-links that begin with 'http:', 'ftp:', etc. Defaults to%0a [=%3ca class='urllink' href='\$LinkUrl' title='\$LinkAlt' rel='nofollow'>\$LinkText%3c/a>=]%0a%0a:$IMapLinkFmt: an array of link formats for various link "schemes". Not set as default.%0a->Examples of custom formats to allow different styling via classes: %0a->Links to http: standard url links:%0a [= $IMapLinkFmt['http:'] = "%3ca class='httplink urllink' href='\$LinkUrl'>\$LinkText%3c/a>"; =] %0a->Links to https: secure pages:%0a [= $IMapLinkFmt['https:'] = "%3ca class='httpslink urllink' href='\$LinkUrl'>\$LinkText%3c/a>"; =] %0a->Links to PmWiki: InterMap shortcut:%0a [= $IMapLinkFmt['PmWiki:'] = "%3ca class='pmwikilink urllink' href='\$LinkUrl'>\$LinkText%3c/a>";=]%0a%0a:$AddLinkCSS:An array of additional custom link CSS classes, that are added to the link format $UrlLinkFmt, $IMapLinkFmt or $LinkPageExistsFmt. Currently can have 2 elements:\\%0a@@$AddLinkCSS['othergroup'] = "''crossgroup''";@@ # add "''crossgroup''" class to wikilinks to other wikigroups\\%0a@@$AddLinkCSS['samedomain'] = "''currentsite''";@@ # add "''currentsite''" class to URL or Path links to resources on the same domain.%0a%0a:$InterMapFiles:An array consisting a list of files and pages containing [[InterMap]] entries to be loaded.%0a%0a:$MakePageNameFunction:Name of a custom function to replace `MakePageName(), which converts strings into valid page names.%0a%0a:$MakePageNamePatterns: $MakePageNamePatterns is an array of regular expression replacements that is used to map the page link in a ''free link'' such as [@[[free link]]@] into a page name. Currently the default sequence is: [@%0a "/'/" => '', # strip single-quotes%0a "/[^$PageNameChars]+/" => ' ', # convert to spaces characters not allowed in pagenames%0a '/((^|[^-\\w])\\w)/' => 'cb_toupper', # capitalize 1st letter of words%0a '/ /' => '' # remove spaces%0a@]%0a: :Note that if you change $MakePageNamePatterns, the documentation links may break. This can be fixed by re-setting $MakePageNamePatterns to the default in local/PmWiki.php.%0a%0a:$MakePageNameSplitPattern:See Cookbook:DotsInLinks.%0a%0a:$WikiWordCountMax:The maximum number of times to convert each WikiWord encountered on a page. Defaults to 1,000,000. Common settings for this variable are zero (disable WikiWord links) and one (convert only the first occurrence of each WikiWord).%0a $WikiWordCountMax = 0; # disable WikiWord links%0a $WikiWordCountMax = 1; # convert only first WikiWord%0a%0a:$WikiWordCount:An array that allows the number of WikiWord conversions to be set on a per-WikiWord basis. The default is to use $WikiWordCountMax unless a value is set in this array. By default PmWiki sets @@$WikiWordCount['PmWiki']=1@@ to limit the number of conversions of "PmWiki".%0a $WikiWordCount[=['PhD']=0; # Don't convert "PhD"=]%0a $WikiWordCount['WikiWord']=5; # Convert WikiWord 5 times%0a # the following lines keep a page from linking to itself%0a $title = [=FmtPageName=]('$Title_',$pagename);%0a $WikiWordCount[$title]=0; %0a %0a:$EnableRedirectQuiet:Enable the @@quiet=1@@ parameter for the [[PmWiki.PageDirectives#redirect|redirect directive]]. On publicly edited wikis it is advisable not to enable quiet redirects.%0a $EnableRedirectQuiet = 0; # disable quiet redirects (default)%0a $EnableRedirectQuiet = 1; # enable quiet redirects%0a%0a:$QualifyPatterns:An array of regular expression replacements applied when text from one page is included in another, used by the function Qualify(). The two default patterns rewrite links like [@[[Page]]@] into [@[[Group/Page]]@], and page (text) variables like [@{$Title}@] into [@{Group.Page$Title}@] so that they work the same way in the source page and in the including page.%0a%0aCategories: [[!PmWiki Developer]] -time=1570179145 +text=(:Summary:variables that control the display of links in pages:)%0a(:Audience: admins (advanced):)%0a:$EnableLinkPageRelative:When enabled, causes PmWiki to use relative urls for page links instead of absolute urls.%0a $EnableLinkPageRelative = 1;%0a%0a:$EnableLinkPlusTitlespaced: When enabled, a [[links|link]] written like [@[[Name|+]]@] will display the "Spaced Title". Default is to display the "Title" of the page. See the page [[PageVariables]] for [@{$Title}@] and [@{$Titlespaced}@].%0a%0a:$PagePathFmt: This array lists the order in which PmWiki looks for the page that you ''most likely'' are attempting to link to. The default is listed below. Look at Cookbook:PagePaths for some ideas.%0a [=array('{$Group}.$1', '$1.$1', '$1.{$DefaultName}')=]%0a%0a:$LinkPageExistsFmt:The (HTML) string to output for links to already existing wiki pages. Defaults to %0a [=%3ca class='wikilink' href='\$LinkUrl'>\$LinkText%3c/a>=]%0a%0a:$LinkPageCreateFmt:The (HTML) string to output for links to non-existent wiki pages. The default is to add a '?' after the link text with a link to the page edit/create form. Defaults to%0a [=%3ca class='createlinktext' href='\$PageUrl?action=edit'>\$LinkText%3c/a>=]%0a [=%3ca class='createlink' href='\$PageUrl?action=edit'>?%3c/a>=]%0a%0a:$LinkPageCreateSpaceFmt:Same as $LinkPageCreateFmt, but used when the link text has a space in it. %0a%0a:$LinkPageSelfFmt:The (HTML) string to output for self-referencing links (i.e. links to the page itself). Defaults to%0a [=%3ca class='selflink' href='\$LinkUrl'>\$LinkText%3c/a>=]%0a%0a:$LinkCategoryFmt:The (HTML) string to output for links to wiki category pages. Defaults to %0a [=%3ca class='categorylink' href='\$LinkUrl'>\$LinkText%3c/a>=]%0a%0a%0a:$UrlLinkFmt:The (HTML) string to output for URL-links that begin with 'http:', 'ftp:', etc. Defaults to%0a [=%3ca class='urllink' href='\$LinkUrl' title='\$LinkAlt' rel='nofollow'>\$LinkText%3c/a>=]%0a-> All InterMap links default to $UrlLinkFmt, unless there is a specific $IMapLinkFmt entry.%0a%0a:$IMapLinkFmt: an array of link formats for various link "schemes". Not set as default.%0a->Examples of custom formats to allow different styling via classes: %0a->Links to http: standard url links:%0a [= $IMapLinkFmt['http:'] = "%3ca class='httplink urllink' href='\$LinkUrl'>\$LinkText%3c/a>"; =] %0a->Links to https: secure pages:%0a [= $IMapLinkFmt['https:'] = "%3ca class='httpslink urllink' href='\$LinkUrl'>\$LinkText%3c/a>"; =] %0a->Links to PmWiki: InterMap shortcut:%0a [= $IMapLinkFmt['PmWiki:'] = "%3ca class='pmwikilink urllink' href='\$LinkUrl'>\$LinkText%3c/a>";=]%0a->Note that if you have enabled ObfuscateLinkIMap (core function based on DeObMail), the snippet can be customized in:%0a [= $IMapLinkFmt['obfuscate-mailto:'] =]%0a->The default (for ObfuscateLinkIMap) is:%0a [= $IMapLinkFmt['obfuscate-mailto:'] = "%3cspan class='_pmXmail' title=\"\$LinkAlt\">%3cspan class='_t'>\$LinkText%3c/span>%3cspan class='_m'>\$LinkUrl%3c/span>%3c/span>"; =]%0a->The @@ObfuscateLinkIMap@@ logic expects the snippet to have some recognisable properties -- classes, elements, otherwise it may not work. Start with the default snippet, make small modifications, and test if it works.%0a%0a:$AddLinkCSS:An array of additional custom link CSS classes, that are added to the link format $UrlLinkFmt, $IMapLinkFmt or $LinkPageExistsFmt. Currently can have 2 elements:\\%0a@@$AddLinkCSS['othergroup'] = "''crossgroup''";@@ # add "''crossgroup''" class to wikilinks to other wikigroups\\%0a@@$AddLinkCSS['samedomain'] = "''currentsite''";@@ # add "''currentsite''" class to URL or Path links to resources on the same domain.%0a%0a:$InterMapFiles:An array consisting a list of files and pages containing [[InterMap]] entries to be loaded.%0a%0a:$MakePageNameFunction:Name of a custom function to replace `MakePageName(), which converts strings into valid page names.%0a%0a:$MakePageNamePatterns: $MakePageNamePatterns is an array of regular expression replacements that is used to map the page link in a ''free link'' such as [@[[free link]]@] into a page name. Currently the default sequence is: [@%0a "/'/" => '', # strip single-quotes%0a "/[^$PageNameChars]+/" => ' ', # convert to spaces characters not allowed in pagenames%0a '/((^|[^-\\w])\\w)/' => 'cb_toupper', # capitalize 1st letter of words%0a '/ /' => '' # remove spaces%0a@]%0a: :Note that if you change $MakePageNamePatterns, the documentation links may break. This can be fixed by re-setting $MakePageNamePatterns to the default in local/PmWiki.php.%0a%0a:$MakePageNameSplitPattern:See Cookbook:DotsInLinks.%0a%0a:$WikiWordCountMax:The maximum number of times to convert each WikiWord encountered on a page. Defaults to 1,000,000. Common settings for this variable are zero (disable WikiWord links) and one (convert only the first occurrence of each WikiWord).%0a $WikiWordCountMax = 0; # disable WikiWord links%0a $WikiWordCountMax = 1; # convert only first WikiWord%0a%0a:$WikiWordCount:An array that allows the number of WikiWord conversions to be set on a per-WikiWord basis. The default is to use $WikiWordCountMax unless a value is set in this array. By default PmWiki sets @@$WikiWordCount['PmWiki']=1@@ to limit the number of conversions of "PmWiki".%0a $WikiWordCount[=['PhD']=0; # Don't convert "PhD"=]%0a $WikiWordCount['WikiWord']=5; # Convert WikiWord 5 times%0a # the following lines keep a page from linking to itself%0a $title = [=FmtPageName=]('$Title_',$pagename);%0a $WikiWordCount[$title]=0; %0a %0a:$EnableRedirectQuiet:Enable the @@quiet=1@@ parameter for the [[PmWiki.PageDirectives#redirect|redirect directive]]. On publicly edited wikis it is advisable not to enable quiet redirects.%0a $EnableRedirectQuiet = 0; # disable quiet redirects (default)%0a $EnableRedirectQuiet = 1; # enable quiet redirects%0a%0a:$QualifyPatterns:An array of regular expression replacements applied when text from one page is included in another, used by the function Qualify(). The two default patterns rewrite links like [@[[Page]]@] into [@[[Group/Page]]@], and page (text) variables like [@{$Title}@] into [@{Group.Page$Title}@] so that they work the same way in the source page and in the including page.%0a%0aCategories: [[!PmWiki Developer]] +time=1604305719 blob - ec0b5f113290032a60de2fc5a10bd337aa83b3ca blob + 4cb9e8860af24ca620ed620388a40976ecf57638 --- wikilib.d/PmWiki.Links +++ wikilib.d/PmWiki.Links @@ -1,9 +1,9 @@ -version=pmwiki-2.2.129 ordered=1 urlencoded=1 -author=simon +version=pmwiki-2.3.13 ordered=1 urlencoded=1 +author=Petko charset=UTF-8 -csum=links with special characters (+173) +csum=fix signature markup; NEVER suggest modifying pmwiki.php or other core files (-35) name=PmWiki.Links -rev=217 -targets=PmWiki.WikiSandbox,PmWiki.BasicEditing,Main.WikiSandbox,Main.HomePage,PmWiki.WikiWikiWeb,PmWiki.Installation,PmWiki.WikiWord,PmWiki.LinkVariables,PmWiki.Links,PmWiki.InterMap,PmWiki.NonexistentPages,PmWiki.CreatingNewPages,PmWiki.WikiGroup,PmWiki.Categories,Profiles.Author,PmWiki.PageSections,Cookbook.FixURL,Cookbook.DirList,PmWiki.Robots,Cookbook.PopupWindow,Cookbook.DeObMail,Cookbook.AddUrlSchemes,PmWiki.PageLists,PmWiki.LinkSchemes,Cookbook.ExternalLinks,PmWiki.Images,PmWiki.ConditionalMarkup -text=(:Summary:Multiple mechanisms for creating links:)%0a(:Audience: authors (basic) :)%0aA key feature of [[wiki(WikiWeb)]]-based systems is the ease of creating %25newwin%25[[Wikipedia:Hyperlink|hyperlinks]]%25%25 (or short '''links''') in the text of a document. %0aPmWiki provides multiple mechanisms for creating such links.%0a%0a!! [[#links]]Links to other pages in the wiki%0a%0aTo create an internal link to another page, simply enclose the name of the page inside double square brackets, as in [@[[wiki sandbox]]@] or [@[[installation]]@]. This results in links to [[wiki sandbox]] and [[installation]], respectively.%0a%0aPmWiki creates a link by using the text inside the double brackets. It does this by removing spaces between the words, and automatically capitalizing the first letter of each word following spaces or other punctuation (like ~). Thus [@[[Wiki Sandbox]]@], [@[[wiki sandbox]]@], and [@[[WikiSandbox]]@] all display differently but create the same link to the page titled [@WikiSandbox@].%0aOr in other words, PmWiki will automatically create the "link path name" using the page name in ''CamelCase'', but the "link text" will display in the format you have entered it.%0a%0aSome PmWiki sites (default not) will recognize words written in CamelCase, called a [[WikiWord]], automatically as a link to a page of the same name.%0a%0a!!! [[#othertext]]Links with different link text%0a%0aThere are three ways to get a different link text:%0a%0a#'''Hide link text'''. Link text within (parentheses) will not be not displayed, so that [@[[(wiki) sandbox]]@] links to ''[=WikiSandbox=]'' but displays as [[(wiki) sandbox]]. For addresses actually containing parentheses, use %2528 and %2529 [[http://www.example.com/linkwith%2528parenthese%2529]].%0a%0a#'''Change link text'''. You can specify another link text after a vertical brace, as in [@[[WikiSandbox | a play area]]@], or you can use an arrow ([@->@]) to reverse the order of the link text and the target, as in [@[[a play area -> WikiSandbox]]@]. Both links displays as [[a play area -> WikiSandbox]].%0a%0a#'''Show page title instead of page name'''. The use of special characters in the page name is not a problem for PmWiki, but on some servers it may be better to use only plain A-Z letters for the page "name" (which is also a filename), and set the page "title" to the extended or international characters with the [=(:title PageTitle:)=] directive within the page. The page title can be shown instead of the page name with the [@[[PageName|+]]@] link markup, e.g. page [@BasicEditing@] contains the directive [=(:title=] {BasicEditing$Title}:) with the result that a link written as [@[[BasicEditing|+]]@] will display as [[BasicEditing|+]]. [-See also $EnableLinkPlusTitlespaced.-]\\%0aSince PmWiki version 2.2.14 this works also for those technical pages that have an entry in the XLPage, without the need to add the [=(:title PageTitleName:)=] directive within that page (for more details see [[(http://www.pmwiki.org/wiki/)Localization.Localization]]).%0a%0aOn top of above ways, a suffix can be added to the end of a link, which becomes part of the link text but not of the target page name.\\%0a'''Note:''' This feature works with the [@[[PageName|+]]@] markup only since Version 2.2.90.%0a%0a[[#markupheaders]]%0a(:table class='markup horiz' align='center':)%0a(:cellnr class='markup1':)%0a[-'''What to type'''-]%0a(:cell class='markup2':)%0a[-'''What it looks like'''-]%0a(:tableend:)%0a[[#markupheadersend]]%0a%0a(:markup class=horiz:)%0a* [[(wiki) sandbox]]%0a* [[(wiki) sandbox]]es%0a* [[WikiSandbox | wiki sandbox]],%0a* [[WikiSandbox | wiki sandbox]]es%0a* [[BasicEditing | +]]%0a(:markupend:)%0a%0a!!! [[#tooltiptitle]] Links with tool tip%0aFrom version 2.2.14 PmWiki can show tooltip titles with the following format:%0a: '''external link''' : @@[=[[http://pmwiki.org"external tool tip title" | external link ]]=]@@, eg [[http://pmwiki.org"external tool tip title" | external link ]] or [[http://pmwiki.org"external tool tip title" ]]%0a: '''internal link''': @@[=[[Links"internal tool tip title" | internal link ]]=]@@, eg [[Links"internal tool tip title" | internal link ]] or [[Links"internal tool tip title" ]]%0a: '''[[#anchors|Anchor links]]''': @@[=[[#name"anchor tool tip title"|anchor link text]]=]@@ (since Version 2.2.48), eg [[#name"anchor tool tip title"|anchor link text]] or [[#name"anchor tool tip title"]]%0a: '''[[InterMap]] link''' : @@[=[[Wikipedia:Wiki"tool tip title"| InterMap link ]]=]@@, eg [[Wikipedia:Wiki"tool tip title"| InterMap link ]] or [[Wikipedia:Wiki"tool tip title" ]]%0a%0a %0a!!! [[#nonexistent]]Links to nonexistent pages%0a%0aLinks to [[nonexistent pages]] are displayed specially, to invite others to create the page.%0aSee [[Creating new pages]] to learn more.%0a%0a!!! [[#othergroup]]Links to pages in other wiki groups%0a%0aLinks as written above are links between pages of the same group. To create a link to a page in another group, add the name of that other group together with a dot or slash as prefix to the page name. For example, links to [@Main/WikiSandbox@] could be written as:%0a%0a(:include {$FullName}#markupheaders#markupheadersend:)%0a%0a(:markup class=horiz:)%0a* [[Main.WikiSandbox]]%0a* [[Main/WikiSandbox]]%0a* [[(Main.Wiki)Sandbox]]%0a* [[Main.WikiSandbox | link text]]%0a* [[Main.WikiSandbox | +]]%0a(:markupend:)%0a%0aTo link to the "default home page" of a group, the name of the page can be omitted:%0a%0a(:markup class=horiz:)%0a* [[Main.]]%0a* [[Main/]]%0a(:markupend:)%0a%0aSee [[Wiki Group]] to learn more about PmWiki groups.%0a%0a!!! [[#categories]]Category links%0a%0aCategories are a way to organize and find related pages. The idea is that every page that falls into a particular subject area should have a link to a shared page containing links to other pages on that subject. These ''shared pages'' are created in the special group [@Category@], and thus these subject areas are called "categories".%0a%0aAdding a page to the category [@Subject@] is simple by adding the [@[[!Subject]]@] markup somewhere on that page. This will create a link to the page [@Category.Subject@]. So [@[[!Subject]]@] is a kind of link shortcut to the page [@Category.Subject@]. See [[Categories]] to learn more.%0a%0a!!! [[#profiles]]User page links%0a%0aSimilar is [@[[~Author]]@] a link shortcut to the page [@Author@] in the special group [@Profiles@]. PmWiki automatically creates this type of link for the ''current author'', when it encounters three tilde characters ([@~@]) in a row ([@~@][@~@][@~@]) in the page text. The current author is the name found in the "Author" field, when you create or modify a page. The current date and time is appended when four tilde characters in a row are encountered ([@~@][@~@][@~@][@~@]).%0a%0aSo, when the Author field contains "Author":\\%0a[@~@][@~@][@~@] markup will be replaced by: [[~Author]]\\%0a[@~@][@~@][@~@][@~@] markup will be replaced by: [[~Author]] October 10, 2010, at 04:50 PM%0a%0a!!! [[#linkshortcuts]]Link shortcuts%0a%0a'''[@[[PageName|#]]@]''' creates a [[#reference|reference]] link as shown below'^[[#reference|#]]^'.%0a%0a!!! [[#anchors]]Links to specific locations within a page -- "anchors"%0a%0aTo define a location, or bookmark, within a page to which you may jump directly, use the markup [@[[#name]]@]. This creates an "[[http://www.w3.org/TR/html4/struct/links.html#h-12.2.1|anchor]]" that uniquely identifies that location in the page. Then to have a link jump directly to that anchor, use one of%0a%0a* [@[[#name|link text]]@] within the same page, or%0a* [@[[PageName#name]]@] or [@[[PageName#name|link text]]@] for a location on another page%0a* The form [@[[PageName(#name)]]@] may be useful for hiding the anchor text in a link. %0a%0aFor example, here's a link to the [[#intermaps | Intermaps]] section, below. %0a%0aNotes:%0a* %25red%25The anchor itself [[http://www.w3.org/TR/html4/types.html#type-name|must]] begin with a letter%25%25, '''not a number'''.%0a* %25green%25Valid characters for anchor names%25%25 are letters, digits, dash (-), underscore (_), and the period (.).%0a* A link to an anchor must have the '''same capitalization as the anchor''' itself. %0a* Spaces are not allowed in an anchor: "[@[[#my anchor]]@]" won't work, "[@[[#myanchor]]@]" will.%0a* All anchor names in a page should be unique.%0a%0a%0a!!! [[#sections]]Sections%0aWhile in HTML the purpose of [[#anchors|anchors]] is mostly for jumping to a position in the text, in PmWiki they serve an internal purpose, too: Each anchor also creates a section, because sections are defined as the part of the page between their start anchor and the next anchor. %0aFor more details, see [[PmWiki:Page Sections|Page Sections]].%0a%0a%0a!!! [[#actions]]Links to actions%0a%0aTo link to a specific action for the current page use [@[[{$FullName}?action=actionname|linkname]]@].%0a%0aExamples:%0a* [@[[{$FullName}?action=edit|Edit]]@] for editing%0a* [@[[{$FullName}?action=diff|differences]]@] for differences.%0a%0a!! Links outside the wiki%0a[[#externallinks]]%0a!!! Links to external sites ([=URLs=])%0a%0aLinks to external sites simply begin with a prefix such as 'http:', 'ftp:', etc. Thus [@http://google.com/@] and [@[[http://google.com/]]@] both link to Google. As with the above, an author can specify the link text by using the vertical brace or arrow syntax, as in [@[[http://google.com/ | Google]]@] and [@[[Google -> http://google.com]]@].%0a%0aIf the external link includes (parentheses), escape these using [=%2528=] for "(" and [=%2529=] for ")" : %0a(:markup:)[=[[http://en.wikipedia.org/wiki/Wiki_%2528disambiguation%2529 | link to "Wiki (disambiguation)" ]]=]%0a%0aThe recipe Cookbook:FixURL makes it easy to encode parentheses and other special characters in link addresses.%0a%0a!!! Links with special characters%0aTo have any special characters, including quotes, spaces, parentheses and pipes in link addresses escape them using [@[=link address=]@].%0a%0a!!! [[#path]] Links from the wiki to resources on the same website%0a%0aYou can use the [@Path:@] prefix to add links outside of the wiki but on the same website.%0a%0aUse @@[=Path:=]%25blue%25/path/to/resource%25%25@@ with a leading slash for links relative to the website document root as in @@www.example.com%25blue%25/path/to/resource%25%25@@.%0a%0aYou can also define a custom [[InterMap]] prefix to a specific path on your website and use it as a shortcut, for example:%0a%0a Pictures: /assets/pictures/$1%0a%0aThen in a wiki page, use [@Pictures:photo.jpg@] instead of [@Path:/assets/pictures/photo.jpg@] or [@http://www.example.com/assets/pictures/photo.jpg@]%0a%0aSee [[InterMap]] for more information.%0a%0a!!! Links to intranet (local) files%0a%0a'''Not all browsers will follow such links''' (some Internet Explorer versions reportedly follow them). You can link to a file system by including the prefix [@'file:///'@]. So [@file:///S:\ProjPlan.mpp@] and [@[[Shared S drive->file:///S:\]]@] are both valid links. On a Windows file system you may want to use network locations (eg [@file:///\\server1\rootdirectory\subdirectory@]) rather than drive letters which may not be consistent across all users. Not all browsers will follow such links, Internet Explorer does allow them.%0a%0aSee also Cookbook:DirList.%0a%0a!! Link characteristics%0a!!! [[#reference]]Links as References%0a%0aLinks may also be specified as '''References''', so the target appears as an anonymous ''numeric'' reference rather than a ''textual'' reference. The following markup is provided to produce sequential reference numbering within a PmWiki page:%0a%0aFormatting the link as: [@[[http://google.com |#]]@] produces: [[http://google.com |#]] as the link.%0a%0aSubsequent occurrence of the reference link format on the same page will be incremented automatically as per the following example: Entering [@[[http://pmwiki.com |#]]@] produces [[http://pmwiki.com |#]], [@[[#intermaps |#]]@] produces [[#intermaps |#]], and so on for further reference links.%0a%0a!!! [[#intermaps]]Intermaps%0a%0a[[Inter Map]] links are also supported (see [[Inter Map]]). In particular, the [@Path:@] InterMap entry can be used to create links using relative or absolute paths on the current site (e.g., [@Path:../../somedir/foo.html@] or [@Path:/dir/something.gif@]).%0a%0a!!! Links that open a new browser window%0a%0aTo have a link open in another window, use [@%25newwin%25...%25%25@]:%0a%0a* [@%25newwin%25 http://pmichaud.com %25%25@] produces %25newwin%25 http://pmichaud.com %25%25%0a* [@%25newwin%25 [[http://google.com/ | Google]] %25%25@] produces %25newwin%25 [[http://google.com/ | Google]]%25%25%0a* [@%25newwin%25 [[Main.WikiSandbox]] %25%25@] produces %25newwin%25 [[Main.WikiSandbox]]%25%25%0a%0aYou can also specify that links should open in a new window via the @@[=%25target=_blank%25...%25%25=]@@ attribute:%0a%0a(:markup class=horiz:)%0aThe following link %25target=_blank%25 http://pmichaud.com %25%25%0awill open in a new window.%0a(:markupend:)%0a%0a!!! [[#robots]]Links that are not followed by [[(PmWiki:)robots]]%0a%0aPrefix a link with [=%25rel=nofollow%25=] to advise %25newwin rel=nofollow%25[[http://robotstxt.org/|robots]] and [[http://validator.w3.org/checklink|link checkers]]%25%25 not to follow it.%0a%0a%0a!! Links and CSS classes%0a%0aPmWiki automatically gives classes to several types of links. Among other things, this enables you to format each type differently.%0a%0aNote: This may be an incomplete list.%0a:.selflink:A link to the current page. Useful in sidebars to show "you are here".%0a:.wikilink:A link to another page within the wiki.%0a:.urllink:A link to a page outside the wiki.%0a%0a!! Notes%0a%0a'''Note:''' The default behavior of "+" above can be overridden to display the spaced title, rather than simply the title by adding the following to config.php:%0a->[@%0a## [[target |+]] title links%0aMarkup('[[|+', '%3c[[|',%0a "/(?>\\[\\[([^|\\]]+))\\|\\s*\\+\\s*]]/e",%0a "Keep(MakeLink(\$pagename, PSS('$1'),%0a PageVar(MakePageName(\$pagename,PSS('$1')), '\$Titlespaced')%0a ),'L')");%0a@]%0a%0a%0a>>faq%3c%3c [[#faq]]%0a%0aQ: How do I create a link that will open as a new window?%0a%0aA: Use the [@%25newwin%25@] wikistyle, as in:%0a(:markup class=horiz:) [=%25newwin%25 http://example.com/ %25%25=]%0a%0aQ: How do I create a link that will open a new window, and configure that new window?%0a%0aA: This requires javascript. See [[Cookbook:PopupWindow]].%0a%0aQ: How do I place a mailing address in a page?%0a%0aA: Use the [@mailto:@] markup, as in one of the following:%0a%0a(:markup class="horiz":)%0a* mailto:myaddress@example.com%0a* [[mailto:myaddress@example.com]]%0a* [[mailto:myaddress@example.com | email me]]%0a* [[mailto:myaddress@example.com?subject=Some subject | email me]]%0a(:markupend:)%0aThe markup @@[=[[mailto:me@example.=]com?%25red%25cc=%25%25someoneelse@example.com%25red%25&bcc=%25%25else@example.com%25red%25&subject=%25%25Pre-set Subject%25red%25&body=%25%25Pre-set body | display text]] =]@@ lets you specify more parameters like the message body and more recipients (may not work in all browsers and e-mail clients).%0a%0aSee also [[Cookbook:DeObMail]] for information on protecting email addresses from spammers.%0a%0aQ: How can I enable links to other protocols, such as nntp:, ssh:, xmpp:, etc?%0a%0aA: See [[Cookbook:Add Url schemes]] {Cookbook.AddUrlSchemes$:Summary}%0a%0aQ: How do I make a WikiWord link to an external page instead of a WikiPage?%0a%0aA: Use link markup. There are two formats:%0a%0a->[@[[http://example.com/ | WikiWord]]%0a[[WikiWord -> http://example.com/]]@]%0a%0aQ: How do I find all of the pages that link to another page (i.e., backlinks)?%0a%0aA: In the wiki search form, use @@link=Group.Page@@ to find all pages linking to Group.Page.%0a%0aA: Use the [@link=@] option of the [[[@(:pagelist:)@] directive -> PmWiki/PageLists#pagelistlink]], as in%0a%0a->[@(:pagelist link=SomePage list=all:) -- show all links to SomePage%0a(:pagelist link={$FullName} list=all:) -- show all links to the current page@]%0a%0aNote that (with a few exceptions) includes, conditionals, pagelists, searchresults, wikitrails, and redirects are not evaluated for Wikilinks, and so any links they put on the page will not be found as backlinks. All other directives and markup, for example links brought to the page by (:pmform:), will be found.%0a%0aQ: What link schemes does PmWiki support?%0aA: See [[PmWiki:Link schemes]] {PmWiki.LinkSchemes$:Summary}%0a%0aQ: How do I open external links in a new window or mark them with an icon?%0aA: See [[Cookbook:External links]] {Cookbook.ExternalLinks$:Summary}%0a%0aQ: How can I use an image as a link?%0aA: Use [=[[Page| Attach:image.jpg ]] or [[ http://site | http://site/image.jpg ]]=] See [[PmWiki/Images#links]]%0a%0aQ: Why my browser does not follow local file:// links?%0aA: For security reasons, most browsers will only enable file:// links if the page containing the link is itself on the local drive. In other words, most browsers do not allow links to file:// from pages that were fetched using http:// such as in a PmWiki site. See also Cookbook:DirList for a workaround.%0a%0aQ: How links to the first existed page ? for example [@ [[Group1.Page Group2.Page|Page]] @]%0aA: See [[PmWiki/ConditionalMarkup]]%0a->[@(:if exists Group1.Page:)%0a [[Group1.Page|Page]]%0a(:elseif exists Group2.Page:)%0a [[Group2.Page|Page]]%0a(:ifend:)@] -time=1590307817 +rev=240 +targets=PmWiki.WikiSandbox,PmWiki.BasicEditing,Main.WikiSandbox,Main.HomePage,PmWiki.WikiWikiWeb,PmWiki.Installation,PmWiki.WikiWord,PmWiki.LinkVariables,PmWiki.Links,PmWiki.InterMap,PmWiki.NonexistentPages,PmWiki.CreatingNewPages,PmWiki.WikiGroup,PmWiki.Categories,Profiles.Author,PmWiki.LayoutVariables,PmWiki.PageSections,Cookbook.FixURL,Cookbook.DirList,PmWiki.Robots,Cookbook.PopupWindow,Cookbook.DeObMail,Cookbook.AddUrlSchemes,PmWiki.PageLists,PmWiki.LinkSchemes,Cookbook.ExternalLinks,PmWiki.Images,PmWiki.ConditionalMarkup,Cookbook.Footnotes +text=(:Summary:Multiple mechanisms for creating links:)%0a(:Audience: authors (basic) :)%0aA key feature of [[wiki(WikiWeb)]]-based systems is the ease of creating %25newwin%25[[Wikipedia:Hyperlink|hyperlinks]]%25%25 (or short '''links''') in the text of a document. %0aPmWiki provides multiple mechanisms for creating such links.%0a%0a!! [[#links]]Links to other pages in the wiki%0a%0aTo create an internal link to another page, simply enclose the name of the page inside double square brackets, as in %25pmhlt%25[@[[wiki sandbox]]@] or %25pmhlt%25[@[[installation]]@]. This results in links to [[wiki sandbox]] and [[installation]], respectively.%0a%0aPmWiki creates a link by using the text inside the double brackets. It does this by removing spaces between the words, and automatically capitalizing the first letter of each word following spaces or other punctuation (like ~). Thus %25pmhlt%25[@[[Wiki Sandbox]]@], [@[[wiki sandbox]]@], and [@[[WikiSandbox]]@] all display differently but create the same link to the page titled [@WikiSandbox@].%0aOr in other words, PmWiki will automatically create the "link path name" using the page name in ''CamelCase'', but the "link text" will display in the format you have entered it.%0a%0aSome PmWiki sites (default not) will recognize words written in CamelCase, called a [[WikiWord]], automatically as a link to a page of the same name.%0a%0a!!! [[#othertext]]Links with different link text%0a%0aThere are three ways to get a different link text:%0a%0a#'''Hide link text'''. Link text within (parentheses) will not be not displayed, so that %25pmhlt%25[@[[(wiki) sandbox]]@] links to ''[=WikiSandbox=]'' but displays as [[(wiki) sandbox]]. For addresses actually containing parentheses, use %2528 and %2529 [[https://www.example.com/linkwith%2528parenthese%2529]].%0a%0a#'''Change link text'''. You can specify another link text after a vertical brace, as in %25pmhlt%25[@[[WikiSandbox | a play area]]@], or you can use an arrow ([@->@]) to reverse the order of the link text and the target, as in [@[[a play area -> WikiSandbox]]@]. Both links displays as [[a play area -> WikiSandbox]].%0a%0a#'''Show page title instead of page name'''. The use of special characters in the page name is not a problem for PmWiki, but on some servers it may be better to use only plain A-Z letters for the page "name" (which is also a filename), and set the page "title" to the extended or international characters with the %25pmhlt%25[@(:title PageTitle:)@] directive within the page. The page title can be shown instead of the page name with the [@[[PageName|+]]@] link markup, e.g. page [@BasicEditing@] contains the directive [=(:title=] {BasicEditing$Title}:) with the result that a link written as [@[[BasicEditing|+]]@] will display as [[BasicEditing|+]]. [-See also $EnableLinkPlusTitlespaced.-]\\%0aSince PmWiki version 2.2.14 this works also for those technical pages that have an entry in the XLPage, without the need to add the [=(:title PageTitleName:)=] directive within that page (for more details see [[(PmWikiHome:Localization.)Localization]]).%0a%0aOn top of above ways, a suffix can be added to the end of a link, which becomes part of the link text but not of the target page name.\\%0a'''Note:''' This feature works with the %25pmhlt%25[@[[PageName|+]]@] markup only since Version 2.2.90.%0a%0a[[#markupheaders]]%0a(:table class='markup horiz' align='center':)%0a(:cellnr class='markup1':)%0a[-'''What to type'''-]%0a(:cell class='markup2':)%0a[-'''What it looks like'''-]%0a(:tableend:)%0a[[#markupheadersend]]%0a%0a(:markup class=horiz:)%0a* [[(wiki) sandbox]]%0a* [[(wiki) sandbox]]es%0a* [[WikiSandbox | wiki sandbox]],%0a* [[WikiSandbox | wiki sandbox]]es%0a* [[BasicEditing | +]]%0a(:markupend:)%0a%0a!!! [[#tooltiptitle]] Links with tool tip%0aFrom version 2.2.14 PmWiki can show tooltip titles with the following format:%0a: '''external link''' : %25pmhlt%25[@[[https://pmwiki.org"external tool tip title" | external link ]]@], eg [[https://pmwiki.org"external tool tip title" | external link ]] or [[https://pmwiki.org"external tool tip title" ]]%0a: '''internal link''': %25pmhlt%25[@[[Links"internal tool tip title" | internal link ]]@], eg [[Links"internal tool tip title" | internal link ]] or [[Links"internal tool tip title" ]]%0a: '''[[#anchors|Anchor links]]''': %25pmhlt%25[@[[#name"anchor tool tip title"|anchor link text]]@] (since Version 2.2.48), eg [[#name"anchor tool tip title"|anchor link text]] or [[#name"anchor tool tip title"]]%0a: '''[[InterMap]] link''' : %25pmhlt%25[@[[Wikipedia:Wiki"tool tip title"| InterMap link ]]@], eg [[Wikipedia:Wiki"tool tip title"| InterMap link ]] or [[Wikipedia:Wiki"tool tip title" ]]%0a%0a %0a!!! [[#nonexistent]]Links to nonexistent pages%0a%0aLinks to [[nonexistent pages]] are displayed specially, to invite others to create the page.%0aSee [[Creating new pages]] to learn more.%0a%0a!!! [[#othergroup]]Links to pages in other wiki groups%0a%0aLinks as written above are links between pages of the same group. To create a link to a page in another group, add the name of that other group together with a dot or slash as prefix to the page name. For example, links to %25pmhlt%25[@Main/WikiSandbox@] could be written as:%0a%0a(:include {$FullName}#markupheaders#markupheadersend:)%0a%0a(:markup class=horiz:)%0a* [[Main.WikiSandbox]]%0a* [[Main/WikiSandbox]]%0a* [[(Main.Wiki)Sandbox]]%0a* [[Main.WikiSandbox | link text]]%0a* [[Main.WikiSandbox | +]]%0a(:markupend:)%0a%0aTo link to the "default home page" of a group, the name of the page can be omitted:%0a%0a(:markup class=horiz:)%0a* [[Main.]]%0a* [[Main/]]%0a(:markupend:)%0a%0aSee [[Wiki Group]] to learn more about PmWiki groups.%0a%0a!!! [[#categories]]Category links%0a%0aCategories are a way to organize and find related pages. The idea is that every page that falls into a particular subject area should have a link to a shared page containing links to other pages on that subject. These ''shared pages'' are created in the special group [@Category@], and thus these subject areas are called "categories".%0a%0aAdding a page to the category [@Subject@] is simple by adding the %25pmhlt%25[@[[!Subject]]@] markup somewhere on that page. This will create a link to the page [@Category.Subject@]. So [@[[!Subject]]@] is a kind of link shortcut to the page [@Category.Subject@]. See [[Categories]] to learn more.%0a%0a!!! [[#profiles]]User page links -- "signatures"%0a%0aSimilar is %25pmhlt%25[@[[~Author]]@] a link shortcut to the page [@Author@] in the special group [@Profiles@]. PmWiki automatically creates this type of link for the ''current author'', when it encounters three tilde characters ([@~@]) in a row (@@~~[==]~@@) in the page text. The current author is the name found in the "Author" field, when you create or modify a page. The current date and time is appended when four tilde characters in a row are encountered (@@~~[==]~~@@).%0a%0aSo, when the Author field contains "Author":\\%0a%25pmhlt%25@@~~[==]~@@ markup will be replaced by: [[~Author]]\\%0a%25pmhlt%25@@~~[==]~~@@ markup will be replaced by: [[~Author]] October 10, 2010, at 04:50 PM%0a%0aTime format can be modified in local configuration with $CurrentTime.%0a%0a!!! [[#linkshortcuts]]Link shortcuts%0a%0a%25pmhlt%25[@[[PageName|#]]@] creates a [[#reference|reference]] link as shown below'^[[#reference|#]]^'.%0a%0a!!! [[#anchors]]Links to specific locations within a page -- "anchors"%0a%0aTo define a location, or bookmark, within a page to which you may jump directly, use the markup %25pmhlt%25[@[[#name]]@]. This creates an "[[https://www.w3.org/TR/html4/struct/links.html#h-12.2.1|anchor]]" that uniquely identifies that location in the page. Then to have a link jump directly to that anchor, use one of%0a%0a* %25pmhlt%25[@[[#name|link text]]@] within the same page, or%0a* %25pmhlt%25[@[[PageName#name]]@] or [@[[PageName#name|link text]]@] for a location on another page%0a* %25pmhlt%25The form [@[[PageName(#name)]]@] may be useful for hiding the anchor text in a link. %0a%0aFor example, here's a link to the [[#intermaps | Intermaps]] section, below. %0a%0aNotes:%0a* %25red%25The anchor itself [[https://www.w3.org/TR/html4/types.html#type-name|must]] begin with a letter%25%25, '''not a number'''.%0a* %25green%25Valid characters for anchor names%25%25 are letters, digits, dash (-), underscore (_), and the period (.).%0a* A link to an anchor must have the '''same capitalization as the anchor''' itself. %0a* %25pmhlt%25Spaces are not allowed in an anchor: "[@[[#my anchor]]@]" won't work, "[@[[#myanchor]]@]" will.%0a* All anchor names in a page should be unique.%0a%0a%0a!!! [[#sections]]Sections%0aWhile in HTML the purpose of [[#anchors|anchors]] is mostly for jumping to a position in the text, in PmWiki they serve an internal purpose, too: Each anchor also creates a section, because sections are defined as the part of the page between their start anchor and the next anchor. %0aFor more details, see [[PmWiki:Page Sections|Page Sections]].%0a%0a%0a!!! [[#actions]]Links to actions%0a%0aTo link to a specific action for the current page use %25pmhlt%25[@[[{$FullName}?action=actionname|link text]]@].%0a%0aExamples:%0a* %25pmhlt%25[@[[{$FullName}?action=edit|Edit]]@] for editing%0a* %25pmhlt%25[@[[{$FullName}?action=diff|History]]@] for history.%0a%0a!! Links outside the wiki%0a[[#externallinks]]%0a!!! Links to external sites ([=URLs=])%0a%0aLinks to external sites simply begin with a prefix such as 'https:', 'ftp:', etc. Thus %25pmhlt%25[@https://google.com/@] and [@[[https://google.com/]]@] both link to Google. As with the above, an author can specify the link text by using the vertical brace or arrow syntax, as in [@[[https://google.com/ | Google]]@] and [@[[Google -> https://google.com]]@].%0a%0aIf the external link includes (parentheses), escape these using [=%2528=] for "(" and [=%2529=] for ")" : %0a(:markup:)%0a[[https://en.wikipedia.org/wiki/Wiki_%2528disambiguation%2529 | link to "Wiki (disambiguation)" ]]%0a(:markupend:)%0a%0aThe recipe Cookbook:FixURL makes it easy to encode parentheses and other special characters in link addresses.%0a%0a!!! [[#escaped]] Links with special characters%0aTo have any special characters, including quotes, spaces, parentheses and pipes in link addresses escape them using %25pmhlt%25[@[=link address=]@].%0a%0a!!! [[#path]] Links from the wiki to resources on the same website%0a%0aYou can use the %25pmhlt%25[@Path:@] prefix to add links outside of the wiki but on the same website.%0a%0aUse @@[=Path:=]%25blue%25/path/to/resource%25%25@@ with a leading slash for links relative to the website document root as in @@www.example.com%25blue%25/path/to/resource%25%25@@.%0a%0aYou can also define a custom [[InterMap]] prefix to a specific path on your website and use it as a shortcut, for example:%0a%0a Pictures: /assets/pictures/$1%0a%0aThen in a wiki page, use %25pmhlt%25[@Pictures:photo.jpg@] instead of [@Path:/assets/pictures/photo.jpg@] or [@https://www.example.com/assets/pictures/photo.jpg@]%0a%0aSee [[InterMap]] for more information.%0a%0a!!! Links to intranet (local) files%0a%0a'''Not all browsers will follow such links''' (some Internet Explorer versions reportedly follow them). You can link to a file system by including the prefix %25pmhlt%25[@'file:///'@]. So [@file:///S:\ProjPlan.mpp@] and [@[[Shared S drive->file:///S:\]]@] are both valid links. On a Windows file system you may want to use network locations (eg [@file:///\\server1\rootdirectory\subdirectory@]) rather than drive letters which may not be consistent across all users. Not all browsers will follow such links, Internet Explorer does allow them.%0a%0aSee also Cookbook:DirList.%0a%0a!! Link characteristics%0a!!! [[#reference]]Links as References%0a%0aLinks may also be specified as '''References''', so the target appears as an anonymous ''numeric'' reference rather than a ''textual'' reference. The following markup is provided to produce sequential reference numbering within a PmWiki page:%0a%0aFormatting the link as: %25pmhlt%25[@[[https://google.com |#]]@] produces: [[https://google.com |#]] as the link.%0a%0aSubsequent occurrence of the reference link format on the same page will be incremented automatically as per the following example: Entering %25pmhlt%25[@[[https://pmwiki.com |#]]@] produces [[https://pmwiki.com |#]], [@[[#intermaps |#]]@] produces [[#intermaps |#]], and so on for further reference links.%0a%0aBut, it should be noticed that the feature is deliberately kept simple and doesn't work as bibliographic references: this supplemental link %25pmhlt%25[@[[https://pmwiki.com |#]]@] would produces [[https://pmwiki.com |#]] and not reuse the first link definition.%0a%0a!!! [[#intermaps]]Intermaps%0a%0a[[Inter Map]] links are also supported (see [[Inter Map]]). In particular, the %25pmhlt%25[@Path:@] InterMap entry can be used to create links using relative or absolute paths on the current site (e.g., [@Path:../../somedir/foo.html@] or [@Path:/dir/something.gif@]).%0a%0a!!! Links that open a new browser window%0a%0aTo have a link open in another window, use %25pmhlt%25[@%25newwin%25...%25%25@]:%0a%0a* %25pmhlt%25[@%25newwin%25 https://pmichaud.com %25%25@] produces %25newwin%25 https://pmichaud.com %25%25%0a* %25pmhlt%25[@%25newwin%25 [[https://google.com/ | Google]] %25%25@] produces %25newwin%25 [[https://google.com/ | Google]]%25%25%0a* %25pmhlt%25[@%25newwin%25 [[Main.WikiSandbox]] %25%25@] produces %25newwin%25 [[Main.WikiSandbox]]%25%25%0a%0aYou can also specify that links should open in a new window via the %25pmhlt%25[@%25target=_blank%25...%25%25@] attribute:%0a%0a(:markup class=horiz:)%0aThe following link %25target=_blank%25 https://pmichaud.com %25%25%0awill open in a new window.%0a(:markupend:)%0a%0a!!! [[#robots]]Links that are not followed by [[(PmWiki:)robots]]%0a%0aPrefix a link with [=%25rel=nofollow%25=] to advise %25newwin rel=nofollow%25[[https://robotstxt.org/|robots]] and [[https://validator.w3.org/checklink|link checkers]]%25%25 not to follow it.%0a%0a%0a!! Links and CSS classes%0a%0aPmWiki automatically gives classes to several types of links. Among other things, this enables you to format each type differently.%0a%0aNote: This may be an incomplete list.%0a:.selflink:A link to the current page. Useful in sidebars to show "you are here".%0a:.wikilink:A link to another page within the wiki.%0a:.urllink:A link to a page outside the wiki.%0a%0a!! Notes%0a%0a'''Note:''' The default behavior of "+" above can be overridden to display the spaced title, rather than simply the title by adding the following to config.php:%0a $EnableLinkPlusTitlespaced = 1;%0a%0a%0a>>faq%3c%3c [[#faq]]%0a%0aQ: How do I create a link that will open as a new window?%0a%0aA: Use the [@%25newwin%25@] wikistyle, as in:%0a(:markup class=horiz:) [=%25newwin%25 https://example.com/ %25%25=]%0a%0aQ: How do I create a link that will open a new window, and configure that new window?%0a%0aA: This requires javascript. See [[Cookbook:PopupWindow]].%0a%0aQ: How do I place a mailing address in a page?%0a%0aA: Use the [@mailto:@] markup, as in one of the following:%0a%0a(:markup class="horiz":)%0a* mailto:myaddress@example.com%0a* [[mailto:myaddress@example.com]]%0a* [[mailto:myaddress@example.com | email me]]%0a* [[mailto:myaddress@example.com?subject=Some subject | email me]]%0a(:markupend:)%0aThe markup @@[=[[mailto:me@example.=]com?%25red%25cc=%25%25someoneelse@example.com%25red%25&bcc=%25%25else@example.com%25red%25&subject=%25%25Pre-set Subject%25red%25&body=%25%25Pre-set body | display text]]@@ lets you specify more parameters like the message body and more recipients (may not work in all browsers and e-mail clients).%0a%0aSee also [[Cookbook:DeObMail]] for information on protecting email addresses from spammers.%0a%0aQ: How can I enable links to other protocols, such as nntp:, ssh:, xmpp:, etc?%0a%0aA: See [[Cookbook:Add Url schemes]] {Cookbook.AddUrlSchemes$:Summary}%0a%0aQ: How do I make a WikiWord link to an external page instead of a WikiPage?%0a%0aA: Use link markup. There are two formats:%0a%0a->%25pmhlt%25[@[[https://example.com/ | WikiWord]]%0a[[WikiWord -> https://example.com/]]@]%0a%0aQ: How do I find all of the pages that link to another page (i.e., backlinks)?%0a%0aA: In the wiki search form, use @@link=Group.Page@@ to find all pages linking to Group.Page.%0a%0aA: Use the %25pmhlt%25[@link=@] option of the [[[@(:pagelist:)@] directive -> PmWiki/PageLists#pagelistlink]], as in%0a%0a->%25pmhlt%25[@(:pagelist link=SomePage list=all:) -- show all links to SomePage%0a(:pagelist link={$FullName} list=all:) -- show all links to the current page@]%0a%0aNote that (with a few exceptions) includes, conditionals, pagelists, searchresults, wikitrails, and redirects are not evaluated for Wikilinks, and so any links they put on the page will not be found as backlinks. All other directives and markup, for example links brought to the page by (:pmform:), will be found.%0a%0aQ: What link schemes does PmWiki support?%0aA: See [[PmWiki:Link schemes]] {PmWiki.LinkSchemes$:Summary}%0a%0aQ: How do I open external links in a new window or mark them with an icon?%0aA: See [[Cookbook:External links]] {Cookbook.ExternalLinks$:Summary}%0a%0aQ: How can I use an image as a link?%0aA: Use [=[[Page| Attach:image.jpg ]] or [[ https://site | https://site/image.jpg ]]=] See [[PmWiki/Images#links]]%0a%0aQ: Why my browser does not follow local file:// links?%0aA: For security reasons, most browsers will only enable file:// links if the page containing the link is itself on the local drive. In other words, most browsers do not allow links to file:// from pages that were fetched using https:// such as in a PmWiki site. See also Cookbook:DirList for a workaround.%0a%0aQ: How links to the first existed page ? for example [@ [[Group1.Page Group2.Page|Page]] @]%0aA: See [[PmWiki/ConditionalMarkup]]%0a->%25pmhlt%25[@(:if exists Group1.Page:)%0a [[Group1.Page|Page]]%0a(:elseif exists Group2.Page:)%0a [[Group2.Page|Page]]%0a(:ifend:)@]%0a%0aQ: How do I make [[#reference|Reference]] links also show up on the bottom of the page like Wikipedia? Or, how do I list all links on a page?%0a%0aA: See Cookbook:Footnotes. +time=1666755651 blob - b459ed0c321f83476bc057159212a806f8d970a2 blob + 2ee696079436fa3548f2c01eb05aac6d720c0a31 --- wikilib.d/PmWiki.LocalCustomizations +++ wikilib.d/PmWiki.LocalCustomizations @@ -1,9 +1,9 @@ -version=pmwiki-2.2.122 ordered=1 urlencoded=1 -author=Petko +version=pmwiki-2.3.11 ordered=1 urlencoded=1 +author=simon charset=UTF-8 -csum=%25hlt php%25 +csum=more highlightinmg, http+s (+139) name=PmWiki.LocalCustomizations -rev=100 +rev=108 targets=PmWiki.GroupCustomizations,PmWiki.WikiAdministrator,PmWiki.DocumentationIndex,PmWiki.Skins,PmWiki.Internationalizations,PmWiki.CustomMarkup,PmWiki.InterMap,PmWiki.PmWikiPhilosophy,PmWiki.Variables,PmWiki.DebugVariables,Cookbook.ControllingWebRobots,Cookbook.Cookbook,PmWiki.BasicVariables,PmWiki.PathVariables,Cookbook.SQLite,Cookbook.CompressedPageStore,Cookbook.PerGroupSubDirectories,PmWiki.UTF-8,PmWiki.MailingLists,PmWiki.Upgrades,Site.PageNotFound,PmWiki.LocalCustomizations -text=(:Summary:Customize your PmWiki installation through @@config.php@@ and @@local.css@@:)%0aA [[Wiki Administrator]] can make a lot of customizations simply by setting variables in the ''/local/config.php'' and defining cascading style sheets in ''/pub/css/local.css'' files. Any group or page can also have [[GroupCustomizations|its own configuration file and configuration css file]].%0a%0aThis page describes how customizations work in general, see [[PmWiki.Documentation Index]] for specific customizations that are commonly performed at many PmWiki installations, including:%0a%0a* [[Skins]] - {Skins$:Summary}%0a* [[Internationalizations]] - {Internationalizations$:Summary}%0a* [[Custom Markup]] - {CustomMarkup$:Summary}%0a* [[InterMap]]s - {InterMap$:Summary}%0a%0a[[#configphp]]%0a!! local/config.php%0a%0aFrom its inception, PmWiki has been designed so that [[Wiki Administrator]]s can greatly customize the way PmWiki displays pages and the markup sequences used to generate pages. (This is even mentioned explicitly in [[PmWiki Philosophy(#collaborativemaintenance)]] #4 Collaborative Maintenance.) As a result, the core ''pmwiki.php'' script makes extensive use of [[PmWiki.Variables]] to determine how markup sequences will be processed and what each individual page will output.%0a%0aThe simplest type of customization is merely setting a variable to 1 (or TRUE). Here's an example that enables ?action=diag and ?action=phpinfo actions:%0a->%25hlt php%25@@$EnableDiag = 1;@@%0a%0aYou can begin a line with a "#" (an octothorpe, a.k.a. a hash symbol or pound sign) to add a comment. Additionally, some built-in PmWiki variables take values other than 1 or 0 (true or false). Here's another example that customizes the wiki's behavior with respect to search engine web robots (see [[Cookbook:ControllingWebRobots]]):%0a%0a->%25hlt php%25[@%0a# Remove the default "rel='nofollow'" attribute for external links.%0a$UrlLinkFmt = "%3ca class='urllink' href='\$LinkUrl' title='\$LinkAlt'>\$LinkText%3c/a>";%0a@]%0a%0aThe ''scripts/'' subdirectory (below the directory holding the ''pmwiki.php'' script) has many customizations.%0aThe PmWiki [[(Cookbook:)Cookbook]] contains many example customizations (recipes) that you can download into the ''cookbook/'' subdirectory,%0aThe first few lines of each of these scripts generally contain instructions about how to enable (and use) the feature provided by the script.%0a%0aThese customizations are included in your ''config.php'' site configuration. For most scripts this is done by simply adding lines like:%0a->%25hlt php%25[@include_once("cookbook/recipefile.php");@]%0aand%0a->%25hlt php%25[@include_once("scripts/scriptfile.php");@]%0aat the end of the ''config.php'' file to enable them. %0a%0aSome of the scripts are automatically enabled for you via the ''scripts/stdconfig.php'' script unless you disable it by setting @@$EnableStdConfig=0;@@ in ''local/config.php''.%0a%0a[[#PostConfig]][[#configphp-order]]%0a!!! Order of the commands in config.php%0aThe following order is recommended:%0a%0a* define $ScriptUrl and $PubDirUrl, if needed,%0a* define any custom PageStore class, like [[(Cookbook:)SQLite]], [[(Cookbook:)CompressedPageStore]] or [[(Cookbook:)PerGroupSubDirectories]],%0a* next include_once scripts/xlpage-utf-8.php,%0a* next call XLPage() which needs the definitive writable $WikiDir already set in order to find the wiki page containing the translations,%0a* next include authuser.php (if needed), because PmWiki caches some group and page authorization levels when a page is accessed,%0a* next include any other scripts and recipes and their configuration %0a** see for any requirements or advice about the order on the recipe pages: some need to be included before or after others, some need to be configured before the script is included, others after.%0a%0a>>frame hlt php%3c%3c%0aIf you need to set per-page or per-group variables or addons, it is recommended to add them into files named local/Group.php and local/Group.Page.php. If you must do it from config.php, or if you need to set these variables after the local files are included, use the following at the bottom of config.php:%0a%0a '''$pagename = ResolvePageName($pagename);'''%0a '''include_once("$FarmD/scripts/pgcust.php");'''%0a list($group, $name) = explode('.', $pagename);%0a if ($group != 'Private') {...} # do whatever you need%0a%0aAny direct function call in config.php, like CondAuth(), PageTextVar(), PageVar(), RetrieveAuthPage(), or others, should be done near the end of config.php after the above snippet in bold. Alternatively, you can add those in a custom function or script in the $PostConfig array:%0a%0a # PmWiki will call this function and include this file '''after'''%0a # farmconfig.php, config.php, Group.Page.php and Group.php%0a # but '''before''' scripts/stdconfig.php:%0a function MyFunction1($pagename) {...}%0a $PostConfig['MyFunction1'] = 25; # %3c 50%0a $PostConfig["cookbook/some-addon.php"] = 26; # %3c 50%0a%0a # PmWiki will call this function and include this file '''after'''%0a # farmconfig.php, config.php, Group.Page.php, Group.php%0a # and scripts/stdconfig.php:%0a function MyFunction2($pagename) {...}%0a $PostConfig['MyFunction2'] = 125; # >= 50%0a $PostConfig["cookbook/other-addon.php"] = 100; # >= 50%0a%0aThe $PostConfig functions and scripts will be called ordered by their values, ie above "MyFunction2" (125) will be called after "other-addon.php" (100). This allows recipe authors more control over the precise order of their recipe compared to other recipes (when that is important).%0a>>%3c%3c%0a%0a''Note, each part is '''not''' required, but if your wiki needs it, this is the recommended order in config.php.''%0a%0a[[#encoding]]%0a!!! Character encoding of config.php%0a%0aThe encoding used when you save [@config.php@] has an effect. Your text editor should allow you to save config.php in the encoding of your wiki. (The default encoding of PmWiki is ISO-8859-1, for new wikis it is recommended to enable UTF-8.)%0a%0aNewer operating systems like GNU/Linux, FreeBSD and Apple generally default to saving text files in Unicode/UTF-8; in Windows the default encoding is ANSI/Windows-1252 which is almost the same as PmWiki's ISO-8859-1.%0a%0aThe following ''free/libre software'' text editors can edit and save a file in different encodings:%0a* Cross-platform: [[http://kate-editor.org/ |Kate]] (for KDE), [[http://www.geany.org/ |Geany]], [[http://www.arachnoid.com/arachnophilia/index.html|Arachnophilia]], [[http://www.scintilla.org/SciTE.html|SciTE]], [[http://bluefish.openoffice.nl/|Bluefish]], [[http://www.vim.org/|vim]] and others.%0a* Windows: [[http://notepad-plus-plus.org/ |Notepad++]], [[http://www.contexteditor.org/|ConTEXT]], [[http://www.flos-freeware.ch/notepad2.html|Notepad2]].%0a* OS X: [[http://aquamacs.org|Aquamacs]].%0a%0aNote that if you use the UTF-8 encoding, you should save your files ''"without Byte Order Mark (BOM)"''.%0a%0aOver time PmWiki will be updated to default to Unicode/UTF-8 encoding, which allows all possible alphabets and languages. See [[UTF-8]] for more information.%0a%0a[[#localcss]]%0a!! pub/css/local.css%0a%0aYou can create this file and set there some custom CSS styles which will override any styles set by skins. For example:%0a%25hlt css%25[@%0a h1, h2, h3, h4, h5 { color: #880000; } /*dark red titles*/%0a a { text-decoration: none; } /* don't underline links */%0a@]%0a%0aCSS files are included in the order%0a# @@$PubDirUrl/css/local.css@@ '-- for the wiki-'%0a# @@$PubDirUrl/css/[@{$Group}.css@]@@ '-- for groups-'%0a# @@$PubDirUrl/css/[@{$FullName}.css@]@@ '-- for single pages-'%0a# @@$PageCSSListFmt@@%0a%0a!! Don't modify pmwiki.php or other core files%0a%0aYou should strongly resist the temptation to directly modify the ''pmwiki.php'' script or the files in the ''scripts/'' subdirectory. Any modifications you make to these files will probably be overwritten whenever you [[PmWiki/upgrade(s)]]. Instead, look at some of the sample scripts for examples of customizations that can be performed from ''config.php''. You can even create your own script to do a customization and use @@include_once(...)@@ to include it from ''config.php''. If you do make your own customization script, you can safely put it in the ''cookbook/'' subdirectory--it won't get overwritten by an upgrade there. You might also want to submit your customization to the [[MailingLists|pmwiki-users mailing list]] or the [[(Cookbook:)Cookbook]] so that others can benefit from your effort and so that it can perhaps be included in future releases of PmWiki.%0a%0a!! FAQ%0a>>faq%3c%3c [[#faq]]%0aQ: There's no "config.php"; it's not even clear what a "local customisation file" is!%0aA: The "sample-config.php" file in the "docs" folder, is given as an example. Copy it to the "local" folder and rename it to "config.php". You can then remove the "#" symbols or add other commands shown in the documentation. See also [[Group Customizations]].%0a%0aQ: Can I change the default page something other than Main.HomePage ($DefaultPage)?%0aA: Yes, just set the $DefaultPage variable to the name of the page you want to be the default. You might also look at the $DefaultGroup and $DefaultName configuration variables.%0a%0a->%25hlt php%25[@$DefaultPage = 'ABC.StartPage';@]%0a%0aNote the recommendations in $DefaultName and the need to set $PagePathFmt as well if you are changing the default startup page for groups.%0a%0aQ: [[#configphp-group-page]] How do I get the group / page name in a local configuration file (e.g. ''local/config.php'')?%0aA: Use the following markup in pmwiki-2.1.beta21 or newer:%0a%0a%25hlt php%25[@%0a## Get the group and page name%0a$pagename = ResolvePageName($pagename);%0a$page = PageVar($pagename, '$FullName');%0a$group = PageVar($pagename, '$Group');%0a$name = PageVar($pagename, '$Name');%0a@]%0a%0aNote the importance of [[#configphp-order|the order of customizations in config.php above]] to avoid caching problems.%0a%0aIf you need the verbatim group and page name (from the request) early in config.php, $pagename is guaranteed to be set to%0a# Any value of ?n= if it's set, or%0a# Any value of ?pagename= if it's set, or%0a# The "path info" information from REQUEST_URI (whatever follows SCRIPT_NAME), or%0a# Blank otherwise%0aaccording to [[http://pmichaud.com/pipermail/pmwiki-users/2011-May/058905.html|this posting]]%0a%0aQ: Can I remove items from the wikilib.d folder on my site?%0aA: The files named Site.* and SiteAdmin.* contain parts of the interface and the configuration and they should not be removed. The other files named PmWiki* contain the documentation and could be removed.%0a%0aQ: How do I customize my own 404 error page for non-existent pages?%0aA: To change the text of the message, try editing the [[Site.PageNotFound]] page.%0a%0aQ: Is the order of customizations in config.php important? Are there certain things that should come before or after others in that file?%0aA: Yes, see [[LocalCustomizations#configphp-order|Order of the commands in config.php]]. -time=1574411138 +text=(:Summary:Customize your PmWiki installation through @@config.php@@ and @@local.css@@:)%0aA [[Wiki Administrator]] can make a lot of customizations simply by setting variables in the ''@@/local/config.php@@'' and defining cascading style sheets in ''@@/pub/css/local.css@@'' files. Any group or page can also have [[GroupCustomizations|its own configuration file and configuration css file]].%0a%0aThis page describes how customizations work in general, see [[PmWiki.Documentation Index]] for specific customizations that are commonly performed at many PmWiki installations, including:%0a%0a* [[Skins]] - {Skins$:Summary}%0a* [[Internationalizations]] - {Internationalizations$:Summary}%0a* [[Custom Markup]] - {CustomMarkup$:Summary}%0a* [[InterMap]]s - {InterMap$:Summary}%0a%0a[[#configphp]]%0a!! local/config.php%0a%0aFrom its inception, PmWiki has been designed so that [[Wiki Administrator]]s can greatly customize the way PmWiki displays pages and the markup sequences used to generate pages. (This is even mentioned explicitly in [[PmWiki Philosophy(#collaborativemaintenance)]] #4 Collaborative Maintenance.) As a result, the core ''@@pmwiki.php@@'' script makes extensive use of [[PmWiki.Variables]] to determine how markup sequences will be processed and what each individual page will output.%0a%0aThe simplest type of customization is merely setting a variable to 1 (or TRUE). Here's an example that enables ?action=diag and ?action=phpinfo actions:%0a->%25hlt php%25@@$EnableDiag = 1;@@%0a%0aYou can begin a line with a "#" (an octothorpe, a.k.a. a hash symbol or pound sign) to add a comment. Additionally, some built-in PmWiki variables take values other than 1 or 0 (true or false). Here's another example that customizes the wiki's behavior with respect to search engine web robots (see [[Cookbook:ControllingWebRobots]]):%0a->%25hlt php%25[@%0a# Remove the default "rel='nofollow'" attribute for external links.%0a$UrlLinkFmt = "%3ca class='urllink' href='\$LinkUrl' title='\$LinkAlt'>\$LinkText%3c/a>";%0a@]%0a%0aThe ''@@scripts/@@'' subdirectory (below the directory holding the ''@@pmwiki.php@@'' script) has many customizations.%0aThe PmWiki [[(Cookbook:)Cookbook]] contains many example customizations (recipes) that you can download into the ''@@cookbook/@@'' subdirectory,%0aThe first few lines of each of these scripts generally contain instructions about how to enable (and use) the feature provided by the script.%0a%0aThese customizations are included in your ''@@config.php@@'' site configuration. For most scripts this is done by simply adding lines like:%0a->%25hlt php%25[@include_once("cookbook/recipefile.php");@]%0aand%0a->%25hlt php%25[@include_once("scripts/scriptfile.php");@]%0aat the end of the ''@@config.php@@'' file to enable them. %0a%0aSome of the scripts are automatically enabled for you via the ''@@scripts/stdconfig.php@@'' script unless you disable it by setting @@$EnableStdConfig=0;@@ in ''@@local/config.php@@''.%0a%0a[[#PostConfig]][[#configphp-order]]%0a!!! Order of the commands in @@config.php@@%0aThe following order is recommended:%0a%0a* define $ScriptUrl and $PubDirUrl, if needed,%0a* define any custom PageStore class, like [[(Cookbook:)SQLite]], [[(Cookbook:)CompressedPageStore]] or [[(Cookbook:)PerGroupSubDirectories]],%0a* next %25hlt php%25[@include_once("scripts/xlpage-utf-8.php")@],%0a* next call %25hlt php%25[@XLPage()@] which needs the definitive writable $WikiDir already set in order to find the wiki page containing the translations,%0a* next include @@authuser.php@@ (if needed), because PmWiki caches some group and page authorization levels when a page is accessed,%0a* next include any other scripts and recipes and their configuration %0a** see for any requirements or advice about the order on the recipe pages: some need to be included before or after others, some need to be configured before the script is included, others after.%0a%0a>>frame hlt php%3c%3c%0aIf you need to set per-page or per-group variables or addons, it is recommended to add them into files named @@local/Group.php@@ and @@local/Group.Page.php@@. If you must do it from @@config.php@@, or if you need to set these variables after the local files are included, use the following at the bottom of @@config.php@@:%0a%0a '''$pagename = ResolvePageName($pagename);'''%0a '''include_once("$FarmD/scripts/pgcust.php");'''%0a list($group, $name) = explode('.', $pagename);%0a if ($group != 'Private') {...} # do whatever you need%0a%0aAny direct function call in @@config.php@@, like @@CondAuth()@@, @@PageTextVar()@@, @@PageVar()@@, @@RetrieveAuthPage()@@, or others, should be done near the end of @@config.php@@ after the above snippet in bold. Alternatively, you can add those in a custom function or script in the $PostConfig array:%0a%0a # PmWiki will call this function and include this file '''after'''%0a # farmconfig.php, config.php, Group.Page.php and Group.php%0a # but '''before''' scripts/stdconfig.php:%0a function MyFunction1($pagename) {...}%0a $PostConfig['MyFunction1'] = 25; # %3c 50%0a $PostConfig["cookbook/some-addon.php"] = 26; # %3c 50%0a%0a # PmWiki will call this function and include this file '''after'''%0a # farmconfig.php, config.php, Group.Page.php, Group.php%0a # and scripts/stdconfig.php:%0a function MyFunction2($pagename) {...}%0a $PostConfig['MyFunction2'] = 125; # >= 50%0a $PostConfig["cookbook/other-addon.php"] = 100; # >= 50%0a%0aThe $PostConfig functions and scripts will be called ordered by their values, ie above "MyFunction2" (125) will be called after "other-addon.php" (100). This allows recipe authors more control over the precise order of their recipe compared to other recipes (when that is important).%0a>>%3c%3c%0a%0a''Note, each part is '''not''' required, but if your wiki needs it, this is the recommended order in @@config.php@@.''%0a%0a[[#encoding]]%0a!!! Character encoding of config.php%0a%0aThe encoding used when you save [@config.php@] has an effect. Your text editor should allow you to save config.php in the encoding of your wiki. (The default encoding of PmWiki is ISO-8859-1, for new wikis it is recommended to enable UTF-8.)%0a%0aNewer operating systems like GNU/Linux, FreeBSD and Apple generally default to saving text files in Unicode/UTF-8; in Windows the default encoding is ANSI/Windows-1252 which is almost the same as PmWiki's ISO-8859-1.%0a%0aThe following ''free/libre software'' text editors can edit and save a file in different encodings:%0a* Cross-platform: [[https://kate-editor.org/ |Kate]] (for KDE), [[https://www.geany.org/ |Geany]], [[https://arachnoid.com/arachnophilia/index.html|Arachnophilia]], [[https://www.scintilla.org/SciTE.html|SciTE]], [[https://bluefish.openoffice.nl/index.html|Bluefish]], [[https://www.vim.org/|vim]] and others.%0a* Windows: [[https://notepad-plus-plus.org/ |Notepad++]], [[https://www.contexteditor.org/|ConTEXT]].%0a* OS X: [[https://aquamacs.org/|Aquamacs]].%0a%0aNote that if you use the UTF-8 encoding, you should save your files ''"without Byte Order Mark (BOM)"''.%0a%0aOver time PmWiki will be updated to default to Unicode/UTF-8 encoding, which allows all possible alphabets and languages. See [[UTF-8]] for more information.%0a%0a[[#localcss]]%0a!! pub/css/local.css%0a%0aYou can create this file and set there some custom CSS styles which will override any styles set by skins. For example:%0a%25hlt css%25[@%0a h1, h2, h3, h4, h5 { color: #880000; } /*dark red titles*/%0a a { text-decoration: none; } /* don't underline links */%0a@]%0a%0aCSS files are included in the order%0a# @@$PubDirUrl/css/local.css@@ '-- for the wiki-'%0a# @@$PubDirUrl/css/[@{$Group}.css@]@@ '-- for groups-'%0a# @@$PubDirUrl/css/[@{$FullName}.css@]@@ '-- for single pages-'%0a# @@$PageCSSListFmt@@%0a%0a!! Don't modify pmwiki.php or other core files%0a%0aYou should strongly resist the temptation to directly modify the ''@@pmwiki.php@@'' script or the files in the ''@@scripts/@@'' subdirectory. Any modifications you make to these files will probably be overwritten whenever you [[PmWiki/upgrade(s)]]. Instead, look at some of the sample scripts for examples of customizations that can be performed from ''@@config.php@@''. You can even create your own script to do a customization and use %25hlt php%25@@include_once(...)@@%25%25 to include it from ''@@config.php@@''. If you do make your own customization script, you can safely put it in the ''@@cookbook/@@'' subdirectory--it won't get overwritten by an upgrade there. You might also want to submit your customization to the [[MailingLists|pmwiki-users mailing list]] or the [[(Cookbook:)Cookbook]] so that others can benefit from your effort and so that it can perhaps be included in future releases of PmWiki.%0a%0a!! FAQ%0a>>faq%3c%3c [[#faq]]%0aQ: There's no "@@config.php@@"; it's not even clear what a "local customisation file" is!%0aA: The "@@sample-config.php@@" file in the "docs" folder, is given as an example. Copy it to the "local" folder and rename it to "@@config.php@@". You can then remove the "#" symbols or add other commands shown in the documentation. See also [[Group Customizations]].%0a%0aQ: Can I change the default page something other than @@Main.HomePage@@ ($DefaultPage)?%0aA: Yes, just set the $DefaultPage variable to the name of the page you want to be the default. You might also look at the $DefaultGroup and $DefaultName configuration variables.%0a%0a->%25hlt php%25[@$DefaultPage = 'ABC.StartPage';@]%0a%0aNote the recommendations in $DefaultName and the need to set $PagePathFmt as well if you are changing the default startup page for groups.%0a%0aQ: [[#configphp-group-page]] How do I get the group / page name in a local configuration file (e.g. ''@@local/config.php@@'')?%0aA: Use the following markup in pmwiki-2.1.beta21 or newer:%0a-> %25hlt php%25[@%0a## Get the group and page name%0a$pagename = ResolvePageName($pagename);%0a$page = PageVar($pagename, '$FullName');%0a$group = PageVar($pagename, '$Group');%0a$name = PageVar($pagename, '$Name');%0a@]%0a%0aNote the importance of [[#configphp-order|the order of customizations in @@config.php@@ above]] to avoid caching problems.%0a%0aIf you need the verbatim group and page name (from the request) early in @@config.php@@, $pagename is guaranteed to be set to%0a# Any value of ?n= if it's set, or%0a# Any value of ?pagename= if it's set, or%0a# The "path info" information from REQUEST_URI (whatever follows SCRIPT_NAME), or%0a# Blank otherwise%0aaccording to [[https://pmichaud.com/pipermail/pmwiki-users/2011-May/058905.html|this posting]]%0a%0aQ: Can I remove items from the wikilib.d folder on my site?%0aA: The files named Site.* and SiteAdmin.* contain parts of the interface and the configuration and they should not be removed. The other files named PmWiki* contain the documentation and could be removed.%0a%0aQ: How do I customize my own 404 error page for non-existent pages?%0aA: To change the text of the message, try editing the [[Site.PageNotFound]] page.%0a%0aQ: Is the order of customizations in config.php important? Are there certain things that should come before or after others in that file?%0aA: Yes, see [[LocalCustomizations#configphp-order|Order of the commands in @@config.php@@]]. +time=1663457731 blob - 5dbcd98ab627e5f099427af0e60c6ef63259edb0 blob + 919c320ec142d479a19563c3d1829ee786287c74 --- wikilib.d/PmWiki.MailingLists +++ wikilib.d/PmWiki.MailingLists @@ -1,10 +1,10 @@ -version=pmwiki-2.2.118 ordered=1 urlencoded=1 -author=Petko +version=pmwiki-2.3.17 ordered=1 urlencoded=1 +author=simon charset=UTF-8 -csum=fix `https +csum=hlt html, 2022 (+19) keywords=email lists name=PmWiki.MailingLists -rev=114 +rev=122 targets=PmWiki.PmWiki -text=(:Summary:The email discussion lists available and their archives:)(:keywords email lists:)%0aThere are several mailing lists available for [[PmWiki]].%0a %0a:[ [[(http://www.pmichaud.com/mailman/listinfo/)pmwiki-users]] ]: This is a great resource where a very helpful group of people will answer questions and discuss PmWiki development. As of 2016, traffic is around 20-40 messages a month. %0a->''If you ask a question on the list and it doesn't get answered, don't feel let down. Just'' '''''ask it again'''''. It probably slipped by unnoticed.%0a%0a->Archives are available from:%0a-->https://www.pmichaud.com/pipermail/pmwiki-users/ ([[https://www.pmwiki.org/search-ml.php|searchable]])%0a-->https://groups.google.com/group/pmwiki-users (searchable, but disconnected from main list in 2012.04, requires a google account)%0a-->https://www.mail-archive.com/pmwiki-users@pmichaud.com/info.html (searchable)%0a%0a%0a-->(:input form action='https://www.pmwiki.org/search-ml.php' method='get':)(:input text q:) (:input submit value='Search pmwiki-users archives':)(:input end:)%0a%0a:[ [[(https://www.pmichaud.com/mailman/listinfo/)pmwiki-users-de]] ]: A mailing list for german-speaking users of PmWiki. Archived at%0a-->https://www.pmichaud.com/pipermail/pmwiki-users-de%0a%0a:[ [[(https://www.pmichaud.com/mailman/listinfo/)pmwiki-users-es]] ]: Lista de usuarios PmWiki en Español.%0a%0a:[ [[(https://www.pmichaud.com/mailman/listinfo/)pmwiki-users-fr]] ]: A mailing list for french-speaking users of PmWiki.%0a%0a:[ [[(https://www.pmichaud.com/mailman/listinfo/)pmwiki-devel]] ]: This list was created to lower the traffic on pmwiki-users, it focuses on discussions surrounding code development for PmWiki (both core and recipe development).%0a%0a->Archives are available from:%0a-->https://www.pmichaud.com/pipermail/pmwiki-devel/ ([[https://www.pmwiki.org/search-ml.php|searchable]])%0a-->https://groups.google.com/group/pmwiki-devel (searchable)%0a-->https://www.mail-archive.com/pmwiki-devel@pmichaud.com/info.html (searchable)%0a%0a:[ [[(https://www.pmichaud.com/mailman/listinfo/)pmwiki-announce]] ]: Announcements of new version releases and urgent information, about 1-2 messages per month. If you use PmWiki in a production environment, this low-volume list is highly recommended. The archive is at:%0a-->https://www.pmichaud.com/pipermail/pmwiki-announce%0a%0aSuggestions:%0a* If you reply to a digest message, please remove the messages irrelevant to your reply before sending it back to the list. %0a** It's also helpful to change "Re: pmwiki-users Digest, Vol [...]" to "Re: [the original subject]" because some mail programs determine threads based on the subject.%0a* If you address a reply to a single list member, please take the [pmwiki-users] off the subject line, or it's possible for your message to get lost in the mailing list traffic. Many people filter list traffic to a separate mailbox.%0a* If you ask a question, you should disable "digest" mode, this way you'll receive the replies as soon as people post them, and you could follow-up. In digest mode you might receive the replies a week or two later.%0a%0a!! Changing mail list settings%0a%0aHere are some tips regarding changing the mailing list settings:%0a%0a* Logging in...%0a** First go to [[https://www.pmichaud.com/mailman/listinfo/pmwiki-users]]%0a and enter your e-mail address in the field at the bottom of the page,%0a to the left of the button ''Unsubscribe or edit options''.%0a** Next you need to enter your password. As you've probably forgotten this,%0a use the button ''Remind'' at the bottom of the page to get a new password.%0a** Finally enter the password you should get momentarily via e-mail.%0a%0a* You can directly go to the options web page through a URI such as the%0a following:%0a-> [@https://www.pmichaud.com/mailman/options/pmwiki-users/%3cuser>%2540%3cdomain>@]%0a-> where [@%3cuser>@] is everything before the [@@@] in an e-mail address,%0a and [@%3cdomain>@] is everything after (%0a For those who wonder, the [@%2540@] in the URI just stands for '[@@@]'.%0a%0a* You can also obtain various help by sending an email to%0a mailto:pmwiki-users-request@pmichaud.com with the text [@help@] in either%0a the subject or the body.%0a%0a!! Newsgroups (NNTP)%0aYou may be interested, that the lists are also accessible as newsgroups.%0a%0aThe NNTP server is:%0a* news.gmane.org '^[[http://news.gmane.org/search.php?match=pmwiki|#]]^'%0a%0aThe groups are:%0a* gmane.comp.web.wiki.pmwiki.user%0a* gmane.comp.web.wiki.pmwiki.announce%0a* gmane.comp.web.wiki.pmwiki.user.de%0a -time=1567282578 +text=(:Summary:The email discussion lists available and their archives:)(:keywords email lists:)%0aThere are several mailing lists available for [[PmWiki]].%0a %0a:[ [[(http://www.pmichaud.com/mailman/listinfo/)pmwiki-users]] ]: This is a great resource where a very helpful group of people will answer questions and discuss PmWiki development. As of 2022, traffic is around 20-40 messages a month. %0a->''If you ask a question on the list and it doesn't get answered, don't feel let down. Just'' '''''ask it again'''''. It probably slipped by unnoticed.%0a%0a->Archives are available from:%0a-->https://www.pmichaud.com/pipermail/pmwiki-users/ ([[https://www.pmwiki.org/search-ml.php|searchable here]])%0a-->https://www.mail-archive.com/pmwiki-users@pmichaud.com/info.html (searchable)%0a%0a%0a-->(:input form action='https://www.pmwiki.org/search-ml.php' method='get':)(:input text q:) (:input submit value='Search pmwiki-users archives':)(:input end:)%0a%0a:[ [[(https://www.pmichaud.com/mailman/listinfo/)pmwiki-users-de]] ]: A mailing list for german-speaking users of PmWiki. Archived at%0a-->https://www.pmichaud.com/pipermail/pmwiki-users-de%0a%0a:[ [[(https://www.pmichaud.com/mailman/listinfo/)pmwiki-users-es]] ]: Lista de usuarios PmWiki en Español.%0a%0a:[ [[(https://www.pmichaud.com/mailman/listinfo/)pmwiki-users-fr]] ]: A mailing list for french-speaking users of PmWiki.%0a%0a:[ [[(https://www.pmichaud.com/mailman/listinfo/)pmwiki-devel]] ]: This list was created to lower the traffic on pmwiki-users, it focuses on discussions surrounding code development for PmWiki (both core and recipe development).%0a%0a->Archives are available from:%0a-->https://www.pmichaud.com/pipermail/pmwiki-devel/ ([[https://www.pmwiki.org/search-ml.php|searchable]])%0a-->https://groups.google.com/group/pmwiki-devel (searchable)%0a-->https://www.mail-archive.com/pmwiki-devel@pmichaud.com/info.html (searchable)%0a%0a:[ [[(https://www.pmichaud.com/mailman/listinfo/)pmwiki-announce]] ]: Announcements of new version releases and urgent information, about 1-2 messages per month. If you use PmWiki in a production environment, this low-volume list is highly recommended. The archive is at:%0a-->https://www.pmichaud.com/pipermail/pmwiki-announce%0a%0aSuggestions:%0a* If you reply to a digest message, please remove the messages irrelevant to your reply before sending it back to the list. %0a** It's also helpful to change "@@Re: pmwiki-users Digest, Vol [...]" to "Re: [the original subject]@@" because some mail programs determine threads based on the subject.%0a* If you address a reply to a single list member, please take the [pmwiki-users] off the subject line, or it's possible for your message to get lost in the mailing list traffic. Many people filter list traffic to a separate mailbox.%0a* If you ask a question, you should disable "digest" mode, this way you'll receive the replies as soon as people post them, and you could follow-up. In digest mode you might receive the replies a week or two later.%0a%0a!! Changing mail list settings%0a%0aHere are some tips regarding changing the mailing list settings:%0a%0a* Logging in...%0a** First go to [[https://www.pmichaud.com/mailman/listinfo/pmwiki-users]]%0a and enter your e-mail address in the field at the bottom of the page,%0a to the left of the button ''Unsubscribe or edit options''.%0a** Next you need to enter your password. As you've probably forgotten this,%0a use the button ''Remind'' at the bottom of the page to get a new password.%0a** Finally enter the password you should get momentarily via e-mail.%0a%0a* You can directly go to the options web page through a URI such as the%0a following:%0a-> %25hlt html%25[@https://www.pmichaud.com/mailman/options/pmwiki-users/%3cuser>%2540%3cdomain>@]%0a-> where [@%3cuser>@] is everything before the [@@@] in an e-mail address,%0a and [@%3cdomain>@] is everything after.%0a (For those who wonder, the [@%2540@] in the URI just stands for '[@@@]').%0a%0a* You can also obtain various help by sending an email to%0a @@mailto:pmwiki-users-request@pmichaud.com@@ with the text [@help@] in either%0a the subject or the body.%0a%0a!! Newsgroups (NNTP)%0aYou may be interested, that the lists are also accessible as newsgroups.%0a%0aThe NNTP server is:%0a* [[news.gmane.io -> https://news.gmane.io/]]%0a%0aThe [[pmwiki groups -> https://admin.gmane.io/]] are:%0a* gmane.comp.web.wiki.pmwiki.user%0a* gmane.comp.web.wiki.pmwiki.announce%0a* gmane.comp.web.wiki.pmwiki.user.de%0a* gmane.comp.web.wiki.pmwiki.user.es %0a* gmane.comp.web.wiki.pmwiki.user.fr %0a* gmane.comp.web.wiki.pmwiki.devel%0a%0a!!! Gmane%0aIf you find a dead link to the PmWiki user groups at Gmane, it is now%0apossible to look for the reference, at https://www.pmwiki.org/search-ml.php and find your%0aanswers and/or update the documentation.%0a%0aYou may have to use the [[WayBack machine -> https://web.archive.org/]] to search by the original URL.%0a%0aThis is a basic and quite fast search function for messages in the [pmwiki-users] and [pmwiki-devel] mailing lists.%0a%0aGmane was a searchable mailing list archive that we used extensively to%0afind information or older discussions, and we also linked to it a lot%0aboth in the documentation and in our everyday messages. It disappeared%0ain 2016 and was only partially restored, so most of the links to it do%0anot work anymore.%0a%0a%0a%0a +time=1672863925 blob - 6fde04f3a0698b876cc1f4cb5f93b0812f14b520 blob + 41d651d6d1ec4eaaa973ae2689d1a4b85c194cb0 --- wikilib.d/PmWiki.MarkupExpressions +++ wikilib.d/PmWiki.MarkupExpressions @@ -1,10 +1,10 @@ -version=pmwiki-2.2.111 ordered=1 urlencoded=1 -author=MFWolff +version=pmwiki-2.3.13 ordered=1 urlencoded=1 +author=Petko charset=UTF-8 -csum=was ment to be inserted in PmWikiDe +csum=%25L, note about undefined formats into WikiStyles (+0) (+355) ctime=1176718061 name=PmWiki.MarkupExpressions -rev=92 -targets=PmWiki.BasicVariables,PmWiki.PageListTemplates,PmWiki.PageLists,PmWiki.WikiStyles,PmWiki.ConditionalMarkup,PmWiki.PageVariables,PmWiki.PageTextVariables,Cookbook.MarkupExpressionSamples,Cookbook.MarkupExprPlus -text=(:Summary:String and formatting operations:)%0a(:Audience: authors (advanced) :)%0a%0aThe [@{(...)}@] "expression markup" allows for a variety of string and formatting operations to be performed from within markup. Operations defined by this recipe include ''[[#substr|substr]]'', ''[[#ftime|ftime]]'', ''[[#strlen|strlen]]'', ''[[#rand|rand]]'', ''[[#mod|mod]]'', ''[[#to|toupper / tolower]]'', ''[[#ucfirst|ucfirst]]'', ''[[#ucwords|ucwords]]'', ''[[#pagename|pagename]]'' and ''[[#asspaced|asspaced]]''.%0aMarkup expressions can be [[#nesting|nested]], using the markup [@{(...(...)...)}@].%0a%0a[[#substr]]%0a!! ''substr''%0a%0aThe "substr" expression extracts portions of a string. The arguments are%0a# the string to be processed. Always quote the string to be processed.%0a# the initial position of the substring. Note that the initial position argument is zero-based (i.e., the first character is referenced via a "0").%0a# the number of characters to extract%0a(:markup class="horiz":)%0a {(substr "PmWiki" 2 3)}%0a {(substr "PmWiki" 2)}%0a {(substr "PmWiki" 0 1)}%0a {(substr "PmWiki" 0 -3)}%0a {(substr "PmWiki" -3)}%0a(:markupend:)%0a%0aTo obtain the last n characters of a string use [@{(substr "string" -n)}@]%0a[[%3c%3c]]%0aTo truncate the last n characters of a string use [@{(substr "string" 0 -n)}@]%0a%0a[[#ftime]]%0a!! ''ftime''%0a%0a"Ftime" expressions are used for date and time formatting. The generic form is%0a%0a->[@{(ftime "fmt" "when")}@]%0a->[@{(ftime fmt="fmt" when="when" tz="tz" locale="locale")}@]%0a%0awhere ''fmt'' is a formatting string and ''when'' is the time to be formatted. The arguments can be in either order and may use the optional "fmt=" and "when=" labels. %0a%0aThe "tz" (time zone) argument allows the setting of a different time zone, only available on installations running PHP 5.1 or newer. See [[http://php.net/timezones|the list of supported time zones]], any value not found there will be silently ignored.%0a%0aThe "locale" (language locale) argument allows the time format to be printed in a different language for names of weekdays and months, as long as that language locale is available on the server. You can set different locales to try, separated with commas or spaces, for example "fr_FR.utf8,fr_FR,fr". If none of the listed locales is available, the argument is silently ignored. %0a%0aWith international locales, if you see weird characters, try adding or removing the ".utf8" or ".UTF-8" part of the locale, e.g. try both "fr_FR.utf8" and "fr_FR" to see which one works for you. Wikis with UTF-8 enabled are more likely to need the ".utf8" part.%0a%0aExamples:%0a(:markup class="horiz":)%0a {(ftime)}%0a {(ftime fmt="%25F %25H:%25M")}%0a {(ftime %25Y)}%0a {(ftime fmt=%25T)}%0a {(ftime when=tomorrow)}%0a {(ftime fmt="%25Y-%25m-%25d" yesterday)}%0a {(ftime "+1 week" %25F)}%0a {(ftime fmt=%25D "+1 month")}%0a {(ftime fmt="%25a%25e %25b" when="next week")}%0a {(ftime fmt="%25A, %25d %25B %25Y, %25Hh%25M" locale=fr_FR.utf8 tz=Europe/Paris)}%0a(:markupend:)%0a%0aThe ''fmt'' parameter is whatever is given by "fmt=", the first parameter containing a '%25', or else the site's default. The formatting codes are described at %25newwin%25 http://php.net/strftime. In addition to those, [='%25F'=] produces ISO-8601 dates, and '%25s' produces Unix timestamps.%0aSome common formatting strings:%0a%0a [= %25F =] # ISO-8601 dates "{(ftime %25F)}"%0a [= %25s =] # Unix timestamp "{(ftime %25s)}"%0a [= %25H:%25M:%25S =] # time as hh:mm:ss "{(ftime %25H:%25M:%25S)}"%0a [= %25m/%25d/%25Y =] # date as mm/dd/yyyy "{(ftime %25m/%25d/%25Y)}"%0a [= "%25A, %25B %25d, %25Y" =] # in words "{(ftime "%25A, %25B %25d, %25Y")}"%0a%0aThe ''when'' parameter understands many different date %25newwin%25[[http://php.net/manual/en/datetime.formats.php|formats]]. The when parameter is whatever is given by "when=", or whatever parameter remains after determining the format parameter. Some examples:%0a%0a 2007-04-11 # ISO-8601 dates%0a 20070411 # dates without hyphens, slashes, or dots%0a 2007-03 # months%0a @1176304315 # Unix timestamps (seconds since 1-Jan-1970 00:00 UTC)%0a now # the current time%0a today # today @ 00:00:00%0a yesterday # yesterday @ 00:00:00%0a "next Monday" # relative dates%0a "last Thursday" # relative dates%0a "-3 days" # three days ago%0a "+2 weeks" # two weeks from now%0a%0a'''Note:''' If you want to convert a Unix timestamp you '''must''' prefix with the @. Thus, [@"{(ftime "%25A, %25B %25d, %25Y" @1231116927)}"@].%0a%0aThe ''when'' parameter uses PHP's %25newwin%25[[(http://www.php.net/)strtotime]] function to convert date strings according to the GNU [[http://www.gnu.org/software/tar/manual/html_node/Date-input-formats.html|date input formats]]; as of this writing it only understands English phrases in date specifications.%0a%0aThe variable $FTimeFmt can be used to override the default date format used by the "ftime" function. The default $FTimeFmt is $TimeFmt.%0a%0a[[#strlen]]%0a!! ''strlen''%0a%0aThe "strlen" expression returns the length of a string. The first argument is the string to be measured.%0a%0a(:markup class="horiz":)%0a {(strlen "{$:Summary}")}%0a(:markupend:)%0a%0a[[#rand]]%0a!! ''rand''%0a%0aThe "rand" expression returns a random integer. The first argument is the minimum number to be returned and the second argument is the maximum number to be returned. If called without the optional min, max arguments rand() returns a pseudo-random integer between 0 and RAND_MAX. If you want a random number between 5 and 15 (inclusive), for example, use (rand 5 15).%0a%0a(:markup class="horiz":)%0a {(rand)}%0a {(rand 1 99)}%0a(:markupend:)%0a%0a[[#mod]]%0a!! ''mod''%0a%0aThe advanced "mod" expression returns the modulo (remainder) of the division of two numbers. It may be used in advanced [[PageList templates]] together with [@{$$PageCount}@] to insert markup every (modulo) entries, for example to create alternate styled "zebra" table rows, or to insert a line/row break. (See also [[PageLists]], [[WikiStyles]] and [[ConditionalMarkup]].)%0a%0a(:markup class="horiz":)[@%0a>>comment%3c%3c%0a%25define=bg1 item bgcolor=#f88%25%0a%25define=bg2 item bgcolor=#ff8%25%0a%25define=bg0 item bgcolor=#8f8%25[=%0a[[#altrows]]%0a* %25bg{(mod {$$PageCount} 3)}%25 {=$Name} ({$$PageCount})%0a[[#altrowsend]]=]%0a>>%3c%3c%0a(:pagelist fmt=#altrows group=PmWiki count=10:)%0a@]%0a%0a[[#to]]%0a!! ''toupper'' / ''tolower''%0a%0aThe "toupper" and "tolower" expressions convert a string into uppercase or lowercase. The first argument is the string to be processed.%0a%0a(:markup class="horiz":)%0a {(toupper "{$:Summary}")}%0a {(tolower "{$:Summary}")}%0a(:markupend:)%0a%0a[[#ucfirst]][[#ucwords]]%0a!!''ucfirst'' / ''ucwords''%0a%0aThe "ucfirst" expression converts to uppercase the first character of the string, and "ucwords", the first character of each word. The first argument is the string to be processed.%0a%0a(:markup class="horiz":)%0a {(ucfirst "{$:Summary}")}%0a {(ucwords "{$:Summary}")}%0a(:markupend:)%0a%0a%0a[[#pagename]]%0a!! ''pagename''%0a%0aThe "pagename" expression builds a pagename from a string. The first argument is the string to be processed.%0a%0a(:markup class="horiz":)%0a {(pagename "{$:Summary}")}%0a(:markupend:)%0a%0a[[#asspaced]]%0a!! ''asspaced''%0a%0aThe "asspaced" expression formats wikiwords. The first argument is the string to be processed.%0a%0a(:markup class="horiz":)%0a {(asspaced "{$FullName}")}%0a(:markupend:)%0a%0a[[#nesting]]%0a!! Nesting expressions%0a%0aMarkup expressions can be nested. Omit the curly braces for the inner expressions:%0a%0a(:markup class="horiz":)%0a {(tolower (substr "Hello World" 2))}%0a(:markupend:)%0a%0a[[#notes]] %0a!! Notes%0a%0a* For PmWikis version 2.2.33 or older, the string-processing expressions may not work properly on multibyte UTF-8 characters. Newer versions should work fine.%0a%0a!! See also%0a* [[Page variables]], [[Page text variables]]%0a* [[Conditional markup]]%0a* Cookbook:MarkupExpressionSamples — '-custom markup expression samples-'%0a* Cookbook:MarkupExprPlus -time=1544859882 +rev=105 +targets=Cookbook.LocalTimes,PmWiki.WikiStyles,PmWiki.BasicVariables,PmWiki.PageListTemplates,PmWiki.PageLists,PmWiki.ConditionalMarkup,Cookbook.MarkupExpressionSamples,Cookbook.MarkupExprPlus +text=(:Summary:String and formatting operations:)%0a(:Audience: authors (advanced) :)%0aThe %25pmhlt%25[@{(...)}@] "expression markup" allows for a variety of string and formatting operations to be performed from within markup. Operations defined by this recipe include ''[[#substr|substr]]'', ''[[#ftime|ftime]]'', ''[[#strlen|strlen]]'', ''[[#rand|rand]]'', ''[[#mod|mod]]'', ''[[#to|toupper / tolower]]'', ''[[#ucfirst|ucfirst]]'', ''[[#ucwords|ucwords]]'', ''[[#pagename|pagename]]'' and ''[[#asspaced|asspaced]]''.%0aMarkup expressions can be [[#nesting|nested]], using the markup [@{(...(...)...)}@].%0a%0a[[#substr]]%0a!! ''substr''%0a%0aThe "substr" expression extracts portions of a string. The arguments are%0a# the string to be processed. Always quote the string to be processed.%0a# the initial position of the substring. Note that the initial position argument is zero-based (i.e., the first character is referenced via a "0").%0a# the number of characters to extract%0a(:markup class="horiz":)%0a {(substr "PmWiki" 2 3)}%0a {(substr "PmWiki" 2)}%0a {(substr "{*$Group}" 2)}%0a {(substr "PmWiki" 0 1)}%0a {(substr "PmWiki" 0 -3)}%0a {(substr "PmWiki" -3)}%0a(:markupend:)%0a%0aTo obtain the last n characters of a string use %25pmhlt%25[@{(substr "string" -n)}@]%0a[[%3c%3c]]%0aTo truncate the last n characters of a string use %25pmhlt%25[@{(substr "string" 0 -n)}@]%0a%0a[[#ftime]]%0a!! ''ftime''%0a%0a"Ftime" expressions are used for date and time formatting. The generic form is%0a%0a->%25pmhlt%25[@{(ftime "fmt" "when")}@]%0a->%25pmhlt%25[@{(ftime fmt="fmt" when="when" tz="tz" locale="locale")}@]%0a%0awhere ''fmt'' is a formatting string and ''when'' is the time to be formatted. The arguments can be in either order and may use the optional "fmt=" and "when=" labels. %0a%0aThe "tz" (time zone) argument allows the setting of a different time zone, only available on installations running PHP 5.1 or newer. See [[https://www.php.net/timezones|the list of supported time zones]], any value not found there will be silently ignored.%0a%0aThe "locale" (language locale) argument allows the time format to be printed in a different language for names of weekdays and months, as long as that language locale is available on the server. You can set different locales to try, separated with commas or spaces, for example "fr_FR.utf8,fr_FR,fr". If none of the listed locales is available, the argument is silently ignored. %0a%0aWith international locales, if you see weird characters, try adding or removing the ".utf8" or ".UTF-8" part of the locale, e.g. try both "fr_FR.utf8" and "fr_FR" to see which one works for you. Wikis with UTF-8 enabled are more likely to need the ".utf8" part.%0a%0aExamples:%0a(:markup class="horiz":)%0a {(ftime)}%0a {(ftime fmt="%25F %25H:%25M")}%0a {(ftime %25Y)}%0a {(ftime fmt=%25T)}%0a {(ftime when=tomorrow)}%0a {(ftime fmt="%25Y-%25m-%25d" yesterday)}%0a {(ftime "+1 week" %25F)}%0a {(ftime fmt=%25D "+1 month")}%0a {(ftime fmt="%25a%25e %25b" when="next week")}%0a {(ftime fmt="%25A, %25d %25B %25Y, %25Hh%25M" locale=fr_FR.utf8 tz=Europe/Paris)}%0a(:markupend:)%0a%0aThe ''fmt'' parameter is whatever is given by "fmt=", the first parameter containing a '%25', or else the site's default. The formatting codes are described at PHP's %25newwin%25 [[https://www.php.net/manual/en/function.strftime.php | strftime]] function. In addition to those, '[=%25o=]' produces the ordinal suffix ("st" for 1st), '[=%25F=]' produces ISO-8601 dates like 2022-10-30, '[=%25s=]' produces Unix timestamps, and '[=%25L=]' produces a format like %25pmhlt%25[@@2022-10-30T01:27:34Z@] which can be displayed in the timezone of the visitor per Cookbook:LocalTimes.%0a%0aSome common formatting strings:%0a%0a [= %25F =] # ISO-8601 dates "{(ftime %25F)}"%0a [= %25s =] # Unix timestamp "{(ftime %25s)}"%0a [= %25H:%25M:%25S =] # time as hh:mm:ss "{(ftime %25H:%25M:%25S)}"%0a [= %25m/%25d/%25Y =] # date as mm/dd/yyyy "{(ftime %25m/%25d/%25Y)}"%0a [= "%25A, %25B %25e%25o, %25Y"=] # in words "{(ftime "%25A, %25B %25e%25o, %25Y")}"%0a%0aNote that if you use an undefined format string such as [@%25q@] or [@%25E@], it will be left unchanged by ''ftime'', but later PmWiki may process it as a [[WikiStyle(s)]] which may be unexpected.%0a%0aThe ''when'' parameter understands many different date %25newwin%25[[https://www.php.net/manual/en/datetime.formats.php|formats]]. The when parameter is whatever is given by "when=", or whatever parameter remains after determining the format parameter. Some examples:%0a%0a 2007-04-11 # ISO-8601 dates%0a 20070411 # dates without hyphens, slashes, or dots%0a 2007-03 # months%0a @1176304315 # Unix timestamps (seconds since 1-Jan-1970 00:00 UTC)%0a now # the current time%0a today # today @ 00:00:00%0a yesterday # yesterday @ 00:00:00%0a "next Monday" # relative dates%0a "last Thursday" # relative dates%0a "-3 days" # three days ago%0a "+2 weeks" # two weeks from now%0a%0a'''Note:''' If you want to convert a Unix timestamp you '''must''' prefix with the @. Thus, %25pmhlt%25[@"{(ftime "%25A, %25B %25d, %25Y" @1231116927)}"@].%0a%0aThe ''when'' parameter uses PHP's %25newwin%25[[https://www.php.net/strtotime | strtotime]] function to convert date strings according to the GNU [[https://www.gnu.org/software/tar/manual/html_node/Date-input-formats.html|date input formats]]; as of this writing it only understands English phrases in date specifications.%0a%0aThe variable $FTimeFmt can be used to override the default date format used by the "ftime" function. The default $FTimeFmt is $TimeFmt.%0a%0a[[#strlen]]%0a!! ''strlen''%0a%0aThe "strlen" expression returns the length of a string. The first argument is the string to be measured.%0a%0a(:markup class="horiz":)%0a {(strlen "{$:Summary}")}%0a(:markupend:)%0a%0a[[#rand]]%0a!! ''rand''%0a%0aThe "rand" expression returns a random integer. The first argument is the minimum number to be returned and the second argument is the maximum number to be returned. If called without the optional min, max arguments rand() returns a pseudo-random integer between 0 and RAND_MAX. If you want a random number between 5 and 15 (inclusive), for example, use (rand 5 15).%0a%0a(:markup class="horiz":)%0a {(rand)}%0a {(rand 1 99)}%0a(:markupend:)%0a%0a[[#mod]]%0a!! ''mod''%0a%0aThe advanced "mod" expression returns the modulo (remainder) of the division of two numbers. It may be used in advanced [[PageList templates]] together with %25pmhlt%25[@{$$PageCount}@] to insert markup every (modulo) entries, for example to create alternate styled "zebra" table rows, or to insert a line/row break. (See also [[PageLists]], [[WikiStyles]] and [[ConditionalMarkup]].)%0a%0a(:markup class="horiz":)[@%0a>>comment%3c%3c%0a%25define=bg1 item bgcolor=#f88%25%0a%25define=bg2 item bgcolor=#ff8%25%0a%25define=bg0 item bgcolor=#8f8%25[=%0a[[#altrows]]%0a* %25bg{(mod {$$PageCount} 3)}%25 {=$Name} ({$$PageCount})%0a[[#altrowsend]]=]%0a>>%3c%3c%0a(:pagelist fmt=#altrows group=PmWiki count=10:)%0a@]%0a%0a[[#to]]%0a!! ''toupper'' / ''tolower''%0a%0aThe "toupper" and "tolower" expressions convert a string into uppercase or lowercase. The first argument is the string to be processed.%0a%0a(:markup class="horiz":)%0a {(toupper "{$:Summary}")}%0a {(tolower "{$:Summary}")}%0a(:markupend:)%0a%0a[[#ucfirst]][[#ucwords]]%0a!!''ucfirst'' / ''ucwords''%0a%0aThe "ucfirst" expression converts to uppercase the first character of the string, and "ucwords", the first character of each word. The first argument is the string to be processed.%0a%0a(:markup class="horiz":)%0a {(ucfirst "{$:Summary}")}%0a {(ucwords "{$:Summary}")}%0a(:markupend:)%0a%0a%0a[[#pagename]]%0a!! ''pagename''%0a%0aThe "pagename" expression builds a pagename from a string. The first argument is the string to be processed.%0a%0a(:markup class="horiz":)%0a {(pagename "{$:Summary}")}%0a(:markupend:)%0a%0a[[#asspaced]]%0a!! ''asspaced''%0a%0aThe "asspaced" expression formats wikiwords. The first argument is the string to be processed.%0a%0a(:markup class="horiz":)%0a {(asspaced "{$FullName}")}%0a(:markupend:)%0a%0a[[#nesting]]%0a!! Nesting expressions%0a%0aMarkup expressions can be nested. Omit the curly braces for the inner expressions:%0a%0a(:markup class="horiz":)%0a {(tolower (substr "Hello World" 2))}%0a(:markupend:)%0a%0a[[#notes]] %0a!! Notes%0a%0a* For PmWikis version 2.2.33 or older, the string-processing expressions may not work properly on multibyte UTF-8 characters. Newer versions should work fine.%0a%0a!! See also%0a(:pagelist group=PmWiki name=PageVariables,PageTextVariables,ConditionalMarkup fmt=#titlesummary:)%0a* Cookbook:MarkupExpressionSamples — '-custom markup expression samples-'%0a* Cookbook:MarkupExprPlus +time=1667098724 blob - f82f13ea995b9c307c191225ca776ef9d0129bc0 blob + 25725aa7a36502463b6c1c1707edfbd458fa621e --- wikilib.d/PmWiki.MarkupMasterIndex +++ wikilib.d/PmWiki.MarkupMasterIndex @@ -1,10 +1,10 @@ -version=pmwiki-2.2.129 ordered=1 urlencoded=1 +version=pmwiki-2.3.17 ordered=1 urlencoded=1 author=simon charset=UTF-8 -csum=[=link address (+109) +csum=add $[phrase] (+29) name=PmWiki.MarkupMasterIndex -rev=278 -targets=PmWiki.WikiStyles,PmWiki.ListStyles,PmWiki.Links,PmWiki.WikiWord,PmWiki.Categories,PmWiki.InterMap,PmWiki.Uploads,PmWiki.LinkSchemes,PmWiki.Images,PmWiki.TextFormattingRules,Cookbook.OutlineLists,PmWiki.BlockMarkup,PmWiki.PageDirectives,PmWiki.Tables,PmWiki.TableDirectives,PmWiki.GroupHeaders,PmWiki.CommentMarkup,PmWiki.PageVariables,PmWiki.IncludeOtherPages,PmWiki.PageTextVariables,PmWiki.ConditionalMarkup,PmWiki.PageLists,PmWiki.TableOfContents,PmWiki.Forms,PmWiki.WikiTrails,PmWiki.PageListTemplates,PmWiki.MarkupExpressions -text=(:title Markup Master Index:)%0a(:Summary:Tabulation of all PmWiki markup:)%0aThis page contains the most frequently used wiki markup, briefly. Follow the links in each section to learn more.%0a%0a!! Markup concepts introduction%0aPmWiki markup can be applied to 'blocks' of text, and to text 'lines'.%0aPmWiki markup is also used to read and save page, group, and wiki metadata through the use of variables. %0aPmWiki markup can be used to process metadata variables though expressions and [[#PageLists|pagelists]].%0aPmWiki provides a [[WikiStyles|wiki style]] markup that can be applied to text, [[ListStyles|lists]], paragraphs, and blocks.%0a%0aText markup, also known as wikitext is variable, see below, and in general broadly follows wiki conventions. %0aText markup only applies to single lines of text, delimited by a [[Wikipedia:Newline|newline]].%0a%0aBlock markup is applied to multiple lines of text as [[#BlockMarkups|paragraph blocks]] and [[#DivisionBlocks|division blocks]].%0a%0aIn PmWiki the most important markup is the [[#Directives|directive]]. %0aThe directive is signified by parenthesis and a colon, viz: [@(:...:)@].%0aThe directive provides most of PmWiki's functionality. %0a%0a[[#Expressions|Markup expressions]] [@{(...)}@], [[#PageVariables|variable markup]] [@{$...}@], and [[wiki styles]] [@%25...%25@] also provide PmWiki functionality.%0a%0a!! [[#LinkMarkups]] Links%0a%0aSee [[Links]]%0a!!![[#ExternalLinks]]External links%0a-%3c [@ http://example.com@]%0a-%3c [@ [[http://example.com]] @]%0a-%3c [@ [[http://example.com"tool tip"]] @]%0a-%3c [@ [[http://example.com | link text]] @]%0a-%3c [@ [[link text -> http://example.com]] @]%0aUse [@[=link address=]@] to escape any special characters, including quotes, spaces, parentheses and pipes. %0a%0a[[#InternalLinks]]%0a!!! Page links%0a-%3c [@ [[PageName]] @]%0a-%3c [@ [[page name]] @]%0a-%3c [@ [[page (name)]] @]%0a-%3c [@ [[PageName | link text]] @]%0a-%3c [@ [[PageName | + ]] @] ''(titled link)''%0a-%3c [@ [[PageName | # ]] @] ''(anonymous numerical reference link)''%0a-%3c [@ [[PageName"tool tip"]] @]%0a-%3c [@ [[link text -> PageName]] @]%0a-%3c [@ [[#anchor]] @] ''(to create an anchor)''%0a-%3c [@ [[#anchor | link text]] @] ''(to refer to an anchor)''%0a-%3c [@ [[anchor | # ]] @] ''(anonymous numerical reference link)''%0a-%3c [@ [[PageName#anchor | link text]] @] ''(to refer to an anchor in another page)''%0a%0a%0aSee also [[WikiWord]] on how to enable [@WikiWord@] links.%0a%0a[[#WikiGroupLinks]]%0a!!! WikiGroup links%0aSee [[Links]] and [[Categories]] %0a-%3c [@ [[GroupName/]] or [[Group name/]] @]%0a-%3c [@ [[GroupName"tool tip"]] @]%0a-%3c [@ [[GroupName.]] @]%0a-%3c [@ [[GroupName/PageName]] or [[GroupName/page name]] @]%0a-%3c [@ [[(GroupName.)page name]] @]%0a%0a-%3c [@ [[~Author Name]] @]%0a-%3c [@ [[~Author Name | +]] @]%0a-%3c [@ [[~Author Name | #]] @]%0a-%3c [@ [[~Author Name | link text]] @]%0a-%3c [@ [[~Author Name"tool tip"]] @]%0a-%3c [@ [[!Category Name]] @]%0a%0a[[#IntermapLinks]]%0a!!! InterMap links%0aSee [[InterMap]]%0a-%3c [@ [[Path:/path/local_document.html]] @]%0a-%3c [@ [[Wikipedia:WikiWikiWeb]] @]%0a%0a[[#EmailLinks]]%0a!!! Email links%0a-%3c [@ mailto:someone@example.com @]%0a-%3c [@ [[(mailto:)someone@example.com]] @]%0a-%3c [@ [[mailto:someone@example.com | display text]] @]%0a-%3c [@ [[display text -> mailto:someone@example.com]] @]%0a%0a[[#UploadLinks]]%0a!!! Upload links%0aSee [[Uploads]] and [[#Images|Images]]%0a-%3c [@ Attach:file.odt @]%0a-%3c [@ [[(Attach:)file.odt]] @]%0a-%3c [@ [[Attach:file.odt | alternative text ]] @]%0a-%3c [@ [[Attach:file with spaces.pdf]] @]%0a-%3c [@ [[Attach:Groupname./file with spaces.pdf]] @]%0a%0a[[#linkschemes]]%0a!!! [[Link Schemes]]%0aIn addition to @@http:@@, @@https:@@, @@mailto:@@ PmWiki also supports:%0a-%3c @@ftp:@@%0a-%3c @@news:@@%0a-%3c @@gopher:@@%0a-%3c @@nap:@@%0a-%3c @@file:@@%0a-%3c @@tel:@@%0a-%3c @@geo:@@%0a%0a!! [[#Images]] Images%0a%0aSee [[Images]] and [[Uploads]]%0a!!! [[#ImagesAsImages]] Images as Images%0a-%3c [@http://example.com/image.gif@]%0a-%3c [@http://example.com/image.gif"alt text"@]%0a-%3c [@Attach:image.gif"My image"@]%0a-%3c [@Attach:Groupname./image.gif"image in another group"@]%0a-%3c [@Attach:Groupname.Pagename/image.gif"image on another page"@]%0a-%3c [@%25lfloat%25 Attach:image.gif | Caption %25%25@] ''(could be [=%25rfloat%25, %25center%25, %25rframe%25, %25lframe%25, %25frame%25 =])''%0a-%3c [@%25width=200px%25 Attach:image.gif %25%25@]%0a-%3c [@%25thumb%25 Attach:image.gif %25%25@]%0a%0a%0a!!! [[#ImagesAsLinks]] Images as links%0a%0a-%3c [@ [[Attach:image.gif]] @]%0a-%3c [@ [[(Attach:)image.gif]] @]%0a-%3c [@ [[PageName | Attach:image.gif"alt text"]] @]%0a-%3c [@ [[http://example.com/ | Attach:image.gif"alt text"]] @]%0a-%3c [@ [[http://example.com/ | http://example.com/image.png"alt text"]] | Caption @]%0a-%3c [@%25rframe thumb%25 [[Attach:image.gif | Attach:image.gif"alt text"]] | Caption @]%0a%0a%0a!! [[#StartOfLine]] Start-of-line markup%0a%0aSee [[Text formatting rules]]%0a%0a!!! [[#Lists]] [[PmWiki/TextFormattingRules#BulletedLists| Lists]]%0a%0aSee [[(PmWiki:)List styles]], [[Wiki styles]] and [[Cookbook:Outline lists]]%0a-%3c [@* unordered list@]%0a-%3c [@** deeper list@]%0a-%3c [@# ordered list@]%0a-%3c [@# %25item value=#%25@] arbitrary start number%0a-%3c [@# %25decimal%25, %25roman%25, %25ROMAN%25, %25alpha%25, %25ALPHA%25 @]%0a-%3c [@%25comment%25 @]%0a-%3c [@:term:definition@]%0aAlso%0a-%3c [@Q:@] start a question paragraph%0a-%3c [@A:@] start an answer paragraph%0a%0a%0a!!! [[#Headings]] Headings%0a%0a-%3c [@!! Heading@]%0a-%3c [@!!! Deeper heading@]%0a%0a%0a!!! [[#BlockMarkups]] Paragraph blocks%0a%0a-%3c [@-> indented text@]%0a-%3c [@-%3c hanging indent@]%0a-%3c [@%3cspace> preformatted text@]%0a-%3c @@[=[@...@]=]@@ preformatted block%0a-%3c [@----@] (horizontal rule)%0a-%3c [@blank line@] is vertical space%0a-%3c [@\@] at end of line joins next line%0a-%3c [@\\@] at end of line produces a line break%0a-%3c [@\\\@] at the end of a line produces a blank line, even within a list item, n backslashes will produce n-1 blank lines%0a-%3c [@ [[%3c%3c]] @] produces a line break that clears floating content%0a%0a%0a!!! [[#DivisionBlocks]] Division blocks%0a%0aSee [[Block markup]], [[Wiki styles]] and [[Page directives]]%0a-%3c [@>>wikistyle%3c%3c@]%0a-%3c [@>>%3c%3c@]%0a-%3c [@ (:div class="" style="":) @]%0a-%3c [@ (:divend:) @]%0a-%3c [@>>comment%3c%3c@] %0a%0a%0a!! [[#Text]] Text markup%0a%0aSee [[Text formatting rules]]%0a!!! [[#InlineMarkups]] Character format%0a%0a-%3c [@''emphasized''@] %0a-%3c [@'''strong'''@]%0a-%3c [@'''''strong emphasis'''''@]%0a-%3c [@@@monospaced@@@]%0a-%3c [@[-small-], [--smaller--]@]%0a-%3c [@[+big+], [++bigger++]@]%0a-%3c [@'-small-', '+big+'@]%0a-%3c [@'^superscript^', '_subscript_'@]%0a-%3c [@{+inserted+} (underscore)@]%0a-%3c [@{-deleted-} (strikethrough)@]%0a-%3c @@[=[@escaped code@]=]@@%0a-%3c [@[=escaped text=]@]%0a%0a%0a!!! [[#PostingMarkups]] Posting markup%0a%0a-%3c @@~~@@@@~@@ (author's signature)%0a-%3c @@~~@@@@~~@@ (author's signature and date)%0a-%3c @@[=(:encrypt=] ''phrase''[=:)=]@@ -- replaced with encrypted form of ''phrase''%0a%0a%0a!! [[#Tables]] Tables%0a%0a!!! [[#PlainTables]] Plain rows and columns of text%0a%0aSee [[Tables]]%0a-%3c [@||table attributes@]%0a-%3c [@||!table caption!||@]%0a-%3c [@||left aligned || centered || right aligned||@]%0a-%3c [@||!column heading||@]%0a-%3c [@||spanned columns ||||||@]%0a%0a!!! [[#TablesAndDivs]] Structured tables%0a%0aSee [[Table directives ]]%0a-%3c [@ (:table attr:) @]%0a-%3c [@ (:cellnr attr:) @]%0a-%3c [@ (:cell attr:) @]%0a-%3c [@ (:tableend:) @]%0a%0a!! [[#Directives]] Directives%0a%0a!!! [[#PageDirectives]] Page directives%0a%0aSee [[Page directives]]%0a-%3c [@ (:redirect PageName:) @]%0a%0a-%3c [@ (:(no)spacewikiwords:) @]%0a-%3c [@ (:(no)linkwikiwords:) @]%0a-%3c [@ (:(no)linebreaks:) @]%0a%0a!!! [[#Display]] Display%0a%0aSee [[Page directives]] [[Group headers]]%0a-%3c [@ (:noheader:), (:nofooter:) @]%0a-%3c [@ (:notitle:) @]%0a-%3c [@ (:noleft:), (:noright:) @]%0a-%3c [@ (:nogroupheader:), (:nogroupfooter:) @]%0a-%3c [@ (:noaction:) @]%0a%0a%0a!!! [[#Metadata]] Metadata%0a%0aSee [[Page directives]], [[(PmWiki:)Comment markup]], [[Page variables]]%0a-%3c [@ (:title text:) @]%0a-%3c [@ (:keywords word, ...:) @]%0a-%3c [@ (:description text:) @]%0a-%3c [@ (:comment text:) @]%0a-%3c [@{Group/PageName$:variable}@] [-includes from [@ (:variable:text:) @]-]%0a%0a%0a!!! [[#IncludeOtherPages]] Include%0a%0aSee [[Include other pages]], [[Page text variables]]%0a-%3c [@ (:include PageName:) @]%0a-%3c [@ (:include PageName#start#end lines=n paras=n:) @]%0a-%3c [@ (:include Page1 Page2 Page3:) @]%0a-%3c [@{Group/PageName$:Var}@] [-includes from [@ (:name:text:) @]-]%0a-%3c [@ (:nl:) @] [-separate included text by conditional line break-]%0a%0a!!! [[#ConditionalMarkup]] Conditional markup%0a%0aSee [[Conditional markup]]%0a-%3c [@ (:if (!)@] ''cond param''[@:)...(:ifend:)@]%0a-%3c [@ (:if (!)@] ''cond param''[@:)...(:else:)...(:ifend:)@]%0a-%3c [@ (:if (!)@] ''cond param''[@:)...(:elseif (!)@] ''cond param''[@:)...(:ifend:) @]%0a%0a%0a!!! [[#PageLists]] Pagelists%0a%0aSee [[Page lists]]%0a-%3c [@ (:searchbox label=label order=-time:) @]%0a-%3c [@ (:searchresults incl -excl group=abc fmt=def:) @]%0a-%3c [@ (:pagelist incl -excl group=abc fmt=def:) @]%0a%0a%0a!!! [[#OtherDirectives]] Other directives%0a%0aSee [[Page directives]]%0a-%3c [@ (:@][[TableOfContents|toc]][@:) @]%0a-%3c [@ (:@][[PageDirectives#attachlist|attachlist]][@:) @]%0a-%3c [@ (:@][[PageDirectives#markup]][@:) @] [@ [=...=] @]%0a-%3c [@ (:markup:)...(:markupend:) @]%0a-%3c [@ (:markup class=horiz:)...(:markupend:) @]%0a-%3c [@ (:markup caption='...':)...(:markupend:) @]%0a-%3c [@ (:messages:) @]%0a%0a%0a!! [[#Forms]] Forms%0a%0aSee [[PmWiki/Forms]]%0a-%3c [@ (:input form method=get action=url enctype=multipart/form-data:) @]%0a--%3c [@ (:input default name=xyz value="abc":) @]%0a--%3c [@ (:input text name=first value="Bob" size=20:) @]%0a--%3c [@ (:input textarea name=xyz [=value=] rows=2 cols=80:) @]%0a--%3c [@ (:input submit name=post value="Go" accesskey=g:) @]%0a--%3c [@ (:input reset:) @]%0a--%3c [@ (:input hidden name=action value=edit:) @]%0a--%3c [@ (:input radio name=xyz value="abc" checked=1:) @]%0a--%3c [@ (:input checkbox name=xyz value="abc" checked=1:) @]%0a--%3c [@ (:input password name=authpw:) @]%0a--%3c [@ (:input file name=upload:) @]%0a--%3c [@ (:input image name=xyz src="http:..." alt="Alt Text":) @]%0a--%3c [@ (:input select name=xyz value="val1" label="Value 1":) @]%0a--%3c [@ (:input select name=xyz value="val2" label="Value 2":) @]%0a-%3c [@ (:input end:) @]%0a%0aSee also [[PmWiki/Forms#pageeditcontrols|PmWiki Edit forms]].%0a%0a!! [[#WikiTrails]] Wiki trails%0a%0aSee [[Wiki trails]]%0a-%3c [@%3c%3c|[[TrailPage]]|>>@]%0a-%3c [@%3c|[[TrailPage]]|>@]%0a-%3c [@^|[[TrailPage]]|^@]%0a%0a%0a!! [[#PageVariables]] Page variables%0a%0aSee [[Page variables]], [[Page text variables]], [[PmWiki/PageLists#pagetextvariables|Page lists]]%0a-%3c [@ {@]''[@$variable@]''[@}@], [@ {@]''[@pagename$variable@]''[@}@], [@ {@]''[@groupname.pagename$variable@]''[@} @]%0a-%3c [@ {@]''[@$:variable@]''[@}@], [@ {@]''[@pagename$:variable@]''[@}@], [@ {@]''[@groupname.pagename$:variable@]''[@} @]%0aSet a [[page text variable(s)]]%0a-%3c [@ (:name:description:) @] %0a-%3c [@ :name:description @] %0a-%3c [@ name:description @] %0aSee [[http://www.pmwiki.org/wiki/PmWiki/PageVariables#specialreferences | special references]]%0a-%3c [@ {@]''[@*$variable@]''[@} @]%0a-%3c [@ {@]''[@*$:variable@]''[@} @]%0a[[Page list templates]] [[http://www.pmwiki.org/wiki/PmWiki/PageListTemplates#specialreferences | special variables]]%0a-%3c [@ {@]''[@=$variable@]''[@}@], [@ {@]''[@%3c$variable@]''[@}@], [@ {@]''[@>$variable@]''[@}@],%0a-%3c [@ {@]''[@=$:variable@]''[@}@], [@ {@]''[@%3c$:variable@]''[@}@], [@ {@]''[@>$:variable@]''[@}@],%0a%0a%0a!! [[#Expressions]] Expressions%0a%0aSee [[Markup expressions]]%0a-%3c [@ {(@]''[@function args@]''[@)} @] -time=1590308050 +rev=288 +targets=PmWiki.WikiStyles,PmWiki.ListStyles,PmWiki.Links,PmWiki.WikiWord,PmWiki.Categories,PmWiki.InterMap,PmWiki.Uploads,PmWiki.LinkSchemes,PmWiki.Images,PmWiki.TextFormattingRules,Cookbook.WikiStylesPlus,PmWiki.BlockMarkup,PmWiki.PageDirectives,PmWiki.Tables,PmWiki.TableDirectives,PmWiki.GroupHeaders,PmWiki.CommentMarkup,PmWiki.PageVariables,PmWiki.IncludeOtherPages,PmWiki.PageTextVariables,PmWiki.ConditionalMarkup,PmWiki.PageLists,PmWiki.TableOfContents,PmWiki.Forms,PmWiki.WikiTrails,PmWiki.PageListTemplates,PmWiki.Internationalizations,PmWiki.SkinTemplates,PmWiki.MarkupExpressions +text=(:title Markup Master Index:)%0a(:Summary:Tabulation of all PmWiki markup:)%0aThis page contains the most frequently used wiki markup, briefly. Follow the links in each section to learn more.%0a%0a!! Markup concepts introduction%0aPmWiki markup can be applied to 'blocks' of text, and to text 'lines'.%0aPmWiki markup is also used to read and save page, group, and wiki metadata through the use of variables. %0aPmWiki markup can be used to process metadata variables though expressions and [[#PageLists|pagelists]].%0aPmWiki provides a [[WikiStyles|wiki style]] markup that can be applied to text, [[ListStyles|lists]], paragraphs, and blocks.%0a%0aText markup, also known as wikitext is variable, see below, and in general broadly follows wiki conventions. %0aText markup only applies to single lines of text, delimited by a [[Wikipedia:Newline|newline]].%0a%0aBlock markup is applied to multiple lines of text as [[#BlockMarkups|paragraph blocks]] and [[#DivisionBlocks|division blocks]].%0a%0aIn PmWiki the most important markup is the [[#Directives|directive]]. %0aThe directive is signified by parenthesis and a colon, viz: %25pmhlt%25[@(:...:)@].%0aThe directive provides most of PmWiki's functionality. %0a%0a[[#Expressions|Markup expressions]] %25pmhlt%25[@{(...)}@], [[#PageVariables|variable markup]] [@{$...}@], and [[wiki styles]] [@%25...%25@] also provide PmWiki functionality.%0a%0a!! [[#LinkMarkups]] Links%0a%0aSee [[Links]]%0a!!![[#ExternalLinks]]External links%0a-%3c %25pmhlt%25[@https://example.com@]%0a-%3c %25pmhlt%25[@[[https://example.com]] @]%0a-%3c %25pmhlt%25[@[[https://example.com"tool tip"]] @]%0a-%3c %25pmhlt%25[@[[https://example.com | link text]] @]%0a-%3c %25pmhlt%25[@[[link text -> https://example.com]] @]%0aUse %25pmhlt%25[@[=link address=]@] to escape any special characters, including quotes, spaces, parentheses and pipes. %0a%0a[[#InternalLinks]]%0a!!! Page links%0a-%3c %25pmhlt%25[@[[PageName]] @]%0a-%3c %25pmhlt%25[@[[page name]] @]%0a-%3c %25pmhlt%25[@[[page (name)]] @]%0a-%3c %25pmhlt%25[@[[PageName | link text]] @]%0a-%3c %25pmhlt%25[@[[PageName | + ]] @] ''(titled link)''%0a-%3c %25pmhlt%25[@[[PageName | # ]] @] ''(anonymous numerical reference link)''%0a-%3c %25pmhlt%25[@[[PageName"tool tip"]] @]%0a-%3c %25pmhlt%25[@[[link text -> PageName]] @]%0a-%3c %25pmhlt%25[@[[#anchor]] @] ''(to create an anchor)''%0a-%3c %25pmhlt%25[@[[#anchor | link text]] @] ''(to refer to an anchor)''%0a-%3c %25pmhlt%25[@[[#anchor | # ]] @] ''(anonymous numerical reference link)''%0a-%3c %25pmhlt%25[@[[PageName#anchor | link text]] @] ''(to refer to an anchor in another page)''%0a%0a%0aSee also [[WikiWord]] on how to enable [@WikiWord@] links.%0a%0a[[#WikiGroupLinks]]%0a!!! WikiGroup links%0aSee [[Links]] and [[Categories]] %0a-%3c %25pmhlt%25[@[[GroupName/]] or [[Group name/]] @]%0a-%3c %25pmhlt%25[@[[GroupName"tool tip"]] @]%0a-%3c %25pmhlt%25[@[[GroupName.]] @]%0a-%3c %25pmhlt%25[@[[GroupName/PageName]] or [[GroupName/page name]] @]%0a-%3c %25pmhlt%25[@[[(GroupName.)page name]] @]%0a%0a-%3c %25pmhlt%25[@[[~Author Name]] @]%0a-%3c %25pmhlt%25[@[[~Author Name | +]] @]%0a-%3c %25pmhlt%25[@[[~Author Name | #]] @]%0a-%3c %25pmhlt%25[@[[~Author Name | link text]] @]%0a-%3c %25pmhlt%25[@[[~Author Name"tool tip"]] @]%0a-%3c %25pmhlt%25[@[[!Category Name]] @]%0a%0a[[#IntermapLinks]]%0a!!! InterMap links%0aSee [[InterMap]]%0a-%3c %25pmhlt%25[@[[Path:/path/local_document.html]] @]%0a-%3c %25pmhlt%25[@[[Wikipedia:WikiWikiWeb]] @]%0a%0a[[#EmailLinks]]%0a!!! Email links%0a-%3c %25pmhlt%25[@mailto:someone@example.com @]%0a-%3c %25pmhlt%25[@[[(mailto:)someone@example.com]] @]%0a-%3c %25pmhlt%25[@[[mailto:someone@example.com | display text]] @]%0a-%3c %25pmhlt%25[@[[display text -> mailto:someone@example.com]] @]%0a%0a[[#UploadLinks]]%0a!!! Upload links%0aSee [[Uploads]] and [[#Images|Images]]%0a-%3c %25pmhlt%25[@Attach:file.odt @]%0a-%3c %25pmhlt%25[@[[(Attach:)file.odt]] @]%0a-%3c %25pmhlt%25[@[[Attach:file.odt | alternative text ]] @]%0a-%3c %25pmhlt%25[@[[Attach:file with spaces.pdf]] @]%0a-%3c %25pmhlt%25[@[[Attach:Groupname./file with spaces.pdf]] @]%0a%0a[[#linkschemes]]%0a!!! [[Link Schemes]]%0aIn addition to %25pmhlt%25@@http:@@, @@https:@@, @@mailto:@@ PmWiki also supports:%0a-%3c %25pmhlt%25@@ftp:@@%0a-%3c %25pmhlt%25@@news:@@%0a-%3c %25pmhlt%25@@gopher:@@%0a-%3c %25pmhlt%25@@nap:@@%0a-%3c %25pmhlt%25@@file:@@%0a-%3c %25pmhlt%25@@tel:@@%0a-%3c %25pmhlt%25@@geo:@@%0a%0a!! [[#Images]] Images%0a%0aSee [[Images]] and [[Uploads]]%0a!!! [[#ImagesAsImages]] Images as Images%0a-%3c %25pmhlt%25[@https://example.com/image.gif@]%0a-%3c %25pmhlt%25[@https://example.com/image.gif"alt text"@]%0a-%3c %25pmhlt%25[@Attach:image.gif"My image"@]%0a-%3c %25pmhlt%25[@Attach:Groupname./image.gif"image in another group"@]%0a-%3c %25pmhlt%25[@Attach:Groupname.Pagename/image.gif"image on another page"@]%0a-%3c %25pmhlt%25[@%25lfloat%25 Attach:image.gif | Caption %25%25@] ''(could be [=%25rfloat%25, %25center%25, %25rframe%25, %25lframe%25, %25frame%25 =])''%0a-%3c %25pmhlt%25[@%25width=200px%25 Attach:image.gif %25%25@]%0a-%3c %25pmhlt%25[@%25thumb%25 Attach:image.gif %25%25@]%0a%0a%0a!!! [[#ImagesAsLinks]] Images as links%0a%0a-%3c %25pmhlt%25[@[[Attach:image.gif]] @]%0a-%3c %25pmhlt%25[@[[(Attach:)image.gif]] @]%0a-%3c %25pmhlt%25[@[[PageName | Attach:image.gif"alt text"]] @]%0a-%3c %25pmhlt%25[@[[https://example.com/ | Attach:image.gif"alt text"]] @]%0a-%3c %25pmhlt%25[@[[https://example.com/ | https://example.com/image.png"alt text"]] | Caption @]%0a-%3c %25pmhlt%25[@%25rframe thumb%25 [[Attach:image.gif | Attach:image.gif"alt text"]] | Caption @]%0a%0a%0a!! [[#StartOfLine]] Start-of-line markup%0a%0aSee [[Text formatting rules]]%0a%0a!!! [[#Lists]] [[PmWiki/TextFormattingRules#BulletedLists| Lists]]%0a%0aSee [[(PmWiki:)List styles]], [[Wiki styles]] and [[Cookbook:Wiki Styles Plus]]%0a-%3c %25pmhlt%25[@* unordered list@]%0a-%3c %25pmhlt%25[@** deeper list@]%0a-%3c %25pmhlt%25[@# ordered list@]%0a-%3c %25pmhlt%25[@# %25item value=#%25@] arbitrary start number%0a-%3c %25pmhlt%25[@# %25decimal%25, %25roman%25, %25ROMAN%25, %25alpha%25, %25ALPHA%25 @]%0a-%3c %25pmhlt%25[@%25comment%25 @]%0a-%3c %25pmhlt%25[@:term:definition@]%0aAlso%0a-%3c %25pmhlt%25[@Q:@] start a question paragraph%0a-%3c %25pmhlt%25[@A:@] start an answer paragraph%0a%0a%0a!!! [[#Headings]] Headings%0a%0a-%3c %25pmhlt%25[@!! Heading@]%0a-%3c %25pmhlt%25[@!!! Deeper heading@]%0a%0a%0a!!! [[#BlockMarkups]] Paragraph blocks%0a%0a-%3c %25pmhlt%25[@-> indented text@]%0a-%3c %25pmhlt%25[@-%3c hanging indent@]%0a-%3c %25pmhlt%25[@%3cspace> preformatted text@]%0a-%3c %25pmhlt%25@@[=[@...@]=]@@ preformatted block%0a-%3c %25pmhlt%25[@----@] (horizontal rule)%0a-%3c %25pmhlt%25[@blank line@] is vertical space%0a-%3c %25pmhlt%25[@\@] at end of line joins next line%0a-%3c %25pmhlt%25[@\\@] at end of line produces a line break%0a-%3c %25pmhlt%25[@\\\@] at the end of a line produces a blank line, even within a list item, n backslashes will produce n-1 blank lines%0a-%3c %25pmhlt%25[@[[%3c%3c]] @] produces a line break that clears floating content%0a%0a%0a!!! [[#DivisionBlocks]] Division blocks%0a%0aSee [[Block markup]], [[Wiki styles]] and [[Page directives]]%0a-%3c %25pmhlt%25[@>>wikistyle%3c%3c@]%0a-%3c %25pmhlt%25[@>>%3c%3c@]%0a-%3c %25pmhlt%25[@ (:div class="" style="":) @]%0a-%3c %25pmhlt%25[@ (:divend:) @]%0a-%3c %25pmhlt%25[@>>comment%3c%3c@] %0aSemantic HTML 5 elements%0a-%3c %25pmhlt%25[@(:article:)...(:articleend:)@]%0a-%3c %25pmhlt%25[@(:section:)...(:sectionend:)@]%0a-%3c %25pmhlt%25[@(:header:)...(:headerend:)@]%0a-%3c %25pmhlt%25[@(:footer:)...(:footerend:)@]%0a-%3c %25pmhlt%25[@(:aside:)...(:asideend:)@]%0a-%3c %25pmhlt%25[@(:address:)...(:addressend:)@]%0a-%3c %25pmhlt%25[@(:nav:)...(:navend:)@]%0a-%3c %25pmhlt%25[@(:details summary="Summary":)...(:detailsend:)@]%0a%0a%0a!! [[#Text]] Text markup%0a%0aSee [[Text formatting rules]]%0a!!! [[#InlineMarkups]] Character format%0a%0a-%3c %25pmhlt%25[@''emphasized''@] %0a-%3c %25pmhlt%25[@'''strong'''@]%0a-%3c %25pmhlt%25[@'''''strong emphasis'''''@]%0a-%3c %25pmhlt%25[@@@monospaced@@@]%0a-%3c %25pmhlt%25[@[-small-], [--smaller--]@]%0a-%3c %25pmhlt%25[@[+big+], [++bigger++]@]%0a-%3c %25pmhlt%25[@'-small-', '+big+'@]%0a-%3c %25pmhlt%25[@'^superscript^', '_subscript_'@]%0a-%3c %25pmhlt%25[@{+inserted+} (underscore)@]%0a-%3c %25pmhlt%25[@{-deleted-} (strikethrough)@]%0a-%3c %25pmhlt%25@@[=[@escaped code@]=]@@%0a-%3c %25pmhlt%25[@[=escaped text=]@]%0a%0a%0a!!! [[#PostingMarkups]] Posting markup%0a%0a-%3c %25pmhlt%25@@~~@@@@~@@ (author's signature)%0a-%3c %25pmhlt%25@@~~@@@@~~@@ (author's signature and date)%0a-%3c %25pmhlt%25@@[=(:encrypt=] ''phrase''[=:)=]@@ -- replaced with encrypted form of ''phrase''%0a%0a%0a!! [[#Tables]] Tables%0a%0a!!! [[#PlainTables]] Plain rows and columns of text%0a%0aSee [[Tables]]%0a-%3c %25pmhlt%25[@||table attributes@]%0a-%3c %25pmhlt%25[@||!table caption!||@]%0a-%3c %25pmhlt%25[@||left aligned || centered || right aligned||@]%0a-%3c %25pmhlt%25[@||!column heading||@]%0a-%3c %25pmhlt%25[@||spanned columns ||||||@]%0a%0a!!! [[#TablesAndDivs]] Structured tables%0a%0aSee [[Table directives ]]%0a-%3c %25pmhlt%25[@(:table attr:) @]%0a-%3c %25pmhlt%25[@(:cellnr attr:) @]%0a-%3c %25pmhlt%25[@(:cell attr:) @]%0a-%3c %25pmhlt%25[@(:tableend:) @]%0a%0a!! [[#Directives]] Directives%0a%0a!!! [[#PageDirectives]] Page directives%0a%0aSee [[Page directives]]%0a-%3c %25pmhlt%25[@(:redirect PageName:) @]%0a%0a-%3c %25pmhlt%25[@(:(no)spacewikiwords:) @]%0a-%3c %25pmhlt%25[@(:(no)linkwikiwords:) @]%0a-%3c %25pmhlt%25[@(:(no)linebreaks:) @]%0a%0a!!! [[#Display]] Display%0a%0aSee [[Page directives]] [[Group headers]]%0a-%3c %25pmhlt%25[@(:noheader:), (:nofooter:) @]%0a-%3c %25pmhlt%25[@(:notitle:) @]%0a-%3c %25pmhlt%25[@(:noleft:), (:noright:) @]%0a-%3c %25pmhlt%25[@(:nogroupheader:), (:nogroupfooter:) @]%0a-%3c %25pmhlt%25[@(:noaction:) @]%0a%0a%0a!!! [[#Metadata]] Metadata%0a%0aSee [[Page directives]], [[(PmWiki:)Comment markup]], [[Page variables]]%0a-%3c %25pmhlt%25[@(:title text:) @]%0a-%3c %25pmhlt%25[@(:keywords word, ...:) @]%0a-%3c %25pmhlt%25[@(:description text:) @]%0a-%3c %25pmhlt%25[@(:comment text:) @]%0a-%3c %25pmhlt%25[@{Group/PageName$:variable}@] [-includes from [@ (:variable:text:) @]-]%0a-%3c for example %25pmhlt%25@@[= (:=]Summary:text:) @@%0a%0a%0a!!! [[#IncludeOtherPages]] Include%0a%0aSee [[Include other pages]], [[Page text variables]]%0a-%3c %25pmhlt%25[@(:include PageName:) @]%0a-%3c %25pmhlt%25[@(:include PageName#start#end lines=n paras=n:) @]%0a-%3c %25pmhlt%25[@(:include Page1 Page2 Page3:) @]%0a-%3c %25pmhlt%25[@{Group/PageName$:Var}@] [-includes from [@ (:name:text:) @]-]%0a-%3c %25pmhlt%25[@(:nl:) @] [-separate included text by conditional line break-]%0a%0a!!! [[#ConditionalMarkup]] Conditional markup%0a%0aSee [[Conditional markup]]%0a-%3c %25pmhlt%25[@(:if (!) cond param:)...(:ifend:)@]%0a-%3c %25pmhlt%25[@(:if (!) cond param:)...(:else:)...(:ifend:)@]%0a-%3c %25pmhlt%25[@(:if (!) cond param:)...(:elseif (!) cond param:)...(:ifend:) @]%0a%0a%0a!!! [[#PageLists]] Pagelists%0a%0aSee [[Page lists]]%0a-%3c %25pmhlt%25[@(:searchbox label=label order=-time:) @]%0a-%3c %25pmhlt%25[@(:searchresults incl -excl group=abc fmt=def:) @]%0a-%3c %25pmhlt%25[@(:pagelist incl -excl group=abc fmt=def:) @]%0a%0a%0a!!! [[#OtherDirectives]] Other directives%0a%0aSee [[Page directives]]%0a-%3c %25pmhlt%25[@(:toc:) @] see [[Table of contents]]%0a-%3c %25pmhlt%25[@(:attachlist:)@] see [[PageDirectives#attachlist]]%0a-%3c %25pmhlt%25[@(:markup:)...(:markupend:) @] see [[PageDirectives#markup]]%0a-%3c %25pmhlt%25[@(:markup class=horiz:)...(:markupend:) @]%0a-%3c %25pmhlt%25[@(:markup class=norender:)...(:markupend:) @]%0a-%3c %25pmhlt%25[@(:markup caption='...':)...(:markupend:) @]%0a-%3c %25pmhlt%25[@(:messages:) @]%0a%0a%0a!! [[#Forms]] Forms%0a%0aSee [[PmWiki/Forms]]%0a-%3c %25pmhlt%25[@(:input form method=get action=url enctype=multipart/form-data:) @]%0a--%3c %25pmhlt%25[@(:input default name=xyz value="abc":) @]%0a--%3c %25pmhlt%25[@(:input text name=first value="Bob" size=20:) @]%0a--%3c %25pmhlt%25[@(:input textarea name=xyz [=value=] rows=2 cols=80:) @]%0a--%3c %25pmhlt%25[@(:input submit name=post value="Go" accesskey=g:) @]%0a--%3c %25pmhlt%25[@(:input reset:) @]%0a--%3c %25pmhlt%25[@(:input hidden name=action value=edit:) @]%0a--%3c %25pmhlt%25[@(:input radio name=xyz value="abc" checked=1:) @]%0a--%3c %25pmhlt%25[@(:input checkbox name=xyz value="abc" checked=1:) @]%0a--%3c %25pmhlt%25[@(:input password name=authpw:) @]%0a--%3c %25pmhlt%25[@(:input file name=upload:) @]%0a--%3c %25pmhlt%25[@(:input image name=xyz src="https:..." alt="Alt Text":) @]%0a--%3c %25pmhlt%25[@(:input select name=xyz value="val1" label="Value 1":) @]%0a--%3c %25pmhlt%25[@(:input select name=xyz value="val2" label="Value 2":) @]%0a-%3c %25pmhlt%25[@(:input end:) @]%0a%0aSee also [[PmWiki/Forms#pageeditcontrols|PmWiki Edit forms]].%0a%0a!! [[#WikiTrails]] Wiki trails%0a%0aSee [[Wiki trails]]%0a-%3c %25pmhlt%25[@%3c%3c|[[TrailPage]]|>>@]%0a-%3c %25pmhlt%25[@%3c|[[TrailPage]]|>@]%0a-%3c %25pmhlt%25[@^|[[TrailPage]]|^@]%0a%0a%0a!! [[#PageVariables]] Page variables%0a%0aSee [[Page variables]], [[Page text variables]], [[PmWiki/PageLists#pagetextvariables|Page lists]]%0a-%3c %25pmhlt%25[@{$variable}, {pagename$variable}, {groupname.pagename$variable} @]%0a-%3c %25pmhlt%25[@{$:variable}, {pagename$:variable}, {groupname.pagename$:variable} @]%0aSet a [[page text variable(s)]]%0a-%3c %25pmhlt%25[@(:name:description:) @] %0a-%3c %25pmhlt%25[@:name:description @] %0a-%3c %25pmhlt%25[@name:description @] %0aSee [[PmWiki:PageVariables#specialreferences | special references]]%0a-%3c %25pmhlt%25[@{*$variable} @]%0a-%3c %25pmhlt%25[@{*$:variable} @]%0a[[Page list templates]] [[PmWiki:PageListTemplates#specialreferences | special variables]]%0a-%3c %25pmhlt%25[@{=$variable}, {%3c$variable}, {>$variable}@],%0a-%3c %25pmhlt%25[@{=$:variable}, {%3c$:variable}, {>$:variable}@]%0a%0a!! [[#Internationalization]] Internationalization%0aSee [[PmWiki/Internationalizations]] and [[PmWiki/SkinTemplates]]%0a-%3c %25pmhlt%25[@$[phrase] @]%0a%0a!! [[#Expressions]] Expressions%0a%0aSee [[Markup expressions]]%0a-%3c %25pmhlt%25[@{(function arg)} @]%0a +time=1671439229 title=Markup Master Index blob - f2f101897e31356bccdeaa0cfc55ea71e2d199a5 blob + 0e30dddfcb40b23a270c3e8d9cc0e30e68bb2e32 --- wikilib.d/PmWiki.Notify +++ wikilib.d/PmWiki.Notify @@ -1,10 +1,10 @@ -version=pmwiki-2.2.106 ordered=1 urlencoded=1 -author=Petko +version=pmwiki-2.3.5 ordered=1 urlencoded=1 +author=simon charset=UTF-8 -csum=+$MailFunction +csum=hlt php, pm hlt, http+s (+984) ctime=1149115706 name=PmWiki.Notify -rev=74 +rev=76 targets=PmWiki.LocalCustomizations,PmWiki.Notify,SiteAdmin.NotifyList,PmWiki.PageLists,PmWiki.WikiTrails,PmWiki.PageTextVariables,PmWiki.BasicVariables,PmWiki.UTF-8,PITS.01159 -text=(:Summary:How to receive email messages whenever pages are changed on the whole wiki site, individual groups or selected watchlists of pages:)%0a(:Audience: administrators (basic) :)%0aThe ''notify.php'' script allows a site administrator to configure PmWiki to send email messages whenever pages are changed on the wiki site. Notifications can be configured so that multiple page changes over a short period of time are combined into a single email message (to avoid flooding mailboxes).%0a%0aThis feature is useful for sites and pages that have infrequent updates, as it eliminates the need to frequently check `RecentChanges pages just to see if anything has changed.%0a%0aIn order for notifications to work, the notify.php script must be enabled in the site's [[local customization(s)]]. Usually this is as simple as placing the following in ''local/config.php'':%0a%0a->$EnableNotify = 1;%0a%0a!! Notification configuration%0aOnce enabled, the notification system gets its configuration from the [[SiteAdmin.NotifyList]] wiki page. The SiteAdmin.NotifyList page contains entries of the form:%0a%0a->notify=alice@example.com%0a%0aThis says that information about page changes should be periodically emailed to ''alice@example.com''. The SiteAdmin.NotifyList page can contain multiple "notify=" lines to cause notifications to be sent to multiple addresses; the "notify=" lines can be concealed by placing them inside of an [@(:if false:)@] conditional section on the page.%0a%0aNOTE: Do not put any spaces around the equal sign! Notifications will fail silently if you have... This is a really easy mistake to make because all of the other assignments have spaces around the equal sign.%0a %0a->%25green%25notify=fred@example.com%25%25 rather than %25red%25notify = fred@example.com%25%25%0a%0a!! Notification options%0aThe basic syntax is %0a->@@notify=''email@address'' \%0a [[#notifyname|name]]=''abc'' \%0a [[#notifygroup|group]]=''def'' \%0a [[#notifytrail|trail]]=''ghi'' \%0a [[#notifysquelch|squelch]]=''123'' \%0a [[#notifydelay|delay]]=''123'' \%0a @@%0a%0aA number of options exist for limiting the pages that result in a notification. The [@group=@] and [@name=@] parameters can be used to restrict notifications to specific pages or groups:%0a%0a[[#notifygroup]]%0a-># send notifications about the Main group to alice@example.com%0a->notify=alice@example.com '''group'''=Main%0a%0a[[#notifyname]]%0a-># notify bob@example.com of any changes to the home page%0a->notify=bob@example.com '''name'''=Main.HomePage%0a%0a-># notify charles@example.com of changes to pages except in Main%0a->notify=charles@example.com '''group'''=-Main%0a%0a(Note: The options are similar to [[PmWiki/PageLists | the PageList syntax]].)%0a%0a[[#notifytrail]]%0aFor maintaining arbitrary lists of pages, i.e., "watchlists", it's generally easier to build a [[trail -> WikiTrails]] of pages to be watched. The following entry in SiteAdmin.NotifyList will send alice@example.com an email containing changes to any of the pages listed in the Profiles.Alice trail:%0a%0a-># notify Alice of changes to pages listed in Profiles.Alice%0a->notify=alice@example.com '''trail'''=Profiles.Alice%0a%0aNote that once this entry has been added to SiteAdmin.NotifyList, Alice can easily change her watchlist by editing the Profiles.Alice page, and doesn't need to edit the SiteAdmin.NotifyList page. In particular, this means that an administrator can restrict editing of SiteAdmin.NotifyList, yet allow individuals to maintain custom watchlists in other pages. %0a%0aLimitations of this feature:%0a* only manually-added links on a trail will be acknowledged by the Notify List (no "group=" or other pagelist syntax, nor any "Group.RecentChanges" links, will generate notifications)%0a* using an [@(:include:)@] directive on the page SiteAdmin.NotifyList is not an operational work-around.%0a* [[PageTextVariables]] are not resolved - you can't get the notification mail address from the profile page.%0a%0aThis is probably a good place to point out that edit access to SiteAdmin.NotifyList should be controlled, otherwise malicious persons can use the notification capability to flood others' electronic mailboxes. By default, SiteAdmin.NotifyList is blocked against reading or edits except by the admin (as is the case for most pages in the SiteAdmin group).%0a%0a!! Adding notification entries via local customizations%0a%0aNotification entries can also be added via the $NotifyList array in ''local/config.php''. Simply add a line like the following:%0a->$EnableNotify = 1;%0a->$NotifyList[] = 'notify=alice@example.com group=Main';%0a->$NotifyList[] = 'notify=bob@example.com name=Main.HomePage';%0a%0a[[#controlling_notification_frequency]]%0a[[#notifysquelch]]%0a!! Controlling notification frequency%0a%0aTo prevent flooding of recipients' mailboxes, the notify script uses a "'''squelch'''" value as the minimum amount of time that must elapse between messages sent to any given email address. The ''default squelch setting is 10800 seconds (three hours)'', which means that once a recipient address is sent a notification message, it will not receive another for at least three hours. Any edits that occur during the squelch interval are queued for the next notification message.%0a%0aThe site administrator can change the default squelch interval via the $NotifySquelch parameter %0a%0a-># enable notifications%0a->$EnableNotify = 1;%0a->$NotifySquelch = 86400; # wait at least one day (in seconds) between notifications%0a%0aIn addition, individual addresses can specify a custom squelch parameter in the SiteAdmin.NotifyList page:%0a%0a-># Alice receives at most one email per day%0a->notify=alice@example.com '''squelch'''=86400%0a%0a-># Bob can get notifications hourly%0a->notify=bob@example.com trail=Profiles.Bob '''squelch'''=3600%0a%0a-># Charles uses the site default squelch%0a->notify=charles@example.com %0a%0a[[#notifydelay]]%0a!! Controlling notification delay%0aBecause a page will often receive several edits in rapid succession (e.g., a long post followed by several minor edits), a site administrator can also set a $NotifyDelay value that specifies how long to wait after an initial post before sending notifications:%0a%0a-># enable notifications%0a->$EnableNotify = 1;%0a->$NotifySquelch = 86400; # wait at least one day between notifications%0a->$NotifyDelay = 300; # wait five minutes after initial post%0a%0aNote that the squelch and delay values are minimums; notifications are sent on the first execution of PmWiki after the delay period has expired. For inactive sites, this could be much longer than the specified delay periods. This isn't really considered an issue since timely notifications are less important on relatively inactive sites. However, changes within the squelch time after the last notification will remain unnoticed if the wiki is not even visited for a long period after. If this matters it might be necessary to make the server call pmwiki.php regularly (e.g. [[Wikipedia:Cron | cron job]]).%0a%0aCustom delay parameters cannot be specified for individual addresses in the [[SiteAdmin.NotifyList]] page:%0a%0a-># the @@delay=@@ parameter will be ignored%0a->notify=edgar@example.com trail=Profiles.Edgar '''delay'''=600%0a%0a!! Note for Windows installations%0a%0aSites running PHP under Windows may not have PHP's [[http://php.net/mail | mail]] function configured correctly. Such sites may need to add a line like%0a%0a->ini_set('SMTP','smtp.server.com');%0a%0ato ''config.php'', where ''smtp.server.com'' is the name of your host's preferred outgoing mail server. You may also need to set the sendmail_from value if that is not configured:%0a%0a->ini_set('sendmail_from','noreply@foo.com');%0a%0a%0a!![[#variables]] Notify Variables%0a%0a:$EnableNotify:Tells ''stdconfig.php'' to enable the notify script.%0a: :$EnableNotify = 1; # enable notify%0a: :$EnableNotify = 0; # disable notify%0a%0a:$MailFunction: The function to call when sending a message, default the built-in PHP function [[http://php.net/mail|mail]]. If you have some custom e-mailing solution or library, place here the function to be called with the same arguments as mail($to, $subject, $message, $additional_headers).%0a%0a:$NotifyFrom:Return email address to be used in the sent email.%0a: :$NotifyFrom = 'wiki@example.com';%0a: :$NotifyFrom = 'Wiki server %3cwiki@example.com>';%0a%0a:$NotifyDelay:The length of time (seconds) to wait before sending mail after the first post. Defaults to zero - posts are sent as soon as any squelch period has expired.%0a: :$NotifyDelay = 300; # send mail 5+ min after first post%0a%0a:$NotifySquelch:The default minimum time (seconds) that must elapse between sending mail messages. Useful when $NotifyDelay is set to a small value to keep the number of mail notification messages down. Defaults to 10800 (three hours). Individual recipients can override this value in the SiteAdmin.NotifyList page.%0a: :$NotifySquelch = 43200; # wait 12+ hours between mailings%0a%0a:$NotifyItemFmt:The text to be sent for each changed item in the post. The string "$PostTime" is substituted with the time of the post (controlled by $NotifyTimeFmt below).%0a: :# default%0a: :$NotifyItemFmt = ' * $FullName . . . $PostTime by $Author';%0a%0a: :# include the page's URL in the message%0a: :$NotifyItemFmt =%0a: :" * \$FullName . . . \$PostTime by \$Author\n \$PageUrl";%0a%0a: :# include the change summary and link to the page's history in the message%0a: :$NotifyItemFmt = %0a: :" * {\$FullName} . . . \$PostTime by {\$Author}%0a: :\n Summary: {\$LastModifiedSummary}\n {\$PageUrl}?action=diff";%0a%0a%0a:$NotifyTimeFmt:The format for dates/times in $PostTime above. Defaults to the value of $TimeFmt.%0a: :$NotifyTimeFmt = [='%25Y-%25m-%25d %25H:%25M'=]; # 2004-03-20 17:44%0a%0a:$NotifyBodyFmt:The body of the message to be sent. The string "$NotifyItems" is replaced with the list of posts (as formatted by $NotifyItemFmt above). Use single quotation marks ' to prevent substring "$NotifyItems" from being untimely evaluated as variable in config.php. %0a: :$NotifyBodyFmt = "Changed items:\n\n" . '$NotifyItems' . "\n\n Best regards...";%0a%0a:$NotifySubjectFmt:The subject line of the mail to be sent.%0a%0a:$NotifyHeaders:String of extra mail headers to be passed to the mail() function.%0a%0a:$NotifyParameters:String of additional parameters to be passed to PHP's mail() function [[http://www.php.net/mail|#]].%0a%0a:$NotifyFile:The scratch file where Notify keeps track of recent posting information. Defaults to @@[="$WorkDir/.notifylist"=]@@. Note that this file must generally be writable by the webserver process.%0a%0a:$NotifyListPageFmt:The name of the page containing [@notify=@] lines for use by ''notify.php''. Defaults to [@$SiteAdminGroup.NotifyList@].%0a%0a:$NotifyList:An array of [@notify=@] specifications that can be specified from a local customization file (used in addition to entries in SiteAdmin.NotifyList).%0a: :# send notifications to alice@example.com%0a: :$NotifyList[] = 'notify=alice@example.com';%0a%0a:$EnableNotifySubjectEncode:Apply a standard (base64) encoding for the e-mail subject. Notify e-mails from international wikis may otherwise have unreadable subjects (added for version 2.2.2).%0a: :$EnableNotifySubjectEncode = 1; # encode subject%0a: :$EnableNotifySubjectEncode = 0; # use subject as is (default)%0a: : To fix encodings with the message body, add to config.php the following line (after XLPage and/or [[UTF-8]]):\\%0a @@$NotifyHeaders = "Content-type: text/plain; charset=$Charset";@@%0a%0a!! Notification only for major edits%0a%0aIt is possible to send notifications only in case of major edits. In your config.php, replace "$EnableNotify=1;" with the following: %0a%0aif ( @$_POST['diffclass'] != 'minor' ) $EnableNotify=1;%0a%0aThis way, only 'major' edits send notify messages (when the author doesn't select the checkbox for minor edit). If you want minor edits and not major edits to send the message then you would use:%0a%0aif ( @$_POST['diffclass'] == 'minor' ) $EnableNotify=1;%0a%0ainstead.%0a%0a!! Disabling notifications for downloads%0a%0aIf you use "$EnableDirectDownloads=0;" (eg. for privacy on a password-protected wiki) then attached images may generate duplicate notification messages. To prevent that disable notifications for downloads via%0a%0aif ( $action != 'download' ) $EnableNotify=1;%0a%0aThat way, only page views (and not images within the page) will generate notifications. See PITS:01159 for more information.%0a -time=1515584747 +text=(:Summary:How to receive email messages whenever pages are changed on the whole wiki site, individual groups or selected watchlists of pages:)%0a(:Audience: administrators (basic) :)%0aThe ''@@notify.php@@'' script allows a site administrator to configure PmWiki to send email messages whenever pages are changed on the wiki site. Notifications can be configured so that multiple page changes over a short period of time are combined into a single email message (to avoid flooding mailboxes).%0a%0aThis feature is useful for sites and pages that have infrequent updates, as it eliminates the need to frequently check @@`RecentChanges@@ pages just to see if anything has changed.%0a%0aIn order for notifications to work, the @@notify.php@@ script must be enabled in the site's [[local customization(s)]]. Usually this is as simple as placing the following in ''@@local/config.php@@'':%0a%0a->%25hlt php%25@@$EnableNotify = 1;@@%0a%0a!! Notification configuration%0aOnce enabled, the notification system gets its configuration from the [[SiteAdmin.NotifyList]] wiki page. The @@SiteAdmin.NotifyList@@ page contains entries of the form:%0a%0a->%25hlt php%25@@notify=alice@example.com@@%0a%0aThis says that information about page changes should be periodically emailed to ''@@alice@example.com@@''. The @@SiteAdmin.NotifyList@@ page can contain multiple "notify=" lines to cause notifications to be sent to multiple addresses; the "notify=" lines can be concealed by placing them inside of an %25pmhlt%25[@(:if false:)@] conditional section on the page.%0a%0aNOTE: Do not put any spaces around the equal sign! Notifications will fail silently if you have... This is a really easy mistake to make because all of the other assignments have spaces around the equal sign.%0a %0a->%25green%25notify=fred@example.com%25%25 rather than %25red%25notify = fred@example.com%25%25%0a%0a!! Notification options%0aThe basic syntax is %0a->%25hlt php%25@@notify=''email@address'' \%0a [[#notifyname|name]]=''abc'' \%0a [[#notifygroup|group]]=''def'' \%0a [[#notifytrail|trail]]=''ghi'' \%0a [[#notifysquelch|squelch]]=''123'' \%0a [[#notifydelay|delay]]=''123'' \%0a [[#tz|tz]]=''123'' \%0a @@%0a%0aA number of options exist for limiting the pages that result in a notification. The [@group=@] and [@name=@] parameters can be used to restrict notifications to specific pages or groups:%0a%0a[[#notifygroup]]%0a->%25hlt php%25@@# send notifications about the Main group to alice@example.com@@%0a->%25hlt php%25@@notify=alice@example.com '''group'''=Main@@%0a%0a[[#notifyname]]%0a->%25hlt php%25@@# notify bob@example.com of any changes to the home page@@%0a->%25hlt php%25@@notify=bob@example.com '''name'''=Main.HomePage@@%0a%0a->%25hlt php%25@@# notify charles@example.com of changes to pages except in Main@@%0a->%25hlt php%25@@notify=charles@example.com '''group'''=-Main@@%0a%0a(Note: The options are similar to [[PmWiki/PageLists | the PageList syntax]].)%0a%0a[[#notifytrail]]%0aFor maintaining arbitrary lists of pages, i.e., "watchlists", it's generally easier to build a [[trail -> WikiTrails]] of pages to be watched. The following entry in @@SiteAdmin.NotifyList@@ will send @@alice@example.com@@ an email containing changes to any of the pages listed in the @@Profiles.Alice@@ trail:%0a%0a->%25hlt php%25@@# notify Alice of changes to pages listed in Profiles.Alice@@%0a->%25hlt php%25@@notify=alice@example.com '''trail'''=Profiles.Alice@@%0a%0aNote that once this entry has been added to @@SiteAdmin.NotifyList@@, Alice can easily change her watchlist by editing the @@Profiles.Alice@@ page, and doesn't need to edit the @@SiteAdmin.NotifyList@@ page. In particular, this means that an administrator can restrict editing of @@SiteAdmin.NotifyList@@, yet allow individuals to maintain custom watchlists in other pages. %0a%0aLimitations of this feature:%0a* only manually-added links on a trail will be acknowledged by the Notify List (no "group=" or other pagelist syntax, nor any "@@Group.RecentChanges@@" links, will generate notifications)%0a* using an %25pmhlt%25[@(:include:)@] directive on the page @@SiteAdmin.NotifyList@@ is not an operational work-around.%0a* [[PageTextVariables]] are not resolved - you can't get the notification mail address from the profile page.%0a%0aThis is probably a good place to point out that edit access to @@SiteAdmin.NotifyList@@ should be controlled, otherwise malicious persons can use the notification capability to flood others' electronic mailboxes. By default, @@SiteAdmin.NotifyList@@ is blocked against reading or edits except by the admin (as is the case for most pages in the @@SiteAdmin@@ group).%0a%0a!! Adding notification entries via local customizations%0a%0aNotification entries can also be added via the @@$NotifyList@@ array in ''@@local/config.php@@''. Simply add a line like the following:%0a->%25hlt php%25@@$EnableNotify = 1;@@%0a->%25hlt php%25@@$NotifyList[] = 'notify=alice@example.com group=Main';@@%0a->%25hlt php%25@@$NotifyList[] = 'notify=bob@example.com name=Main.HomePage';@@%0a%0a[[#controlling_notification_frequency]]%0a[[#notifysquelch]]%0a!! Controlling notification frequency%0a%0aTo prevent flooding of recipients' mailboxes, the notify script uses a "'''squelch'''" value as the minimum amount of time that must elapse between messages sent to any given email address. The ''default squelch setting is 10800 seconds (three hours)'', which means that once a recipient address is sent a notification message, it will not receive another for at least three hours. Any edits that occur during the squelch interval are queued for the next notification message.%0a%0aThe site administrator can change the default squelch interval via the @@$NotifySquelch@@ parameter %0a%0a->%25hlt php%25@@# enable notifications@@%0a->%25hlt php%25@@$EnableNotify = 1;@@%0a->%25hlt php%25@@$NotifySquelch = 86400; # wait at least one day (in seconds) between notifications@@%0a%0aIn addition, individual addresses can specify a custom squelch parameter in the @@SiteAdmin.NotifyList@@ page:%0a%0a->%25hlt php%25@@# Alice receives at most one email per day@@%0a->%25hlt php%25@@notify=alice@example.com '''squelch'''=86400@@%0a%0a->%25hlt php%25@@# Bob can get notifications hourly@@%0a->%25hlt php%25@@notify=bob@example.com trail=Profiles.Bob '''squelch'''=3600@@%0a%0a->%25hlt php%25@@# Charles uses the site default squelch@@%0a->%25hlt php%25@@notify=charles@example.com @@%0a%0a[[#notifydelay]]%0a!! Controlling notification delay%0aBecause a page will often receive several edits in rapid succession (e.g., a long post followed by several minor edits), a site administrator can also set a @@$NotifyDelay@@ value that specifies how long to wait after an initial post before sending notifications:%0a%0a->%25hlt php%25@@# enable notifications@@%0a->%25hlt php%25@@$EnableNotify = 1;@@%0a->%25hlt php%25@@$NotifySquelch = 86400; # wait at least one day between notifications@@%0a->%25hlt php%25@@$NotifyDelay = 300; # wait five minutes after initial post@@%0a%0aNote that the squelch and delay values are minimums; notifications are sent on the first execution of PmWiki after the delay period has expired. For inactive sites, this could be much longer than the specified delay periods. This isn't really considered an issue since timely notifications are less important on relatively inactive sites. However, changes within the squelch time after the last notification will remain unnoticed if the wiki is not even visited for a long period after. If this matters it might be necessary to make the server call @@pmwiki.php@@ regularly (e.g. [[Wikipedia:Cron | cron job]]).%0a%0aCustom delay parameters cannot be specified for individual addresses in the [[SiteAdmin.NotifyList]] page:%0a%0a->%25hlt php%25@@# the delay= parameter will be ignored@@%0a->%25hlt php%25@@notify=edgar@example.com trail=Profiles.Edgar '''delay'''=600@@%0a%0a[[#tz]]%0a!! Time zone%0aSince PmWiki 2.3.0, individual users can configure the date and time stamps to show in their own timezone, for example:%0a%0a->%25hlt php%25@@notify=edgar@example.com [other arguments] '''tz'''=Europe/Paris@@%0a%0aFind your timezone in this [[https://www.php.net/manual/en/timezones.php|list of supported timezones]].%0a%0a!! Note for Windows installations%0a%0aSites running PHP under Windows may not have PHP's [[https://www.php.net/manual/en/function.mail.php | mail]] function configured correctly. Such sites may need to add a line like%0a%0a->%25hlt php%25@@ini_set('SMTP','smtp.server.com');@@%0a%0ato ''@@config.php@@'', where ''@@smtp.server.com@@'' is the name of your host's preferred outgoing mail server. You may also need to set the sendmail_from value if that is not configured:%0a%0a->%25hlt php%25@@ini_set('sendmail_from','noreply@foo.com');@@%0a%0a%0a!![[#variables]] Notify Variables%0a%0a:$EnableNotify:Tells ''@@stdconfig.php@@'' to enable the notify script.%0a: :%25hlt php%25@@$EnableNotify = 1; # enable notify@@%0a: :%25hlt php%25@@$EnableNotify = 0; # disable notify@@%0a%0a:$MailFunction: The function to call when sending a message, default the built-in PHP function [[https://www.php.net/manual/en/function.mail.php|mail]]. If you have some custom e-mailing solution or library, place here the function to be called with the same arguments as %25hlt php%25@@mail($to, $subject, $message, $additional_headers)@@.%0a%0a:$NotifyFrom:Return email address to be used in the sent email.%0a: :%25hlt php%25@@$NotifyFrom = 'wiki@example.com';@@%0a: :%25hlt php%25@@$NotifyFrom = 'Wiki server %3cwiki@example.com>';@@%0a%0a:$NotifyDelay:The length of time (seconds) to wait before sending mail after the first post. Defaults to zero - posts are sent as soon as any squelch period has expired.%0a: :%25hlt php%25@@$NotifyDelay = 300; # send mail 5+ min after first post@@%0a%0a:$NotifySquelch:The default minimum time (seconds) that must elapse between sending mail messages. Useful when @@$NotifyDelay@@ is set to a small value to keep the number of mail notification messages down. Defaults to 10800 (three hours). Individual recipients can override this value in the @@SiteAdmin.NotifyList@@ page.%0a: :%25hlt php%25@@$NotifySquelch = 43200; # wait 12+ hours between mailings@@%0a%0a:$NotifyItemFmt:The text to be sent for each changed item in the post. The string "@@$PostTime@@" is substituted with the time of the post (controlled by @@$NotifyTimeFmt@@ below).%0a: :%25hlt php%25@@# default@@%0a: :%25hlt php%25@@$NotifyItemFmt = ' * $FullName . . . $PostTime by $Author';@@%0a%0a: :%25hlt php%25@@# include the page's URL in the message@@%0a: :%25hlt php%25@@$NotifyItemFmt = " * \$FullName . . . \$PostTime by \$Author\n \$PageUrl";@@%0a%0a: :%25hlt php%25@@# include the change summary and link to the page's history in the message@@%0a: :%25hlt php%25@@$NotifyItemFmt = " * {\$FullName} . . . \$PostTime by {\$Author}\n Summary: {\$LastModifiedSummary}\n {\$PageUrl}?action=diff";@@%0a%0a%0a:$NotifyTimeFmt:The format for dates/times in @@$PostTime@@ above. Defaults to the value of @@$TimeFmt@@.%0a: :%25hlt php%25@@$NotifyTimeFmt = [='%25Y-%25m-%25d %25H:%25M'=]; # 2004-03-20 17:44@@%0a%0a:$NotifyBodyFmt:The body of the message to be sent. The string "@@$NotifyItems@@" is replaced with the list of posts (as formatted by @@$NotifyItemFmt@@ above). Use single quotation marks ' to prevent substring "@@$NotifyItems@@" from being untimely evaluated as variable in @@config.php@@. %0a: :%25hlt php%25@@$NotifyBodyFmt = "Changed items:\n\n" . '$NotifyItems' . "\n\n Best regards...";@@%0a%0a:$NotifySubjectFmt:The subject line of the mail to be sent.%0a%0a:$NotifyHeaders:String of extra mail headers to be passed to the %25hlt php%25@@mail()@@ function.%0a%0a:$NotifyParameters:String of additional parameters to be passed to PHP's %25hlt php%25@@mail()@@ function [[https://www.php.net/manual/en/function.mail.php|#]].%0a%0a:$NotifyFile:The scratch file where Notify keeps track of recent posting information. Defaults to @@[="$WorkDir/.notifylist"=]@@. Note that this file must generally be writable by the webserver process.%0a%0a:$NotifyListPageFmt:The name of the page containing [@notify=@] lines for use by ''@@notify.php@@''. Defaults to [@$SiteAdminGroup.NotifyList@].%0a%0a:$NotifyList:An array of [@notify=@] specifications that can be specified from a local customization file (used in addition to entries in SiteAdmin.NotifyList).%0a: :%25hlt php%25@@# send notifications to alice@example.com@@%0a: :%25hlt php%25@@$NotifyList[] = 'notify=alice@example.com';@@%0a%0a:$EnableNotifySubjectEncode:Apply a standard (base64) encoding for the e-mail subject. Notify e-mails from international wikis may otherwise have unreadable subjects (added for version 2.2.2).%0a: :%25hlt php%25@@$EnableNotifySubjectEncode = 1; # encode subject@@%0a: :%25hlt php%25@@$EnableNotifySubjectEncode = 0; # use subject as is (default)@@%0a: : To fix encodings with the message body, add to @@config.php@@ the following line (after XLPage and/or [[UTF-8]]):\\%0a %25hlt php%25@@$NotifyHeaders = "Content-type: text/plain; charset=$Charset";@@%0a%0a!! Notification only for major edits%0a%0aIt is possible to send notifications only in case of major edits. In your @@config.php@@, replace "@@$EnableNotify=1;@@" with the following: %0a%0a%25hlt php%25@@if ( @$_POST['diffclass'] != 'minor' ) $EnableNotify=1;@@%0a%0aThis way, only 'major' edits send notify messages (when the author doesn't select the checkbox for minor edit). If you want minor edits and not major edits to send the message then you would use:%0a%0a%25hlt php%25@@if ( @$_POST['diffclass'] == 'minor' ) $EnableNotify=1;@@%0a%0ainstead.%0a%0a!! Disabling notifications for downloads%0a%0aIf you use "@@$EnableDirectDownloads=0;@@" (eg. for privacy on a password-protected wiki) then attached images may generate duplicate notification messages. To prevent that disable notifications for downloads via%0a%0a%25hlt php%25@@if ( $action != 'download' ) $EnableNotify=1;@@%0a%0aThat way, only page views (and not images within the page) will generate notifications. See PITS:01159 for more information.%0a +time=1654245714 blob - 795334c85199433026052fa9fab15e20bb463cfd blob + 3723b9aae3970af79c1f2c566b11507ee93fc1c9 --- wikilib.d/PmWiki.OtherVariables +++ wikilib.d/PmWiki.OtherVariables @@ -1,9 +1,9 @@ -version=pmwiki-2.2.125 ordered=1 urlencoded=1 +version=pmwiki-2.3.10 ordered=1 urlencoded=1 author=Petko charset=UTF-8 -csum=$PageCacheDir - a hidden subdirectory works faster and doesn't mess with the actual pages (+20) +csum=$MarkupDirectiveFunctions (+151) name=PmWiki.OtherVariables -rev=89 -targets=PmWiki.OtherVariables,PmWiki.FmtPageName,PmWiki.SecurityVariables,PmWiki.PageVariables,Cookbook.HttpVariables,Cookbook.MoreCustomPageVariables,PmWiki.PageTextVariables,PmWiki.PagelistVariables,PmWiki.Forms -text=(:Summary:Variables not yet classified:)%0a:$FmtV: %0a: :This variable is an array that is used for string substitutions at the end of a call to @@[[FmtPageName]]()@@. For each element in the array, the "key" (interpreted as a string) will be replaced by the corresponding "value". The variable is intended to be a place to store substitution variables that have frequently changing values (thus avoiding a rebuild of the variable cache making @@[[FmtPageName]]()@@ faster). Also see $FmtP. %25green%25''Values of $FmtV are set by the internal functions FormatTableRow, LinkIMap, HandleBrowse, PreviewPage, HandleEdit, PmWikiAuth, and PasswdVar, apparently to set values for system generated string substitutions like PageText.''%25%25%0a%0a:$FmtP:%0a: :This variable is an array that is used for pattern substitutions near the beginning of a call to [@FmtPageName@]. For each element in the array, the "key" (interpreted as a pattern) will be replaced by the corresponding value evaluated for the name of the current page. This is for instance used to handle $-substitutions that depend on the pagename passed to [@FmtPageName()@]. Also see $FmtV. %25green%25From robots.php: ''If $EnableRobotCloakActions is set, then a pattern is added to $FmtP to hide any "?action=" url parameters in page urls generated by PmWiki for actions that robots aren't allowed to access. This can greatly reduce the load on the server by not providing the robot with links to pages that it will be forbidden to index anyway.''%0a%0a%0a:$FmtPV:%0a: :This variable is an array that is used for defining [[Page Variables]]. New variables can be defined with [@$FmtPV['$VarName'] = 'variable definition';@] which can be used in markup with [@{$VarName}@]. Please note that the contents of [@$FmtPV['$VarName']@] are [@eval()@]ed to produce the final text for [@$VarName@], so the contents must be a PHP expression which is valid at the time of substitution. In particular, %25red%25this does not work:%25%25%0a%0a:: :%25red%25[@#This doesn't work@]%25%25%0a:: :[@$FmtPV['$MyText'] = "This is my text."; # WARNING: Doesn't work!@]%0a%0a: :The problem is that the text %25blue%25[@This is my text.@]%25%25 is not a valid PHP expression. To work it would need to be placed in quotes, so that what actually gets stored in [@$FmtPV['$MyText']@] is %25blue%25[@"This is my text."@]%25%25 which '''is''' a valid PHP expression for a text string. Thus the correct way to do this would be with an extra set of quotes:%0a%0a:: :[@#This will work@]%0a:: :[@$FmtPV['$MyText'] = '"This is my text."';@]%0a%0a: :This also has implications for how internal PHP or PmWiki variables are accessed. To have the page variable [@$MyVar@] produce the contents of the internal variable [@$myvar@], many folks try the following %25red%25which does not work:%25%25%0a%0a:: :%25red%25[@#This doesn't work either!@]%0a:: :[@$myvar = SomeComplexFunction();@]%0a:: :[@$FmtPV['$MyVar'] = $myvar; # WARNING: Doesn't work!@]%0a%0a: :There are several correct ways to do this, depending on whether you need the value of the [@$myvar@] variable as it was at the time the [@$FmtPV@] entry was created, or at the time that a particular instance of [@$MyVar@] is being rendered on a page. For most simple page variables that don't change during the processing of a page its more efficient to set the value when the entry is created:%0a%0a:: :[@$myvar = SomeComplexFunction();@]%0a:: :[@$FmtPV['$MyVar'] = "'" . $myvar . "'"; #capture contents of $myvar@]%0a%0a: :NOTE: If [@$myvar@] should contain single quotes, the above won't work as is, and you'll need to process the variable to escape any internal quotes.%0a%0a: :For more complex cases where an internal variable may have different values at different places in the page (possibly due to the effects of other markup), then you need to make the [@$FmtPV@] entry make an explicit reference to the global value of the variable (and the variable had better be global) like this:%0a%0a:: :[@global $myvar;@]%0a:: :[@$FmtPV['$MyVar'] = '$GLOBALS["myvar"]';@]%0a%0a: :Finally, there's nothing to stop you from simply having the evaluation of the [@$FmtPV@] entry execute a function to determine the replacement text:%0a%0a:: :[@# add page variable {$Today}, formats today's date as yyyy-mm-dd@]%0a:: :[@$FmtPV['$Today'] = 'strftime("%25Y-%25m-%25d", time() )';@]%0a%0a>>frame%3c%3c%0a: : Once again, please note that the values of the elements of $FmtPV are @@eval()@@ed so always sanitize any user input. The following is very insecure[=:=]%0a%0a:: : [@$FmtPV['$Var'] = $_REQUEST['Var'];@] %25red%25# critically insecure, allows PHP code injection%0a:: : [@$FmtPV['$Var'] = '"'. addslashes($_REQUEST['Var']).'"';@] %25red%25# critically insecure, allows PHP code injection%0a%0a: : See the recipe Cookbook:HttpVariables for a better way to use these variables.%0a>>%3c%3c%0a%0a: :See [[Cookbook:MoreCustomPageVariables]] for more examples of how to use [@$FmtPV@].%0a%0a:$MaxPageTextVars: This variable prevents endless loops in accidental recursive [[PageTextVariables]] which could lock down a server. Default is 500 which means that each PageTextVariable from one page can be displayed up to 500 times in one wiki page. If you need to display it more than 500 times, set in config.php something like\\%0a@@$MaxPageTextVars = 10000;@@ # ten thousand times%0a%0a:$DefaultUnsetPageTextVars: An array setting default values to page text variables which are not defined in the page, or when the user doesn't have read permissions for the page. See [[PageTextVariables#default]].%0a%0a:$DefaultEmptyPageTextVars: An array setting default values to page text variables which are defined in the page but empty. See [[PageTextVariables#default]].%0a%0a:$PageCacheDir: Enables the cache of most of the HTML for pages with no conditionals. The variable contains the name of a writable directory where PmWiki can cache the HTML output to speed up subsequent displays of the same page. Default is empty, which disables the cache. See also $PageListCacheDir.%0a # Enable HTML caching in work.d/.pagecache%0a $PageCacheDir = 'work.d/.pagecache';%0a%0a:$MarkupMarkupLevel: This global variable is a positive integer when the markup processing engine is inside a [@(:markup:)@] block; it is 0 (zero) or null otherwise.%0a%0a:$EnableInputDataAttr: This variable controls whether [[forms|input form elements]] should accept custom @@data-*@@ attributes. By default they do.%0a # Disable data-* attributes in forms%0a $EnableInputDataAttr = 0;%0a -time=1580364675 +rev=91 +targets=PmWiki.OtherVariables,PmWiki.FmtPageName,PmWiki.SecurityVariables,PmWiki.PageVariables,PmWiki.Functions,Cookbook.HttpVariables,Cookbook.MoreCustomPageVariables,PmWiki.PageTextVariables,PmWiki.PagelistVariables,PmWiki.Forms,Cookbook.MarkupDirectiveFunctions +text=(:Summary:Variables not yet classified:)%0a:$FmtV: %0a: :This variable is an array that is used for string substitutions at the end of a call to @@[[FmtPageName]]()@@. For each element in the array, the "key" (interpreted as a string) will be replaced by the corresponding "value". The variable is intended to be a place to store substitution variables that have frequently changing values (thus avoiding a rebuild of the variable cache making @@[[FmtPageName]]()@@ faster). Also see $FmtP. %25green%25''Values of $FmtV are set by the internal functions FormatTableRow, LinkIMap, HandleBrowse, PreviewPage, HandleEdit, PmWikiAuth, and PasswdVar, apparently to set values for system generated string substitutions like PageText.''%25%25%0a%0a:$FmtP:%0a: :This variable is an array that is used for pattern substitutions near the beginning of a call to [@FmtPageName@]. For each element in the array, the "key" (interpreted as a pattern) will be replaced by the corresponding value evaluated for the name of the current page. This is for instance used to handle $-substitutions that depend on the pagename passed to [@FmtPageName()@]. Also see $FmtV. %25green%25From robots.php: ''If $EnableRobotCloakActions is set, then a pattern is added to $FmtP to hide any "?action=" url parameters in page urls generated by PmWiki for actions that robots aren't allowed to access. This can greatly reduce the load on the server by not providing the robot with links to pages that it will be forbidden to index anyway.''%0a%0a%0a:$FmtPV:%0a: :This variable is an array that is used for defining [[Page Variables]]. New variables can be defined with [@$FmtPV['$VarName'] = 'variable definition';@] which can be used in markup with [@{$VarName}@]. Please note that the contents of [@$FmtPV['$VarName']@] are [@eval()@]ed to produce the final text for [@$VarName@], so the contents must be a PHP expression which is valid at the time of substitution. In particular, %25red%25this does not work:%25%25%0a%0a:: :%25red%25@@#This doesn't work@@%25%25%0a:: :@@$FmtPV['$MyText'] = "This is my text."; # WARNING: Doesn't work!@@%0a%0a: :The problem is that the text %25blue%25[@This is my text.@]%25%25 is not a valid PHP expression. To work it would need to be placed in quotes, so that what actually gets stored in [@$FmtPV['$MyText']@] is %25blue%25[@"This is my text."@]%25%25 which '''is''' a valid PHP expression for a text string. Thus the correct way to do this would be with an extra set of quotes:%0a%0a:: :@@#This will work@@%0a:: :@@$FmtPV['$MyText'] = '"This is my text."';@@%0a%0a: :This also has implications for how internal PHP or PmWiki variables are accessed. To have the page variable [@$MyVar@] produce the contents of the internal variable [@$myvar@], many folks try the following %25red%25which does not work:%25%25%0a%0a:: :%25red%25@@#This doesn't work either!@@%0a:: :@@$myvar = SomeComplexFunction();@@%0a:: :@@$FmtPV['$MyVar'] = $myvar; # WARNING: Doesn't work!@@%0a%0a: :There are several correct ways to do this, depending on whether you need the value of the [@$myvar@] variable as it was at the time the [@$FmtPV@] entry was created, or at the time that a particular instance of [@$MyVar@] is being rendered on a page. For most simple page variables that don't change during the processing of a page its more efficient to set the value when the entry is created:%0a%0a:: :@@$myvar = SomeComplexFunction();@@%0a:: :@@$FmtPV['$MyVar'] = "'" . $myvar . "'"; #capture contents of $myvar@@%0a%0a: :NOTE: If [@$myvar@] should contain single quotes, the above won't work as is, and you'll need to process the variable to escape any internal quotes.%0a%0a: :For more complex cases where an internal variable may have different values at different places in the page (possibly due to the effects of other markup), then you need to make the [@$FmtPV@] entry make an explicit reference to the global value of the variable (and the variable had better be global) like this:%0a%0a:: :@@global $myvar;@@%0a:: :@@$FmtPV['$MyVar'] = '$GLOBALS["myvar"]';@@%0a%0a: :Finally, there's nothing to stop you from simply having the evaluation of the [@$FmtPV@] entry execute a function to determine the replacement text:%0a%0a:: :@@# add page variable [={$Today}=], formats today's date as yyyy-mm-dd@@%0a:: :@@$FmtPV['$Today'] = '[[PmWiki/Functions#PSFT|PSFT]]([="%25Y-%25m-%25d"=], time() )';@@%0a%0a>>frame%3c%3c%0a: : Once again, please note that the values of the elements of $FmtPV are @@eval()@@ed so always sanitize any user input. The following is very insecure[=:=]%0a%0a:: : @@$FmtPV['$Var'] = $_REQUEST['Var'];@@ %25red%25# critically insecure, allows PHP code injection%0a:: : @@$FmtPV['$Var'] = '"'. addslashes($_REQUEST['Var']).'"';@@ %25red%25# critically insecure, allows PHP code injection%0a%0a: : See the recipe Cookbook:HttpVariables for a better way to use these variables.%0a>>%3c%3c%0a%0a: :See [[Cookbook:MoreCustomPageVariables]] for more examples of how to use [@$FmtPV@].%0a%0a:$MaxPageTextVars: This variable prevents endless loops in accidental recursive [[PageTextVariables]] which could lock down a server. Default is 500 which means that each PageTextVariable from one page can be displayed up to 500 times in one wiki page. If you need to display it more than 500 times, set in config.php something like\\%0a@@$MaxPageTextVars = 10000;@@ # ten thousand times%0a%0a:$DefaultUnsetPageTextVars: An array setting default values to page text variables which are not defined in the page, or when the user doesn't have read permissions for the page. See [[PageTextVariables#default]].%0a%0a:$DefaultEmptyPageTextVars: An array setting default values to page text variables which are defined in the page but empty. See [[PageTextVariables#default]].%0a%0a:$PageCacheDir: Enables the cache of most of the HTML for pages with no conditionals. The variable contains the name of a writable directory where PmWiki can cache the HTML output to speed up subsequent displays of the same page. Default is empty, which disables the cache. See also $PageListCacheDir.%0a # Enable HTML caching in work.d/.pagecache%0a $PageCacheDir = 'work.d/.pagecache';%0a%0a:$MarkupMarkupLevel: This global variable is a positive integer when the markup processing engine is inside a [@(:markup:)@] block; it is 0 (zero) or null otherwise.%0a%0a:$EnableInputDataAttr: This variable controls whether [[forms|input form elements]] should accept custom @@data-*@@ attributes. By default they do.%0a # Disable data-* attributes in forms%0a $EnableInputDataAttr = 0;%0a%0a:$MarkupDirectiveFunctions: This is an array that allows recipe authors to easily configure custom directives. See Cookbook:MarkupDirectiveFunctions.%0a +time=1661698360 blob - ee09b22eed50a05442433bfb266e3186ba7a7395 blob + 1114ce974ad81c0204bb5255d603980d76614844 --- wikilib.d/PmWiki.PageDirectives +++ wikilib.d/PmWiki.PageDirectives @@ -1,11 +1,11 @@ -version=pmwiki-2.2.118 ordered=1 urlencoded=1 -author=Petko +version=pmwiki-2.3.8 ordered=1 urlencoded=1 +author=Benji charset=UTF-8 -csum= +csum= (+15) (+15) description=PmWiki Page Directives keywords=description, keywords, markup, header, redirect name=PmWiki.PageDirectives -rev=105 -targets=PmWiki.Uploads,PmWiki.UploadVariables,PmWiki.BasicVariables,PmWiki.LayoutVariables,PmWiki.GroupHeaders,PmWiki.Skins,PmWiki.Links,PmWiki.IncludeOtherPages,PmWiki.LinkVariables,PmWiki.TableOfContents -text=(:description PmWiki Page Directives:)(:Summary: Directives to specify page titles, descriptions, keywords, and display:)(:Keywords description, keywords, markup, header, redirect:)%0aPmWiki uses a number of directives to specify page titles, descriptions, page keywords, and control the display of various components.%0aDirective keywords are not case sensitive, e.g. Description, description, and DESCRIPTION are equivalent.%0a%0a[[#attachlist]]%0a:[@(:attachlist:)@]:%0a->Shows a list of attachments of the current group or page, depending on whether attachments are organised per group or per page. The attachlist is displayed at the foot of the [[uploads]] page form.%0a->The parameter to [=(:attachlist:)=] always resolves to a pagename. The directive then displays all of the attachments currently available for that page.%0a%0a::Options: [@(:attachlist NAME:)@] shows a list of attachments of the group or page NAME. %0a-->[@(:attachlist ext=xxx,yyy:)@] comma separated extension patterns for filtering by type of file (case insensitive). %0a-->[@(:attachlist names=*.jpg,*.pdf,-private*.jpg:)@] comma separated filename patterns for filtering by file name (case insensitive).%0a-->[@(:attachlist *:)@] shows the uploads directory and permits browsing of all uploaded files by directory if your server configuration allows automatic file listings (''will not work if $EnableDirectDownload is set to 0'').%0a%0a[[#description]]%0a:[@(:description text:)@]:Descriptive text associated with the page. (Generates a [@%3cmeta name='description' content='...' />@] element in the page output.)%0a%0a[[#keywords]]%0a:[@(:keywords word1, word2, ...:)@]:Identifies keywords associated with the page. These are not displayed anywhere, but are useful to help search engines locate the page. (Essentially, this generates a [@%3cmeta name='keywords' content='...' />@] element in the output.)%0a%0a[[#linebreaks]]%0a:[@(:linebreaks:)@], [@(:nolinebreaks:)@]: Honors any newlines in the markup; i.e., text entered on separate lines in the markup will appear as separate lines in the output. Use [@(:nolinebreaks:)@] to cause text lines to automatically join again.%0a%0a[[#linkwikiwords]]%0a:[@(:linkwikiwords:), (:nolinkwikiwords:)@]: Enables/disables WikiWord links in text. Note, this setting requires WikiWords to be enabled, see $EnableWikiWords. See also $LinkWikiWords.%0a%0a[[#markup]]%0a:[@(:markup:) ... (:markupend:)@] or [@(:markup:)@][@[=...=]@]: Can be used for markup examples, showing first the markup and then the result of the markup. %0a%0a::Options: [@(:markup class=horiz:)@] will show the markup side by side instead of one upon the other.%0a-->[@(:markup caption='...':)@] adds a caption to the markup example.%0a-->[@(:markupend:)@] is not required when using [@(:markup:)@] [@[=...=]@].%0a%0a->''Note'' that the placement of newlines is very important for this markup. If you are using the [@[=...=]@] option then the opening [@[=@] MUST occur on the same line as the [@(:markup:)@]. If you are using the full [@(:markup:) ... (:markupend:)@] form then your markup code must appear AFTER a newline after the initial [@(:markup:)@].%0a%0a[[#message]]%0a:[@(:messages:)@]: Displays [[PmWiki/LayoutVariables#MessagesFmt|messages]] from PmWiki or recipes, for instance from editing pages.%0a%0a%0a[[#noaction]]%0a:[@(:noaction:)@]: Turns off the section of the skin marked by %3c!--PageActionFmt--> thru %3c!--/PageActionFmt-->. In the pmwiki skin, this turns off the display of the actions at the top-right of the page (other skins may locate the actions in other locations). The actions at the bottom of the page are still available.%0a%0a[[#nogroupheader]]%0a:[@(:nogroupheader:)@]:%0a:[@(:nogroupfooter:)@]: Turns off any groupheader or groupfooter for the page. (See [[GroupHeaders]].)%0a%0a[[#noheader]]%0a:[@(:noheader:), (:nofooter:)@]: %0a:[@(:noleft:), (:noright:), (:notitle:)@]: If supported by the [[skin(s)]], each of these turns off the corresponding portion of the page.%0a%0a[[#redirect]]%0a:[@(:redirect PageName:)@]: Redirects to another wiki page.%0a:[@(:redirect PageName#anchor:)@]: Redirects to an [[PmWiki/Links#anchors|anchor]] within a page%0a:[@(:redirect PageName status=301 from=name quiet=1:)@]:Redirects the browser to another page, along with a redirect message. For security reasons this only redirects to other pages within the wiki and does not redirect to external urls. The [@status=@] option can be used to return a different HTTP status code as part of the redirect. The [@from=@] option limits redirects to occuring only on pages matching the wildcarded ''name'' (helpful when [@(:redirect:)@] is in [[include other pages|another page]]). The [@quiet=1@] option allows the target page not to display a link back to the original page ($EnableRedirectQuiet variable should be set to 1).%0a%0a[[#spacewikiwords]]%0a:[@(:spacewikiwords:), (:nospacewikiwords:)@]:%0a->Enables/disables automatic spacing of WikiWords in text.%0a%0a[[#title]]%0a:[@(:title text:)@]: Sets a page's title to be something other than the page's name. The title text can contain apostrophes and other special characters. If there are multiple titles in a page, the last one encountered wins (see also $EnablePageTitlePriority about how to change it).%0a%0a:[@(:toc:)@], [@(:notoc:)@]: Override the default table of contents settings. This directive requires a corresponding configuration of the wiki, see [[Table of contents]] '-{TableOfContents$:Summary}-'%0a%0a>>faq%3c%3c [[#faq]]%0aQ: Can I get [@(:redirect:)@] to return a "moved permanently" (HTTP 301) status code?%0aA: Use [@(:redirect PageName status=301:)@].%0a%0aQ: Is there any way to prevent the "redirected from" message from showing at the top of the target page when I use [@(:redirect:)@]?%0aA: From version 2.2.1 on, set in config.php @@$EnableRedirectQuiet=1;@@ and in the page @@[=(:redirect OtherPage quiet=1:)=]@@ for a quiet redirect.%0a%0aQ: Is there any method for redirecting to the equivalent page in a different group, i.e. from BadGroup/thispage => GoodGroup/thispage using similar markup to (:redirect Goodgroup.{Name}:)?%0aA:%0a->[=(:redirect Goodgroup.{$Name}:)=] works if you want to put it in one page. %0a%0a->If you want it to work for the entire group, put [=(:redirect Goodgroup.{*$Name}:)=] into Badgroup.GroupHeader - however, that only works with pages that really exist in Goodgroup; if you visit a page in Badgroup without a corresponding page of the same name in Goodgroup, instead of being redirected to a nonexistant page, you get the redirect Directive at the top of the page.%0a%0a->With [=(:if exists Goodgroup.{*$Name}:)(:redirect Goodgroup.{*$Name}:)(:ifend:)=] in Badgroup.GroupHeader you get redirected to Goodgroup.Name if it exists, otherwise you get Badgroup.Name without the bit of code displayed.%0a%0aQ: How can a wiki enable linebreaks by default, i.e. without having the directive [@(:linebreaks:)@] in a page or in a GroupHeader?%0aA: Add to config.php such a line:\\%0a@@$HTMLPNewline = '%3cbr/>';@@ -time=1568971514 +rev=123 +targets=PmWiki.Uploads,PmWiki.GroupHeaders,PmWiki.UploadsAdmin,PmWiki.UploadVariables,PmWiki.BasicVariables,PmWiki.LayoutVariables,PmWiki.Skins,PmWiki.Links,PmWiki.IncludeOtherPages,PmWiki.LinkVariables,PmWiki.TableOfContents,PmWiki.PageListTemplates,PmWiki.PageTextVariables +text=(:description PmWiki Page Directives:)(:Summary: Directives to specify page titles, descriptions, keywords, and display:)(:Keywords description, keywords, markup, header, redirect:)%0aPmWiki uses a number of directives to specify page titles, descriptions, page keywords, and control the display of various components.%0aDirective keywords are not case sensitive, e.g. Description, description, and DESCRIPTION are equivalent.%0a%0a[[#attachlist]]%0a:%25pmhlt%25[@(:attachlist:)@]:%0a->Shows a list of attachments of the current group or page, depending on whether attachments are organised per group or per page. The attachlist is displayed at the foot of the [[uploads]] page form.%0a->The parameter to %25pmhlt%25[@(:attachlist:)@] always resolves to a pagename. The directive then displays all of the attachments currently available for that page.%0a%0a::Options: %25pmhlt%25[@(:attachlist NAME:)@] shows a list of attachments of the group or page NAME. %0a-->%25pmhlt%25[@(:attachlist {*$Name}:)@] shows a list of attachments of the current page or group. (useful for making a [[GroupHeaders|Group Headers or Footers]] in a case of [[UploadsAdmin#pageprefix|per-page attachments]])%0a-->%25pmhlt%25[@(:attachlist ext=xxx,yyy:)@] comma separated extension patterns for filtering by type of file (case insensitive). %0a-->%25pmhlt%25[@(:attachlist names=*.jpg,*.pdf,-private*.jpg:)@] comma separated filename patterns for filtering by file name (case insensitive).%0a-->%25pmhlt%25[@(:attachlist *:)@] shows the uploads directory and permits browsing of all uploaded files by directory if your server configuration allows automatic file listings (''will not work if $EnableDirectDownload is set to 0'').%0a%0a[[#description]]%0a:%25pmhlt%25[@(:description text:)@]:Descriptive text associated with the page. (Generates a %25hlt hmtl%25[@%3cmeta name='description' content='...' />@] element in the page output.)%0a%0a[[#keywords]]%0a:%25pmhlt%25[@(:keywords word1, word2, ...:)@]:Identifies keywords associated with the page. These are not displayed anywhere, but are useful to help search engines locate the page. (Essentially, this generates a %25hlt html%25[@%3cmeta name='keywords' content='...' />@] element in the output.)%0a%0a[[#linebreaks]]%0a:%25pmhlt%25[@(:linebreaks:)@], [@(:nolinebreaks:)@]: Honors any newlines in the markup; i.e., text entered on separate lines in the markup will appear as separate lines in the output. Use [@(:nolinebreaks:)@] to cause text lines to automatically join again.%0a%0a[[#linkwikiwords]]%0a:%25pmhlt%25[@(:linkwikiwords:), (:nolinkwikiwords:)@]: Enables/disables WikiWord links in text. Note, this setting requires WikiWords to be enabled, see $EnableWikiWords. See also $LinkWikiWords.%0a%0a[[#markup]]%0a:%25pmhlt%25[@(:markup:) ... (:markupend:)@] or @@[=(:markup:)=][@[=...=]@]@@: Can be used for markup examples, showing first the markup and then the result of the markup. %0a%0a::Options: %25pmhlt%25[@(:markup class=horiz:)@] will show the markup side by side instead of one upon the other.%0a-->%25pmhlt%25[@(:markup class=norender:)@] will show only the markup not the result.%0a-->%25pmhlt%25[@(:markup caption='...':)@] adds a caption to the markup example.%0a-->%25pmhlt%25[@(:markupend:)@] is not required when using @@[=(:markup:)=][@[=...=]@]@@.%0a%0a->%25pmhlt%25''Note'' that the placement of newlines is very important for this markup. If you are using the [@[=...=]@] option then the opening [@[=@] MUST occur on the same line as the [@(:markup:)@]. If you are using the full [@(:markup:) ... (:markupend:)@] form then your markup code must appear AFTER a newline after the initial [@(:markup:)@].%0a%0a[[#message]]%0a:%25pmhlt%25[@(:messages:)@]: Displays [[PmWiki/LayoutVariables#MessagesFmt|messages]] from PmWiki or recipes, for instance from editing pages.%0a%0a%0a[[#noaction]]%0a:%25pmhlt%25[@(:noaction:)@]: Turns off the section of the skin marked by %25hlt html%25[@%3c!--PageActionFmt-->@] thru [@%3c!--/PageActionFmt-->@]. In the PmWiki skin, this turns off the display of the actions at the top-right of the page (other skins may locate the actions in other locations). The actions at the bottom of the page are still available.%0a%0a[[#nogroupheader]]%0a:%25pmhlt%25[@(:nogroupheader:)@]:%0a:%25pmhlt%25[@(:nogroupfooter:)@]: Turns off any groupheader or groupfooter for the page. (See [[GroupHeaders]].)%0a%0a[[#noheader]]%0a:%25pmhlt%25[@(:noheader:), (:nofooter:)@]: %0a:%25pmhlt%25[@(:noleft:), (:noright:), (:notitle:)@]: If supported by the [[skin(s)]], each of these turns off the corresponding portion of the page.%0a%0a[[#redirect]]%0a:%25pmhlt%25[@(:redirect PageName:)@]: Redirects to another wiki page.%0a:%25pmhlt%25[@(:redirect PageName#anchor:)@]: Redirects to an [[PmWiki/Links#anchors|anchor]] within a page%0a:%25pmhlt%25[@(:redirect PageName status=301 from=name quiet=1:)@]:Redirects the browser to another page, along with a redirect message. For security reasons this only redirects to other pages within the wiki and does not redirect to external urls. The [@status=@] option can be used to return a different HTTP status code as part of the redirect. The [@from=@] option limits redirects to occurring only on pages matching the wildcarded ''name'' (helpful when %25pmhlt%25[@(:redirect:)@] is in [[include other pages|another page]]). The [@quiet=1@] option allows the target page not to display a link back to the original page ($EnableRedirectQuiet variable should be set to 1).%0a%0a[[#spacewikiwords]]%0a:%25pmhlt%25[@(:spacewikiwords:), (:nospacewikiwords:)@]:%0a->Enables/disables automatic spacing of WikiWords in text.%0a%0a[[#title]]%0a:%25pmhlt%25[@(:title text:)@]: Sets a page's title to be something other than the page's name. The title text can contain apostrophes and other special characters. If there are multiple titles in a page, the last one encountered wins (see also $EnablePageTitlePriority about how to change it).%0a%0a:%25pmhlt%25[@(:toc:)@], [@(:notoc:)@]: Override the default table of contents settings. This directive requires a corresponding configuration of the wiki, see [[Table of contents]] '-{TableOfContents$:Summary}-'%0a%0a[[#summary]]%0a:%25pmhlt%25@@[=(:Summary=][=:text:)=]@@: Sets a page's summary. Used in some of the default [[PageList Templates]]. Note, this is a [[PageTextVariable(s)]] and unlike core page directives it is case sensitive.%0a%0a>>faq%3c%3c [[#faq]]%0aQ: Can I get %25pmhlt%25[@(:redirect:)@] to return a "moved permanently" (HTTP 301) status code?%0aA: Use %25pmhlt%25[@(:redirect PageName status=301:)@].%0a%0aQ: Is there any way to prevent the "redirected from" message from showing at the top of the target page when I use %25pmhlt%25[@(:redirect:)@]?%0aA: From version 2.2.1 on, set in @@config.php@@ @@$EnableRedirectQuiet=1;@@ and in the page %25pmhlt%25[@(:redirect OtherPage quiet=1:)@] for a quiet redirect.%0a%0aQ: Is there any method for redirecting to the equivalent page in a different group, i.e. from BadGroup/thispage => GoodGroup/thispage using similar markup to (:redirect Goodgroup.{Name}:)?%0aA:%0a->%25pmhlt%25[@(:redirect Goodgroup.{$Name}:)@] works if you want to put it in one page. %0a%0a->If you want it to work for the entire group, put %25pmhlt%25[@(:redirect Goodgroup.{*$Name}:)@] into @@Badgroup.GroupHeader@@ - however, that only works with pages that really exist in @@Goodgroup@@; if you visit a page in @@Badgroup@@ without a corresponding page of the same name in @@Goodgroup@@, instead of being redirected to a nonexistant page, you get the redirect Directive at the top of the page.%0a%0a->With %25pmhlt%25[@(:if exists Goodgroup.{*$Name}:)(:redirect Goodgroup.{*$Name}:)(:ifend:)@] in @@Badgroup.GroupHeader@@ you get redirected to @@Goodgroup.Name@@ if it exists, otherwise you get @@Badgroup.Name@@ without the bit of code displayed.%0a%0aQ: How can a wiki enable linebreaks by default, i.e. without having the directive %25pmhlt%25[@(:linebreaks:)@] in a page or in a GroupHeader?%0aA: Add to @@config.php@@ such a line:\\%0a%25hlt php%25[@$HTMLPNewline = '%3cbr/>';@] +time=1658899602 blob - 3ecf4e88178d26a4905d842451ddafee3be44c1e blob + 835873b8fe59ced175fcbedcf0e5bb6afad76ee8 --- wikilib.d/PmWiki.PageFileFormat +++ wikilib.d/PmWiki.PageFileFormat @@ -1,9 +1,9 @@ -version=pmwiki-2.2.118 ordered=1 urlencoded=1 -author=Petko +version=pmwiki-2.3.11 ordered=1 urlencoded=1 +author=simon charset=UTF-8 -csum=Host is the IP address +csum=hlt bash (+10) name=PmWiki.PageFileFormat -rev=66 -targets=PmWiki.Passwords,SiteAdmin.Status,Cookbook.ImportText,Cookbook.AdminByShell,Cookbook.PageTopStore,Category.PmWikiDeveloper -text=(:Summary:Create wiki formatted pages in bulk and for upload to your pmwiki site:)%0aYou may have many documents that you would like to use a local program to format in a format PmWiki can display.%0a%0aYou could open each document and copy/paste the content to new pmwiki pages or you could format the document in advance and upload it using an FTP client.%0a%0a!! Format [[#format]]%0aOnly two lines are necessary in a PmWiki page file:%0a%0a->[@%0aversion=pmwiki-2.1.0 urlencoded=1%0atext=Markup text%0a@]%0a%0a"version=" tells PmWiki that the values are urlencoded. The actual value doesn't matter, as long as "urlencoded=1" appears somewhere in the line.%0a%0a"text=" ''needs'' to have the markup text with newlines converted to "%250a" and percent signs converted to "%2525".%0a%0a-> In addition, ''PmWiki writes'' pages with '%3c' encoded as "%253c" (to help with security), but it doesn't require that %3c's be encoded that way in order to be able to read the page. More conversions are possible to be added in the future.%0a%0aIn order to let searches and the [@(:pagelist :)@] markup work, make sure the filename begins with an uppercase letter.%0a%0aIn order to have the [@(:pagelist link= ... :)@] markup on other pages list this page, a third attribute is required:%0a%0a->[@%0atargets=GroupName1.Pagename1,GroupName2.Pagename2,...%0a@]%0a%0a"targets=" is a comma delimited list of all links from the current page (no space following the comma).%0a%0a!!! Page file attributes [[#attr]]%0a%0aKeys you could see in a raw PmWiki file:%0a%0a:'''version''': Version of PmWiki used to create the file %25comment%25 More??? (ordered, urlencoded)%25%25%0a:'''agent''': Author's browser when saving the page%0a:'''author''': Last author to save page%0a:'''charset''': The character encoding of the page text%0a:'''csum''': Change summary%0a:'''ctime''': Page creation time%0a:'''description''':Page description. Used to fill [@%3cmeta name='description' />@] if set via[@(:description page'sdecription text:)@]%0a:'''host''': Host (IP address) last edited the page%0a:'''name''': Name of the page (e.g., [@Main.WikiSandbox@])%0a:'''passwdattr''': encrypted version of the password required to change [[PmWiki/Passwords|attributes]]%0a:'''passwdedit''': encrypted version of the password required to edit %0a:'''passwdread''': encrypted version of the password required to read%0a:'''passwdupload''': encrypted version of the password required to upload%0a:'''rev''': Number of times the page has been edited%0a:'''targets''': Targets for links in the page%0a:'''text''': The page's wiki markup%0a:'''time''': Time the page was last saved (seconds since 1 Jan 1970 00:00 UTC)%0a:'''title''': Page title set via [@(:title The Page Title:)@].%0a:'''newline''': Character used for newlines (deprecated)%0a:'''updatedto''': The version to which PmWiki has been updated to by [@upgrades.php@] (only on [[SiteAdmin.Status]])%0a%0aBelow these you will see information used to keep track of the page's revision history.%0a%0a!![[#creating]] Creating a Page for Distribution%0a%0aA simple way to create a wikipage file to use for distribution (for example with a recipe or a skin) is to create the page with PmWiki and then use a text editor to delete all lines but ''version'', ''text'', and ''ctime''. Example:%0a%0a->[@%0aversion=pmwiki-2.1.0 ordered=1 urlencoded=1%0atext=This is a line.%250aThis is another.%0actime=1142030000%0a@]%0a%0a[[#history]]%0a!! Keeping track of page history%0a%0aInside of a page file, PmWiki stores the latest version of the markup text, and uses this to render the page. The page history is kept as a sequence of differences between the latest version of the page and each previous version.%0a%0aPmWiki normally puts the page history at the end of each page file in reverse chronological sequence, and sets the "ordered=1" items in the header. If an operation needs only the most recent version of a page, then PmWiki will stop reading and processing a page file at the point where the history begins, potentially saving a lot of time and memory. If the "ordered=1" flag isn't present, PmWiki makes no assumptions about the ordering of items in the pagefile and processes the entire file.%0a%0a!! Load pages from text files%0aSee [[Cookbook: Import text]]. {Cookbook/ImportText$:Summary}%0a%0a!! Unix utility to extract wiki text%0a%0aThis one-line sed command extracts and prints the text of a PmWiki 2.x file (could be aliased, eg. ''pmcat''):%0a%0a [=sed -n 's/^text=//; s/%250a/\n/gp; s/%253c/%3c/gp; s/%2525/%25/gp'=] '''GroupName.PageName'''%0a%0a%0aThe following unix script (tested on MacOSX) will extract and decode the current text from a wiki file:%0a%0a->[@%0a#!/bin/tcsh%0a# wtext - extract wiki text%0a#%0a# wtext wikifile > output%0a%0aset fn = "$1"%0aif ("$fn" == "") then%0a echo "need input file parameter"%0a exit 999%0aendif%0aif (! -f $fn) then%0a echo "$fn does not exist"%0a exit 999%0aendif%0arm sedin.$$ >& /dev/null%0aset ch = `grep ^newline= $fn | cut -d= -f2`%0aif ("$ch" == "") set ch = "%250a"%0acat %3c%3ceof > sedin.$$%0as/^text=//%0as/$ch/\%0a/g%0as/%253c/%3c/g%0as/%2525/%25/g%0aeof%0agrep "^text=" "$1" | sed -f sedin.$$%0arm sedin.$$ >& /dev/null%0a@]%0a%0a!!See also%0a* [[Cookbook:AdminByShell]] [-A collection of ways to assist sysadmin of pmwiki using shell tools-]%0a* [[Cookbook:PageTopStore]] [-A PageStore alternative which doesn't mangle page contents when viewed outside PmWiki-]%0a%0aCategories: [[!PmWiki Developer]] -time=1569835012 +rev=69 +targets=PmWiki.Passwords,SiteAdmin.Status,Cookbook.ImportText,Cookbook.AdminByShell,Cookbook.PageTopStore,Category.PmWikiDeveloper,!PmWikiDeveloper +text=(:Summary:Create wiki formatted pages in bulk and for upload to your pmwiki site:)%0aYou may have many documents that you would like to use a local program to format in a format PmWiki can display.%0a%0aYou could open each document and copy/paste the content to new pmwiki pages or you could format the document in advance and upload it using an FTP client.%0a%0a!! Format [[#format]]%0aOnly two lines are necessary in a PmWiki page file:%0a%0a->[@%0aversion=pmwiki-2.1.0 urlencoded=1%0atext=Markup text%0a@]%0a%0a"version=" tells PmWiki that the values are urlencoded. The actual value doesn't matter, as long as "urlencoded=1" appears somewhere in the line.%0a%0a"text=" ''needs'' to have the markup text with newlines converted to "%250a" and percent signs converted to "%2525".%0a%0a-> In addition, ''PmWiki writes'' pages with '%3c' encoded as "%253c" (to help with security), but it doesn't require that %3c's be encoded that way in order to be able to read the page. More conversions are possible to be added in the future.%0a%0aIn order to let searches and the %25pmhlt%25[@(:pagelist :)@] markup work, make sure the filename begins with an uppercase letter.%0a%0aIn order to have the %25pmhlt%25[@(:pagelist link= ... :)@] markup on other pages list this page, a third attribute is required:%0a%0a->[@%0atargets=GroupName1.Pagename1,GroupName2.Pagename2,...%0a@]%0a%0a"targets=" is a comma delimited list of all links from the current page (no space following the comma).%0a%0a!!! Page file attributes [[#attr]]%0a%0aKeys you could see in a raw PmWiki file:%0a%0a:'''version''': Version of PmWiki used to create the file %25comment%25 More??? (ordered, urlencoded)%25%25%0a:'''agent''': Author's browser when saving the page%0a:'''author''': Last author to save page%0a:'''charset''': The character encoding of the page text%0a:'''csum''': Change summary%0a:'''ctime''': Page creation time%0a:'''description''':Page description. Used to fill %25hlt html%25[@%3cmeta name='description' />@] if set via %25pmhlt%25[@(:description page'sdecription text:)@]%0a:'''host''': Host (IP address) last edited the page%0a:'''name''': Name of the page (e.g., %25pmhlt%25[@Main.WikiSandbox@])%0a:'''passwdattr''': encrypted version of the password required to change [[PmWiki/Passwords|attributes]]%0a:'''passwdedit''': encrypted version of the password required to edit %0a:'''passwdread''': encrypted version of the password required to read%0a:'''passwdupload''': encrypted version of the password required to upload%0a:'''rev''': Number of times the page has been edited%0a:'''targets''': Targets for links in the page%0a:'''text''': The page's wiki markup%0a:'''time''': Time the page was last saved (seconds since 1 Jan 1970 00:00 UTC)%0a:'''title''': Page title set via %25pmhlt%25[@(:title The Page Title:)@].%0a:'''newline''': Character used for newlines (deprecated)%0a:'''updatedto''': The version to which PmWiki has been updated to by [@upgrades.php@] (only on [[SiteAdmin.Status]])%0a%0aBelow these you will see information used to keep track of the page's revision history.%0a%0a!![[#creating]] Creating a Page for Distribution%0a%0aA simple way to create a wikipage file to use for distribution (for example with a recipe or a skin) is to create the page with PmWiki and then use a text editor to delete all lines but ''version'', ''text'', and ''ctime''. Example:%0a%0a->[@%0aversion=pmwiki-2.1.0 ordered=1 urlencoded=1%0atext=This is a line.%250aThis is another.%0actime=1142030000%0a@]%0a%0a[[#history]]%0a!! Keeping track of page history%0a%0aInside of a page file, PmWiki stores the latest version of the markup text, and uses this to render the page. The page history is kept as a sequence of differences between the latest version of the page and each previous version.%0a%0aPmWiki normally puts the page history at the end of each page file in reverse chronological sequence, and sets the "ordered=1" items in the header. If an operation needs only the most recent version of a page, then PmWiki will stop reading and processing a page file at the point where the history begins, potentially saving a lot of time and memory. If the "ordered=1" flag isn't present, PmWiki makes no assumptions about the ordering of items in the pagefile and processes the entire file.%0a%0a!! Load pages from text files%0aSee [[Cookbook: Import text]]. {Cookbook/ImportText$:Summary}%0a%0a!! Unix utility to extract wiki text%0a%0aThis one-line sed command extracts and prints the text of a PmWiki 2.x file (could be aliased, eg. ''pmcat''):%0a%0a [=sed -n 's/^text=//; s/%250a/\n/gp; s/%253c/%3c/gp; s/%2525/%25/gp'=] '''GroupName.PageName'''%0a%0a%0aThe following unix script (tested on MacOSX) will extract and decode the current text from a wiki file:%0a%0a->%25hlt bash%25[@%0a#!/bin/tcsh%0a# wtext - extract wiki text%0a#%0a# wtext wikifile > output%0a%0aset fn = "$1"%0aif ("$fn" == "") then%0a echo "need input file parameter"%0a exit 999%0aendif%0aif (! -f $fn) then%0a echo "$fn does not exist"%0a exit 999%0aendif%0arm sedin.$$ >& /dev/null%0aset ch = `grep ^newline= $fn | cut -d= -f2`%0aif ("$ch" == "") set ch = "%250a"%0acat %3c%3ceof > sedin.$$%0as/^text=//%0as/$ch/\%0a/g%0as/%253c/%3c/g%0as/%2525/%25/g%0aeof%0agrep "^text=" "$1" | sed -f sedin.$$%0arm sedin.$$ >& /dev/null%0a@]%0a%0a!!See also%0a* [[Cookbook:AdminByShell]] [-A collection of ways to assist sysadmin of pmwiki using shell tools-]%0a* [[Cookbook:PageTopStore]] [-A PageStore alternative which doesn't mangle page contents when viewed outside PmWiki-]%0a%0aCategories: [[!PmWiki Developer]] +time=1663575965 blob - dc694de5a314b5a0da0ff01cddecefe55a1b9931 blob + a264c9a25ff2303c65f6c42dc7e058900ea44fbe --- wikilib.d/PmWiki.PageHistory +++ wikilib.d/PmWiki.PageHistory @@ -1,9 +1,9 @@ -version=pmwiki-2.2.107 ordered=1 urlencoded=1 -author=Petko +version=pmwiki-2.3.12 ordered=1 urlencoded=1 +author=simon charset=UTF-8 -csum=Fix link to page on pmwiki.org +csum=hlt php (+19) name=PmWiki.PageHistory -rev=49 +rev=52 targets=PmWiki.LayoutVariables,PmWiki.WikiAdministrator,PmWiki.EditVariables,PmWiki.SpecialPages,Cookbook.ExpireDiff,Cookbook.LimitDiffsPerPage,Cookbook.ViewDiff,Cookbook.TrackChanges,PmWiki.PageFileFormat -text=(:Summary: History of previous edits to a page:)%0a(:Audience: authors (basic) :)%0aWhen PmWiki is called with '?action=diff', it displays a summary of past edits on a page. Each past edit is shown in a box which shows lines added, changed or deleted during that edit in a before & after format.%0a%0aBelow each box is a "Restore" link. Clicking the link will open an edit box with the page as it was ''before'' that edit. You can make changes or simply click Save to restore the text.%0a%0aThere are two additional options specific to Page''''History:%0a%0a* '''Hide minor edits''' - hides any edit that the author marked as 'minor'. - This is done by adding "&minor=n" to "?action=diff". The default value for this is to show minor edits with "&minor=y"%0a%0a* '''Show changes to output''' - It shows changes to the rendered output (as opposed to the normal display which shows changes to the wiki-markup). This is done by adding "&source=n" to "?action=diff". You can show changes to markup (the default behavior from 2.2.13) with "&source=y".%0a%0a* You can set both by using "?action=diff&source=y&minor=y".%0a%0aIn the default mode "Show changes to markup", you can disable word-level highlighting of differences by adding to config.php such a line:%0a $EnableDiffInline = 0;%0a%0aA page's history is kept for the number of days given by the $DiffKeepDays and $DiffKeepNum variables (set by the site's [[wiki administrator]]). When a page is edited, any page history information older than both these values is automatically discarded.%0a%0aNote that a specific page revision isn't removed from the page until the first edit ''after'' the time specified by $DiffKeepDays has elapsed. Thus, it's still possible for some pages to have revisions older than $DiffKeepDays -- such revisions will be removed the next time those pages are edited.%0a%0a!! See also%0a* [[PmWiki:SpecialPages#recentchanges | recent changes]] special pages%0a* Cookbook:ExpireDiff%0a* Cookbook:LimitDiffsPerPage%0a* Cookbook:ViewDiff%0a* Cookbook:TrackChanges%0a%0a>>faq%3c%3c [[#faq]]%0a%0aQ: [[#removepagehistory]] Is there a way to remove page history from page files?%0aA: 1. Administrators can clean page histories using the Cookbook:ExpireDiff recipe. %0a%0aA: 2. Administrators with FTP file access can download individual pages from the wiki.d directory, open them in a text editor, manually remove history, and re-upload the files to wiki.d/ directory. Care must be exercised, when manually editing a page file, to preserve the minimum required elements of the page and avoid corrupting its contents. See [[PmWiki/PageFileFormat#creating]].%0a%0aA: 3. Edit the page. Select ''all'' the contents of the edit text area and cut them to the clipboard. Enter @@delete@@ into the text area and click on the ''save and edit'' button. Select ''all'' the contents of the edit text area and paste the contents of the clipboard over them. Click on the ''save'' button. This will remove all of the page's history up to the final save in which the pasted material is re-added.%0a%0aQ: [[#restrictpagehistory]] How can I restrict viewing the page history [@(?action=diff)@] to people with edit permission?%0aA: In the ''local/config.php'' file, set%0a%0a->[@$HandleAuth['diff'] = 'edit'@];%0a%0aIn case of this restriction is set up on a farm, and you want to allow it on a particular wiki, set in your local/config.php :%0a%0a->[@$HandleAuth['diff'] = 'read'@];%0a -time=1518807578 +text=(:Summary: History of previous edits to a page:)%0a(:Audience: authors (basic) :)%0aWhen PmWiki is called with '@@?action=diff@@', it displays a summary of past edits on a page. Each past edit is shown in a box which shows lines added, changed or deleted during that edit in a before and after format.%0a%0aBelow each box is a "Restore" link. Clicking the link will open an edit box with the page as it was ''before'' that edit. You can make changes or simply click Save to restore the text.%0a%0aThere are two additional options specific to Page''''History:%0a%0a* '''Hide minor edits''' - hides any edit that the author marked as 'minor'. - This is done by adding "&minor=n" to "?action=diff". The default value for this is to show minor edits with "&minor=y"%0a%0a* '''Show changes to output''' - It shows changes to the rendered output (as opposed to the normal display which shows changes to the wiki-markup). This is done by adding "&source=n" to "?action=diff". You can show changes to markup (the default behavior from 2.2.13) with "&source=y".%0a%0a* You can set both by using "?action=diff&source=y&minor=y".%0a%0aIn the default mode "Show changes to markup", you can disable word-level highlighting of differences by adding to @@config.php@@ such a line:%0a-> %25hlt php%25@@$EnableDiffInline = 0;@@%0a%0aA page's history is kept for the number of days given by the $DiffKeepDays and $DiffKeepNum variables (set by the site's [[wiki administrator]]). When a page is edited, any page history information older than both these values is automatically discarded.%0a%0aNote that a specific page revision isn't removed from the page until the first edit ''after'' the time specified by $DiffKeepDays has elapsed. Thus, it's still possible for some pages to have revisions older than $DiffKeepDays -- such revisions will be removed the next time those pages are edited.%0a%0a!! See also%0a* [[PmWiki:SpecialPages#recentchanges | recent changes]] special pages%0a* Cookbook:ExpireDiff%0a* Cookbook:LimitDiffsPerPage%0a* Cookbook:ViewDiff%0a* Cookbook:TrackChanges%0a%0a>>faq%3c%3c [[#faq]]%0a%0aQ: [[#removepagehistory]] Is there a way to remove page history from page files?%0aA: 1. Administrators can clean page histories using the Cookbook:ExpireDiff recipe. %0a%0aA: 2. Administrators with FTP file access can download individual pages from the @@wiki.d@@ directory, open them in a text editor, manually remove history, and re-upload the files to @@wiki.d/@@ directory. Care must be exercised, when manually editing a page file, to preserve the minimum required elements of the page and avoid corrupting its contents. See [[PmWiki/PageFileFormat#creating]].%0a%0aA: 3. Edit the page. Select ''all'' the contents of the edit text area and cut them to the clipboard. Enter @@delete@@ into the text area and click on the ''save and edit'' button. Select ''all'' the contents of the edit text area and paste the contents of the clipboard over them. Click on the ''save'' button. This will remove all of the page's history up to the final save in which the pasted material is re-added.%0a%0aQ: [[#restrictpagehistory]] How can I restrict viewing the page history [@(?action=diff)@] to people with edit permission?%0aA: In the @@local/config.php@@ file, set%0a%0a->%25hlt php%25[@$HandleAuth['diff'] = 'edit'@];%0a%0aIn case of this restriction is set up on a farm, and you want to allow it on a particular wiki, set in your @@local/config.php@@:%0a%0a->%25hlt php%25[@$HandleAuth['diff'] = 'read'@];%0a +time=1664588528 blob - 90f8a499857c4e5bdb43f1cb46ebe19b695193e4 blob + 1449efd7c6b0f3259f8dd2b107be480c920ae004 --- wikilib.d/PmWiki.PageListTemplates +++ wikilib.d/PmWiki.PageListTemplates @@ -1,10 +1,10 @@ -version=pmwiki-2.2.120 ordered=1 urlencoded=1 -author=Petko +version=pmwiki-2.3.3 ordered=1 urlencoded=1 +author=simon charset=UTF-8 -csum=$$EachCount +csum=pm hlt (+321) ctime=1176759249 name=PmWiki.PageListTemplates -rev=43 +rev=44 targets=PmWiki.PageLists,Site.PageListTemplates,Site.LocalTemplates,PmWiki.PagelistVariables,Cookbook.PagelistTemplateSamples,PmWiki.PageVariables,PmWiki.PageTextVariables,Cookbook.DictIndex,Cookbook.SimpleForum,Cookbook.Cookbook -text=(:Summary: Creating [[PmWiki/page list(s)]] format templates:)%0a!! Default [[page list(s)]] templates%0a%0aPmWiki's default templates for [[page lists]] are in [[Site.PageListTemplates]], which is replaced during upgrades. %0aThese default templates can be supplemented or overridden with custom templates stored in other locations. %0a %0aPmWiki's default configuration looks for templates in the following locations in the following order:%0a# the page name specified as part of the template name%0a# the current page body%0a# [[Site.LocalTemplates]], %0a# [[Site.PageListTemplates]]%0aIf the pagelist is defined in a sidebar, group header or footer, etc, the page name must be specified as part of the template name.%0aAdministrators can change those locations by using the $FPLTemplatePageFmt variable. %0a%0aIf the template is on the current page, the current page must be saved for changes involving the template to show up ''(preview alone will not work)''.%0a%0a!! Custom page list templates%0aCustom templates are used in the same way as default templates: by referencing the desired format with the @@fmt=#''anchor''@@ option. %0aThere are several ways to indicate which template to use:%0a* [@fmt=#custom@] uses the #custom section from the current page, [[Site.LocalTemplates]], or [[Site.PageListTemplates]], (sections are denoted by [@[[#custom]]@] anchors.%0a* [@fmt=MyTemplatePage#custom@] uses a custom format from page @@MyTemplatePage@@ from its @@#custom@@ section.%0a* [@fmt=MyTemplatePage@] uses a custom format from the entire page @@MyTemplatePage@@.%0a* [@fmt=custom@] uses custom format which is defined in a cookbook script as ''custom''.%0a%0aSee Cookbook:PagelistTemplateSamples for examples of custom pagelist formats.%0a%0a!! Creating page list templates%0aA pagelist template contains standard pmwiki markup. %0aWhen creating pagelist output, pmwiki iterates over each page returned from the pagelist and will include the pagelist template markup once for every page in the list. %0a%0a[[#specialreferences]]%0a!!! Special references %0aDuring the page list iteration pmwiki sets 3 special page references: '''=''', '''%3c''' and '''>'''. %0aThese special page references are updated on each pagelist iteration and can be used with the [[page variables]] syntax, such as ''{=$variable}'', to define a pagelist template which will format the pagelist output. The meaning of the special references are:%0a||width=*%0a|| = ||current page ||so ''[@{=$Title}@]'' ||displays the title of the current page in the iteration%0a|| %3c ||previous page ||so ''[@{%3c$Group}@]'' ||displays the group of the previous page in the iteration%0a|| > ||next page ||so ''[@{>$Name}@]'' ||displays the name of the next page in the iteration%0a%0a%0aThe > and %3c references are most useful to help structure pagelist output before and after the actual pagelist. Some common tests used to structure pagelist output are:%0a(:table class=frame:)%0a(:cellnr:)[@(:template first:)@]%0a(:cell:)[- {- [@(:if equal {%3c$Group}:)@] -} -]%0a(:cell:)Iteration is at the beginning of list%0a(:cellnr:)[@(:template last:)@]%0a(:Cell:)[- {- [@(:if equal {>$Group}:)@] -} -]%0a(:cell:)Iteration is at the end of list%0a(:cellnr:)[@(:template first {=$Group}:)@]%0a(:cell:)[- {- [@(:if ! equal {=$Group} {%3c$Group}:)@] -} -]%0a(:cell:)Iteration is at the first item in a group%0a(:cellnr:)[@(:template last {=$Group}:)@]%0a(:cell:)[- {- [@(:if ! equal {=$Group} {>$Group}:)@] -} -]%0a(:cell:)Iteration is at the last item in a group %0a(:cellnr:)[@(:template defaults:)@]%0a(:cell:)%0a(:cell:)Default options to be used in the pagelist command%0a(:cellnr:)[@(:template each:)@]%0a(:cell:)%0a(:cell:)Signifies the repeated part%0a(:cellnr:)[@(:template none:)@]%0a(:cell:)%0a(:cell:)Used if no match found%0a(:tableend:)%0a[[#specialreferencesend]]%0a''Note'': the markup in column 2 is deprecated.%0a-%3c See also [[PageVariables#specialreferences|page variable special references]].%0a%0a!! Page list template special markup%0aPagelist templates may have special sections%0a* [@(:template first ...:)@] and [@(:template ! first ...:)@]%0a* [@(:template last ...:)@] and [@(:template ! last ...:)@]%0ato specify output for the first or last page in the list or a group (use @@ !first @@ and @@ !last @@ for output ''except'' for the first/last page).%0a%0aThere's also a %0a* [@(:template defaults ...:)@] %0a to allow a template to specify default options,%0a* [@(:template each ...:)@]%0a to signify the repeated part, and%0a* [@(:template none:)@]%0a whose content will appear if no page was found (from version 2.2.5).%0a%0aThese allow Pagelist templates to be easily separated into "sections"%0athat are included or not included in the output based on a variety of%0aconditions. These are intended to be improved versions of the%0a[=(:if ...:)=] conditions that have traditionally been used to control%0apagelist output (however, the [=(:if:)=] conditions still work as before).%0a%0a!!! First, Each, Last, None%0aThe simplest versions of the directives are:%0a-> [@%0a(:template first:) # markup to display only for first page in list%0a(:template ! first:) # markup to display for every page in list but the first%0a(:template each:) # markup to display for each page in list%0a(:template last:) # markup to display only on last page in list%0a(:template ! last:) # markup to display for every page in list but the last%0a(:template none:) # markup to display only if no pages were found@]%0a%0aSo, a pagelist template can specify:%0a%0a->[@(:template first:)%0aPages in the list:%0a(:template each:)%0a* [[{=$FullName}]] [-{=$:Summary}-]%0a(:template last:)%0aDisplayed {$$PageCount} pages.@]%0a%0aIn addition, the "first" and "last" options can have control break%0aarguments that identify markup to be displayed on the first or last%0apage within a particular control section. For example, to specify%0amarkup to be displayed upon reaching the first or last page of%0aa group, one can use%0a%0a->[@(:template first {=$Group}:)%0a(:template last {=$Group}:)@]%0a%0aThus, instead of writing control breaks using (:if:) directives, as in%0a%0a->[@(:if ! equal {%3c$Group} {=$Group}:)%0aGroup: {=$Group}%0a(:ifend:)%0a* [[{=$FullName}]]@]%0a%0aone can now write%0a%0a->[@(:template first {=$Group}:)%0aGroup: {=$Group}%0a(:template each:)%0a* [[{=$FullName}]]@]%0a%0a[[Page text variables]] and [[page variables]] can also be used, for example%0a->[@(:template default $:Maintainer=- order=$:Maintainer,name:)%0a(:template first {=$:Maintainer}:)%0a@]%0a%0a!!! Default options%0aIn addition, a template may specify default options to be used%0ain the pagelist command. For example, a pagelist template to%0adisplay a list of pages by their titles (and sorted by title)%0amight use:%0a%0a->[@[[#bytitle]]%0a(:template defaults order=title:)%0a* [[{=$FullName}|+]]%0a[[#bytitleend]]@]%0a%0aThen an author could write [=(:pagelist fmt=#bytitle:)=] and the%0apages would automatically be sorted by title without having to%0aspecify an additional "order=title" option to the [=(:pagelist:)=]%0adirective.%0a%0aTo specify multiple parameters to an option enclose the parameters in double quotes, eg to sort by a [[page text variable(s)]] and then the page name%0a-> [@ (:template defaults order="$:Database,name" :) @]%0a%0a!!! Examples%0a:[=(:template defaults ... :)=] : default options for pagelists using this template%0a:[=(:template each:)=] : markup for each page in the pagelist%0a:[=(:template first:)=] : markup output only for the first page in the pagelist%0a:[=(:template last:)=] : markup output only for the last page in the pagelist%0a:[=(:template first {=$Group}:)=] : markup output only for a page where the value of {=$Group} has just changed%0a:[=(:template last {=$Group}:)=] : markup output only for a page where the value of {=$Group} will change with the next page%0a%0aSo, we have:%0a%0a->[@[[#template]]%0a(:template defaults order=name:)%0a(:template first:)%0aPages ordered by group%0a(:template first {=$Group}:)%0a%0aPages in group [[{=$Group}/]]%0a(:template each:)%0a* [[{=$FullName}]]%0a(:template last {=$Group}:)%0a {=$Group} contains {$$GroupPageCount} pages.%0a(:template last:)%0a {$$PageCount} pages total.%0a[[#templateend]] @]%0a%0a[[#additionalpagevariables]]%0a!! Page list template additional page variables%0aAdditional [[Page Variables]] that are only available during pagelist are: %0a->[@%0a{$$PageCount} The current page count of this iteration%0a{$$GroupCount} The current group count of this iteration%0a{$$GroupPageCount} The current page count within the current group of this iteration%0a{$$EachCount} The current page count within the current loop@]%0a->@@[={$$=]''option''} The argument option values from @@[@(:pagelist:)@]%0a%0a[@{$$EachCount}@] increases with each page from the pagelist, and resets when a [@(:template first {=$Property}:)@] or [@(:template last {=$Property}:)@] section is output. It can be useful when a pagelist is ordered by a page (text) variable or other property, and the pages with the same property need to be grouped together. If the order is [@$Group@] and the property is "[@{=$Group}@]", then [@{$$EachCount}@] and [@{$$GroupPageCount}@] are the same.%0a%0aUse of {$$''option''}: For example {$$trail} returns the page name entered in the trail= option of the pagelist directive. You can make up custom "options" with no other purpose than being displayed in the pagelist.%0a%0a[[#redirect]]%0a!! Redirect %0aTo enable searches that return only one page to automatically redirect to that page add the following to a pagelist template where the "jump to a page" functionality is desired:%0a%0a-> [@(:template last:)%0a(:if equal {$$PageCount} 1:)(:redirect {=$FullName}:)(:ifend:)%0a@]%0a%0a[[#closure]]%0a!! Closure of markup%0aAny open tables, divs, or other%0astructures inside of [=(:pagelist:)=] are, by default, automatically closed at the%0aend of the pagelist command. In other words, [=(:pagelist:)=] acts like%0aits own complete page, as opposed to generating markup that is then%0ainserted into the enclosing page.%0a%0aFor example a table generated by the [=(:cell:)=]%0adirective in the first [=(:pagelist:)=] command is automatically closed%0aat the end of the pagelist. The [=(:cell:)=] in the second [=(:pagelist:)=]%0acommand then starts a new table.%0a%0aNote that the [=(:table:)=] directive doesn't actually start a new table,%0ait's the [=(:cell:)=] or [=(:cellnr:)=] directive that does it. All that the%0a[=(:table:)=] directive does is set attributes for any tables that follow.%0a%0a!! Usage%0aIt is advisable to not modify the page [[Site.PageListTemplates]] directly so that you will still benefit from upgrades. %0aInstead, modify your [[Site.LocalTemplates]] page (which is not part of the PmWiki distribution). Cookbook:PagelistTemplateSamples has many examples of custom pagelist formats.%0a%0a!! Other recipes%0aIn addition, the [[(Cookbook:)Cookbook]] has other recipes for special [@fmt=@] options, including [[Cookbook:DictIndex | [@fmt=dictindex@] ]] (alphabetical index) and [[Cookbook:SimpleForum | [@fmt=forum@] ]] (forum postings).%0a -time=1574162643 +text=(:Summary: Creating [[PmWiki/page list(s)]] format templates:)%0a!! Default [[page list(s)]] templates%0a%0aPmWiki's default templates for [[page lists]] are in [[Site.PageListTemplates]], which is replaced during upgrades. %0aThese default templates can be supplemented or overridden with custom templates stored in other locations. %0a %0aPmWiki's default configuration looks for templates in the following locations in the following order:%0a# the page name specified as part of the template name%0a# the current page body%0a# [[Site.LocalTemplates]], %0a# [[Site.PageListTemplates]]%0aIf the pagelist is defined in a sidebar, group header or footer, etc, the page name must be specified as part of the template name.%0aAdministrators can change those locations by using the $FPLTemplatePageFmt variable. %0a%0aIf the template is on the current page, the current page must be saved for changes involving the template to show up ''(preview alone will not work)''.%0a%0a!! Custom page list templates%0aCustom templates are used in the same way as default templates: by referencing the desired format with the %25pmhlt%25[@fmt=#''anchor''@] option. %0aThere are several ways to indicate which template to use:%0a* %25pmhlt%25[@fmt=#custom@] uses the #custom section from the current page, [[Site.LocalTemplates]], or [[Site.PageListTemplates]], (sections are denoted by [@[[#custom]]@] anchors.%0a* [@fmt=MyTemplatePage#custom@] uses a custom format from page @@MyTemplatePage@@ from its @@#custom@@ section.%0a* [@fmt=MyTemplatePage@] uses a custom format from the entire page @@MyTemplatePage@@.%0a* [@fmt=custom@] uses custom format which is defined in a cookbook script as ''custom''.%0a%0aSee Cookbook:PagelistTemplateSamples for examples of custom pagelist formats.%0a%0a!! Creating page list templates%0aA pagelist template contains standard pmwiki markup. %0aWhen creating pagelist output, pmwiki iterates over each page returned from the pagelist and will include the pagelist template markup once for every page in the list. %0a%0a[[#specialreferences]]%0a!!! Special references %0aDuring the page list iteration pmwiki sets 3 special page references: '''=''', '''%3c''' and '''>'''. %0aThese special page references are updated on each pagelist iteration and can be used with the [[page variables]] syntax, such as ''{=$variable}'', to define a pagelist template which will format the pagelist output. The meaning of the special references are:%0a||width=*%0a|| = ||current page ||so %25pmhlt%25[@{=$Title}@] ||displays the title of the current page in the iteration%0a|| %3c ||previous page ||so %25pmhlt%25[@{%3c$Group}@] ||displays the group of the previous page in the iteration%0a|| > ||next page ||so %25pmhlt%25[@{>$Name}@] ||displays the name of the next page in the iteration%0a%0a%0aThe > and %3c references are most useful to help structure pagelist output before and after the actual pagelist. Some common tests used to structure pagelist output are:%0a(:table class=frame:)%0a(:cellnr:)%25pmhlt%25[@(:template first:)@]%0a(:cell:)[- {- [=(:if equal {%3c$Group}:)=] -} -]%0a(:cell:)Iteration is at the beginning of list%0a(:cellnr:)%25pmhlt%25[@(:template last:)@]%0a(:Cell:)[- {- [=(:if equal {>$Group}:)=] -} -]%0a(:cell:)Iteration is at the end of list%0a(:cellnr:)%25pmhlt%25[@(:template first {=$Group}:)@]%0a(:cell:)[- {- [=(:if ! equal {=$Group} {%3c$Group}:)=] -} -]%0a(:cell:)Iteration is at the first item in a group%0a(:cellnr:)%25pmhlt%25[@(:template last {=$Group}:)@]%0a(:cell:)[- {- [=(:if ! equal {=$Group} {>$Group}:)=] -} -]%0a(:cell:)Iteration is at the last item in a group %0a(:cellnr:)%25pmhlt%25[@(:template defaults:)@]%0a(:cell:)%0a(:cell:)Default options to be used in the pagelist command%0a(:cellnr:)%25pmhlt%25[@(:template each:)@]%0a(:cell:)%0a(:cell:)Signifies the repeated part%0a(:cellnr:)%25pmhlt%25[@(:template none:)@]%0a(:cell:)%0a(:cell:)Used if no match found%0a(:tableend:)%0a[[#specialreferencesend]]%0a''Note'': the markup in column 2 is deprecated.%0a-%3c See also [[PageVariables#specialreferences|page variable special references]].%0a%0a!! Page list template special markup%0aPagelist templates may have special sections%0a* %25pmhlt%25[@(:template first ...:)@] and [@(:template ! first ...:)@]%0a* %25pmhlt%25[@(:template last ...:)@] and [@(:template ! last ...:)@]%0ato specify output for the first or last page in the list or a group (use @@ !first @@ and @@ !last @@ for output ''except'' for the first/last page).%0a%0aThere's also a %0a* %25pmhlt%25[@(:template defaults ...:)@] %0a to allow a template to specify default options,%0a* %25pmhlt%25[@(:template each ...:)@]%0a to signify the repeated part, and%0a* %25pmhlt%25[@(:template none:)@]%0a whose content will appear if no page was found (from version 2.2.5).%0a%0aThese allow Pagelist templates to be easily separated into "sections"%0athat are included or not included in the output based on a variety of%0aconditions. These are intended to be improved versions of the%0a%25pmhlt%25[@(:if ...:)@] conditions that have traditionally been used to control%0apagelist output (however, the [@(:if:)@] conditions still work as before).%0a%0a!!! First, Each, Last, None%0aThe simplest versions of the directives are:%0a-> %25pmhlt%25[@%0a(:template first:) # markup to display only for first page in list%0a(:template ! first:) # markup to display for every page in list but the first%0a(:template each:) # markup to display for each page in list%0a(:template last:) # markup to display only on last page in list%0a(:template ! last:) # markup to display for every page in list but the last%0a(:template none:) # markup to display only if no pages were found@]%0a%0aSo, a pagelist template can specify:%0a%0a->%25pmhlt%25[@(:template first:)%0aPages in the list:%0a(:template each:)%0a* [[{=$FullName}]] [-{=$:Summary}-]%0a(:template last:)%0aDisplayed {$$PageCount} pages.@]%0a%0aIn addition, the "first" and "last" options can have control break%0aarguments that identify markup to be displayed on the first or last%0apage within a particular control section. For example, to specify%0amarkup to be displayed upon reaching the first or last page of%0aa group, one can use%0a%0a->%25pmhlt%25[@(:template first {=$Group}:)%0a(:template last {=$Group}:)@]%0a%0aThus, instead of writing control breaks using (:if:) directives, as in%0a%0a->%25pmhlt%25[@(:if ! equal {%3c$Group} {=$Group}:)%0aGroup: {=$Group}%0a(:ifend:)%0a* [[{=$FullName}]]@]%0a%0aone can now write%0a%0a->%25pmhlt%25[@(:template first {=$Group}:)%0aGroup: {=$Group}%0a(:template each:)%0a* [[{=$FullName}]]@]%0a%0a[[Page text variables]] and [[page variables]] can also be used, for example%0a->%25pmhlt%25[@(:template default $:Maintainer=- order=$:Maintainer,name:)%0a(:template first {=$:Maintainer}:)%0a@]%0a%0a!!! Default options%0aIn addition, a template may specify default options to be used%0ain the pagelist command. For example, a pagelist template to%0adisplay a list of pages by their titles (and sorted by title)%0amight use:%0a%0a->%25pmhlt%25[@[[#bytitle]]%0a(:template defaults order=title:)%0a* [[{=$FullName}|+]]%0a[[#bytitleend]]@]%0a%0aThen an author could write %25pmhlt%25[@(:pagelist fmt=#bytitle:)@] and the%0apages would automatically be sorted by title without having to%0aspecify an additional "order=title" option to the [=(:pagelist:)=]%0adirective.%0a%0aTo specify multiple parameters to an option enclose the parameters in double quotes, eg to sort by a [[page text variable(s)]] and then the page name%0a-> %25pmhlt%25[@ (:template defaults order="$:Database,name" :) @]%0a%0a!!! Examples%0a:%25pmhlt%25[@(:template defaults ... :)@] : default options for pagelists using this template%0a:%25pmhlt%25[@(:template each:)@] : markup for each page in the pagelist%0a:%25pmhlt%25[@(:template first:)@] : markup output only for the first page in the pagelist%0a:%25pmhlt%25[@(:template last:)@] : markup output only for the last page in the pagelist%0a:%25pmhlt%25[@(:template first {=$Group}:)@] : markup output only for a page where the value of {=$Group} has just changed%0a:%25pmhlt%25[@(:template last {=$Group}:)@] : markup output only for a page where the value of {=$Group} will change with the next page%0a%0aSo, we have:%0a%0a->%25pmhlt%25[@[[#template]]%0a(:template defaults order=name:)%0a(:template first:)%0aPages ordered by group%0a(:template first {=$Group}:)%0a%0aPages in group [[{=$Group}/]]%0a(:template each:)%0a* [[{=$FullName}]]%0a(:template last {=$Group}:)%0a {=$Group} contains {$$GroupPageCount} pages.%0a(:template last:)%0a {$$PageCount} pages total.%0a[[#templateend]] @]%0a%0a[[#additionalpagevariables]]%0a!! Page list template additional page variables%0aAdditional [[Page Variables]] that are only available during pagelist are: %0a->%25pmhlt%25[@%0a{$$PageCount} The current page count of this iteration%0a{$$GroupCount} The current group count of this iteration%0a{$$GroupPageCount} The current page count within the current group of this iteration%0a{$$EachCount} The current page count within the current loop@]%0a->%25pmhlt%25[@{$$option} The argument option values from (:pagelist:)@]%0a%0a%25pmhlt%25[@{$$EachCount}@] increases with each page from the pagelist, and resets when a [@(:template first {=$Property}:)@] or [@(:template last {=$Property}:)@] section is output. It can be useful when a pagelist is ordered by a page (text) variable or other property, and the pages with the same property need to be grouped together. If the order is [@$Group@] and the property is "[@{=$Group}@]", then [@{$$EachCount}@] and [@{$$GroupPageCount}@] are the same.%0a%0aUse of %25pmhlt%25[@{$$''option''}@]: For example [@{$$trail}@] returns the page name entered in the trail= option of the pagelist directive. You can make up custom "options" with no other purpose than being displayed in the pagelist.%0a%0a[[#redirect]]%0a!! Redirect %0aTo enable searches that return only one page to automatically redirect to that page add the following to a pagelist template where the "jump to a page" functionality is desired:%0a%0a-> %25pmhlt%25[@(:template last:)%0a(:if equal {$$PageCount} 1:)(:redirect {=$FullName}:)(:ifend:)%0a@]%0a%0a[[#closure]]%0a!! Closure of markup%0aAny open tables, divs, or other%0astructures inside of %25pmhlt%25[@(:pagelist:)@] are, by default, automatically closed at the%0a%25pmhlt%25end of the pagelist command. In other words, [@(:pagelist:)@] acts like%0aits own complete page, as opposed to generating markup that is then%0ainserted into the enclosing page.%0a%0a%25pmhlt%25 For example a table generated by the [@(:cell:)@]%0a%25pmhlt%25directive in the first [@(:pagelist:)@] command is automatically closed%0a%25pmhlt%25at the end of the pagelist. The [@(:cell:)@] in the second [@(:pagelist:)@]%0acommand then starts a new table.%0a%0a%25pmhlt%25Note that the [@(:table:)@] directive doesn't actually start a new table,%0a%25pmhlt%25it's the [@(:cell:)@] or [@(:cellnr:)@] directive that does it. All that the%0a%25pmhlt%25[@(:table:)@] directive does is set attributes for any tables that follow.%0a%0a!! Usage%0aIt is advisable to not modify the page [[Site.PageListTemplates]] directly so that you will still benefit from upgrades. %0aInstead, modify your [[Site.LocalTemplates]] page (which is not part of the PmWiki distribution). Cookbook:PagelistTemplateSamples has many examples of custom pagelist formats.%0a%0a!! Other recipes%0a%25pmhlt%25In addition, the [[(Cookbook:)Cookbook]] has other recipes for special [@fmt=@] options, including [[Cookbook:DictIndex | [@fmt=dictindex@] ]] (alphabetical index) and [[Cookbook:SimpleForum | [@fmt=forum@] ]] (forum postings).%0a +time=1649196717 blob - 6763fd12b0f438e9bcb92948d530b1301beb767d blob + 7acdfae730b0f39a7324e0a209a71e4500d5e73a --- wikilib.d/PmWiki.PageLists +++ wikilib.d/PmWiki.PageLists @@ -1,10 +1,10 @@ -version=pmwiki-2.2.127 ordered=1 urlencoded=1 -author=simon +version=pmwiki-2.3.16 ordered=1 urlencoded=1 +author=Petko charset=UTF-8 -csum=add link (+16) +csum=there is no order=size (-113) ctime=1138643894 name=PmWiki.PageLists -rev=271 -targets=PmWiki.PageListTemplates,PmWiki.DocumentationIndex,PmWiki.PageTextVariables,PmWiki.MarkupExpressions,PmWiki.PageVariables,PmWiki.WikiTrails,PmWiki.BasicVariables,Cookbook.SearchResults,PmWiki.PagelistVariables,Site.PageListTemplates,PmWiki.Categories,Cookbook.PageListMultiTargets,PmWiki.ConditionalMarkup,PmWiki.CustomPagelistSortOrder,PmWiki.PathVariables,PmWiki.Internationalizations,Cookbook.PagelistTemplateSamples,Cookbook.Forms,Cookbook.CustomPagelistSortOrderFunctions,PmWiki.PageLists,PmWiki.PageDirectives,PmWiki.Search -text=(:Audience: authors, admins (intermediate) :)%0a(:Summary:Searching and listing pages by multiple criteria with templated output:)%0aPmWiki comes with two directives for generating lists of pages -- [@(:pagelist:)@] and @@[=(:=]searchresults:)@@. Both directives are basically the same and each accepts the parameters documented below. The primary difference between the two is that searchresults generates the "Results of search for ..." and "### pages found out of ### searched" messages around the results.%0a%0aThe [@(:searchbox:)@] directive generates a search form (input text box) to submit search queries. The markup generally accepts the same parameters as [@(:pagelist:)@], which makes it possible to restrict, order and format searchresults in the same ways that are described below for a [@(:pagelist:)@]. For more information about the [@(:searchbox:)@] directive, and the ways in which it differs from a [@(:pagelist:)@], skip to the section [[#searchbox|below]].%0a%0a!! Basic syntax%0a%0a* [@(:pagelist:)@] %0a->without any arguments shows a bulleted list of all pages, as links, ordered alphabetically and in groups.%0a* @@[=(:=]pagelist [[#pagelistgroup|group]]=''ab'' \%0a [[#pagelistname|name]]=''cd'' \%0a [[#pagelistfmt|fmt]]=''[[page list templates|template]]'' \%0a [[#pagelistlist|list]]=''ef'' \%0a [[#pagelistorder|order]]=''gh'' \%0a [[#pagelistcount|count]]=''123'' \%0a [[#pagelistlink|link]]=''ij'' \%0a [[#pagelisttrail|trail]]=''kl'' \%0a [[#pagelistwrap|wrap]]=''mn'' \%0a [[#pagelistpasswd|passwd]]=''op'' \%0a [[#pagelistif|if]]=''qr'' \%0a [[#pagetextvariables|$:''ptv'']]=''st'' \%0a [[#pagevariables|$''pv'']]=''uv'' \%0a [[#pagelistcache|cache]]=0 \%0a ''[[#pagelistarg|argument]]1'' -''[[#pagelistarg|argument]]2'' ''etc'' \%0a [[#includevariable|variable]]=''value'' \%0a [[#pagelistclass|class]]=''class'' \%0a [[#pagelistrequest|''request=1'']] \%0a [[#pagelistreq|''req=1'']] \%0a :)@@ %0a->shows a pagelist according to the parameters supplied. Parameters are optional.%0a* @@[=(:=][[#searchbox|searchbox]] value=''abc'' size=''99'' target=''def'' label="label":)@@%0a* @@[=(:=][[#searchresults|searchresults]]:)@@%0a%0a!! Parameters%0a[[#pagelistarg]]%0aAny argument supplied within [@(:pagelist:)@] that isn't in the form @@'key=value'@@ is treated as text that either must (or must not) exist in the page text.%0a%0aThe minus sign (-) can be used to indicate things that should be excluded. Thus%0a->[@(:pagelist trail=PmWiki.DocumentationIndex list=normal apple -pie:)@]%0alists all "normal" pages listed in the [[Documentation Index ]] trail that contain the word "apple" but not "pie".%0a%0a!!![[#pagetextvariables]]With page text variables%0aYou can also use [[page text variables]] as a ''key'' to list pages according to the existence of a page text variable. Eg : %0a->[@(:pagelist $:pagetextvar=avalue:)@]%0alists pages having ''$:pagetextvar'' set to ''avalue''.%0a[[%3c%3c]]%0aMinus sign (-), wildcards (?*) and a comma separated list of values also works when specifying a selection based on pagetextvariables. Eg :%0a->[@(:pagelist $:apagetextvar=t*,-test:)@]%0alists pages having $:apagetextvar like 't*' but not 'test'.%0a[[%3c%3c]]%0aExamples:%0a||width=* class="tabtable" rules=rows%0a||PTV is set (is not empty): ||[@(:pagelist $:MyPageTextVariable=- :)@]||%0a||PTV is empty or not set:[[%3c%3c]] (ie, is not set to one char followed by 0 or more chars) ||[@(:pagelist $:MyPageTextVariable=-?* :)@]||%0a||PTV is not VALUE: ||[@(:pagelist $:MyPageTextVariable=-VALUE :)@]||%0a||PTV is set and not YES: ||[@(:pagelist $:MyPageTextVariable=?*,-YES :)@]||%0aBe aware that if using [@(:pagelist $:MyPTV=$:YourPTV :)@] PTVs include PmWiki formatting, so you may not get the matches you expect. Currently the only way around this is to use wild cards, so if the formatting is embedded you may be out of luck.%0a%0aNOTE: Pagelist does not evaluate [[PmWiki/MarkupExpressions]] when working with PTVs. So if your [[page text variables]] is defined using a markup expression to set the value, pagelist will see the literal values of the text of your markup expression rather than the result of your expression. (e.g., the PTV definition [@(:foo:{(substr abcdef 2 4)}:)@] will be seen by pagelist as an open-curly-brace followed by an open-paren followed by s-u-b-s-t-r, etc. rather than being seen as b-c-d-e) Any processing of the markup expression in the output of your pagelist occurs in subsequent rules (after pagelist) within the context of the current page and thus these values cannot be used for sorting or selecting pages. ([[http://thread.gmane.org/gmane.comp.web.wiki.pmwiki.user/60968/focus=60970|source]])%0a%0a!!![[#pagevariables]]With page variables (PV)%0a%0a[[Page variables]] can be used within pagelists in the same way as [[page text variables]]. See [[#pagetextvariables|Page Text Variables]] above for more details. Simply use @@$var@@ instead of @@$:var@@.%0a%0a!!![[#pagelistgroup]] group= and [[#pagelistname]]name= %0a%0aThe "[@group=@]" and "[@name=@]" parameters limit results to pages in a specific group or with a specific name:%0a(:table class='tabtable' rules=rows:)%0a(:cellnr:)All pages in the Pmwiki group:%0a(:cell:)[@(:pagelist group=PmWiki :)@]%0a(:cellnr:)All pages except those in the PmWiki or Site groups:%0a(:cell:)[@(:pagelist group=-PmWiki,-Site :)@]%0a(:cellnr:)All RecentChanges pages%0a(:cell:)[@(:pagelist name=RecentChanges :)@]%0a(:cellnr:)All pages except RecentChanges%0a(:cell:)[@(:pagelist name=-RecentChanges :)@]%0a(:tableend:)%0a%0a!!! Wildcards%0aName and group parameters can contain ''wildcard'' characters that display only pages matching a given pattern:%0a* An asterisk (*) represents zero or more characters%0a* A question mark (?) represents exactly one character%0a* A set of characters enclosed in square brackets ([]) represents any one of the characters in the brackets%0a%0aExamples:%0a(:table class='tabtable' rules=rows:)%0a(:cell:)All pages in any group beginning with "PmWiki"%0a(:cell:)[@(:pagelist group=PmWiki* :)@]%0a(:cellnr:)All pages in any group beginning with "PmWiki", except for Chinese%0a(:cell:)[@(:pagelist group=PmWiki*,-PmWikiZh :)@]%0a(:cellnr:)All pages in the PmCal group with names starting with "2005":%0a(:cell:)[@(:pagelist name=PmCal.2005* :)@]%0a(:cellnr:)All Cookbooks with names beginning with a A and a B letter%0a->note the different separators used for the same result%0a(:cell:)[@%0a(:pagelist group=Cookbook name=A*,B* :)%0a(:pagelist group=Cookbook name="A* B*" :)%0a(:pagelist group=Cookbook name=[AB]* :)%0a(:pagelist group=Cookbook, name=[AB]* :)@]%0a(:tableend:)%0a%0aIf you want to use multiples conditions in name you need to use quotes or commas to delimit the string. For example%0a-> [@key="one value,another value"@]%0a%0a!!![[#pagelisttrail]] trail= %0aThe "[@trail=@]" option obtains the list of pages to be displayed from a [[WikiTrail(s)]]:%0a* Display pages in the documentation by modification time%0a->[@(:pagelist trail=PmWiki.DocumentationIndex order=-time:)@]%0a* Display five most recently changed pages%0a->[@(:pagelist trail=RecentChanges count=5:)@]%0a%0a!!![[#pagelistlist]] list= %0a%0aThe "[@list=@]" option allows a search to include or exclude pages according to predefined patterns set by the administrator. %0a* "[@list=normal@]" is predefined, and which excludes things like AllRecentChanges, RecentChanges, GroupHeader, GroupFooter, GroupAttributes, and the like from being displayed in the list results. Note that list=normal also excludes the current page.%0a* "[@list=all@]" over-rides a "default" list that may be set by the wiki's administrator to exclude groups such as PmWiki or Site from regular search results.%0a* "[@list=grouphomes@]" only lists the home pages of every group on the wiki, either Group.Group, or Group.HomePage, or other/localized, as defined in $DefaultName, and/or $PagePathFmt.%0a%0aWiki administrators can define custom lists via the $SearchPatterns array (see [[Cookbook:SearchResults]]).%0a%0a!!![[#pagelistfmt]] fmt= %0a%0aThe "[@fmt=@]" option determines how the resulting list should be displayed. %0aPmWiki [[Site/PageListTemplates|predefines]] several formats:%0a* @@fmt=#bygroup@@ - Display pages within groups (default format)%0a* @@fmt=#simple@@ - Display a simple ordered list of pages in the form Group.Name%0a* @@fmt=#title@@ - Display a list of pages by page title. Use "[@order=title@]" to have them sorted by title (default is to order by page name).%0a* @@fmt=#titlespaced@@ - Display a list of pages by page title, like above, but with spaces between the words in the title.%0a* @@fmt=#group@@ - Display a list of wikigroups (without listing the pages in the groups)%0a* @@fmt=#include@@ - Display the contents of each page in the list (note, this could take a very long time for long lists!)%0aThese formats are defined by [[page list templates]], which can be customized.%0a%0aThis format is not predefined by a page list template:%0a* @@fmt=count@@ - Display the number of pages in the list (note the absence of the "#"). In a trail, @@fmt=count@@ counts existing and non-existing pages ; to limit count to existing pages, use : @@if="exists {=$FullName}" fmt=count@@ [-([[http://thread.gmane.org/gmane.comp.web.wiki.pmwiki.user/58621|mailing list]])-].%0a%0a%0a!!![[#pagelistlink]] link= %0a%0aThe "[@link=@]" option implements "backlinks" -- i.e., it returns a list of pages with a link to the target. It's especially useful for [[categor(ies)]]y pages and finding related pages.%0a%0a* all pages with a link to PmWiki.DocumentationIndex%0a->[@(:pagelist link=PmWiki.DocumentationIndex:)@]%0a* all pages with links to the current page%0a->[@(:pagelist link={$FullName}:)@]%0a* all pages in the "Skins" category%0a->[@(:pagelist link=Category.Skins:)@]%0a%0aNote that the @@link=@@ parameter doesn't accept multiple or negative targets and wildcard lists. For these see Cookbook:PageListMultiTargets.%0a%0aAlso, @@link=@@ will ignore the directives @@[=(:if...:), (:include...:), (:redirect...:), (:pagelist...:)=]@@, and page text variable directives, while searching for links in a page. That means links in included pages will not be found, and links inside non-displayed conditional markup will be found. See [[PageTextVariables]] for ways to hide a link on a page while still allowing @@link=@@ to find it.%0a%0a!!![[#pagelistcount]] count= %0a%0aThe "[@count=@]" option provides the ability to%0a* limit the pagelist to a specific number of pages%0a* subsets of a list%0a* return items from the end of a list, subsets of a list%0a* display pages in reverse sequence%0a%0a(:table class=tabtable rules=rows:)%0a(:cellnr:)A simple bullet list of ten most recently modified pages%0a(:cell:)%0a[@(:pagelist trail=Site.AllRecentChanges count=10 fmt=#simple:)@]%0a(:cellnr:)Display the first ten pages of a list%0a(:cell:)%0a[@count=10 # display the first ten pages of list@]%0a(:cellnr:)Negative numbers specify pages to be displayed from the end of the list:%0a(:cell:)%0a[@count=-10 # display last ten pages of list@]%0a(:cellnr:)Ranges may be specified using '..', thus:%0a(:cell:)%0a[@count=1..10 # first ten pages of list%0acount=5..10 # 5th through 10th pages of list@]%0a(:cellnr:)Negative numbers in ranges count from the end of the list:%0a(:cell:)%0a[@count=-10..-5 # 10th from end, 9th from end, ..., 5th from end@]%0a(:cellnr:)Omitting the start or end of the range uses the start or end of the list:%0a(:cell:)%0a[@count=10.. # skip first ten pages%0acount=..10 # 1st through 10th page of list%0acount=-10.. # last ten pages of list%0acount=..-10 # all but the last nine pages@]%0a(:cellnr:)Ranges can be reversed, indicating that the order of pages in the output should likewise be reversed:%0a(:cell:)%0a[@count=5..10 # 5th through 10th pages of list%0acount=10..5 # same as 5..10 but in reverse sequence%0acount=-1..1 # all pages in reverse sequence@]%0a(:cellnr:)"Reverse sequence" here refers to the sequence ''after'' any sorting has taken place. Therefore the three directives to the right are equivalent:%0a(:cell:)%0a[@(:pagelist order=-name count=10:)%0a(:pagelist order=-name count=1..10:)%0a(:pagelist order=name count=-1..-10:) @]%0a(:tableend:)%0a%0a!!![[#pagelistwrap]] wrap=%0aThe "[@wrap@]" option has the values, ''none'' and ''inline''.%0a%0aWith "wrap=inline" and "wrap=none", the output from pagelist (markup or HTML) is directly embedded in a page's markup without any surrounding %3cdiv> class=...%3c/div> tags.%0a%0aWith "wrap=inline", any surrounding %3cul> is continued. Without "wrap=inline", the HTML output starts a new %3cul>. This is important if you want to get a second level %3cul> produced by the page list since starting a new %3cul> with "**" doesn't yield a second level %3cul> but %3cdl>%3cdd>%3cul>...%0a%0a"wrap=inline" likely has other effects since it suppresses the call to $FPLTemplateMarkupFunction (being MarkupToHTML by default).%0a%0a!!![[#pagelistclass]] class=%0aBy default, a pagelist has the 'fpltemplate' class. The 'bygroup', 'simple', 'group' and 'title' page list formats have specific class names fplbygroup, fplsimple etc. You can set any class using the class= parameter or by setting the $FPLFormatOpt array.%0a%0a!!![[#pagelistrequest]] request=1%0aWith [@(:pagelist [other parameters] request=1:) @] you can override most pagelist parameters, by providing request parameters in the URL. %0aFor example, [@ (:pagelist order=name request=1:) @] will normally sort the list by name. But if the page's URL contains @@?order=time@@, the list will be sorted by time. If the URL contains @@?order=@@, the list will be unordered. Note: In the URL, encode any "#"s that are in your parameters as "%2523". Since this parameter gives users who don't have edit rights the ability to run a pagelist of their choosing, consider its security implications for your website before using it.%0a%0aSince version 2.2.71, it is possible to explicitely allow only certain parameters that can be overridden, or to disallow some parameters to be overridden. If you need this, instead of 1, enter the parameter names.%0a%0aAllow all parameters to be overridden: [@%0a(:pagelist request=1:)%0a@]%0a%0aAllow only 'order' and 'count' parameters to be overridden: [@%0a(:pagelist request=order,count:)%0a@]%0a%0aAllow all parameters to be overridden, except 'fmt' and 'trail', note the "minus" sign before each forbidden parameter: [@%0a(:pagelist request=-fmt,-trail:)%0a@]%0a%0a!!![[#pagelistreq]] req=1%0aThe @@req=1@@ parameter requires that search terms be posted (that is, that the user presses "search" on a search form, or follows a link with additional parameters like [@[[Page?q=terms&order=-name]]@]) before the pagelist is executed. Note that [@(:pagelist request=1 req=1:)@] works mostly like [@(:searchresults:)@] without the lines "''Results of search for ...''" and "''X pages found out of Y pages searched''". Both "request=1" and "req=1" are needed. %0a%0aWhen a search is performed, either via a searchbox directive, or via the search form of the skin, if the page contains a "searchresults" directive, that page will be used to display the results of the search; if the page doesn't have a "searchresults" directive, the page Site.Search will be used to display the results.%0a%0a!!![[#pagelistpasswd]] passwd=%0aThe "[@passwd@]" option returns only those pages that have some sort of password attribute on them.%0a%0a!!![[#pagelistif]] if=%0aThe "[@if@]" option allows a condition to be specified as part of the pagelist processing, rather than from within the [[page list template(s)]]. Only those pages for which the condition is true are retrieved. Anything that could [[ConditionalMarkup | go within an [@(:if ...:)@]]] can be used as a condition. For example%0a%0a [@(:pagelist if="date {(ftime %25GW%25V {*$Name})} {=$Name}" :)@]%0a%0areturns all of the pages where the name is in the same week as that of the current page.%0a%0aIf any arguments within the quotes could contain a space they must be quoted:%0a%0a [@(:pagelist if="date 2009-01-01..2009-12-31 '{=$:Mydate}'" :)@]%0a%0a!!![[#pagelistorder]] order=%0a%0aThe "[@order=@]" option allows the pages in the list to be sorted according to different criteria. Use a minus sign to indicate a reverse sort. Multiple sorting criteria can be specified using a comma, and you can create your own [[(PmWiki:)custom pagelist sort order]]:%0a* [@order=name@] - alphabetically by name (default order)%0a* [@order=$Name@] - alphabetically by name across groups%0a* [@order=title@] - alphabetically by title rather than names%0a* [@order=time@] - most recently changed pages '''last'''%0a* [@order=ctime@] - time of page creation (see note)%0a* [@order=group,title@] - by multiple criteria, in this instance sort by title within groups%0a* [@order=random@] - shuffle the pages into random sequence%0a* [@order=$:pagetextvarname@] - alphabetically by [[PageTextVariables|page text variable]] value (note no braces)%0a* [@order=$pagevarname@] - alphabetically by [[PageVariables|page variable]] value (note no braces)%0a%0aAlso, the [@order=@] option allows custom ordering functions to be written.%0a%0a* Note: trail= preserves the order of the pages as they appear on the trail (unless you've specified order= explicitly or there is a default order in the page list template). So PmWiki's alphabetical default order does not apply when trail= is specified.%0a* Note: ctime was added to pages only from pmwiki 2.1.beta15 onwards, pages created by earlier versions don't carry a ctime attribute and can't be sorted that way.%0a%0a[[#pagelistcache]]%0a!!! cache=0%0aPagelist has the capability to cache lists which greatly speeds up processing (when [[PmWiki/PagelistVariables#PageListCacheDir|$PageListCacheDir]] is set). Every once in a while this caching can result in undesired results. Specifying @@cache=0@@ disables caching.%0a%0a%0a[[#includevariable]]%0a!!!! Specifying variables as parameters%0aYou can also specify variable values inline with the pagelist statement, and refer to the variables in the template using the [@{$$variable1}@] format:%0a-> [@(:pagelist fmt=#pagelist variable1="value" variable2="value2":)@]%0a%0aThis assumes that a site has $EnableRelativePageVars enabled (default since 2.2.9).%0a%0aFor example, in the template:%0a%0a(:markup:)%0a>>comment%3c%3c%0a[[#tvars]]%0a(:template default count=1 ParamName=Simon:)%0aHi, {$$ParamName}, how are you today?%0a[[#tvarsend]]%0a>>%3c%3c%0a(:markupend:)%0a%0aThis gives:%0a%0a(:markup class=horiz:)%0a(:pagelist fmt=#tvars ParamName="Sam":)%0a%0a(:pagelist fmt=#tvars ParamName="Sally":)%0a%0a(:pagelist fmt=#tvars:)%0a(:markupend:)%0a%0a''See also $EnableUndefinedTemplateVars.'' %0a%0a!! Examples%0a%0aInclude the contents of a random page from the Banners group:%0a->[@(:pagelist group=Banners order=random count=1 fmt=#include list=normal:)@]%0a%0aDisplay a simple list of the last ten recently changed pages:%0a->[@(:pagelist trail=Site.AllRecentChanges count=10 fmt=#simple:)@]%0a%0aDisplay the "top twenty" biggest cookbook pages:%0a->[@(:pagelist group=Cookbook order=-size count=20 :)@]%0a%0a!![[#searchbox]] The Searchbox Directive%0a%0aThe [@(:searchbox:)@] directive generally accepts the same parameters as [@(:pagelist:)@] and [@(:input text:)@] directives:%0a* Pagelist parameters can be added to the input text of a searchbox (or to the markup, or both)%0a* Input text box parameters can be added to the searchbox markup%0a** An initial search string can be specified in the searchbox markup, but it must be in the form @@value='search string'@@. That search string is displayed in the input text and can be modified by when the search is run.%0a** An optional placeholder value can be specified in the form @@placeholder="Search"@@. In recent browsers, this value appears gray in the search field when it is empty. Note, this attribute is valid HTML5 but if you use it in a HTML4 skin your page will not validate.%0a** Optionally, you can add @@aria-label@@ and other @@aria-*@@ accessibility attributes that will be attached to the input text field.%0a** The size of the text input field can be specified with the size parameter, where "size=40" would specify the current default value.%0a*** Tip: If more than one searchbox appears on a page, adding a blank initial value like this @@value=''@@, to the markup for each searchbox will prevent a search string for one box from populating all of the other boxes.%0a* The target page for displaying searchbox results can be set with the parameter @@target=''GroupName.PageName''@@. The default is the current page. %0a* The entire searchbox form can be overridden by defining the $SearchBoxFmt variable in one's configuration file. If $SearchBoxFmt is defined, then the parameters to [@(:searchbox:)@] are ignored, and the content of the $SearchBoxFmt variable are used instead.%0a%0aThe additional parameter @@label="Label"@@ can be used to change the label of the associated submit button:%0a%0a [@(:searchbox label="Search this wiki":)@]%0a%0aBy default, the input field has the "text" type for compatibility with HTML/XHTML. Alternatively, you can set it to the "search" input type for HTML5, see $SearchBoxInputType (some HTML5 skins already set this).%0a%0a[[#searchresults]]%0a!! The Searchresults directive%0aThe [@(:searchresults:)@] directive generally accepts the same parameters as [@(:pagelist:)@] and [@(:input text:)@] directives.%0a%0a%0a!!! Customizing "Results of search for..." and "3 pages found out of..."%0a%0aTo change the text surrounding the search results, customize the following and add it to ''local/config.php'' or ''$FarmD/local/farmconfig.php''. Note that @@'en'@@ should be changed to the localized language.%0a%0a->[@XLSDV('en', array(%0a 'SearchFor' => 'Results of search for %3cem>$Needle%3c/em>:',%0a 'SearchFound' => %0a '$MatchCount pages found out of $MatchSearched pages searched.'%0a));@]%0a%0aAlternatively, adjust the 'SearchFor' and 'SearchFound' phrases in your [[Internationalizations|translation pages]].%0a%0aThe $SearchResultsFmt variable can also be set in ''local/config.php'' or ''$FarmD/local/farmconfig.php''.%0a%0a->[@SDV($SearchResultsFmt, "%3cdiv class='wikisearch'>\$[SearchFor]%0a %3cdiv class='vspace'>%3c/div>\$MatchList%0a %3cdiv class='vspace'>%3c/div>\$[SearchFound]%3c/div>");@]%0a%0aYou can remove the lines above and below the generated list by adding this in config.php:%0a->[@$SearchResultsFmt = '$MatchList';@]%0a%0a!! See Also%0a* [[Site.PageListTemplates]] - default pmwiki pagelist templates%0a* [[Cookbook:PagelistTemplateSamples]] - contributed pagelist template samples%0a* [[PmWiki/PageListTemplates]] - how to create custom pagelist templates for the fmt= option%0a* [[(PmWiki/)PagelistVariables]] - ''local/config.php'' customizations%0a* [[Cookbook:Forms]] - documentation for [@(:input text:)@] markup, which applies to [@(:searchbox:)@]%0a* [[(PmWiki:)CustomPagelistSortOrder]] - creating custom order sort functions%0a* [[Cookbook:CustomPagelistSortOrderFunctions]] - {Cookbook.CustomPagelistSortOrderFunctions$:Summary}%0a* [[Cookbook:PageListMultiTargets]] - {Cookbook.PageListMultiTargets$:Summary}%0a* [[Cookbook:SearchResults]] - {Cookbook.SearchResults$:Summary}%0a* [[PageDirectives#attachlist]] - display a list of attachments%0a* [[PmWiki.Search]] - {Search$:Summary}%0a%0a!! [[#FAQ]] FAQ%0a%0a[[#faq]]%0a>>faq%3c%3c%0aQ: How PmWiki opens pages with PageStore?%0aA: When PmWiki needs to open a file for reading, it will ask the PageStore, %0aobjects one after another, in the order you have defined them in config.php,%0aif they have MyGroup.MyPage. The first PageStore object that finds this page%0awill return it and if there are more PageStores they will be not bothered.%0a%0aWhen you define a PageStore object with paths like%0a[@wiki.d/{$Group}/{$FullName}@] and then ask "is there a page MyGroup.MyPage",%0athe PageStore only checks "is there a file wiki.d/MyGroup/MyGroup.MyPage" so%0ait will only look in the wiki.d/MyGroup sub-directory, not in other%0asubdirectories.%0a%0aWhen you write a page, only the first PageStore object is used, that is%0ausually $WikiDir. This way we can have documentation in wikilib.d but if you%0amodify a page from the PmWiki or Site groups on your wiki, it will be saved%0ain wiki.d and from now on only the file in wiki.d will be read and written.%0a%0aQ: What is the behavior of pagelist and searchresults when only name or word is provided?%0aA: Both pagelist and searchresults are searching for all groups unless either%0a(there is a group=ThisGroup argument in the markup or in the search field),%0aor (you have [@(:template default group=SomeGroup,{*$Group}:)@] in the pagelist%0atemplate), or (there is a @@request=1@@ argument in the markup and there is%0asomehow a @@$_REQUEST['group']@@ variable, eg from a search form or from the%0aurl), or (you set some @@$SearchPatterns['xy']@@ and @@list=xy@@), or (set a default%0a@@$MakePageListOpt['group']@@ or @@$SearchBoxOpt['group']@@).%0a%0aIf one option is not used, then this option should not be predefined. If%0athere is no needle show all pages; if @@group=@@ is not used show all groups; if%0a@@name=@@ is not used show all names; if @@link=@@ is not used show pages linking or%0anot linking to anywhere; if @@count=@@ is not used show all pages instead of a%0aportion of them. (The only exception is the @@order=@@ option which defaults to%0a@@order=name@@ because without it the results may be ordered inconsistently%0abetween page reloads, especially bad if you also use @@count=21..30@@.)%0a -time=1586673214 +rev=290 +targets=PmWiki.PageDirectives,PmWiki.PageListTemplates,PmWiki.DocumentationIndex,PmWiki.PageTextVariables,PmWiki.MarkupExpressions,PmWiki.PageVariables,PmWiki.WikiTrails,PmWiki.BasicVariables,Cookbook.SearchResults,PmWiki.PagelistVariables,Site.PageListTemplates,PmWiki.Categories,Cookbook.ReindexCategories,PmWiki.ConditionalMarkup,PmWiki.CustomPagelistSortOrder,PmWiki.PathVariables,PmWiki.Internationalizations,Cookbook.PagelistTemplateSamples,Cookbook.Forms,Cookbook.CustomPagelistSortOrderFunctions,Cookbook.PageListMultiTargets,PmWiki.PageLists,PmWiki.Search +text=(:Audience: authors, admins (intermediate) :)%0a(:Summary:Searching and listing pages by multiple criteria with templated output:)%0aPmWiki comes with two [[PageDirectives|directives]] for generating lists of pages: %25pmhlt%25[@(:pagelist:)@] and [@(:searchresults:)@]. %25%25 Both directives are basically the same and each accepts the parameters documented below. The primary difference between the two is that @@searchresult@@s generates the "@@Results of search for ...@@" and "@@### pages found out of ### searched@@" messages around the results.%0a%0aThe %25pmhlt%25[@(:searchbox:)@] directive generates a search form (input text search box) to submit search queries. The markup generally accepts the same parameters as [@(:pagelist:)@], which makes it possible to restrict, order and format @@searchresults@@ in the same ways that are described below for a [@(:pagelist:)@]. For more information about the [@(:searchbox:)@] directive, and the ways in which it differs from a [@(:pagelist:)@], skip to the section [[#searchbox|below]].%0a%0a!! Basic syntax%0a%0a* %25pmhlt%25[@(:pagelist:)@] %0a->without any arguments shows a bulleted list of all pages, as links, ordered alphabetically and in groups.%0a* @@[=(:=]pagelist [[#pagelistgroup|group]]=''ab'' \%0a [[#pagelistname|name]]=''cd'' \%0a [[#pagelistcategory|category]]=''tag'' \%0a [[#pagelistfmt|fmt]]=''[[page list templates|template]]'' \%0a [[#pagelistlist|list]]=''ef'' \%0a [[#pagelistorder|order]]=''gh'' \%0a [[#pagelistcount|count]]=''123'' \%0a [[#pagelistlink|link]]=''ij'' \%0a [[#pagelisttrail|trail]]=''kl'' \%0a [[#pagelistwrap|wrap]]=''mn'' \%0a [[#pagelistpasswd|passwd]]=''op'' \%0a [[#pagelistif|if]]=''qr'' \%0a [[#pagetextvariables|$:''ptv'']]=''st'' \%0a [[#pagevariables|$''pv'']]=''uv'' \%0a [[#pagelistcache|cache]]=0 \%0a ''[[#pagelistarg|argument]]1'' -''[[#pagelistarg|argument]]2'' ''etc'' \%0a [[#includevariable|variable]]=''value'' \%0a [[#pagelistclass|class]]=''class'' \%0a [[#pagelistrequest|request]]=''wx'' \%0a [[#pagelistreq|req]]=''1'' \%0a :)@@ %0a->shows a pagelist according to the parameters supplied. Parameters are optional.%0a* @@[=(:=][[#searchbox|searchbox]] value=''abc'' size=''99'' target=''def'' label="''label''":)@@%0a* @@[=(:=][[#searchresults|searchresults]]:)@@%0a%0a!! Parameters%0a[[#pagelistarg]]%0aAny argument supplied within %25pmhlt%25[@(:pagelist:)@] that isn't in the form @@'key=value'@@ is treated as text that either must (or must not) exist in the page text.%0a%0aThe minus sign (-) can be used to indicate things that should be excluded. Thus%0a->%25pmhlt%25[@(:pagelist trail=PmWiki.DocumentationIndex list=normal apple -pie:)@]%0alists all "normal" pages listed in the [[Documentation Index ]] trail that contain the word "apple" but not "pie".%0a%0a!!![[#pagetextvariables]]With page text variables%0aYou can also use [[page text variables]] as a ''key'' to list pages according to the existence of a page text variable. Eg : %0a->%25pmhlt%25[@(:pagelist $:pagetextvar=avalue:)@]%0alists pages having ''$:pagetextvar'' set to ''avalue''.%0a[[%3c%3c]]%0aMinus sign (-), wildcards (?*) and a comma separated list of values also works when specifying a selection based on pagetextvariables. Eg :%0a->%25pmhlt%25[@(:pagelist $:apagetextvar=t*,-test:)@]%0alists pages having @@$:apagetextvar@@ like 't*' but not 'test'.%0a[[%3c%3c]]%0aExamples:%0a||width=* class="tabtable" rules=rows%0a||PTV is set (is not empty): ||%25pmhlt%25[@(:pagelist $:MyPageTextVariable=- :)@]||%0a||PTV is empty or not set:[[%3c%3c]] (ie, is not set to one char followed by 0 or more chars) ||%25pmhlt%25[@(:pagelist $:MyPageTextVariable=-?* :)@]||%0a||PTV is not VALUE: ||%25pmhlt%25[@(:pagelist $:MyPageTextVariable=-VALUE :)@]||%0a||PTV is set and not YES: ||%25pmhlt%25[@(:pagelist $:MyPageTextVariable=?*,-YES :)@]||%0aBe aware that if using %25pmhlt%25[@(:pagelist $:MyPTV=$:YourPTV :)@] PTVs include PmWiki formatting, so you may not get the matches you expect. Currently the only way around this is to use wild cards, so if the formatting is embedded you may be out of luck.%0a%0aNOTE: Pagelist does not evaluate [[PmWiki/MarkupExpressions]] when working with PTVs. So if your [[page text variables]] is defined using a markup expression to set the value, pagelist will see the literal values of the text of your markup expression rather than the result of your expression. (e.g., the PTV definition %25pmhlt%25[@(:foo:{(substr abcdef 2 4)}:)@] will be seen by pagelist as an open-curly-brace followed by an open-paren followed by s-u-b-s-t-r, etc. rather than being seen as b-c-d-e) Any processing of the markup expression in the output of your pagelist occurs in subsequent rules (after pagelist) within the context of the current page and thus these values cannot be used for sorting or selecting pages. ([[http://thread.gmane.org/gmane.comp.web.wiki.pmwiki.user/60968/focus=60970|source]])%0a%0a!!![[#pagevariables]]With page variables (PV)%0a%0a[[Page variables]] can be used within pagelists in the same way as [[page text variables]]. See [[#pagetextvariables|Page Text Variables]] above for more details. Simply use @@$var@@ instead of @@$:var@@.%0a%0a!!![[#pagelistgroup]] group= and [[#pagelistname]]name= %0a%0aThe "%25pmhlt%25[@group=@]" and "[@name=@]" parameters limit results to pages in a specific group or with a specific name:%0a(:table class='tabtable' rules=rows:)%0a(:cellnr:)All pages in the Pmwiki group:%0a(:cell:)%25pmhlt%25[@(:pagelist group=PmWiki :)@]%0a(:cellnr:)All pages except those in the PmWiki or Site groups:%0a(:cell:)%25pmhlt%25[@(:pagelist group=-PmWiki,-Site :)@]%0a(:cellnr:)All RecentChanges pages%0a(:cell:)%25pmhlt%25[@(:pagelist name=RecentChanges :)@]%0a(:cellnr:)All pages except RecentChanges%0a(:cell:)%25pmhlt%25[@(:pagelist name=-RecentChanges :)@]%0a(:tableend:)%0a%0a!!! [[#wildcards]] Wildcards%0aName, group, link, and category parameters can contain ''wildcard'' characters that display only pages matching a given pattern:%0a* An asterisk (*) represents zero or more characters%0a* A question mark (?) represents exactly one character%0a* A set of characters enclosed in square brackets ([]) represents any one of the characters in the brackets%0a* A comma separates different specifiers, of which at least one should match.%0a* A minus sign before a specifier requires it to be absent.%0a* Only for @@link=@@ and @@category=@@, a plus sign before a specifier requires it to be present.%0a%0aExamples:%0a(:table class='tabtable' rules=rows:)%0a(:cell:)All pages in any group beginning with "PmWiki"%0a(:cell:)%25pmhlt%25[@(:pagelist group=PmWiki* :)@]%0a(:cellnr:)All pages in any group beginning with "PmWiki", except for Chinese%0a(:cell:)%25pmhlt%25[@(:pagelist group=PmWiki*,-PmWikiZh :)@]%0a(:cellnr:)All pages in the PmCal group with names starting with "2005":%0a(:cell:)%25pmhlt%25[@(:pagelist name=PmCal.2005* :)@]%0a(:cellnr:)All Cookbooks with names beginning with a A and a B letter%0a->note the different specifiers used for the same result%0a(:cell:)%25pmhlt%25[@%0a(:pagelist group=Cookbook name=A*,B* :)%0a(:pagelist name=Cookbook.A*,Cookbook.B* :)%0a(:pagelist group=Cookbook name=[AB]* :)%0a(:pagelist name=Cookbook.[AB]* :)@]%0a(:cellnr:)Pages in the categories Media ''or'' Images (at least one)%0a(:cell:)%25pmhlt%25[@%0a(:pagelist category=Media,Images :)@]%0a(:cellnr:)Pages in the categories Media ''and'' Images (both)%0a(:cell:)%25pmhlt%25[@%0a(:pagelist category=+Media,+Images :)@]%0a(:tableend:)%0a%0aIf you want to use multiples conditions you need to use commas to delimit the string. For example%0a-> %25pmhlt%25[@key="one value,another value"@]%0a%0a!!![[#pagelisttrail]] trail= %0aThe "%25pmhlt%25[@trail=@]" option obtains the list of pages to be displayed from a [[WikiTrails#creating | trail index]].%0a* Display pages in the documentation by modification time%0a->%25pmhlt%25[@(:pagelist trail=PmWiki.DocumentationIndex order=-time:)@]%0a* Display five most recently changed pages%0a->%25pmhlt%25[@(:pagelist trail=RecentChanges count=5:)@]%0a%0a!!![[#pagelistlist]] list= %0a%0aThe "%25pmhlt%25[@list=@]" option allows a search to include or exclude pages according to predefined patterns set by the administrator. %0a* "[@list=normal@]" is predefined, and which excludes things like @@AllRecentChanges@@, @@RecentChanges@@, @@GroupHeader@@, @@GroupFooter@@, @@GroupAttributes@@, and the like from being displayed in the list results. Note that list=normal also excludes the current page.%0a* "[@list=all@]" over-rides a "default" list that may be set by the wiki's administrator to exclude groups such as PmWiki or Site from regular search results.%0a* "[@list=grouphomes@]" only lists the home pages of every group on the wiki, either @@Group.Group@@, or @@Group.HomePage@@, or other/localized, as defined in @@$DefaultName@@, and/or @@$PagePathFmt@@.%0a%0aWiki administrators can define custom lists via the @@$SearchPatterns@@ array (see [[Cookbook:SearchResults]]).%0a%0a!!![[#pagelistfmt]] fmt= %0a%0aThe "[@fmt=@]" option determines how the resulting list should be displayed. %0aPmWiki [[Site/PageListTemplates|predefines]] several formats:%0a* @@fmt=#bygroup@@ - Display pages within groups (default format)%0a* @@fmt=#simple@@ - Display a simple ordered list of pages in the form Group.Name%0a* @@fmt=#title@@ - Display a list of pages by page title. Use "[@order=title@]" to have them sorted by title (default is to order by page name).%0a* @@fmt=#titlespaced@@ - Display a list of pages by page title, like above, but with spaces between the words in the title.%0a* @@fmt=#group@@ - Display a list of wikigroups (without listing the pages in the groups)%0a* @@fmt=#include@@ - Display the contents of each page in the list (note, this could take a very long time for long lists!)%0a* @@fmt=#grouphomes@@ - An optimized bullet list of group home pages (will work with count=...), requires PmWiki 2.2.103. %0a* @@fmt=#includefaq@@ - Include just the @@#faq@@ sections from pages in the list. (This can also be expensive, especially if the list includes pages that don't have the [@[[#faq]]@] anchor!) %0a* @@fmt=#description@@ - List pages and append the page's description if it exists. Creates dash by all names, but adding a nested loop to get rid of it causes markup problems (nested loops are not allowed). %0a* @@fmt=#simplename@@ - Simple bullet list of page names, without the Group name. %0a* @@fmt=#simplenamespaced@@ - Simple bullet list of spaced page names, without the Group name. %0a* @@fmt=#titlesummary@@ - A simple bullet list of page title and summary, defined in page by %25pmhlt%25[@(:Title ttttt:)@] and [@(@][@:Summary:sssss:)@] markup.%0aThese formats are defined by [[page list templates]], which can be customized.%0a%0aThis format is not predefined by a page list template:%0a* @@fmt=count@@ - Display the number of pages in the list (note the absence of the "#"). In a trail, @@fmt=count@@ counts existing and non-existing pages ; to limit count to existing pages, use : %25pmhlt%25[@if="exists {=$FullName}" fmt=count@] [-([[http://thread.gmane.org/gmane.comp.web.wiki.pmwiki.user/58621|mailing list]])-].%0a%0a%0a!!![[#pagelistlink]] link= and [[#pagelistcategory]] category= %0a%0aThe "[@link=@]" and "[@category=@]" arguments implement "backlinks" -- i.e., it returns a list of pages with a link to the target, or declared in the category. It's especially useful for [[categor(ies)]]y pages and finding related pages.%0a%0aThe @@category=Name@@ argument differs from @@link=Category.Name@@ as it only lists pages declared in the category with the markup %25pmhlt%25[@[[!Name]]@], and does not include pages simply linking to [@[[Category/Name]]@] (unless they also contain [@[[!Name]]@]).%0a%0a* all pages with a link to PmWiki.DocumentationIndex%0a->%25pmhlt%25[@(:pagelist link=PmWiki.DocumentationIndex:)@]%0a* all pages with links to the current page%0a->%25pmhlt%25[@(:pagelist link={$FullName}:)@]%0a* all pages in the "Skins" category%0a->%25pmhlt%25[@(:pagelist category=Skins:)@]%0a%0aSince PmWiki 2.3.0, @@link=@@ and @@category=@@ accept multiple and negative targets and wildcard lists, see the section [[#wildcards|Wildcards]].%0a%0aNote, @@link=@@ and @@category=@@ will ignore the directives %25pmhlt%25[@(:if...:)@], [@(:include...:)@], [@(:redirect...:)@], [@(:pagelist...:)@], and page text variable directives, while searching for links in a page. That means links in included pages will not be found, and links inside non-displayed conditional markup will be found. See [[PageTextVariables]] for ways to hide a link on a page while still allowing @@link=@@ to find it.%0a%0aNote: The new @@category=@@ argument requires all pages containing %25pmhlt%25[@[[!Category]]@] links to be reindexed. See the recipe Cookbook:ReindexCategories which can automate this.%0a%0a!!![[#pagelistcount]] count= %0a%0aThe "%25pmhlt%25[@count=@]" option provides the ability to%0a* limit the pagelist to a specific number of pages%0a* subsets of a list%0a* return items from the end of a list, subsets of a list%0a* display pages in reverse sequence%0a%0a(:table class=tabtable rules=rows:)%0a(:cellnr:)A simple bullet list of ten most recently modified pages%0a(:cell:)%0a%25pmhlt%25[@(:pagelist trail=Site.AllRecentChanges count=10 fmt=#simple:)@]%0a(:cellnr:)Display the first ten pages of a list%0a(:cell:)%0a[@count=10 # display the first ten pages of list@]%0a(:cellnr:)Negative numbers specify pages to be displayed from the end of the list:%0a(:cell:)%0a[@count=-10 # display last ten pages of list@]%0a(:cellnr:)Ranges may be specified using '..', thus:%0a(:cell:)%0a[@count=1..10 # first ten pages of list%0acount=5..10 # 5th through 10th pages of list@]%0a(:cellnr:)Negative numbers in ranges count from the end of the list:%0a(:cell:)%0a[@count=-10..-5 # 10th from end, 9th from end, ..., 5th from end@]%0a(:cellnr:)Omitting the start or end of the range uses the start or end of the list:%0a(:cell:)%0a[@count=10.. # skip first ten pages%0acount=..10 # 1st through 10th page of list%0acount=-10.. # last ten pages of list%0acount=..-10 # all but the last nine pages@]%0a(:cellnr:)Ranges can be reversed, indicating that the order of pages in the output should likewise be reversed:%0a(:cell:)%0a[@count=5..10 # 5th through 10th pages of list%0acount=10..5 # same as 5..10 but in reverse sequence%0acount=-1..1 # all pages in reverse sequence@]%0a(:cellnr:)"Reverse sequence" here refers to the sequence ''after'' any sorting has taken place. Therefore the three directives to the right are equivalent:%0a(:cell:)%0a%25pmhlt%25[@(:pagelist order=-name count=10:)%0a(:pagelist order=-name count=1..10:)%0a(:pagelist order=name count=-1..-10:) @]%0a(:tableend:)%0a%0a!!![[#pagelistwrap]] wrap=%0aThe "[@wrap@]" option has the values, ''none'' and ''inline''.%0a%0aWith "wrap=inline" and "wrap=none", the output from pagelist (markup or HTML) is directly embedded in a page's markup without any surrounding %25hlt html%25[@%3cdiv> class=...%3c/div>@] tags.%0a%0aWith "wrap=inline", any surrounding %25hlt html%25[@%3cul>@] is continued. Without "wrap=inline", the HTML output starts a new [@%3cul>@]. This is important if you want to get a second level [@%3cul>@] produced by the page list since starting a new [@%3cul>@] with "**" doesn't yield a second level [@%3cul>@] but [@%3cdl>%3cdd>%3cul>...@]%0a%0a"wrap=inline" likely has other effects since it suppresses the call to @@$FPLTemplateMarkupFunction@@ (being MarkupToHTML by default).%0a%0a!!![[#pagelistclass]] class=%0aBy default, a pagelist has the 'fpltemplate' class. The 'bygroup', 'simple', 'group' and 'title' page list formats have specific class names fplbygroup, fplsimple etc. You can set any class using the @@class=@@ parameter or by setting the @@$FPLFormatOpt@@ array.%0a%0a!!![[#pagelistrequest]] request=%0aWith %25pmhlt%25[@(:pagelist [other parameters] request=1:) @] you can override most pagelist parameters, by providing request parameters in the URL. %0aFor example, %25pmhlt%25[@ (:pagelist order=name request=1:) @] will normally sort the list by name. But if the page's URL contains @@?order=time@@, the list will be sorted by time. If the URL contains @@?order=@@, the list will be unordered. Note: In the URL, encode any "#"s that are in your parameters as "%2523". Since this parameter gives users who don't have edit rights the ability to run a pagelist of their choosing, consider its security implications for your website before using it.%0a%0aSince version 2.2.71, it is possible to explicitly allow only certain parameters that can be overridden, or to disallow some parameters to be overridden. If you need this, instead of 1, enter the parameter names.%0a%0aAllow all parameters to be overridden: %25pmhlt%25[@%0a(:pagelist request=1:)%0a@]%0a%0aAllow only 'order' and 'count' parameters to be overridden: %25pmhlt%25[@%0a(:pagelist request=order,count:)%0a@]%0a%0aAllow all parameters to be overridden, except 'fmt' and 'trail', note the "minus" sign before each forbidden parameter: %25pmhlt%25[@%0a(:pagelist request=-fmt,-trail:)%0a@]%0a%0a!!![[#pagelistreq]] req=1%0aThe @@req=1@@ parameter requires that search terms be posted (that is, that the user presses "search" on a search form, or follows a link with additional parameters like [@[[Page?q=terms&order=-name]]@]) before the pagelist is executed. Note that %25pmhlt%25[@(:pagelist request=1 req=1:)@] works mostly like [@(:searchresults:)@] without the lines "''Results of search for ...''" and "''X pages found out of Y pages searched''". Both "request=1" and "req=1" are needed. %0a%0aWhen a search is performed, either via a @@searchbox@@ directive, or via the search form of the skin, if the page contains a "@@searchresults@@" directive, that page will be used to display the results of the search; if the page doesn't have a "@@searchresults@@" directive, the page @@Site.Search@@ will be used to display the results.%0a%0a!!![[#pagelistpasswd]] passwd=%0aThe "[@passwd@]" option returns only those pages that have some sort of password attribute on them.%0a%0a!!![[#pagelistif]] if=%0aThe "[@if@]" option allows a condition to be specified as part of the pagelist processing, rather than from within the [[page list template(s)]]. Only those pages for which the condition is true are retrieved. Anything that could [[ConditionalMarkup | go within an %25pmhlt%25[@(:if ...:)@]]] can be used as a condition. For example%0a%0a %25pmhlt%25[@(:pagelist if="date {(ftime %25GW%25V {*$Name})} {=$Name}" :)@]%0a%0areturns all of the pages where the name is in the same week as that of the current page.%0a%0aIf any arguments within the quotes could contain a space they must be quoted:%0a%0a %25pmhlt%25[@(:pagelist if="date 2009-01-01..2009-12-31 '{=$:Mydate}'" :)@]%0a%0a!!![[#pagelistorder]] order=%0a%0aThe "[@order=@]" option allows the pages in the list to be sorted according to different criteria. Use a minus sign to indicate a reverse sort. Multiple sorting criteria can be specified using a comma, and you can create your own [[(PmWiki:)custom pagelist sort order]]:%0a* [@order=name@] - alphabetically by name (default order)%0a* [@order=$Name@] - alphabetically by name across groups%0a* [@order=title@] - alphabetically by title rather than names%0a* [@order=time@] - most recently changed pages '''last'''%0a* [@order=ctime@] - time of page creation (see note)%0a* [@order=group,title@] - by multiple criteria, in this instance sort by title within groups%0a* [@order=random@] - shuffle the pages into random sequence%0a* [@order=$:pagetextvarname@] - alphabetically by [[PageTextVariables|page text variable]] value (note no braces)%0a* [@order=$pagevarname@] - alphabetically by [[PageVariables|page variable]] value (note no braces)%0a%0aAlso, the [@order=@] option allows custom ordering functions to be written.%0a%0a* Note: trail= preserves the order of the pages as they appear on the trail (unless you've specified order= explicitly or there is a default order in the page list template). So PmWiki's alphabetical default order does not apply when trail= is specified.%0a* Note: ctime was added to pages only from pmwiki 2.1.beta15 onwards, pages created by earlier versions don't carry a ctime attribute and can't be sorted that way.%0a%0a[[#pagelistcache]]%0a!!! cache=0%0aPagelist has the capability to cache lists which greatly speeds up processing (when [[PmWiki/PagelistVariables#PageListCacheDir|@@$PageListCacheDir@@]] is set). Every once in a while this caching can result in undesired results. Specifying @@cache=0@@ disables caching.%0a%0a%0a[[#includevariable]]%0a!!!! Specifying variables as parameters%0aYou can also specify variable values inline with the pagelist statement, and refer to the variables in the template using the %25pmhlt%25[@{$$variable1}@] format:%0a-> %25pmhlt%25[@(:pagelist fmt=#pagelist variable1="value" variable2="value2":)@]%0a%0aThis assumes that a site has @@$EnableRelativePageVars@@ enabled (default since 2.2.9).%0a%0aFor example, in the template:%0a%0a(:markup:)%0a>>comment%3c%3c%0a[[#tvars]]%0a(:template default count=1 ParamName=Simon:)%0aHi, {$$ParamName}, how are you today?%0a[[#tvarsend]]%0a>>%3c%3c%0a(:markupend:)%0a%0aThis gives:%0a%0a(:markup class=horiz:)%0a(:pagelist fmt=#tvars ParamName="Sam":)%0a%0a(:pagelist fmt=#tvars ParamName="Sally":)%0a%0a(:pagelist fmt=#tvars:)%0a(:markupend:)%0a%0a''See also @@$EnableUndefinedTemplateVars@@.'' %0a%0a!! Examples%0a%0aInclude the contents of a random page from the Banners group:%0a->%25pmhlt%25[@(:pagelist group=Banners order=random count=1 fmt=#include list=normal:)@]%0a%0aDisplay a simple list of the last ten recently changed pages:%0a->%25pmhlt%25[@(:pagelist trail=Site.AllRecentChanges count=10 fmt=#simple:)@]%0a%0a!![[#searchbox]] The Searchbox Directive%0a%0aThe %25pmhlt%25[@(:searchbox:)@] directive generally accepts the same parameters as [@(:pagelist:)@] and [@(:input search:)@] directives:%0a* Pagelist parameters can be added to the input text of a searchbox (or to the markup, or both)%0a* Input text box parameters can be added to the searchbox markup%0a** An initial search string can be specified in the searchbox markup, but it must be in the form @@value='search string'@@. That search string is displayed in the input text and can be modified by when the search is run.%0a** The default placeholder value is "Search" (localized in other languages), and can be modified in the form @@placeholder="Type search terms..."@@ or removed with @@placeholder=""@@. In recent browsers, this value appears gray in the search field when it is empty.%0a** Optionally, you can add @@aria-label@@ and other @@aria-*@@ accessibility attributes that will be attached to the input text field.%0a** The size of the text input field can be specified with the size parameter, where "size=40" would specify the current default value.%0a*** Tip: If more than one searchbox appears on a page, adding a blank initial value like this @@value=''@@, to the markup for each searchbox will prevent a search string for one box from populating all of the other boxes.%0a* The target page for displaying searchbox results can be set with the parameter @@target=''GroupName.PageName''@@. The default is the current page. %0a* The entire searchbox form can be overridden by defining the $SearchBoxFmt variable in one's configuration file. If $SearchBoxFmt is defined, then the parameters to %25pmhlt%25[@(:searchbox:)@] are ignored, and the content of the $SearchBoxFmt variable are used instead.%0a%0aThe additional parameter @@label="Label"@@ can be used to change the label of the associated submit button:%0a%0a %25pmhlt%25[@(:searchbox label="Search this wiki":)@]%0a%0aUse @@label=""@@ to remove the submit button (users need to press "Enter" to search).%0a%0aBy default, the input field has the "text" type for compatibility with HTML/XHTML. Alternatively, you can set it to the "search" input type for HTML5, see @@$SearchBoxInputType@@ (some HTML5 skins already set this).%0a%0a[[#searchresults]]%0a!! The Searchresults directive%0aThe %25pmhlt%25[@(:searchresults:)@] directive generally accepts the same parameters as [@(:pagelist:)@] and [@(:input search:)@] directives.%0a%0a%0a!!! Customizing "Results of search for..." and "3 pages found out of..."%0a%0aTo change the text surrounding the search results, customize the following and add it to ''@@local/config.php@@'' or ''@@$FarmD/local/farmconfig.php@@''. Note that @@'en'@@ should be changed to the localized language.%0a%0a->%25hlt php%25[@XLSDV('en', array(%0a 'SearchFor' => 'Results of search for %3cem>$Needle%3c/em>:',%0a 'SearchFound' => %0a '$MatchCount pages found out of $MatchSearched pages searched.'%0a));@]%0a%0aAlternatively, adjust the 'SearchFor' and 'SearchFound' phrases in your [[Internationalizations|translation pages]].%0a%0aThe @@$SearchResultsFmt@@ variable can also be set in ''@@local/config.php@@'' or ''@@$FarmD/local/farmconfig.php@@''.%0a%0a->%25hlt php%25[@SDV($SearchResultsFmt, "%3cdiv class='wikisearch'>\$[SearchFor]%0a %3cdiv class='vspace'>%3c/div>\$MatchList%0a %3cdiv class='vspace'>%3c/div>\$[SearchFound]%3c/div>");@]%0a%0aYou can remove the lines above and below the generated list by adding this in config.php:%0a->%25hlt php%25[@$SearchResultsFmt = '$MatchList';@]%0a%0a!! See Also%0a* [[Site.PageListTemplates]] - default pmwiki pagelist templates%0a* [[Cookbook:PagelistTemplateSamples]] - contributed pagelist template samples%0a* [[PmWiki/PageListTemplates]] - how to create custom pagelist templates for the fmt= option%0a* [[(PmWiki/)PagelistVariables]] - ''local/config.php'' customizations%0a* [[Cookbook:Forms]] - documentation for [@(:input text:)@] markup, which applies to [@(:searchbox:)@]%0a* [[(PmWiki:)CustomPagelistSortOrder]] - creating custom order sort functions%0a* [[Cookbook:CustomPagelistSortOrderFunctions]] - {Cookbook.CustomPagelistSortOrderFunctions$:Summary}%0a* [[Cookbook:PageListMultiTargets]] - {Cookbook.PageListMultiTargets$:Summary}%0a* [[Cookbook:SearchResults]] - {Cookbook.SearchResults$:Summary}%0a* [[PageDirectives#attachlist]] - display a list of attachments%0a* [[PmWiki.Search]] - {Search$:Summary}%0a%0a!! [[#FAQ]] FAQ%0a%0a[[#faq]]%0a>>faq%3c%3c%0aQ: How PmWiki opens pages with PageStore?%0aA: When PmWiki needs to open a file for reading, it will ask the PageStore, %0aobjects one after another, in the order you have defined them in config.php,%0aif they have @@MyGroup.MyPage@@. The first PageStore object that finds this page%0awill return it and if there are more PageStores they will be not bothered.%0a%0aWhen you define a PageStore object with paths like%0a[@wiki.d/{$Group}/{$FullName}@] and then ask "is there a page @@MyGroup.MyPage@@",%0athe PageStore only checks "is there a file @@wiki.d/MyGroup/MyGroup.MyPage@@" so%0ait will only look in the @@wiki.d/MyGroup sub-directory@@, not in other%0asubdirectories.%0a%0aWhen you write a page, only the first PageStore object is used, that is%0ausually $WikiDir. This way we can have documentation in wikilib.d but if you%0amodify a page from the PmWiki or Site groups on your wiki, it will be saved%0ain wiki.d and from now on only the file in wiki.d will be read and written.%0a%0aQ: What is the behavior of pagelist and searchresults when only name or word is provided?%0aA: Both pagelist and searchresults are searching for all groups unless either%0a(there is a group=ThisGroup argument in the markup or in the search field),%0aor (you have %25pmhlt%25[@(:template default group=SomeGroup,{*$Group}:)@] in the pagelist%0atemplate), or (there is a @@request=1@@ argument in the markup and there is%0asomehow a @@$_REQUEST['group']@@ variable, eg from a search form or from the%0aurl), or (you set some @@$SearchPatterns['xy']@@ and @@list=xy@@), or (set a default%0a@@$MakePageListOpt['group']@@ or @@$SearchBoxOpt['group']@@).%0a%0aIf one option is not used, then this option should not be predefined. If%0athere is no needle show all pages; if @@group=@@ is not used show all groups; if%0a@@name=@@ is not used show all names; if @@link=@@ is not used show pages linking or%0anot linking to anywhere; if @@count=@@ is not used show all pages instead of a%0aportion of them. (The only exception is the @@order=@@ option which defaults to%0a@@order=name@@ because without it the results may be ordered inconsistently%0abetween page reloads, especially bad if you also use @@count=21..30@@.)%0a%0aQ: How can a custom function retrieve the results of a pagelist as an array?%0aA: See [[https://www.pmichaud.com/pipermail/pmwiki-users/2022-November/064946.html|this thread on the mailing list]].%0a%0a +time=1670907949 blob - c0e7ee5ea9936f4fcefe0bfd73fd14ebad7a59b7 blob + f417a50d16895867ae5d77b71b95fbf9137700d9 --- wikilib.d/PmWiki.PageTextVariables +++ wikilib.d/PmWiki.PageTextVariables @@ -1,10 +1,10 @@ -version=pmwiki-2.2.120 ordered=1 urlencoded=1 -author=Petko +version=pmwiki-2.3.4 ordered=1 urlencoded=1 +author=simon charset=UTF-8 -csum=Add $DefaultUnsetPageTextVars, $DefaultEmptyPageTextVars. +csum=pm hlt, hlt php (+9) ctime=1159470179 name=PmWiki.PageTextVariables -rev=156 -targets=PmWiki.Name,PmWiki.FullName,Cookbook.InternationalPTVs,PmWiki.PageTextVariables-Talk,PmWiki.TextFormattingRules,PmWiki.PageDirectives,PmWiki.PageVariables,PmWiki.PageListTemplates,PmWiki.IncludeOtherPages,PmWiki.PageLists,Site.PageListTemplates,Site.LocalTemplates,PmWiki.ConditionalMarkup,PmWiki.BasicVariables -text=(:Summary:Page variables automatically made available through natural or explicit page markup:)%0a(:if false:)%0a[[#singleline]]%0a[-[[{=$FullName}|+]],-] \%0a[[#singlelineend]]%0a(:ifend:)%0a%0aPage text variables are string variables created in the wiki text of a page, and can be automatically made available for inclusion in other pages. In the default installation, PageTextVariables can only have a name containing basic Latin/Roman (ASCII) letters, digits, dash and underscore. This is a limitation for international wikis (experimental recipe for international PTV : Cookbook:InternationalPTVs). %0a%0a[[#defining]]%0a!! Defining Page Text Variables%0a%0aThere are three ways to define automated Page Text Variables ([[PmWiki:PageTextVariables-Talk#new_patterns|more patterns]] can be defined if needed) :%0a%0a* use a [[TextFormattingRules#DefinitionLists | definition list]] - the normal pmwiki markup for a definition list will create a page text variable%0a(:markup caption='Example definition list:' class="horiz":)%0a:Name: Crisses%0a"{$:Name}"%0a(:markupend:)%0a->This creates a new variable that can be accessed by [@{$:Name}@] (becomes: "{$:Name}") in the page.%0a%0a* use a simple colon delimiter in normal text%0a(:markup caption='Example colon delimited:' class="horiz":)%0aAddress: 1313 Mockingbird Lane%0a%0a"{$:Address}"%0a(:markupend:)%0a->This creates the [@{$:Address}@] variable (variable markup becomes: "{$:Address}") in the page.%0a%0a* hidden [[PmWiki/PageDirectives | directive]] form - PmWiki markup that doesn't render on the page, but defines the variable%0a(:markup caption='Example directive:' class="horiz":)%0a(:Country: Transylvania :)%0a"{$:Country}"%0a(:markupend:)%0a->This creates the [@{$:Country}@] variable (variable markup becomes: "{$:Country}") in the page.%0a%0a[[#default]]%0a!! Default values for unset or empty Page Text Variables%0a%0aIf a page text variable is not [[#defining|defined in a page]], or if the current visitor doesn't have read permissions for the page containing the variable definition, then the markup to access the variable like [@{$:Country}@] will return an empty string.%0a%0aAn administrator can define default values for such cases (PmWiki 2.2.121+). The following arrays can be defined in local/config.php:%0a%0a $DefaultUnsetPageTextVars = array(%0a 'SpecificVariable' => 'SpecificVariable is unset',%0a '*PartialMatch*' => 'some value',%0a '*' => '(unset)',%0a );%0a %0a $DefaultEmptyPageTextVars = array(%0a 'SpecificVariable' => 'SpecificVariable is set, but empty',%0a '*' => '(empty)',%0a );%0a%0aIn the above examples, [@{$:SpecificVariable}@] or [@{OtherPage$:SpecificVariable}@] will output the value defined:%0a* in $DefaultUnsetPageTextVars if the variable is not defined in the page text, or if the user doesn't have read permissions for OtherPage%0a* in $DefaultEmptyPageTextVars if the user has read permissions, and the variable is defined but empty, for example [@(:SpecificVariable::)@].%0a%0aThe patterns are processed in order, and the first matching pattern assigns the value to the variable. The asterisk [@*@] matches any string, in the above examples an undefined variable that doesn't match 'SpecificVariable' or '*PartialMatch*' will output '(unset)'.%0a%0a%0a[[#usage]]%0a!! Usage%0a[[#usagesamepage]]%0a!!! Usage on the same page%0a%0aOn the same page you can resolve page text variables through the [@{$:Var}@] format (shown above).%0a%0a[[#specialreferences]]%0a!!! Usage in headers and footers: special references%0a%0aIf you want a GroupHeader, GroupFooter, SideBar, etc to call on page text variable in the main page, you need to include special reference information. %0aTo explicitly reference the page text variable from the page being displayed add an asterisk to the page text variable's markup: [@{*$:Address}@] on the GroupFooter or GroupHeader page. %0a(:markup caption='Example' class=horiz:)%0a{*$:Mountain} \\%0a{*$Namespaced}%0a(:markupend:)%0aTo include a page text variable ''from'' a header or footer see [[#usageotherpage |usage from other pages]] below.%0a-%3c Special references also apply to [[page variables(#specialreferences)]] and [[page list templates(#specialreferences)]].%0a%0a%0a[[#usageotherpage]]%0a!!! Usage from other pages%0a%0aIf you want to pull the data from another page, use the [@{Group/PageName$:Var}@] format.%0a(:markup caption='Example:' class="horiz":)%0aSuburb: Khandallah%0a(:Lake:Taupo:)%0a:Mountain:Mt Ruapehu%0a%0a->"{PmWiki/PageTextVariables$:Suburb}"%0a->"{{$FullName}$:Lake}"%0a->"{PmWiki/PageTextVariables$:Mountain}"%0a(:markupend:)%0a%0a[[#usageincludedpage]]%0a!!! Usage from included pages%0a%0aPage text variables are never [[IncludeOtherPages|included]] from their source page.%0aSee [[#usageotherpage|Usage from other pages]] above to refer to a page text variable on another page.%0a%0a[[#pagelists]]%0a!!! Usage with pagelists%0a%0a[[Page lists]] can also access the page text variables:%0a(:markup caption='Example:' class="horiz":)%0a(:pagelist group=PmWiki order=$:Summary count=6 fmt=#singleline:)%0a(:markupend:)%0a%0aAnd to create pagelist formats (such as those documented at [[Site.Page List Templates]], [[PmWiki/Page Lists]], [[PmWiki/Page List Templates]], [[PmWiki/Page Variables]]. Store custom pagelists at [[Site.Local Templates]]).%0a%0a[[Page lists]] can also use page text variables to select pages :%0a(:markup caption='Example:' class="horiz":)%0a(:pagelist group=PmWiki $:City=Paris count=8 fmt=#singleline order=-name:)%0a(:markupend:)%0a->lists pages having '$:City' set to 'Paris'.%0a%0a(:markup caption='Example: multiple selections with spaces' class="horiz":)%0a(:pagelist group=PmWiki $:City="Addis Ababa,Paris" order=-$:Version count=8 fmt=#singleline:)%0a(:markupend:)%0a->'quotes' must surround ''all'' the selections.%0a%0a* When using page text variables for selection or ordering, don't put the curly braces around the variable name. The curly forms do a replacement before the pagelist command is evaluated. %0a* Link markup within the contents of a hidden page text variable directive (as opposed to other ways of specifying PTVs) will not be cached as a link on the page and thus won't be seen by pagelist's link= option. If you want the link to be found by link=, you need to specify the PTV using non-directive markup, or else put the link on the page even if it's hidden within a false conditional: [@(:Linkme: [[PageToLink]]:) (:if false:){$:Linkme}(:ifend:)@]%0a%0aThe page text variable value is always the text that is written in the page. %0aIt is only evaluated when the variable is printed/output to HTML. %0aTo sort by a page text variable variable, all values in all pages are the not-yet-evaluated text strings, and the pagelist order function does what it can with them. It does not process/evaluate the text at this point.%0a%0aE.g. With a page name in to format "yyyyMonth" it is simpler to use a @@PageVariable@@ calculated in @@config.php@@, not a @@PageTextVariable@@:%0a-> [@ $FmtPV['$NameToYearMonth'] = 'strftime("%25Y%25m", strtotime($name))';@]%0aThen use [@(:pagelist order=$NameToYearMonth:)@]%0a%0aAn alternative is writing in the wiki page:%0a-> [@(:MonthNum:07:)@]%0aas the markup expression that follows won't work:%0a-> [@(:MonthNum:{(ftime fmt=%25m when="{$Namespaced}")}:)@]%0a%0a[[#set]]%0a!!!! Testing if set or not set within a pagelist%0a|| border=0 cellpadding=4 rules=all%0a|| '''=-''' ||PTV is set (is not empty), eg [@(:pagelist $:Var=- :)@] ||%0a|| '''=-?*''' ||PTV is not set (is empty), ie not one character followed by 0 or more characters, eg. [@(:pagelist $:Var=-?* :) @] ||%0a|| '''=*''' ||display ''all'' pages, regardless of the page text variable (slow) ||%0a|| '''=-*''' ||display ''no'' pages, regardless of the page text variable (slow) ||%0a%0a%0a[-Tip : [@(:if ! equal "{$:PTV}" "":)@] will test if PTV is empty/unset or not.-]%0a%0a%0a(:markup caption='Example: Pages without a summary' class="horiz":)%0a(:pagelist group=PmWiki $:Summary=-?* count=6 fmt=#singleline:)%0a(:markupend:)%0a%0a[[#templates]]%0a!!! Use page text variable in a template%0aDisplay pages by Audience page text variable.%0a(:markup caption='Example:' class="horiz":)%0a>>comment%3c%3c%0a[[#byaudience]]%0a(:if ! equal '{=$:Audience}' '{%3c$:Audience}':)%0a-%3c'''{=$:Audience}''': %0a(:ifend:)%0a[[{=$Name}]]%0a[[#byaudienceend]]%0a>>%3c%3c%0a(:pagelist group=PmWiki count=10 fmt=#byaudience order=-$:Audience:)%0a(:markupend:)%0a%0a[[#conditionals]]%0a!!! Use page text variables in [[PmWiki/conditional markup]]%0aPage text variables will be assigned/evaluated '''before''' any conditional markup is evaluated. This effectively means that you cannot declare a PTV within an if...else condition; and also that a PTV will have a value even if it is set within a [@(:if false:)....(:if:)@] condition.%0a%0a[[#withincode]]%0a!!! Usage - from within code (developers only)%0a%0aThe standard @@PageVar($pagename,$varname)@@ function can return page text variables, but remember to include the dollar and colon like this:%0a%0a->@@$var=PageVar($pagename,'$:City')@@%0a%0aIt works by caching all page (text) variables it finds in a page (in @@$PCache@@) and returns the one requested. -time=1572426811 +rev=160 +targets=PmWiki.Name,PmWiki.FullName,Cookbook.InternationalPTVs,PmWiki.PageTextVariables-Talk,PmWiki.TextFormattingRules,PmWiki.PageDirectives,PmWiki.OtherVariables,PmWiki.PageVariables,PmWiki.PageListTemplates,PmWiki.IncludeOtherPages,PmWiki.PageLists,Site.PageListTemplates,Site.LocalTemplates,PmWiki.Functions,PmWiki.ConditionalMarkup +text=(:Summary:Page variables automatically made available through natural or explicit page markup:)%0a(:if false:)%0a[[#singleline]]%0a[-[[{=$FullName}|+]],-] \%0a[[#singlelineend]]%0a(:ifend:)%0a%0aPage text variables are string variables created in the wiki text of a page, and can be automatically made available for inclusion in other pages.\\%0aIn the default installation, PageTextVariables can only have a name containing basic Latin/Roman (ASCII) letters, digits, dash and underscore (meaning regular PTVs don't have accented characters). This is a limitation for international wikis (experimental recipe for international PTV : Cookbook:InternationalPTVs). %0a%0a[[#defining]]%0a!! Defining Page Text Variables%0a%0aThere are three ways to define automated Page Text Variables ([[PmWiki:PageTextVariables-Talk#new_patterns|more patterns]] can be defined if needed) :%0a%0a* use a [[TextFormattingRules#DefinitionLists | definition list]] - the normal pmwiki markup for a definition list will create a page text variable%0a(:markup caption='Example definition list:' class="horiz":)%0a:Name: Crisses%0a"{$:Name}"%0a(:markupend:)%0a->This creates a new variable that can be accessed by %25pmhlt%25[@{$:Name}@] (becomes: "{$:Name}") in the page.%0a%0a* use a simple colon delimiter in normal text%0a(:markup caption='Example colon delimited:' class="horiz":)%0aAddress: 1313 Mockingbird Lane%0a%0a"{$:Address}"%0a(:markupend:)%0a->This creates the %25pmhlt%25[@{$:Address}@] variable (variable markup becomes: "{$:Address}") in the page.%0a%0a* hidden [[PmWiki/PageDirectives | directive]] form - PmWiki markup that doesn't render on the page, but defines the variable%0a(:markup caption='Example directive:' class="horiz":)%0a(:Country: Transylvania :)%0a"{$:Country}"%0a(:markupend:)%0a->This creates the %25pmhlt%25[@{$:Country}@] variable (variable markup becomes: "{$:Country}") in the page.%0a%0a[[#default]]%0a!! Default values for unset or empty Page Text Variables%0a%0aIf a page text variable is not [[#defining|defined in a page]], or if the current visitor doesn't have read permissions for the page containing the variable definition, then the markup to access the variable like %25pmhlt%25[@{$:Country}@] will return an empty string.%0a%0aAn administrator can define default values for such cases (PmWiki 2.2.121+). The following arrays can be defined in @@local/config.php@@:%0a%0a%25hlt php%25[@ $DefaultUnsetPageTextVars = array(%0a 'SpecificVariable' => 'SpecificVariable is unset',%0a '*PartialMatch*' => 'some value',%0a '*' => '(unset)',%0a );@]%0a %0a%25hlt php%25[@ $DefaultEmptyPageTextVars = array(%0a 'SpecificVariable' => 'SpecificVariable is set, but empty',%0a '*' => '(empty)',%0a );@]%0a%0aIn the above examples, %25pmhlt%25[@{$:SpecificVariable}@] or [@{OtherPage$:SpecificVariable}@] will output the value defined:%0a* in $DefaultUnsetPageTextVars if the variable is not defined in the page text, or if the user doesn't have read permissions for OtherPage%0a* in $DefaultEmptyPageTextVars if the user has read permissions, and the variable is defined but empty, for example %25pmhlt%25[@(:SpecificVariable::)@].%0a%0aThe patterns are processed in order, and the first matching pattern assigns the value to the variable. The asterisk %25pmhlt%25[@*@] matches any string, in the above examples an undefined variable that doesn't match 'SpecificVariable' or '*PartialMatch*' will output '(unset)'.%0a%0a%0a[[#usage]]%0a!! Usage%0a[[#usagesamepage]]%0a!!! Usage on the same page%0a%0aOn the same page you can resolve page text variables through the %25pmhlt%25[@{$:Var}@] format (shown above).%0a%0a[[#specialreferences]]%0a!!! Usage in headers and footers: special references%0a%0aIf you want a GroupHeader, GroupFooter, SideBar, etc to call on page text variable in the main page, you need to include special reference information. %0aTo explicitly reference the page text variable from the page being displayed add an asterisk to the page text variable's markup: %25pmhlt%25[@{*$:Address}@] on the GroupFooter or GroupHeader page. %0a(:markup caption='Example' class=horiz:)%0a{*$:Mountain} \\%0a{*$Namespaced}%0a(:markupend:)%0aTo include a page text variable ''from'' a header or footer see [[#usageotherpage |usage from other pages]] below.%0a-%3c Special references also apply to [[page variables(#specialreferences)]] and [[page list templates(#specialreferences)]].%0a%0a%0a[[#usageotherpage]]%0a!!! Usage from other pages%0a%0aIf you want to pull the data from another page, use the %25pmhlt%25[@{Group/PageName$:Var}@] format.%0a(:markup caption='Example:' class="horiz":)%0aSuburb: Khandallah%0a(:Lake:Taupo:)%0a:Mountain:Mt Ruapehu%0a%0a->"{PmWiki/PageTextVariables$:Suburb}"%0a->"{{$FullName}$:Lake}"%0a->"{PmWiki/PageTextVariables$:Mountain}"%0a(:markupend:)%0a%0a[[#usageincludedpage]]%0a!!! Usage from included pages%0a%0aPage text variables are never [[IncludeOtherPages|included]] from their source page.%0aSee [[#usageotherpage|Usage from other pages]] above to refer to a page text variable on another page.%0a%0a[[#pagelists]]%0a!!! Usage with pagelists%0a%0a[[Page lists]] can also access the page text variables:%0a(:markup caption='Example:' class="horiz":)%0a(:pagelist group=PmWiki order=$:Summary count=6 fmt=#singleline:)%0a(:markupend:)%0a%0aAnd to create pagelist formats (such as those documented at [[Site.Page List Templates]], [[PmWiki/Page Lists]], [[PmWiki/Page List Templates]], [[PmWiki/Page Variables]]. Store custom pagelists at [[Site.Local Templates]]).%0a%0a[[Page lists]] can also use page text variables to select pages :%0a(:markup caption='Example:' class="horiz":)%0a(:pagelist group=PmWiki $:City=Paris count=8 fmt=#singleline order=-name:)%0a(:markupend:)%0a->lists pages having '$:City' set to 'Paris'.%0a%0a(:markup caption='Example: multiple selections with spaces' class="horiz":)%0a(:pagelist group=PmWiki $:City="Addis Ababa,Paris" order=-$:Version count=8 fmt=#singleline:)%0a(:markupend:)%0a->'quotes' must surround ''all'' the selections.%0a%0a* When using page text variables for selection or ordering, don't put the curly braces around the variable name. The curly forms do a replacement before the pagelist command is evaluated. %0a* Link markup within the contents of a hidden page text variable directive (as opposed to other ways of specifying PTVs) will not be cached as a link on the page and thus won't be seen by pagelist's link= option. If you want the link to be found by link=, you need to specify the PTV using non-directive markup, or else put the link on the page even if it's hidden within a false conditional: %25pmhlt%25[@(:Linkme: [[PageToLink]]:) (:if false:){$:Linkme}(:ifend:)@]%0a%0aThe page text variable value is always the text that is written in the page. %0aIt is only evaluated when the variable is printed/output to HTML. %0aTo sort by a page text variable variable, all values in all pages are the not-yet-evaluated text strings, and the pagelist order function does what it can with them. It does not process/evaluate the text at this point.%0a%0aE.g. With a page name in to format "yyyyMonth" it is simpler to use a @@PageVariable@@ calculated in @@config.php@@, not a @@PageTextVariable@@:%0a-> %25hlt php%25[@$FmtPV['$NameToYearMonth'] = 'PSFT("%25Y%25m", strtotime($name))';@]%25%25 # see $FmtPV and [[PmWiki/Functions#PSFT|PSFT]]%0aThen use %25pmhlt%25[@(:pagelist order=$NameToYearMonth:)@]%0a%0aAn alternative is writing in the wiki page:%0a-> %25pmhlt%25[@(:MonthNum:07:)@]%0aas the markup expression that follows won't work:%0a-> %25pmhlt%25[@(:MonthNum:{(ftime fmt=%25m when="{$Namespaced}")}:)@]%0a%0a[[#set]]%0a!!!! Testing if set or not set within a pagelist%0a|| border=0 cellpadding=4 rules=all%0a|| '''=-''' ||PTV is set (is not empty), eg %25pmhlt%25[@(:pagelist $:Var=- :)@] ||%0a|| '''=-?*''' ||PTV is not set (is empty), ie not one character followed by 0 or more characters, eg. %25pmhlt%25[@(:pagelist $:Var=-?* :) @] ||%0a|| '''=*''' ||display ''all'' pages, regardless of the page text variable (slow) ||%0a|| '''=-*''' ||display ''no'' pages, regardless of the page text variable (slow) ||%0a%0a%0a[-Tip : %25pmhlt%25[@(:if ! equal "{$:PTV}" "":)@] will test if PTV is empty/unset or not.-]%0a%0a%0a(:markup caption='Example: Pages without a summary' class="horiz":)%0a(:pagelist group=PmWiki $:Summary=-?* count=6 fmt=#singleline:)%0a(:markupend:)%0a%0a[[#templates]]%0a!!! Use page text variable in a template%0aDisplay pages by Audience page text variable.%0a(:markup caption='Example:' class="horiz":)%0a>>comment%3c%3c%0a[[#byaudience]]%0a(:if ! equal '{=$:Audience}' '{%3c$:Audience}':)%0a-%3c'''{=$:Audience}''': %0a(:ifend:)%0a[[{=$Name}]]%0a[[#byaudienceend]]%0a>>%3c%3c%0a(:pagelist group=PmWiki count=10 fmt=#byaudience order=-$:Audience:)%0a(:markupend:)%0a%0a[[#conditionals]]%0a!!! Use page text variables in [[PmWiki/conditional markup]]%0aPage text variables will be assigned/evaluated '''before''' any conditional markup is evaluated. This effectively means that you cannot declare a PTV within an @@if...else@@ condition; and also that a PTV will have a value even if it is set within a %25pmhlt%25[@(:if false:)....(:ifend:)@] condition.%0a%0a[[#withincode]]%0a!!! Usage - from within code (developers only)%0a%0aThe standard %25hlt php%25[@PageVar($pagename,$varname)@] function can return page text variables, but remember to include the dollar and colon like this:%0a%0a->%25hlt php%25[@$var=PageVar($pagename,'$:City')@]%0a%0aIt works by caching all page (text) variables it finds in a page (in @@$PCache@@) and returns the one requested. +time=1650967314 blob - 853b3a9f07301b3f0d6deb6b59cbc9e43a2f991a blob + 5df34b2d14e709b974ad08034b185ba7675e6cdb --- wikilib.d/PmWiki.PageVariables +++ wikilib.d/PmWiki.PageVariables @@ -1,12 +1,12 @@ -version=pmwiki-2.2.109 ordered=1 urlencoded=1 +version=pmwiki-2.3.13 ordered=1 urlencoded=1 author=Petko charset=UTF-8 -csum=Despam +csum=markup expressions can process page variables (-26) ctime=1135816487 description=Documentation for "variables" that are associated with pages. name=PmWiki.PageVariables -rev=115 -targets=PmWiki.PageVariables,PmWiki.Variables,Cookbook.Functions,PmWiki.FmtPageName,PmWiki.BasicVariables,PmWiki.MarkupExpressions,Site.PageNotFound,PmWiki.IncludeOtherPages,PmWiki.PageLists,PmWiki.PageTextVariables,PmWiki.PageListTemplates,PmWiki.OtherVariables,PmWiki.ConditionalMarkup,Cookbook.HttpVariables,Cookbook.MoreCustomPageVariables,PmWiki.MarkupMasterIndex,Category.PmWikiDeveloper -text=(:title Page specific variables:)%0a(:description Documentation for "variables" that are associated with pages. :)%0a(:Summary: variables that are associated with pages:)%0a(:Audience: authors (intermediate) :)%0a%0a[[#desc]]This page describes the "variables" that are associated with pages. Page variables have the form @@{$''variable''}@@, and can be used in page markup or in certain formatting strings in PmWiki. For example, the markup "[@{$Group}@]" renders in this page as "{$Group}".%0a%0aNote: Do not confuse these variables (set and used only in PmWiki pages) with [[PmWiki/Variables|PHP variables]]. Page variables can be read in PHP with the [[Cookbook:Functions#PageVar|PageVar()]] function.%0a%0aNote that these variables do not necessarily exist in the PHP code, because they have to be determined for a specific page. (However, they are usable in [[FmtPageName]] strings.)%0a%0aThere is also the form @@{''pagename''$''variable''}@@, which returns the value of the variable for another page. For example, "[@{MarkupMasterIndex$Title}@]" displays as "{MarkupMasterIndex$Title}".%0a%0a%0a!! Default page variables%0a%0aThe page variables defined for PmWiki are:%0a%0a->[@{$Action}@] - page's url action argument, as in "{$Action}"%0a->[@{$BaseName}@] - page's "base" form (stripping any prefixes or suffixes defined via @@$BaseNamePatterns@@) as in "`{$BaseName}"%0a->[@{$DefaultGroup}@] - default group name, as in "{$DefaultGroup}"%0a->[@{$DefaultName}@] - name of default page, as in "`{$DefaultName}" (take note also of $PagePathFmt for setting a homepage for a group)%0a->[@{$Description}@] - page's description from the [@(:description:)@] markup, as in "{$Description}"%0a->[@{$FullName}@] - page's full name, as in "`{$FullName}"%0a->[@{$Group}@] - page's group name, as in "`{$Group}"%0a->[@{$Groupspaced}@] - spaced group name, as in "{$Groupspaced}"%0a%0a->[@{$LastModified}@] - date page was edited, as in "{$LastModified}"%0a->[@{$LastModifiedBy}@] - page's last editor, as in "{$LastModifiedBy}"%0a->[@{$LastModifiedHost}@] - IP of page's last editor, as in "{$LastModifiedHost}"%0a->[@{$LastModifiedSummary}@] - Summary from last edit, as in "{$LastModifiedSummary}"%0a->[@{$LastModifiedTime}@] - time page was edited in unix-style timestamp, as in "{$LastModifiedTime}"%0a-->This can be used (preceded by '@') in [[PmWiki.MarkupExpressions#ftime|[@{(ftime)}@]]] and other date/time markups.%0a%0a->[@{$Name}@] - page name, as in "`{$Name}"%0a->[@{$Namespaced}@] - spaced page name, as in "{$Namespaced}"%0a->[@{$PageUrl}@] - page's url, as in "{$PageUrl}"%0a->[@{$PasswdRead}@] - "read" permissions for the page e.g. "{$PasswdRead}"%0a->[@{$PasswdEdit}@] - "edit" permissions for the page e.g. "{$PasswdEdit}"%0a->[@{$PasswdAttr}@] - "attr" permissions for the page e.g. "{$PasswdAttr}"%0a->[@{$RequestedPage}@] - page requested in URL, used on [[Site.PageNotFound]]. e.g. "{$RequestedPage}"%0a->[@{$SiteGroup}@] - default interface group name for e.g. SideBar, forms, templates, as in "{$SiteGroup}"%0a->[@{$SiteAdminGroup}@] - default administrative group name for e.g. AuthUser, Blocklist, as in "{$SiteAdminGroup}"%0a->[@{$WikiTitle}@] - title of the website, as in "{$WikiTitle}"%0a->[@{$Title}@] - page title (may differ from Name), as in "{$Title}"%0a->[@{$Titlespaced}@] - either the page title (if defined), or the spaced page name, as in "{$Titlespaced}"%0a%0aIn addition to the above, there are some page-invariant variables available through this markup:%0a%0a->[@{$Author}@] - the name of the person currently interacting with the site, as in "{$Author}"%0a->[@{$AuthId}@] - current authenticated id, as in "{$AuthId}" %25red%25note the lower case 'd'.%25%25%0a%0a->[@{$Version}@] - PmWiki version, as in "{$Version}"%0a->[@{$VersionNum}@] - The internal version number, as in "{$VersionNum}"%0a->[@{$ScriptUrl}@] - The url to the pmwiki script, as in "{$ScriptUrl}"%0a%0a%0a[[#specialreferences]]%0a!! Special references%0aSpecial referenced variables are used to specify the context of the variable when:%0a* the variable is [[PmWiki/IncludeOtherPages|included]] into a destination (target) page%0a* the variable is used in a sidebar, header, or footer.%0a%0aPrefixing the variable name with an asterisk (*) means the variable's value is related to the browsed page or main (body) page.%0a%0a* @@{'''[@*$@]'''PageVariablename}@@ - prefixed by an asterisk (*) - value reflects the context of the browsed page.\\%0a Without the asterisk the variable's value is provided by the page from which it originates, eg source page of include, sidebar, or header or footer.\\%0a With asterisk the value will be provided by the browsed page, even if the markup comes from an included page or from a sidebar.%0a* @@{'''[@$@]'''PageVariablename}@@ - retains value in source page context.%0a* @@{'''[@=$@]'''PageVariablename}@@ - used only in [[PageLists|pagelist]] templates to print the variable provided by each page from the pagelist.%0a%0a-%3c See also $EnableRelativePageVars.%0a-%3c Special references are also used in [[page text variables(#specialreferences)]] and [[page list templates(#specialreferences)]].%0a%0aFor example you can test to see if the page is part of another page%0a(: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:)%0aor refer to the main page in a sidebar, footer, or header%0a(:markup class=horiz:)%0aThis page is [[{*$FullName}]]%0a(:markupend:)%0a%0a[[#specialreferencesend]]%0a%0a[[#security]]%0a!! Page variable security ($authpage)%0a%0aThe form @@{''pagename''$''variable''}@@ or some [[PageLists]], can display the values for other pages, regardless of the password protections. %0a%0aIf the other pages are protected and the visitor has no read permissions, PageVariables, unlike [[PageTextVariables]], normally display the values. While most variables do not contain sensitive information, some of them could do: $Title, $Description and those starting with $LastModified.%0a%0aAdministrators and module developers can redefine the sensitive page variables to respect authentications, by using the "$authpage" variable instead of "$page" in the definition. The following snippet can be added in local/config.php -- it will rewrite the default possibly sensitive definitions to the secure ones.%0a%0a[@%0aforeach($FmtPV as $k=>$v) {%0a if(preg_match('/^\\$(Title(spaced)?|LastModified(By|Host|Summary|Time)?|Description)$/', $k))%0a $FmtPV[$k] = str_replace('$page', '$authpage', $v);%0a}%0a@]%0a%0a%0a[[#custompv]]%0a!! Custom page variables%0a%0aYou may add custom page variables as a local customization. In a local configuration file or a recipe script, use the variable $FmtPV:%0a%0a->[@%0a$FmtPV['$VarName'] = "'variable definition'";%0a$FmtPV['$CurrentSkin'] = '$GLOBALS["Skin"]';%0a$FmtPV['$WikiTitle'] = '$GLOBALS["WikiTitle"]';%0a@]%0a%0aDefines new Page Variable of name $CurrentSkin, which can be used in the page with [@{$CurrentSkin}@] (also for [[Conditional markup]]). It's necessary to use the single quotes nested inside double-quotes as shown above (preferred) or a double-quoted string nested inside single-quotes like ''[@'"this"'@]''.%0a%0aYou can make a string a Page Variable by adding the string to the $GLOBALS[] array first.%0a%0a->[@%0a## Create a {$BaseUrl} page variable%0a$GLOBALS['BaseUrl'] = $UrlScheme."://".$_SERVER["HTTP_HOST"]."/Wiki";%0a$FmtPV['$BaseUrl'] = '$GLOBALS["BaseUrl"]';%0a@]%0a%0aYou can also have a function create the string.%0a%0a->[@%0a## Create a {$BaseUrl} page variable%0afunction BaseUrl() { %0a global $UrlScheme;%0a return $UrlScheme."://".$_SERVER['HTTP_HOST']."/Wiki"; %0a}%0a$FmtPV['$BaseUrl'] = 'BaseUrl()';%0a@]%0a%0a>>frame%3c%3c%0aPlease note that the values of the elements of $FmtPV are @@eval()@@ed so '''always sanitize any user input'''. The following is very insecure[=:=]%0a%0a->[@$FmtPV['$Var'] = $_REQUEST['Var'];@] %25red%25# critically insecure, allows PHP code injection%25%25\\%0a[@$FmtPV['$Var'] = '"'. addslashes($_REQUEST['Var']).'"';@] %25red%25# critically insecure, allows PHP code injection%25%25%0a%0aSee the recipe Cookbook:HttpVariables for a better way to use these variables.%0a>>%3c%3c%0a%0a!! See also%0a%0a* [[Cookbook:More custom page variables]]%0a* [[PmWiki.Variables]] — about variables internal to PmWiki.%0a* [[PmWiki.MarkupMasterIndex]] — complete list of PmWiki markups.%0a* [[PmWiki/PageTextVariables]] — page variables automatically made available through natural page markup or explicit page markup within the wiki text of the page.%0a* [[PmWiki.Markup Expressions]] — markup expressions can manipulate page variables%0a%0a>>faq%3c%3c [[#faq]]%0a%0aQ:Is there a variable like $LastModified, but which shows me the creation time?%0aA:No, but you can create one in config.php. For instance:%0a->[@# add page variable {$PageCreationDate} in format yyyy-mm-dd%0a$FmtPV['$PageCreationDate'] = 'strftime("%25Y-%25m-%25d", $page["ctime"])';@]%0a%0aIf you like the same format that you define in config.php with $TimeFmt use%0a[@ $FmtPV['$Created'] = "strftime(\$GLOBALS['TimeFmt'], \$page['ctime'])";%0a@]%0a%0aQ: How can I test if a variable is set and/or not empty?%0aA: Use @@[=(:if ! equal "{$Variable}" "":) $Variable is not empty. (:ifend:)=]@@. Note that undefined/inexistent variables appear as empty ones.%0a%0aCategories: [[!PmWiki Developer]] -time=1538373726 +rev=127 +targets=PmWiki.PageVariables,PmWiki.Variables,Cookbook.Functions,PmWiki.FmtPageName,PmWiki.BasicVariables,PmWiki.MarkupExpressions,Site.PageNotFound,PmWiki.IncludeOtherPages,PmWiki.PageLists,PmWiki.PageTextVariables,PmWiki.PageListTemplates,PmWiki.OtherVariables,PmWiki.ConditionalMarkup,Cookbook.HttpVariables,Cookbook.MoreCustomPageVariables,PmWiki.MarkupMasterIndex,Category.PmWikiDeveloper,!PmWikiDeveloper +text=(:title Page specific variables:)%0a(:description Documentation for "variables" that are associated with pages. :)%0a(:Summary: variables that are associated with pages:)%0a(:Audience: authors (intermediate) :)%0a%0a[[#desc]]This page describes the "[[variables]]" that are associated with pages. Page variables have the form %25pmhlt%25[@{$variable}@], and can be used in page markup or in certain formatting strings in PmWiki. For example, the markup "[@{$Group}@]" renders in this page as "{$Group}".%0a%0aNote: Do not confuse these variables (set and used only in PmWiki pages) with [[PmWiki/Variables|PHP variables]]. Page variables can be read in PHP with the [[Cookbook:Functions#PageVar|PageVar()]] function.%0a%0aNote that these variables do not necessarily exist in the PHP code, because they have to be determined for a specific page. (However, they are usable in [[FmtPageName]] strings.)%0a%0a%25pmhlt%25There is also the form [@{pagename$variable}@], which returns the value of the variable for another page. For example, "[@{MarkupMasterIndex$Title}@]" displays as "{MarkupMasterIndex$Title}".%0a%0a%0a!! Default page variables%0a%0aThe page variables defined for PmWiki are:%0a%0a->%25pmhlt%25[@{$Action}@] - page's url action argument, as in "{$Action}"%0a->%25pmhlt%25[@{$BaseName}@] - page's "base" form (stripping any prefixes or suffixes defined via @@$BaseNamePatterns@@) as in "`{$BaseName}"%0a->%25pmhlt%25[@{$DefaultGroup}@] - default group name, as in "{$DefaultGroup}"%0a->%25pmhlt%25[@{$DefaultName}@] - name of default page, as in "`{$DefaultName}" (take note also of $PagePathFmt for setting a homepage for a group)%0a->%25pmhlt%25[@{$Description}@] - page's description from the [@(:description:)@] markup, as in "{$Description}"%0a->%25pmhlt%25[@{$FullName}@] - page's full name, as in "`{$FullName}"%0a->%25pmhlt%25[@{$Group}@] - page's group name, as in "`{$Group}"%0a->%25pmhlt%25[@{$Groupspaced}@] - spaced group name, as in "{$Groupspaced}"%0a%0a->%25pmhlt%25[@{$LastModified}@] - date page was edited, as in "{$LastModified}"%0a->%25pmhlt%25[@{$LastModifiedBy}@] - page's last editor, as in "{$LastModifiedBy}"%0a->%25pmhlt%25[@{$LastModifiedHost}@] - IP of page's last editor, as in "{$LastModifiedHost}"%0a->%25pmhlt%25[@{$LastModifiedSummary}@] - Summary from last edit, as in "{$LastModifiedSummary}"%0a->%25pmhlt%25[@{$LastModifiedTime}@] - time page was edited in unix-style timestamp, as in "{$LastModifiedTime}"%0a-->%25pmhlt%25This can be used (preceded by '@') in [[PmWiki.MarkupExpressions#ftime|[@{(ftime)}@]]] and other date/time markups.%0a%0a->%25pmhlt%25[@{$Name}@] - page name, as in "`{$Name}"%0a->%25pmhlt%25[@{$Namespaced}@] - spaced page name, as in "{$Namespaced}"%0a->%25pmhlt%25[@{$PageUrl}@] - page's url, as in "{$PageUrl}"%0a->%25pmhlt%25[@{$PasswdRead}@] - "read" permissions for the page e.g. "{$PasswdRead}"%0a->%25pmhlt%25[@{$PasswdEdit}@] - "edit" permissions for the page e.g. "{$PasswdEdit}"%0a->%25pmhlt%25[@{$PasswdAttr}@] - "attr" permissions for the page e.g. "{$PasswdAttr}"%0a->%25pmhlt%25[@{$RequestedPage}@] - page requested in URL, used on [[Site.PageNotFound]]. e.g. "{$RequestedPage}"%0a->%25pmhlt%25[@{$SiteGroup}@] - default interface group name for e.g. SideBar, forms, templates, as in "{$SiteGroup}"%0a->%25pmhlt%25[@{$SiteAdminGroup}@] - default administrative group name for e.g. AuthUser, Blocklist, as in "{$SiteAdminGroup}"%0a->%25pmhlt%25[@{$WikiTitle}@] - title of the website, as in "{$WikiTitle}"%0a->%25pmhlt%25[@{$Title}@] - page title (may differ from Name), as in "{$Title}"%0a->%25pmhlt%25[@{$Titlespaced}@] - either the page title (if defined), or the spaced page name, as in "{$Titlespaced}"%0a->%25pmhlt%25 [@{$GroupHomePage}@], [@{$GroupHomePageName}@], [@{$GroupHomePageTitle}@], [@{$GroupHomePageTitlespaced}@] - information about the homepage in the group of the current page, respectively the full name of the homepage, its [@{$Name}@], [@{$Title}@], and [@{$Titlespaced}@], as in "{$GroupHomePage}", "{$GroupHomePageName}", "{$GroupHomePageTitle}", "{$GroupHomePageTitlespaced}"%0a->%25pmhlt%25 All other variables derived from the group homepage can be output with nested markup, for example \%0a [@{{$GroupHomePage}$LastModified}@], [@{{$GroupHomePage}$Description}@].%0a%0aIn addition to the above, there are some page-invariant variables available through this markup:%0a%0a->%25pmhlt%25[@{$Author}@] - the name of the person currently interacting with the site, as in "{$Author}"%0a->%25pmhlt%25[@{$AuthId}@] - current authenticated id, as in "{$AuthId}" %25red%25note the lower case 'd'.%25%25%0a%0a->%25pmhlt%25[@{$Version}@] - PmWiki version, as in "{$Version}"%0a->%25pmhlt%25[@{$VersionNum}@] - The internal version number, as in "{$VersionNum}"%0a->%25pmhlt%25[@{$ScriptUrl}@] - The URL to the pmwiki script, as in "{$ScriptUrl}"%0a%0a%0a[[#specialreferences]]%0a!! Special references%0aSpecial referenced variables are used to specify the context of the variable when:%0a* the variable is [[PmWiki/IncludeOtherPages|included]] into a destination (target) page%0a* the variable is used in a sidebar, header, or footer.%0a%0aPrefixing the variable name with an asterisk (*) means the variable's value is related to the browsed page or main (body) page.%0a%0a* %25pmhlt%25[@{*$PageVariablename}@] - prefixed by an asterisk (*) - value reflects the context of the browsed page.\\%0a Without the asterisk the variable's value is provided by the page from which it originates, eg source page of include, sidebar, or header or footer.\\%0a With asterisk the value will be provided by the browsed page, even if the markup comes from an included page or from a sidebar.%0a* %25pmhlt%25[@{$PageVariablename}@] - retains value in source page context.%0a* %25pmhlt%25[@{=$PageVariablename}@] - used only in [[PageLists|pagelist]] templates to print the variable provided by each page from the pagelist.%0a%0a-%3c See also $EnableRelativePageVars.%0a-%3c Special references are also used in [[page text variables(#specialreferences)]] and [[page list templates(#specialreferences)]].%0a%0aFor example you can test to see if the page is part of another page%0a(: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:)%0aor refer to the main page in a sidebar, footer, or header%0a(:markup class=horiz:)%0aThis page is [[{*$FullName}]]%0a(:markupend:)%0a%0a[[#specialreferencesend]]%0a%0a[[#security]]%0a!! Page variable security ($authpage)%0a%0aThe form %25pmhlt%25[@{pagename$variable}@] in some [[PageLists]], can display the values for other pages, regardless of the password protections. %0a%0aIf the other pages are protected and the visitor has no read permissions, [[PageVariables]], unlike [[PageTextVariables]], normally display the values. While most variables do not contain sensitive information, some of them could do: $Title, $Description and those starting with $LastModified.%0a%0a%25pmhlt%25Administrators and module developers can redefine the sensitive page variables to respect authentications, by using the "$authpage" variable instead of "$page" in the definition. The following snippet can be added in @@local/config.php@@ -- it will rewrite the default possibly sensitive definitions to the secure ones.%0a%0a%25hlt php%25[@%0aforeach($FmtPV as $k=>$v) {%0a if(preg_match('/^\\$(Title(spaced)?|LastModified(By|Host|Summary|Time)?|Description)$/', $k))%0a $FmtPV[$k] = str_replace('$page', '$authpage', $v);%0a}%0a@]%0a%0a%0a[[#custompv]]%0a!! Custom page variables%0a%0aYou may add custom page variables as a local customization. In a local configuration file or a recipe script, use the variable $FmtPV:%0a%0a->%25hlt php%25[@%0a$FmtPV['$VarName'] = "'variable definition'";%0a$FmtPV['$CurrentSkin'] = '$GLOBALS["Skin"]';%0a@]%0a%0aDefines new Page Variable of name $CurrentSkin, which can be used in the page with [@{$CurrentSkin}@] (also for [[Conditional markup]]). It's necessary to use the single quotes nested inside double-quotes as shown above (preferred) or a double-quoted string nested inside single-quotes like ''[@'"this"'@]''.%0a%0aYou can make a string a Page Variable by adding the string to the $GLOBALS[] array first.%0a%0a->%25hlt php%25[@%0a## Create a {$BaseUrl} page variable%0a$GLOBALS['BaseUrl'] = $UrlScheme."://".$_SERVER["HTTP_HOST"]."/Wiki";%0a$FmtPV['$BaseUrl'] = '$GLOBALS["BaseUrl"]';%0a@]%0a%0aYou can also have a function create the string.%0a%0a->%25hlt php%25[@%0a## Create a {$BaseUrl} page variable%0afunction BaseUrl() { %0a global $UrlScheme;%0a return $UrlScheme."://".$_SERVER['HTTP_HOST']."/Wiki"; %0a}%0a$FmtPV['$BaseUrl'] = 'BaseUrl()';%0a@]%0a%0a>>frame%3c%3c%0aPlease note that the values of the elements of $FmtPV are @@eval()@@ed so '''always sanitize any user input'''. The following is very insecure[=:=]%0a%0a->%25hlt php%25[@$FmtPV['$Var'] = $_REQUEST['Var'];@] %25red%25# critically insecure, allows PHP code injection%25%25\\%0a%25hlt php%25[@$FmtPV['$Var'] = '"'. addslashes($_REQUEST['Var']).'"';@] %25red%25# critically insecure, allows PHP code injection%25%25%0a%0aSee the recipe [[Cookbook:HttpVariables]] for a better way to use these variables.%0a>>%3c%3c%0a%0a!! See also%0a%0a* [[Cookbook:More custom page variables]]%0a* [[PmWiki.Variables]] — about variables internal to PmWiki.%0a* [[PmWiki.MarkupMasterIndex]] — complete list of PmWiki markups.%0a* [[PmWiki/PageTextVariables]] — page variables automatically made available through natural page markup or explicit page markup within the wiki text of the page.%0a* [[PmWiki.Markup Expressions]] — markup expressions can process page variables.%0a%0a>>faq%3c%3c [[#faq]]%0a%0aQ:Is there a variable like $LastModified, but which shows me the creation time?%0aA:No, but you can create one in config.php. For instance:%0a-->%25hlt php%25[@# add page variable [={$PageCreationDate}=] in format yyyy-mm-dd@]%0a-->%25hlt php%25[@$FmtPV['$PageCreationDate'] = '[[PmWiki/Functions#PSFT|PSFT]]("[=%25Y-%25m-%25d=]", $page["ctime"])';@]%0a%0a->If you like the same format that you define in config.php with $TimeFmt use%0a-->%25hlt php%25[@$FmtPV['$Created'] = "[[PmWiki/Functions#PSFT|PSFT]](\$GLOBALS['TimeFmt'], \$page['ctime'])";@]%0a%0aQ: How can I test if a variable is set and/or not empty?%0aA: Use %25pmhlt%25[@[=(:if ! equal "{$Variable}" "":) $Variable is not empty. (:ifend:)=]@]. Note that undefined/inexistent variables appear as empty ones.%0a%0aCategories: [[!PmWiki Developer]] +time=1666586148 title=Page specific variables blob - 136201292cd547a1344c39ce420c663f40f3dde9 blob + 93f777e21afa408eedf04685c7e9f6aa1328605a --- wikilib.d/PmWiki.PagelistVariables +++ wikilib.d/PmWiki.PagelistVariables @@ -1,10 +1,10 @@ -version=pmwiki-2.2.125 ordered=1 urlencoded=1 +version=pmwiki-2.3.5 ordered=1 urlencoded=1 author=Petko charset=UTF-8 -csum=hidden subdir (+28) +csum=$PageIndexTermsFunction (+408) ctime=1136054369 name=PmWiki.PagelistVariables -rev=40 +rev=44 targets=PmWiki.PagelistVariables,PmWiki.CustomPagelistSortOrder,PmWiki.PageLists,Cookbook.SearchPatterns,PmWiki.PathVariables,Site.LocalTemplates,Site.PageListTemplates,PmWiki.IncludeOtherPages,PmWiki.PageListTemplates -text=(:Summary:variables used with [[PmWiki/page lists]] and search results:)%0a:$EnablePageListProtect:When set to 1 (which is the default), causes [@(:pagelist:)@] and [@(:searchresults:)@] to exclude listing any pages for which the browser does not currently have read authorization. Setting this to zero means that read-protected pages can appear in a listing, but can also speed up searches considerably (because page permissions do not need to be checked).%0a%0a:$PageListSortCmpFunction:The function used to compare values when ordering a page list, for historical reasons the default is '[[(http://php.net/)strcasecmp]]' and sorts alphabetically and case insensitively. If you regularly order numbers or strings with numbers, you can set this variable to '[[(http://php.net/)strnatcasecmp]]' and the list will be sorted according to a [[https://github.com/sourcefrog/natsort#readme|natural order]], case insensitively:\\%0a[@ $PageListSortCmpFunction = 'strnatcasecmp';# "natural" sorting of pagelists@]\\%0aOr you can write here the name of a custom function you have defined. This is the general sorting function, for specific needs you can create specific functions, see [[(PmWiki:)CustomPagelistSortOrder]].%0a%0a:$PageListVarFoldFn: PageList and Search terms, including page variable search terms are always case insensitive for the Latin alphabet. For international characters the page variable terms were case sensitive until PmWiki 2.2.115, and became case insensitive from 2.2.116 (like for the Latin characters). If your pagelists relied on the previous behavior, you can set here a function name that does not change the case of the international characters, for example [@$PageListVarFoldFn = 'strval';@]%0a%0a:$SearchPatterns:An array of page name patterns to be required or excluded from search and [[PmWiki/PageLists|pagelist]] results. In order to be included in a search listing or page listing, a page's name must not match any pattern that is delimited by exclamation points (!) and must match all other patterns. See [[Cookbook:SearchPatterns]].%0a--> [@# Limit all searches to Main group%0a$SearchPatterns['default'][] = '/^Main\\./';%0a# Exclude the Main group from search results%0a$SearchPatterns['default'][] = '!^Main\\.!';%0a# Exclude RecentChanges pages from search results%0a$SearchPatterns['default'][] = '!\\.(All)?RecentChanges$!';%0a# Prevent a page from listing itself in (:pagelist:) or (:searchresults:)%0a$SearchPatterns['default'][] = FmtPageName('!^$FullName$!', $pagename);%0a@]%0a%0a:$SearchBoxOpt:%0a--> For example [@ $SearchBoxOpt ['target'] = '$DefaultGroup.Search'; @]%0a%0a:$SearchBoxInputType:The HTML "type" attribute for the search field. Default is "text" which is valid HTML4. If your skin uses HTML5, you can change this to "search":%0a--> @@ $SearchBoxInputType = "search";@@%0a%0a%0a:$EnablePageIndex:When set to 0, disables default indexing. By default PmWiki maintains a "link and word index" in $PageIndexFile which significantly speeds up categories, backlinks, and searches.%0a%0a:$PageIndexFile:The location of the "page index" file for [@(:pagelist:)@], defaults to @@$WorkDir/.pageindex@@.%0a%0a:$PageListCacheDir:The name of a writable directory where PmWiki can cache results of [@(:pagelist:)@] directives to speed up subsequent displays of the same list. Default is empty, which disables the pagelist cache.%0a--> [@# Enable pagelist caching in work.d/.pagelistcache%0a$PageListCacheDir = 'work.d/.pagelistcache';%0a@]%0a%0a:$PageSearchForm:The page to be used to format search results for [@?action=search@] (unless the current page has a "searchresults" directive in it). This variable can be an array, in which case the first page found from the array is used.%0a--> [@# Simple use of page search form in the default group%0a$PageSearchForm = '$DefaultGroup.Search';%0a@]%0a--> [@# Use Search page in current group if it exists, otherwise use Site.Search%0a$PageSearchForm = array('$Group.Search', '[=$[$SiteGroup/Search]=]');%0a@]%0a%0a:$FPLTemplatePageFmt:The pages to be searched for a pagelist template specified by a [@fmt=#xyz@] parameter. Defaults to searching the current page, [[Site.LocalTemplates]] and [[Site.PageListTemplates]].%0a%0a--> [@# PMWiki default setup%0aglobal $FPLTemplatePageFmt;%0a$FPLTemplatePageFmt = array(%0a '{$FullName}', %0a '{$SiteGroup}.LocalTemplates', %0a '{$SiteGroup}.PageListTemplates');@]%0a%0a-> It can be customized to look in other pages.%0a%0a--> [@# Search a Group.Templates page as well as the Site templates%0aglobal $FPLTemplatePageFmt;%0a$FPLTemplatePageFmt = array(%0a '{$Group}.Templates',%0a '{$SiteGroup}.LocalTemplates',%0a '{$SiteGroup}.PageListTemplates');@]%0a%0a-> Or declare defaults for the template array:%0a--> [@# Search a Group.Templates page as well as the Site templates%0aglobal $FPLTemplatePageFmt;%0aSDV($FPLTemplatePageFmt, array('{$FullName}',%0a '{$Group}.Templates',%0a '{$SiteGroup}.LocalTemplates', '{$SiteGroup}.PageListTemplates')%0a );@]%0a%0a:$EnableUndefinedTemplateVars: This variable controls how undefined [={$$Variable}=] is processed in [[IncludeOtherPages|includes]] and [[PageList templates]]. If set to 0 (default), undefined [={$$Variable}=]s are removed from the included section or template. If set to 1, undefined [={$$Variable}=]s are displayed as is, with {$$...}. ''Note that PmWiki versions 2.2.13 and earlier '''kept''' unset include/template variables.''%0a: : @@$EnableUndefinedTemplateVars = 0;@@ # Delete unset raw template variables%0a: : @@$EnableUndefinedTemplateVars = 1;@@ # Keep and print unset raw template variables%0a -time=1580365171 +text=(:Summary:variables used with [[PmWiki/page lists]] and search results:)%0a:$EnablePageListProtect:When set to 1 (which is the default), causes [@(:pagelist:)@] and [@(:searchresults:)@] to exclude listing any pages for which the browser does not currently have read authorization. Setting this to zero means that read-protected pages can appear in a listing, but can also speed up searches considerably (because page permissions do not need to be checked).%0a%0a:$PageListSortCmpFunction:The function used to compare values when ordering a page list, for historical reasons the default is '[[(http://php.net/)strcasecmp]]' and sorts alphabetically and case insensitively. If you regularly order numbers or strings with numbers, you can set this variable to '[[(http://php.net/)strnatcasecmp]]' and the list will be sorted according to a [[https://github.com/sourcefrog/natsort#readme|natural order]], case insensitively:\\%0a[@ $PageListSortCmpFunction = 'strnatcasecmp';# "natural" sorting of pagelists@]\\%0aOr you can write here the name of a custom function you have defined. This is the general sorting function, for specific needs you can create specific functions, see [[(PmWiki:)CustomPagelistSortOrder]].%0a%0a:$PageListVarFoldFn: PageList and Search terms, including page variable search terms are always case insensitive for the Latin alphabet. For international characters the page variable terms were case sensitive until PmWiki 2.2.115, and became case insensitive from 2.2.116 (like for the Latin characters). If your pagelists relied on the previous behavior, you can set here a function name that does not change the case of the international characters, for example [@$PageListVarFoldFn = 'strval';@]%0a%0a:$SearchPatterns:An array of page name patterns to be required or excluded from search and [[PmWiki/PageLists|pagelist]] results. In order to be included in a search listing or page listing, a page's name must not match any pattern that is delimited by exclamation points (!) and must match all other patterns. See [[Cookbook:SearchPatterns]].%0a--> [@# Limit all searches to Main group%0a$SearchPatterns['default'][] = '/^Main\\./';%0a# Exclude the Main group from search results%0a$SearchPatterns['default'][] = '!^Main\\.!';%0a# Exclude RecentChanges pages from search results%0a$SearchPatterns['default'][] = '!\\.(All)?RecentChanges$!';%0a# Prevent a page from listing itself in (:pagelist:) or (:searchresults:)%0a$SearchPatterns['default'][] = FmtPageName('!^$FullName$!', $pagename);%0a@]%0a%0a:$SearchBoxOpt:%0a--> For example [@ $SearchBoxOpt ['target'] = '$DefaultGroup.Search'; @]%0a%0a:$SearchBoxInputType:The HTML "type" attribute for the search field. Default is "text" which is valid HTML4. If your skin uses HTML5, you can change this to "search":%0a--> @@ $SearchBoxInputType = "search";@@%0a%0a%0a:$EnablePageIndex:When set to 0, disables default indexing. By default PmWiki maintains a "link and word index" in $PageIndexFile which significantly speeds up categories, backlinks, and searches.%0a%0a:$PageIndexFile:The location of the "page index" file for [@(:pagelist:)@], defaults to @@$WorkDir/.pageindex@@.%0a%0a:$PageListCacheDir:The name of a writable directory where PmWiki can cache results of [@(:pagelist:)@] directives to speed up subsequent displays of the same list. Default is empty, which disables the pagelist cache.%0a--> [@# Enable pagelist caching in work.d/.pagelistcache%0a$PageListCacheDir = 'work.d/.pagelistcache';%0a@]%0a%0a:$PageSearchForm:The page to be used to format search results for [@?action=search@] (unless the current page has a "searchresults" directive in it). This variable can be an array, in which case the first page found from the array is used.%0a--> [@# Simple use of page search form in the default group%0a$PageSearchForm = '$DefaultGroup.Search';%0a@]%0a--> [@# Use Search page in current group if it exists, otherwise use Site.Search%0a$PageSearchForm = array('$Group.Search', '[=$[$SiteGroup/Search]=]');%0a@]%0a%0a:$FPLTemplatePageFmt:The pages to be searched for a pagelist template specified by a [@fmt=#xyz@] parameter. Defaults to searching the current page, [[Site.LocalTemplates]] and [[Site.PageListTemplates]].%0a%0a--> [@# PMWiki default setup%0aglobal $FPLTemplatePageFmt;%0a$FPLTemplatePageFmt = array(%0a '{$FullName}', %0a '{$SiteGroup}.LocalTemplates', %0a '{$SiteGroup}.PageListTemplates');@]%0a%0a-> It can be customized to look in other pages.%0a%0a--> [@# Search a Group.Templates page as well as the Site templates%0aglobal $FPLTemplatePageFmt;%0a$FPLTemplatePageFmt = array(%0a '{$Group}.Templates',%0a '{$SiteGroup}.LocalTemplates',%0a '{$SiteGroup}.PageListTemplates');@]%0a%0a-> Or declare defaults for the template array:%0a--> [@# Search a Group.Templates page as well as the Site templates%0aglobal $FPLTemplatePageFmt;%0aSDV($FPLTemplatePageFmt, array('{$FullName}',%0a '{$Group}.Templates',%0a '{$SiteGroup}.LocalTemplates', '{$SiteGroup}.PageListTemplates')%0a );@]%0a%0a:$EnableUndefinedTemplateVars: This variable controls how undefined [={$$Variable}=] is processed in [[IncludeOtherPages|includes]] and [[PageList templates]]. If set to 0 (default), undefined [={$$Variable}=]s are removed from the included section or template. If set to 1, undefined [={$$Variable}=]s are displayed as is, with {$$...}. ''Note that PmWiki versions 2.2.13 and earlier '''kept''' unset include/template variables.''%0a: : @@$EnableUndefinedTemplateVars = 0;@@ # Delete unset raw template variables%0a: : @@$EnableUndefinedTemplateVars = 1;@@ # Keep and print unset raw template variables%0a%0a:$PageIndexFoldFunction: A custom function used to 'fold' (simplify, normalize) the page words before storing them in the wiki.d/.pageindex file, and the search terms typed by the users. By default, PmWiki converts these to lowercase, here you can define a function that does it differently (for example, stripping inline HTML tags).%0a%0a:$PageIndexTermsFunction: A function to split the page texts into normalized search terms. By default, the core function PageIndexTerms() is called, with this variable you can override it with a custom function. This may be useful if you need to remove some texts from the page index, for example inline HTML tags. The first and only argument of the function may be either a string, or an array of strings.%0a +time=1654003159 blob - 3071f191103ba31d0895f841398949d764a54316 blob + df367095b9e4e345a2f065f159d2e9966ba91964 --- wikilib.d/PmWiki.Passwords +++ wikilib.d/PmWiki.Passwords @@ -1,11 +1,11 @@ -version=pmwiki-2.2.118 ordered=1 urlencoded=1 -author=Petko +version=pmwiki-2.3.12 ordered=1 urlencoded=1 +author=simon charset=UTF-8 -csum=rm manual TOC, add !!FAQ +csum=typo (+1) description=General use of passwords and login name=PmWiki.Passwords post= Save -rev=240 -targets=PmWiki.PasswordsAdmin,Category.Spam,PmWiki.PmWiki,PmWiki.WikiGroup,PmWiki.Security,PmWiki.AvailableActions,PmWiki.SpecialPages,PmWiki.GroupAttributes,PmWiki.Uploads,SiteAdmin.AuthList,PmWiki.SecurityVariables,PmWiki.AuthUser,Cookbook.SessionSecurityAdvice,PmWiki.ConditionalMarkup,PITS.01417,PmWiki.IncludeOtherPages,Cookbook.Cookbook -text=(:Summary:General use of passwords and login:)(:Audience: authors :)(:Description General use of passwords and login:)%0a%0a[[PmWiki]] has built-in support for password-protecting various areas of the wiki site. Authors generally want to be able to apply passwords to individual pages or to [[wiki group]]s. Wiki Administrators can apply passwords to individual pages, to wiki groups, or to the [[PasswordsAdmin#settingsitewidepasswords|entire site]]. Setting an edit password on a [[#pageattr|page]] or [[#groupattr|group]] (or [[#siteattr|the entire site]]) is one of the most common ways to stop [[!spam]]. As with any access control system, the password protection mechanisms described here are only a small part of overall system and wiki [[security]].%0a%0a!! As an author editing pages...%0aAn author will generally set 3 types of passwords:%0a# to control who can see a page or group, use @@read@@ passwords%0a# to control who can edit a page or group, use @@edit@@ passwords%0a# to control who can alter the passwords used to protect a page or group, use @@attr@@ passwords%0a%0aIf required most [[AvailableActions|page actions]] can be password protected.%0a%0a[[#pageattr]]%0a!!! Protect an individual page%0aTo set a password on an individual wiki page, add the [[AvailableActions|page action]]%0a->@@?action=attr@@ %0ato the page's URL (address) to access its attributes. Using the form on the attributes page, you can set or clear the @@read@@, @@edit@@, or @@attr@@ passwords on the page. In the form you enter the passwords as cleartext; PmWiki encrypts them for you automatically when it stores them. %0a%0aAdditional options:%0a* Leaving a field blank will leave the attribute unchanged. %0a* To remove a password from a page (''reverting back'' to the group's or site's default), enter %0a--> @@ clear @@%0a* To indicate that the page can be edited ''even if a group or site password is set'', enter %0a--> @@ @nopass @@%0a* To lock a page for everybody but the admin, enter %0a--> @@ @lock @@%0a* To assign the site's site-wide passwords to the @@read@@, @@edit@@, or @@attr@@ password for the page, enter %0a--> @@ @_site_edit, @_site_read or @_site_upload @@%0a%0a[[#groupattr]]%0a!!! Protect a wiki group of pages%0aTo set a password on a [[wiki group]] is slightly more difficult -- you just set the passwords on a [[special page(s)]] in each group called %0a->[[GroupAttributes]]%0a%0aFirst, you can get to the attributes page for `GroupAttributes by entering a URL (address) like %0a->[@http://example.com/pmwiki/pmwiki.php?n=GroupName.GroupAttributes?action=attr@]%0aReplace example.com with your domain name, and GroupName with the name of the group%0a%0aThen, using the form on the attributes page, you can set or clear the @@read@@, @@edit@@, or @@attr@@ passwords for the entire group. In the form you enter the passwords as cleartext; PmWiki encrypts them for you automatically.%0a%0aAdditional options:%0a* To remove a password from a group (''reverting back'' to the site's default), enter %0a-->@@clear@@%0a* To indicate that the group can be edited ''even if a site password is set'', enter %0a-->@@@nopass@@%0a* To lock a group for everybody but the admin, enter %0a-->@@@lock@@%0a* (Beginning with Ver 2.2.3) To assign the site's site-wide passwords to the @@read@@, @@edit@@, or @@attr@@ password for the group, enter %0a--> @@ @_site_edit, @_site_read or @_site_upload @@%0a%0a%0a!!! Passwords%0aPasswords may consist of any combination of characters, except double "quotes" or 'apostrophes'.%0aPasswords with spaces or colons must be entered using quotes, eg "foo bar" or "foo:bar".%0aObviously longer is [[Wikipedia:Password_strength|better]], and on some systems passwords need to have 4 or more characters.%0a%0a!!! Multiple passwords%0aMultiple passwords for a page, group or site are allowed. %0aSimply enter multiple passwords separated by a space. This allows you to have a read password, a write password, and have the write password allow read/write access. In other words, if the read password is %0a->alpha%0aand the edit password is %0a->beta%0athen enter%0a-> [@Set new read password: alpha beta%0aSet new edit password: beta@]%0a%0aThis says that either %0a->alpha%0aor %0a->beta%0acan be used to read pages, but only %0a->beta%0amay edit. Since PmWiki checks the passwords you've entered since the browser has been opened, entering a read password that is also a write password allows both reading and writing.%0a%0a[[#siteattr]]%0a!!! Protect the site%0aPasswords can be applied to the entire wiki website in ''config.php''.%0aSee [[PasswordsAdmin#settingsitewidepasswords|passwords]] administration for details.%0a%0a%0a%25audience%25 administrator%0a%0a[[#administrators]]%0a!! As an administrator ...%0a%0aYou can set passwords on pages and groups exactly as described above for authors. You can also:%0a# set site-wide passwords for pages and groups that do not have passwords%0a# use @@attr@@ passwords to control who is able to set passwords on pages%0a# use @@upload@@ passwords to control access to the file [[upload(s)]] capabilities (if uploads are enabled)%0a# use an @@admin@@ password to override the passwords set for any individual page or group%0a# use [[SiteAdmin.AuthList]] to view the permissions settings for pages that have permissions set. %0aFor more information on password options available to administrators, see [[PasswordsAdmin]].%0a%0a!! [[#priority]]Which password wins?%0aIn PmWiki, page passwords override group passwords, group passwords override the ''default'' passwords, and the @@admin@@ password overrides all passwords. This gives a great deal of flexibility in controlling access to wiki pages in PmWiki. %0a%0aThe [[special page(s)]] [[SiteAdmin.AuthList]] is a page list of all pages with access permissions set.%0a%0a!! Opening access to pages in protected groups/sites%0aSometimes we want to "unprotect" pages in a group or site that is otherwise protected. In these cases, the special password %0a->@@ @nopass @@%0ais used to indicate that access should be allowed to a page without requiring a password. %0a%0aFor example, suppose `Main.GroupAttributes has an edit password set, thus restricting the editing of all pages in Main. Now we want `Main.WikiSandbox to be editable without a password. Using %0a->@@clear@@%0afor the edit password for `Main.WikiSandbox ''doesn't unprotect the page'', because the password is being set by the group. Instead, we set the edit password for `Main.WikiSandbox to the special value %0a->@@ @nopass @@%0awhich tells PmWiki to ignore any site-wide or group-level passwords for that page.%0a%0a!! FAQ%0a>>faq%3c%3c [[#faq]]%0a%0a[[#site]]%0aQ: How can I password protect all the pages and groups on my site? Do I really have to set passwords page by page, or group by group?%0a%0aA: Administrators can set passwords for the entire site by editing the config.php file; they don't have to set passwords for each page or group. For example, to set the entire site to be editable only by those who know an "edit" password, an administrator can add a line like the following to local/config.php:%0a%0a-> @@ $DefaultPasswords['edit'] = pmcrypt('edit_password'); @@%0a%0aFor more information about the password options that are available only to administrators, see [[PasswordsAdmin]].%0a%0aQ: I get http error 500 "Internal Server Error" when I try to log in. What's wrong?%0a%0aA: This can happen if the encrypted passwords are not created on the web server that hosts the PmWiki.\\%0aThe [[http://php.net/crypt|PHP crypt() function]] changed during the PHP development, e.g. a password encrypted with PHP 5.2 can not be decrypted in PHP 5.1, but PHP 5.2 can decrypt passwords created by PHP 5.1.\\%0aThis situation normally happens if you prepare everything on your local machine with the latest PHP version and you upload the passwords to a webserver which is running an older version.\\%0aThe same error occurs when you add encrypted passwords to local/config.php.%0a%0aSolution: Create the passwords on the system with the oldest PHP version and use them on all other systems.%0a%0aQ: How can I create private groups for users, so that each user can edit pages in their group, but no one else (other than the admin) can?%0a%0aA: Modify the edit attribute for each group to id:username, e.g. set the edit attribute in JaneDoe.GroupAttributes to id:JaneDoe.%0a%0aThere is a more automatic solution, but it's probably not a good idea for most wikis. Administrators can use the [[(PmWiki:)AuthUser]] recipe and add the following few lines to their local/config.php file to set this up:%0a->[@$group = FmtPageName('$Group', $pagename);%0a$DefaultPasswords['edit'] = 'id:'.$group;%0ainclude_once("$FarmD/scripts/authuser.php"); @]%0aThis automatically gives edit rights to a group to every user who has the same user name as the group name. Unfortunately it also gives edit rights to such a user who is visiting a same-named group not just for pages in that group, but for any page on the wiki that relies on the site's default edit password. This can create security holes.%0a%0aQ: [[#farm]] How come when I switch to another wiki within a farm, I keep my same authorization?%0a%0aA: PmWiki uses PHP sessions to keep track of authentication/authorization information, and by default PHP sets things up such that all interactions with the same server are considered part of the same session.\\%0aFor security considerations about shared session pools, see the "Session injection" chapter in Cookbook:SessionSecurityAdvice.\\%0aTo fix the browser-side convenience issue, one easy way is to make sure each wiki uses a different cookie name for its session identifier. Near the top of one of the wiki's @@local/config.php@@ files, before calling authuser or any other recipes, add a line like:%0a-> [@session_name('XYZSESSID');@]%0aYou can pick any alphanumeric name for XYZSESSID; for example, for the cs559-1 wiki you might choose%0a-> [@session_name('CS559SESSID');@]%0aThis will keep the two wikis' session cookies independent of each other.%0a%0aQ: Is it possible to test the password level for display and/or if condition? Example: [= * (:if WriterPassword:) (display Edit link) (:ifend:) =]%0a%0aA: You can use [@(:if auth edit:)@]. See [[ConditionalMarkup]].%0a%0aQ: [[#condmarkup-secrets]] Can I use [@(:if …:)@] to hide secrets in a wiki page?%0a%0aA: You can, but [[usually that's not secure -> PITS:01417]].%0aThe recommended strategy is to put secrets in a separate page and restrict all read-related¹ access permissions to those users who are allowed to read the secrets.%0aTo display the secrets in another page, you can [[include( other pages)]] (parts of) the secrets page:%0aUsers with read access to the secrets will readily see them, whereas other users see nothing or (at your choosing) some other text, e.g. a login link.%0a-> ¹ Currently (version 2.2.99), these are: @@read@@ (would allow include), @@edit@@ (would show the source), @@attr@@ (would allow to obtain read/edit), @@diff@@ (would allow viewing any change), @@source@@ (allows raw source display)%0a%0aThe reason why [[Conditional Markup]] isn't suitable for access control is that it only applies for rendering wikitext as a web page, and that's just one of many ways to access a page's text.%0aIn order to rely on Conditional Markup for protection of secrets, you'd have to restrict all access methods that can circumvent it.%0aTo do so, you'd need to keep track of all methods available.%0aIn a default installation of PmWiki, some of the easy methods include: Editing a page, viewing its edit history, its source, or [[including fragments of it -> IncludeOtherPages]] into the edit preview of another page. (Preview: To avoid traces in RecentChanges.)%0aHowever, this list is far from exhaustive, and could easily grow with [[Recipes -> Cookbook/]] or future versions of PmWiki.%0a%0a -time=1567166082 +rev=248 +targets=PmWiki.PasswordsAdmin,PmWiki.PmWiki,PmWiki.WikiGroup,Category.Spam,!Spam,PmWiki.Security,PmWiki.AvailableActions,PmWiki.SpecialPages,PmWiki.GroupAttributes,PmWiki.Uploads,SiteAdmin.AuthList,PmWiki.SecurityVariables,PmWiki.AuthUser,Cookbook.SessionSecurityAdvice,PmWiki.ConditionalMarkup,PITS.01417,PmWiki.IncludeOtherPages,Cookbook.Cookbook +text=(:Summary:General use of passwords and login:)(:Audience: authors :)(:Description General use of passwords and login:)%0a%0a[[PmWiki]] has built-in support for password-protecting various areas of the wiki site. Authors generally want to be able to apply passwords to individual pages or to [[wiki group]]s. Wiki Administrators can apply passwords to individual pages, to wiki groups, or to the [[PasswordsAdmin#settingsitewidepasswords|entire site]]. Setting an edit password on a [[#pageattr|page]] or [[#groupattr|group]] (or [[#siteattr|the entire site]]) is one of the most common ways to stop [[!spam]]. As with any access control system, the password protection mechanisms described here are only a small part of overall system and wiki [[security]].%0a%0a!! As an author editing pages...%0aAn author will generally set 3 types of passwords:%0a# to control who can see a page or group, use @@read@@ passwords%0a# to control who can edit a page or group, use @@edit@@ passwords%0a# to control who can alter the passwords used to protect a page or group, use @@attr@@ passwords%0a%0aIf required most [[AvailableActions|page actions]] can be password protected.%0a%0a[[#pageattr]]%0a!!! Protect an individual page%0aTo set a password on an individual wiki page, add the [[AvailableActions|page action]]%0a->@@?action=attr@@ %0ato the page's URL (address) to access its attributes. Using the form on the attributes page, you can set or clear the @@read@@, @@edit@@, or @@attr@@ passwords on the page. In the form you enter the passwords as cleartext; PmWiki encrypts them for you automatically when it stores them. %0a%0aAdditional options:%0a* Leaving a field blank will leave the attribute unchanged. %0a* To remove a password from a page (''reverting back'' to the group's or site's default), enter %0a--> @@ clear @@%0a* To indicate that the page can be edited ''even if a group or site password is set'', enter %0a--> @@ @nopass @@%0a* To lock a page for everybody but the admin, enter %0a--> @@ @lock @@%0a* To assign the site's site-wide passwords to the @@read@@, @@edit@@, @@upload@@, or @@attr@@ password for the page, enter %0a--> @@ @_site_read, @_site_edit, @_site_upload, or @_site_attr @@%0a%0a[[#groupattr]]%0a!!! Protect a wiki group of pages%0aTo set a password on a [[wiki group]] is slightly more difficult -- you just set the passwords on a [[special page(s)]] in each group called %0a->[[GroupAttributes]]%0a%0aFirst, you can get to the attributes page for `GroupAttributes by entering a URL (address) like %0a->[@https://example.com/pmwiki/pmwiki.php?n=GroupName.GroupAttributes?action=attr@]%0aReplace example.com with your domain name, and GroupName with the name of the group%0a%0aThen, using the form on the attributes page, you can set or clear the @@read@@, @@edit@@, or @@attr@@ passwords for the entire group. In the form you enter the passwords as cleartext; PmWiki encrypts them for you automatically.%0a%0aAdditional options:%0a* To remove a password from a group (''reverting back'' to the site's default), enter %0a-->@@clear@@%0a* To indicate that the group can be edited ''even if a site password is set'', enter %0a-->@@@nopass@@%0a* To lock a group for everybody but the admin, enter %0a-->@@@lock@@%0a* (Beginning with Ver 2.2.3) To assign the site's site-wide passwords to the @@read@@, @@edit@@, @@upload@@, or @@attr@@ password for the group, enter %0a--> @@ @_site_read, @_site_edit, @_site_upload, or @site_attr @@%0a%0a%0a!!! Passwords%0aPasswords may consist of any combination of characters, except double "quotes" or 'apostrophes'.%0aPasswords with spaces or colons must be entered using quotes, eg "foo bar" or "foo:bar".%0aObviously longer is [[Wikipedia:Password_strength|better]], and on some systems passwords need to have 4 or more characters.%0a%0a!!! Multiple passwords%0aMultiple passwords for a page, group or site are allowed. %0aSimply enter multiple passwords separated by a space. This allows you to have a read password, a write password, and have the write password allow read/write access. In other words, if the read password is %0a->alpha%0aand the edit password is %0a->beta%0athen enter%0a-> [@Set new read password: alpha beta%0aSet new edit password: beta@]%0a%0aThis says that either %0a->alpha%0aor %0a->beta%0acan be used to read pages, but only %0a->beta%0amay edit. Since PmWiki checks the passwords you've entered since the browser has been opened, entering a read password that is also a write password allows both reading and writing.%0a%0a[[#siteattr]]%0a!!! Protect the site%0aPasswords can be applied to the entire wiki website in ''@@config.php@@''.%0aSee [[PasswordsAdmin#settingsitewidepasswords|passwords]] administration for details.%0a%0a%0a%25audience%25 administrator%0a%0a[[#administrators]]%0a!! As an administrator ...%0a%0aYou can set passwords on pages and groups exactly as described above for authors. You can also:%0a# set site-wide passwords for pages and groups that do not have passwords%0a# use @@attr@@ passwords to control who is able to set passwords on pages%0a# use @@upload@@ passwords to control access to the file [[upload(s)]] capabilities (if uploads are enabled)%0a# use an @@admin@@ password to override the passwords set for any individual page or group%0a# use [[SiteAdmin.AuthList]] to view the permissions settings for pages that have permissions set. %0aFor more information on password options available to administrators, see [[PasswordsAdmin]].%0a%0a!! [[#priority]]Which password wins?%0aIn PmWiki, page passwords override group passwords, group passwords override the ''default'' passwords, and the @@admin@@ password overrides all passwords. This gives a great deal of flexibility in controlling access to wiki pages in PmWiki. %0a%0aThe [[special page(s)]] [[SiteAdmin.AuthList]] is a page list of all pages with access permissions set.%0a%0a!! Opening access to pages in protected groups/sites%0aSometimes we want to "unprotect" pages in a group or site that is otherwise protected. In these cases, the special password %0a->@@ @nopass @@%0ais used to indicate that access should be allowed to a page without requiring a password. %0a%0aFor example, suppose `Main.GroupAttributes has an edit password set, thus restricting the editing of all pages in Main. Now we want `Main.WikiSandbox to be editable without a password. Using %0a->@@clear@@%0afor the edit password for `Main.WikiSandbox ''doesn't unprotect the page'', because the password is being set by the group. Instead, we set the edit password for `Main.WikiSandbox to the special value %0a->@@ @nopass @@%0awhich tells PmWiki to ignore any site-wide or group-level passwords for that page.%0a%0a!! FAQ%0a>>faq%3c%3c [[#faq]]%0a%0a[[#site]]%0aQ: How can I password protect all the pages and groups on my site? Do I really have to set passwords page by page, or group by group?%0a%0aA: Administrators can set passwords for the entire site by editing the @@config.php@@ file; they don't have to set passwords for each page or group. For example, to set the entire site to be editable only by those who know an "edit" password, an administrator can add a line like the following to @@local/config.php@@:%0a%0a-> %25hlt php%25@@ $DefaultPasswords['edit'] = pmcrypt('edit_password'); @@%0a%0aFor more information about the password options that are available only to administrators, see [[PasswordsAdmin]].%0a%0aQ: I get http error 500 "Internal Server Error" when I try to log in. What's wrong?%0a%0aA: This can happen if the encrypted passwords are not created on the web server that hosts the PmWiki.\\%0aThe [[https://www.php.net/crypt|PHP crypt() function]] changed during the PHP development, e.g. a password encrypted with PHP 5.2 can not be decrypted in PHP 5.1, but PHP 5.2 can decrypt passwords created by PHP 5.1.\\%0aThis situation normally happens if you prepare everything on your local machine with the latest PHP version and you upload the passwords to a webserver which is running an older version.\\%0aThe same error occurs when you add encrypted passwords to @@local/config.php@@.%0a%0aSolution: Create the passwords on the system with the oldest PHP version and use them on all other systems.%0a%0aQ: How can I create private groups for users, so that each user can edit pages in their group, but no one else (other than the admin) can?%0a%0aA: Modify the edit attribute for each group to id:username, e.g. set the edit attribute in JaneDoe.GroupAttributes to id:JaneDoe.%0a%0aThere is a more automatic solution, but it's probably not a good idea for most wikis. Administrators can use the [[(PmWiki:)AuthUser]] recipe and add the following few lines to their local/config.php file to set this up:%0a->%25hlt php%25[@$group = FmtPageName('$Group', $pagename);%0a$DefaultPasswords['edit'] = 'id:'.$group;%0ainclude_once("$FarmD/scripts/authuser.php"); @]%0aThis automatically gives edit rights to a group to every user who has the same user name as the group name. Unfortunately it also gives edit rights to such a user who is visiting a same-named group not just for pages in that group, but for any page on the wiki that relies on the site's default edit password. This can create security holes.%0a%0aQ: [[#farm]] How come when I switch to another wiki within a farm, I keep my same authorization?%0a%0aA: PmWiki uses PHP sessions to keep track of authentication/authorization information, and by default PHP sets things up such that all interactions with the same server are considered part of the same session.\\%0aFor security considerations about shared session pools, see the "Session injection" chapter in Cookbook:SessionSecurityAdvice.\\%0aTo fix the browser-side convenience issue, one easy way is to make sure each wiki uses a different cookie name for its session identifier. Near the top of one of the wiki's @@local/config.php@@ files, before calling authuser or any other recipes, add a line like:%0a-> %25hlt php%25[@session_name('XYZSESSID');@]%0aYou can pick any alphanumeric name for XYZSESSID; for example, for the cs559-1 wiki you might choose%0a-> %25hlt php%25[@session_name('CS559SESSID');@]%0aThis will keep the two wikis' session cookies independent of each other.%0a%0aQ: Is it possible to test the password level for display and/or if condition? Example: %25pmhlt%25[= * (:if WriterPassword:) (display Edit link) (:ifend:) =]%0a%0aA: You can use %25pmhlt%25[@(:if auth edit:)@]. See [[ConditionalMarkup]].%0a%0aQ: [[#condmarkup-secrets]] Can I use %25pmhlt%25[@(:if …:)@] to hide secrets in a wiki page?%0a%0aA: You can, but [[usually that's not secure -> PITS:01417]].%0aThe recommended strategy is to put secrets in a separate page and restrict all read-related¹ access permissions to those users who are allowed to read the secrets.%0aTo display the secrets in another page, you can [[include( other pages)]] (parts of) the secrets page:%0aUsers with read access to the secrets will readily see them, whereas other users see nothing or (at your choosing) some other text, e.g. a login link.%0a-> ¹ Currently (version 2.2.99), these are: @@read@@ (would allow include), @@edit@@ (would show the source), @@attr@@ (would allow to obtain read/edit), @@diff@@ (would allow viewing any change), @@source@@ (allows raw source display)%0a%0aThe reason why [[Conditional Markup]] isn't suitable for access control is that it only applies for rendering wikitext as a web page, and that's just one of many ways to access a page's text.%0aIn order to rely on Conditional Markup for protection of secrets, you'd have to restrict all access methods that can circumvent it.%0aTo do so, you'd need to keep track of all methods available.%0aIn a default installation of PmWiki, some of the easy methods include: Editing a page, viewing its edit history, its source, or [[including fragments of it -> IncludeOtherPages]] into the edit preview of another page. (Preview: To avoid traces in @@RecentChanges@@.)%0aHowever, this list is far from exhaustive, and could easily grow with [[Recipes -> Cookbook/]] or future versions of PmWiki.%0a%0a +time=1664785630 blob - f0c7071bf1f93c1da6e3ad7c66647a83209209ca blob + 3de5b85a88f387aaa71b9aae76ad7297af51fd87 --- wikilib.d/PmWiki.PasswordsAdmin +++ wikilib.d/PmWiki.PasswordsAdmin @@ -1,10 +1,10 @@ -version=pmwiki-2.2.118 ordered=1 urlencoded=1 -author=Petko +version=pmwiki-2.3.5 ordered=1 urlencoded=1 +author=simon charset=UTF-8 -csum=add !! FAQ +csum=hlt php, pm hlt (+300) name=PmWiki.PasswordsAdmin post= Save -rev=204 -targets=PmWiki.Passwords,PmWiki.WikiGroup,PmWiki.Security,PmWiki.WikiAdministrator,Category.Spam,PmWiki.AvailableActions,PmWiki.SecurityVariables,PmWiki.AuthUser,PmWiki.PasswordsAdmin,Cookbook.RequireAuthor,Cookbook.ProtectEmail,PmWiki.ConditionalMarkup,Cookbook.HtpasswdForm,Cookbook.UserAuth2,PmWiki.GroupCustomizations,Cookbook.LimitWikiGroups,Cookbook.NewGroupWarning,Cookbook.LimitNewPagesInWikiGroups,Site.AuthForm,Cookbook.CustomAuthForm,Site.AttrForm,Cookbook.CustomAttrForm -text=(:Summary:More password options for the administrator:)(:Audience: administrators (basic) :)%0aPmWiki has built-in support for [[Passwords|password-protecting]] various areas of the wiki site. Passwords can be applied to individual pages, to [[Wiki Group]]s, or to the entire wiki site. Note that the password protection mechanisms described here are only a small part of overall system (and wiki) security, see [[PmWiki.Security]] for more discussion of this.%0a%0aAuthors can use PmWiki to add passwords to individual pages and WikiGroups as described in [[Passwords]]. However, [[WikiAdministrator]]s can also set passwords in ''local/config.php'' as described below. (Please note that one cannot set passwords reliably in per group or per page customization files. See the [[#faq | FAQ section]] for details.)%0a%0a[[#authlevel]]%0a!! Password basics%0a%0aPmWiki supports several levels of access to wiki pages, known as authorisation level:%0a* '''@@read@@''' passwords allow viewing the contents of wiki pages%0a* '''@@edit@@''' passwords control editing and modification of wiki pages (effective against [[!spam]])%0a* '''@@attr@@''' passwords control who is able to set passwords on pages (and potentially other future attributes)%0a* '''@@upload@@''' password, if uploads are enabled, controls uploading of files and attachments%0a* in addition all [[available actions]] can be password authorised%0a* '''@@admin@@''' password allows an administrator to override the passwords set for any individual page or group.%0a%0aBy default, PmWiki has the following password settings:%0a* The @@admin@@ and @@upload@@ passwords are locked by default.%0a* The Main and PmWiki groups have a locked @@attr@@ password (in their respective `GroupAttributes pages).%0a* The pages in the Site group except `Site.SideBar are locked against editing; by default the Site.SideBar page requires the admin or the site-wide edit password.%0a%0aAn @@admin@@ password can be used to overcome "locked" passwords, other than that, no password will allow access.%0a%0aSee [[Passwords]] for information about setting per-page and per-group passwords. %0aThe remainder of this page describes setting site-wide passwords from the ''local/config.php'' file.%0a%0a[[#settingsitewidepasswords]]%0a!! Setting site-wide passwords%0a%0aOne of the first things an admin should do is set an @@admin@@ password for the site. This is done via a line like the following in the ''local/config.php'' file:%0a%0a-> $DefaultPasswords['admin'] = pmcrypt('secret_password');%0a%0aNote that the pmcrypt() call is required for this -- PmWiki stores and processes all passwords internally as encrypted strings. %25note%25 See the [[#crypt | crypt section]] below for details about eliminating the cleartext password from the configuration file.%25%25%0a%0aTo set the entire site to be editable only by those who know an "edit" password, add a line like the following to ''local/config.php'':%0a%0a-> $DefaultPasswords['edit'] = pmcrypt('edit_password');%0a%0aSimilarly, you can set a password for any [[available action(s)]], via [@$DefaultPasswords['read']@], [@$DefaultPasswords['edit']@], and [@$DefaultPasswords['upload']@] to control default @@read@@, @@edit@@, and @@upload@@ passwords for the entire site. The default passwords are used for pages and groups which do not have passwords set, and as additional passwords for pages and groups which do have passwords set. Also, each of the $DefaultPasswords values may be arrays of encrypted passwords:%0a%0a-> $DefaultPasswords['read'] = array(pmcrypt('alpha'), pmcrypt('beta'));%0a-> $DefaultPasswords['edit'] = pmcrypt('beta');%0a%0aThis says that either "alpha" or "beta" can be used to read pages, but only the "beta" password will allow someone to edit a page. Since PmWiki remembers any passwords entered during the current session, the "beta" password will allow both reading and writing of pages, while the "alpha" password allows reading only. A person without either password would be unable to view pages at all.%0a%0aTo lock an action so that only admins can perform it, use @@'@lock'@@ as the value, without @@pmcrypt@@:%0a%0a-> $DefaultPasswords['edit'] = '@lock';%0a%0a%0a!! Setting passwords by reference%0a%25note%25 This is an unintended feature.%0a%0aSetting passwords by reference allows you to change the password for a whole set of pages as easily as you can change site-wide passwords. (Otherwise you would have to update each page's attributes individually.) Enter in the [[Passwords#pageattr|Page Attributes]] or [[Passwords#groupattr|Group Attributes]]:%0a-> @_site_MyLevel2%0a%0aAnd in the local configuration file set the actual password with lines like this:%0a-> $DefaultPasswords['MyLevel2'] = array(pmcrypt('secret'), '@admins');%0a-> $DefaultPasswords['MyLevel9'] = array('$1$NuBV/Mcc$GG3J60h.TLczUTRKhoVPM.');%0a%0aNote that passwords set by reference in a configuration file currently can not be used as a site-wide default. However, you could explicitly specify your @_site_level at the group level for every group to achieve the same effect. Once specified as a group attribute, the password applies to all pages in the group unless overridden, just like any other password. %0a%0a!! Identity-based authorization (username/password logins, [[AuthUser]])%0a%0aUnlike many systems which have '''identity-based''' systems for controlling access to pages (e.g., using a separate ''username'' and ''password'' for each person), PmWiki defaults to a ''password-based'' system as described above. In general password-based systems are often easier to maintain because they avoid the administrative overheads of creating user accounts, recovering lost passwords, and mapping usernames to permitted actions.%0a%0aHowever, PmWiki's ''authuser.php'' script augments the password-based system to allow access to pages based on a username and password combination. See [[AuthUser]] for more details on controlling access to pages based on user identity.%0a%0a!!Security holes ...%0a%0aAdministrators need to carefully plan where passwords are applied to avoid opening inadvertent security holes. If your wiki is open (anyone can read and edit), this would not seem to be a concern, '''except''', a malicious or confused user could apply a read password to a group and make the group completely unavailable to all other users. At the very least, even an open wiki should have a site-wide "admin" password and a site-wide "attr" password set in config.php. The ''sample-config.php'' file distributed with PmWiki indicates that the PmWiki and Main groups have "attr" locked by default, but if anyone creates a new group, "attr" is unlocked. Administrators must remember to set "attr" passwords for each new group (if desired) in this case. An easier solution is to include these lines in ''config.php'' :%0a%0a-> [@%0a$DefaultPasswords['admin'] = pmcrypt('youradminpassword');%0a$DefaultPasswords['attr'] = pmcrypt('yourattrpassword');%0a@]%0a%0a!! Encrypting passwords in ''config.php'' [[#crypt]]%0a%0aOne drawback to using the pmcrypt() function directly to set passwords in ''config.php'' is that anyone able to view the file will see the unencrypted password. For example, if ''config.php'' contains%0a%0a-> $DefaultPasswords['admin'] = pmcrypt('mysecret');%0a%0athen the "mysecret" password is in plain text for others to see. However, a wiki administrator can obtain and use an encrypted form of the password directly by using [@?action=crypt@] on any PmWiki url on the target wiki (or just jump to [[{$Name}?action=crypt]] on your own wiki). This action presents a form that generates encrypted versions of passwords for use in the ''config.php'' file. For example, when [@?action=crypt@] is given the password "@@mysecret@@", PmWiki will return a string like%0a%0a-> [@$1$hMMhCdfT$mZSCh.BJOidMRn4SOUUSi1@]%0a%0aThe string returned from [@?action=crypt@] can then be placed directly into config.php, as in:%0a%0a-> $DefaultPasswords['admin'] = [='$1$hMMhCdfT$mZSCh.BJOidMRn4SOUUSi1'=];%0a%0aNote that in the encrypted form the ''pmcrypt'' function and parentheses are removed, since the password is already encrypted. Also, the encrypted password must be in single quotes. In this example the password is still "@@mysecret@@", but somebody looking at ''config.php'' won't be able to see that just from looking at the encrypted form. ''?action=crypt'' may give you different encryptions for the same password--this is normal (and makes it harder for someone else to determine the original password).%0a%0aPlease note that the encrypted password should be created with ?action=crypt on the wiki that will use it. A password encrypted on one system may or may not be usable on another.%0a%0a!! Removing passwords%0a%0aTo remove a site password entirely, such as the default locked password for uploads, just set it to empty:%0a%0a-> $DefaultPasswords['upload'] = '';%0a%0aYou can also use the special password "@nopass" via @@?action=attr@@ to have a non-password protected page within a password-protected group, or a non-password protected group with a site-wide default password set.%0a%0a!! Revoking or invalidating passwords%0a%0aIf a password is compromised and the wiki administrator wants to quickly invalidate all uses of that password on a site, a quick solution is the following in ''local/config.php'':%0a%0a-> [@%0a$ForbiddenPasswords = array('secret', 'tanstaafl');%0aif (in_array(@$_POST['authpw'], $ForbiddenPasswords)) %0a unset($_POST['authpw']);%0a@]%0a%0aThis prevents "secret" and "tanstaafl" from ever being accepted as a%0avalid authorization password, regardless of what pages may be%0ausing it.%0a%0a!! See Also%0a%0a* The $HandleAuth array, which sets the required authentication level that is necessary to perform an action.%0a* [[Cookbook:RequireAuthor]]%0a%0a[[#protectingactions]]%0a!! Protecting actions (example)%0a%0aEach [[(available) action(s)]] can be password protected. Cookbook authors providing scripts with own actions can use this also, but I'll limit the example to a (by default) not protected [@?action=source@]. This action shows the wikisource of the actual page. Sometimes you don't want that especially to [[Cookbook:protect email]] or when using some [[PmWiki/conditional markup]] which should not be discovered easily or only by persons that are allowed to edit the page.%0a%0aThere are several solutions for that:%0a# Limit "source" only to editors add the following to your ''local/config.php'':%0a %0a--> [@$HandleAuth['source'] ='edit';@]%0a%0a# For using "source" with an own password, then add:%0a%0a--> [@$HandleAuth['source'] ='source';@]%0a--> [@$DefaultPasswords['source'] = pmcrypt('secret');@] # ''see above''%0a%0aIf you additionally want to set the password in the attributes page add:%0a%0a--> [@$PageAttributes['passwdsource'] = "$['Set new source password']";@]%0a%0aIn general, adding the prefix 'passwd' to an action name in the [@$PageAttributes@] array indicates that you wish for the given field to be encrypted when saved to disk.%0a%0aThe full set of steps to add new password handling for an action such as "diff" would be:%0a%0a->[@%0a# add a new (encrypted) field to the attr page%0a$PageAttributes['passwddiff'] = '$[Set new history password:]';%0a%0a# clear the default password for 'diff'%0a$DefaultPasswords['diff'] = '';%0a%0a# Tell PmWiki that the 'diff' password allows action 'diff'.%0a$HandleAuth['diff'] = 'diff';%0a%0a# Tell PmWiki that a 'read' password %0a# (or optionally the 'edit') password%0a# is also sufficient to enable 'diff'.%0a# Of course, the 'admin' password will work too.%0a$AuthCascade['diff'] = 'read'; ## or 'edit'%0a@]%0a%0a!! FAQ%0a>>faq%3c%3c [[#faq]]%0a%0aQ: There seems to be a default password. What is it? [[#pwlocked]]%0aA: There isn't any valid password until you set one. [[#settingsitewidepasswords|Passwords admin]] describes how to set one.%0a%0aPmWiki comes "out of the box" with $DefaultPasswords['admin'] set to '*'. This doesn't mean the password is an asterisk, it means that default admin password has to be something that encrypts to an asterisk. Since it's impossible for the pmcrypt() function to ever return a 1-character encrypted value, the admin password is effectively locked until the admin sets one in config.php.%0a%0aQ: How do I use passwd-formatted files (like .htpasswd) for authentication?%0aA: See [[AuthUser]], Cookbook:HtpasswdForm or Cookbook:UserAuth2.%0a%0aQ: Is there anything I can enter in a GroupAttributes field to say 'same as the admin password'? If not, is there anything I can put into the config.php file to have the same effect?%0a%0aA: Enter '@lock' in GroupAttributes?action=attr to require an admin password for that group.%0a%0aQ: How do I edit protect, say, all RecentChanges pages?%0aA: see [[PmWiki/Security#wikivandalism]].%0a%0aQ: How can I read password protect all pages in a group except the HomePage using configuration files?%0a%0aA: As described in [[PmWiki.GroupCustomizations]] per-group or per-page configuration files should not be used for defining passwords. The reason is that per-group (or per-page) customization files are only loaded for the current page. So, if @@[=$DefaultPasswords['read']=]@@ is set in ''local/GroupA.php'', then someone could use a page in another group to view the contents of pages in GroupA. For example, Main.WikiSandbox could contain:%0a%0a--> [=(:include GroupA.SomePage:)=]%0a%0aand because the ''GroupA.php'' file wasn't loaded (we're looking at Main.WikiSandbox --> ''local/Main.php''), there's no read password set.%0a%0aQ: How can I password protect the creation of new pages?%0aA: See Cookbook:LimitWikiGroups, Cookbook:NewGroupWarning, Cookbook:LimitNewPagesInWikiGroups.%0a%0aQ: How do I change the password prompt screen?%0aA: If your question is about how to make changes to that page... edit [[Site.AuthForm]]. If your question is about how to change which page you are sent to when prompted for a password, you might check out the [[Cookbook:CustomAuthForm]] for help.%0a%0aQ: How do I change the prompt on the attributes (@@?action=attr@@) screen?%0aA: Simply create a new page at [[Site.AttrForm]], and add the following line of code to @@config.php@@:%0a-->@@$PageAttrFmt = 'page:Site.AttrForm';@@%0a%0aNote that this only changes the text above the password inputs on the attributes page, but doesn't change the inputs themselves - the inputs have to be dealt with separately. See [[Cookbook:CustomAttrForm]] for more info.%0a%0aQ: I get http error 500 "Internal Server Error" when I try to log in. What's wrong?%0aA: This can happen if the encrypted passwords are not created on the web server that hosts the PmWiki.\\%0aThe crypt function changed during the PHP development, e.g. a password encrypted with PHP 5.2 can not be decrypted in PHP 5.1, but PHP 5.2 can decrypt passwords created by PHP 5.1.\\%0aThis situation normally happens if you prepare everything on your local machine with the latest PHP version and you upload the passwords to a webserver which is running an older version.\\%0aThe same error occurs when you add encrypted passwords to local/config.php.%0a%0aSolution: Create the passwords on the system with the oldest PHP version and use them on all other systems.%0a%0aQ: I only want users to have to create an 'edit' password, which is automatically used for their 'upload' & 'attr' passwords (without them having to set those independently). How do I do this?%0aA: By setting [@$HandleAuth@] like so:%0a $HandleAuth['upload'] = 'edit';%0a // And to prevent a WikiSandbox from having it's 'attr' permissions changed %0a // except by the admin (but allowing editors to change it on their own pages/group)%0a if(($group=="Site") || ($group=="Main") || ($group=="Category") || %0a ($group=="SiteAdmin") || ($group=="PmWiki") ) {%0a $HandleAuth['attr'] = 'admin'; // for all main admin pages, set 'attr' to 'admin' password%0a } else { %0a $HandleAuth['attr'] = 'edit'; // if you can edit, then you can set attr%0a }%0a%0a -time=1567168221 +rev=206 +targets=PmWiki.Passwords,PmWiki.WikiGroup,PmWiki.Security,PmWiki.WikiAdministrator,Category.Spam,!Spam,PmWiki.AvailableActions,PmWiki.SecurityVariables,PmWiki.AuthUser,PmWiki.PasswordsAdmin,Cookbook.RequireAuthor,Cookbook.ProtectEmail,PmWiki.ConditionalMarkup,Cookbook.HtpasswdForm,Cookbook.UserAuth2,PmWiki.GroupCustomizations,Cookbook.LimitWikiGroups,Cookbook.NewGroupWarning,Cookbook.LimitNewPagesInWikiGroups,Site.AuthForm,Cookbook.CustomAuthForm,Site.AttrForm,Cookbook.CustomAttrForm +text=(:Summary:More password options for the administrator:)(:Audience: administrators (basic) :)%0aPmWiki has built-in support for [[Passwords|password-protecting]] various areas of the wiki site. Passwords can be applied to individual pages, to [[Wiki Group]]s, or to the entire wiki site. Note that the password protection mechanisms described here are only a small part of overall system (and wiki) security, see [[PmWiki.Security]] for more discussion of this.%0a%0aAuthors can use PmWiki to add passwords to individual pages and WikiGroups as described in [[Passwords]]. However, [[WikiAdministrator]]s can also set passwords in ''local/config.php'' as described below. (Please note that one cannot set passwords reliably in per group or per page customization files. See the [[#faq | FAQ section]] for details.)%0a%0a[[#authlevel]]%0a!! Password basics%0a%0aPmWiki supports several levels of access to wiki pages, known as authorisation level:%0a* '''@@read@@''' passwords allow viewing the contents of wiki pages%0a* '''@@edit@@''' passwords control editing and modification of wiki pages (effective against [[!spam]])%0a* '''@@attr@@''' passwords control who is able to set passwords on pages (and potentially other future attributes)%0a* '''@@upload@@''' password, if uploads are enabled, controls uploading of files and attachments%0a* in addition all [[available actions]] can be password authorised%0a* '''@@admin@@''' password allows an administrator to override the passwords set for any individual page or group.%0a%0aBy default, PmWiki has the following password settings:%0a* The @@admin@@ and @@upload@@ passwords are locked by default.%0a* The @@Main@@ and @@PmWiki@@ groups have a locked @@attr@@ password (in their respective `@@GroupAttributes@@ pages).%0a* The pages in the @@Site@@ group except `@@Site.SideBar@@ are locked against editing; by default the @@Site.SideBar@@ page requires the admin or the site-wide edit password.%0a%0aAn @@admin@@ password can be used to overcome "locked" passwords, other than that, no password will allow access.%0a%0aSee [[Passwords]] for information about setting per-page and per-group passwords. %0aThe remainder of this page describes setting site-wide passwords from the ''local/config.php'' file.%0a%0a[[#settingsitewidepasswords]]%0a!! Setting site-wide passwords%0a%0aOne of the first things an admin should do is set an @@admin@@ password for the site. This is done via a line like the following in the ''@@local/config.php@@'' file:%0a%0a-> %25hlt php%25$DefaultPasswords['admin'] = pmcrypt('secret_password');%0a%0aNote that the @@pmcrypt()@@ call is required for this -- PmWiki stores and processes all passwords internally as encrypted strings. %25note%25 See the [[#crypt | crypt section]] below for details about eliminating the cleartext password from the configuration file.%25%25%0a%0aTo set the entire site to be editable only by those who know an "edit" password, add a line like the following to ''@@local/config.php@@'':%0a%0a-> %25hlt php%25$DefaultPasswords['edit'] = pmcrypt('edit_password');%0a%0aSimilarly, you can set a password for any [[available action(s)]], via %25hlt php%25[@$DefaultPasswords['read']@], [@$DefaultPasswords['edit']@], and [@$DefaultPasswords['upload']@] to control default @@read@@, @@edit@@, and @@upload@@ passwords for the entire site. The default passwords are used for pages and groups which do not have passwords set, and as additional passwords for pages and groups which do have passwords set. Also, each of the @@$DefaultPasswords@@ values may be arrays of encrypted passwords:%0a%0a-> %25hlt php%25$DefaultPasswords['read'] = array(pmcrypt('alpha'), pmcrypt('beta'));%0a-> %25hlt php%25$DefaultPasswords['edit'] = pmcrypt('beta');%0a%0aThis says that either "alpha" or "beta" can be used to read pages, but only the "beta" password will allow someone to edit a page. Since PmWiki remembers any passwords entered during the current session, the "beta" password will allow both reading and writing of pages, while the "alpha" password allows reading only. A person without either password would be unable to view pages at all.%0a%0aTo lock an action so that only admins can perform it, use @@'@lock'@@ as the value, without @@pmcrypt()@@:%0a%0a-> %25hlt php%25$DefaultPasswords['edit'] = '@lock';%0a%0a%0a!! Setting passwords by reference%0a%25note%25 This is an unintended feature.%0a%0aSetting passwords by reference allows you to change the password for a whole set of pages as easily as you can change site-wide passwords. (Otherwise you would have to update each page's attributes individually.) Enter in the [[Passwords#pageattr|Page Attributes]] or [[Passwords#groupattr|Group Attributes]]:%0a-> @_site_MyLevel2%0a%0aAnd in the local configuration file set the actual password with lines like this:%0a-> %25hlt php%25$DefaultPasswords['MyLevel2'] = array(pmcrypt('secret'), '@admins');%0a-> %25hlt php%25$DefaultPasswords['MyLevel9'] = array('$1$NuBV/Mcc$GG3J60h.TLczUTRKhoVPM.');%0a%0aNote that passwords set by reference in a configuration file currently can not be used as a site-wide default. However, you could explicitly specify your @_site_level at the group level for every group to achieve the same effect. Once specified as a group attribute, the password applies to all pages in the group unless overridden, just like any other password. %0a%0a!! Identity-based authorization (username/password logins, [[AuthUser]])%0a%0aUnlike many systems which have '''identity-based''' systems for controlling access to pages (e.g., using a separate ''username'' and ''password'' for each person), PmWiki defaults to a ''password-based'' system as described above. In general password-based systems are often easier to maintain because they avoid the administrative overheads of creating user accounts, recovering lost passwords, and mapping usernames to permitted actions.%0a%0aHowever, PmWiki's ''@@authuser.php@@'' script augments the password-based system to allow access to pages based on a username and password combination. See [[AuthUser]] for more details on controlling access to pages based on user identity.%0a%0a!!Security holes ...%0a%0aAdministrators need to carefully plan where passwords are applied to avoid opening inadvertent security holes. If your wiki is open (anyone can read and edit), this would not seem to be a concern, '''except''', a malicious or confused user could apply a read password to a group and make the group completely unavailable to all other users. At the very least, even an open wiki should have a site-wide "admin" password and a site-wide "attr" password set in @@config.php@@. The ''@@sample-config.php@@'' file distributed with PmWiki indicates that the PmWiki and Main groups have "attr" locked by default, but if anyone creates a new group, "attr" is unlocked. Administrators must remember to set "attr" passwords for each new group (if desired) in this case. An easier solution is to include these lines in ''@@config.php@@'' :%0a%0a-> %25hlt php%25[@%0a$DefaultPasswords['admin'] = pmcrypt('youradminpassword');%0a$DefaultPasswords['attr'] = pmcrypt('yourattrpassword');%0a@]%0a%0a!! Encrypting passwords in ''@@config.php@@'' [[#crypt]]%0a%0aOne drawback to using the @@pmcrypt()@@ function directly to set passwords in ''@@config.php@@'' is that anyone able to view the file will see the unencrypted password. For example, if ''@@config.php@@'' contains%0a%0a-> %25hlt php%25$DefaultPasswords['admin'] = pmcrypt('mysecret');%0a%0athen the "mysecret" password is in plain text for others to see. However, a wiki administrator can obtain and use an encrypted form of the password directly by using [@?action=crypt@] on any PmWiki url on the target wiki (or just jump to [[{$Name}?action=crypt]] on your own wiki). This action presents a form that generates encrypted versions of passwords for use in the ''@@config.php@@'' file. For example, when [@?action=crypt@] is given the password "@@mysecret@@", PmWiki will return a string like%0a%0a-> [@$1$hMMhCdfT$mZSCh.BJOidMRn4SOUUSi1@]%0a%0aThe string returned from [@?action=crypt@] can then be placed directly into config.php, as in:%0a%0a-> %25hlt php%25$DefaultPasswords['admin'] = [='$1$hMMhCdfT$mZSCh.BJOidMRn4SOUUSi1'=];%0a%0aNote that in the encrypted form the ''pmcrypt'' function and parentheses are removed, since the password is already encrypted. Also, the encrypted password must be in single quotes. In this example the password is still "@@mysecret@@", but somebody looking at ''@@config.php@@'' won't be able to see that just from looking at the encrypted form. ''@@?action=crypt@@'' may give you different encryptions for the same password--this is normal (and makes it harder for someone else to determine the original password).%0a%0aPlease note that the encrypted password should be created with @@?action=crypt@@ on the wiki that will use it. A password encrypted on one system may or may not be usable on another.%0a%0a!! Removing passwords%0a%0aTo remove a site password entirely, such as the default locked password for uploads, just set it to empty:%0a%0a-> %25hlt php%25$DefaultPasswords['upload'] = '';%0a%0aYou can also use the special password "@nopass" via @@?action=attr@@ to have a non-password protected page within a password-protected group, or a non-password protected group with a site-wide default password set.%0a%0a!! Revoking or invalidating passwords%0a%0aIf a password is compromised and the wiki administrator wants to quickly invalidate all uses of that password on a site, a quick solution is the following in ''@@local/config.php@@'':%0a%0a-> %25hlt php%25[@%0a$ForbiddenPasswords = array('secret', 'tanstaafl');%0aif (in_array(@$_POST['authpw'], $ForbiddenPasswords)) %0a unset($_POST['authpw']);%0a@]%0a%0aThis prevents "secret" and "tanstaafl" from ever being accepted as a%0avalid authorization password, regardless of what pages may be%0ausing it.%0a%0a!! See Also%0a%0a* The $HandleAuth array, which sets the required authentication level that is necessary to perform an action.%0a* [[Cookbook:RequireAuthor]]%0a%0a[[#protectingactions]]%0a!! Protecting actions (example)%0a%0aEach [[(available) action(s)]] can be password protected. Cookbook authors providing scripts with own actions can use this also, but I'll limit the example to a (by default) not protected [@?action=source@]. This action shows the wikisource of the actual page. Sometimes you don't want that especially to [[Cookbook:protect email]] or when using some [[PmWiki/conditional markup]] which should not be discovered easily or only by persons that are allowed to edit the page.%0a%0aThere are several solutions for that:%0a# Limit "source" only to editors add the following to your ''@@local/config.php@@'':%0a %0a--> %25hlt php%25[@$HandleAuth['source'] ='edit';@]%0a%0a# For using "source" with an own password, then add:%0a%0a--> %25hlt php%25[@$HandleAuth['source'] ='source';@]%0a--> %25hlt php%25[@$DefaultPasswords['source'] = pmcrypt('secret');@] # ''see above''%0a%0aIf you additionally want to set the password in the attributes page add:%0a%0a--> %25hlt php%25[@$PageAttributes['passwdsource'] = "$['Set new source password']";@]%0a%0aIn general, adding the prefix 'passwd' to an action name in the [@$PageAttributes@] array indicates that you wish for the given field to be encrypted when saved to disk.%0a%0aThe full set of steps to add new password handling for an action such as "diff" would be:%0a%0a->%25hlt php%25[@%0a# add a new (encrypted) field to the attr page%0a$PageAttributes['passwddiff'] = '$[Set new history password:]';%0a%0a# clear the default password for 'diff'%0a$DefaultPasswords['diff'] = '';%0a%0a# Tell PmWiki that the 'diff' password allows action 'diff'.%0a$HandleAuth['diff'] = 'diff';%0a%0a# Tell PmWiki that a 'read' password %0a# (or optionally the 'edit') password%0a# is also sufficient to enable 'diff'.%0a# Of course, the 'admin' password will work too.%0a$AuthCascade['diff'] = 'read'; ## or 'edit'%0a@]%0a%0a!! FAQ%0a>>faq%3c%3c [[#faq]]%0a%0aQ: There seems to be a default password. What is it? [[#pwlocked]]%0aA: There isn't any valid password until you set one. [[#settingsitewidepasswords|Passwords admin]] describes how to set one.%0a%0aPmWiki comes "out of the box" with @@$DefaultPasswords['admin']@@ set to '*'. This doesn't mean the password is an asterisk, it means that default admin password has to be something that encrypts to an asterisk. Since it's impossible for the @@pmcrypt()@@ function to ever return a 1-character encrypted value, the admin password is effectively locked until the admin sets one in @@config.php@@.%0a%0aQ: How do I use passwd-formatted files (like .htpasswd) for authentication?%0aA: See [[AuthUser]], Cookbook:HtpasswdForm or Cookbook:UserAuth2.%0a%0aQ: Is there anything I can enter in a @@GroupAttributes@@ field to say 'same as the admin password'? If not, is there anything I can put into the @@config.php@@ file to have the same effect?%0a%0aA: Enter '@lock' in @@GroupAttributes?action=attr@@ to require an admin password for that group.%0a%0aQ: How do I edit protect, say, all RecentChanges pages?%0aA: see [[PmWiki/Security#wikivandalism]].%0a%0aQ: How can I read password protect all pages in a group except the @@HomePage@@ using configuration files?%0a%0aA: As described in [[PmWiki.GroupCustomizations]] per-group or per-page configuration files should not be used for defining passwords. The reason is that per-group (or per-page) customization files are only loaded for the current page. So, if %25hlt php%25@@[=$DefaultPasswords['read']=]@@ is set in ''@@local/GroupA.php@@'', then someone could use a page in another group to view the contents of pages in GroupA. For example, @@Main.WikiSandbox@@ could contain:%0a%0a--> %25pmhlt%25[=(:include GroupA.SomePage:)=]%0a%0aand because the ''GroupA.php'' file wasn't loaded (we're looking at Main.WikiSandbox --> ''local/Main.php''), there's no read password set.%0a%0aQ: How can I password protect the creation of new pages?%0aA: See Cookbook:LimitWikiGroups, Cookbook:NewGroupWarning, Cookbook:LimitNewPagesInWikiGroups.%0a%0aQ: How do I change the password prompt screen?%0aA: If your question is about how to make changes to that page... edit [[Site.AuthForm]]. If your question is about how to change which page you are sent to when prompted for a password, you might check out the [[Cookbook:CustomAuthForm]] for help.%0a%0aQ: How do I change the prompt on the attributes (@@?action=attr@@) screen?%0aA: Simply create a new page at [[Site.AttrForm]], and add the following line of code to @@config.php@@:%0a-->@@$PageAttrFmt = 'page:Site.AttrForm';@@%0a%0aNote that this only changes the text above the password inputs on the attributes page, but doesn't change the inputs themselves - the inputs have to be dealt with separately. See [[Cookbook:CustomAttrForm]] for more info.%0a%0aQ: I get http error 500 "Internal Server Error" when I try to log in. What's wrong?%0aA: This can happen if the encrypted passwords are not created on the web server that hosts the PmWiki.\\%0aThe crypt function changed during the PHP development, e.g. a password encrypted with PHP 5.2 can not be decrypted in PHP 5.1, but PHP 5.2 can decrypt passwords created by PHP 5.1.\\%0aThis situation normally happens if you prepare everything on your local machine with the latest PHP version and you upload the passwords to a webserver which is running an older version.\\%0aThe same error occurs when you add encrypted passwords to @@local/config.php@@.%0a%0aSolution: Create the passwords on the system with the oldest PHP version and use them on all other systems.%0a%0aQ: I only want users to have to create an 'edit' password, which is automatically used for their 'upload' & 'attr' passwords (without them having to set those independently). How do I do this?%0aA: By setting [@$HandleAuth@] like so:%0a-> %25hlt php%25[@$HandleAuth['upload'] = 'edit';%0a// And to prevent a WikiSandbox from having it's 'attr' permissions changed %0a// except by the admin (but allowing editors to change it on their own pages/group)%0aif(($group=="Site") || ($group=="Main") || ($group=="Category") || %0a ($group=="SiteAdmin") || ($group=="PmWiki") ) {%0a $HandleAuth['attr'] = 'admin'; // for all main admin pages, set 'attr' to 'admin' password%0a} else { %0a $HandleAuth['attr'] = 'edit'; // if you can edit, then you can set attr%0a}@]%0a%0a +time=1654236291 blob - f22da067363d6b612c10d20edfbd2f324fcbde81 blob + 7934b9b20e348d7b396aee92901e56fa1f189efd --- wikilib.d/PmWiki.PathVariables +++ wikilib.d/PmWiki.PathVariables @@ -1,9 +1,9 @@ -version=pmwiki-2.2.71 ordered=1 urlencoded=1 -author=ff +version=pmwiki-2.3.2 ordered=1 urlencoded=1 +author=Petko charset=UTF-8 -csum=fixed a typo in the markup +csum=$UrlScheme (-2) (+97) name=PmWiki.PathVariables -rev=65 -targets=PmWiki.WhySeeIfCSSExists,Cookbook.SharedPages,Cookbook.CleanUrls,PmWiki.SkinTemplates,Cookbook.PerGroupSubDirectories,PmWiki.LocalCustomizations,PmWiki.PerGroupCustomizations,PmWiki.WikiFarms,PmWiki.LayoutVariables,PmWiki.LinkVariables,PmWiki.EditVariables,PmWiki.UploadVariables -text=(:Summary:variables used to specify various locations on the server:)%0a%0aWhen dealing with file or path variables, one has to recognize the difference between working with URLs and files on disk. For example:%0a* The include() statements are used to include other files (on disk) into the currently running PmWiki script. Thus they require paths on the server's filesystem. %0a* The $ScriptUrl and $PubDirUrl variables are used to tell a ''browser'', connecting via the webserver, how to execute the pmwiki script ($ScriptUrl) and the base url for getting files from PmWiki's pub/ directory ($PubDirUrl).%0a%0aNote that a browser needs a URL (http://example.com/pmwiki/pub) while an include statement requires a server file path ($FarmD/scripts/something.php).%0a%0a:$FarmD: The directory on the server where the farm is located (i.e., the directory containing the farm's copy of ''pmwiki.php'' and the ''scripts/'' directory). This directory is automatically determined by pmwiki.php when it runs, and can be used to distinguish the farm's ''cookbook/'' and ''pub/'' subdirectories from a field's subdirectories.%0a%0a:$FarmPubDirUrl: is the url that refers to the @@pub@@ directory for an entire farm. It defaults to the same value as $PubDirUrl. %0a%0a:$PageCSSListFmt: is an associative array which PmWiki uses to find any local css configuration files. It consists of a set of (''key'',''value'') pairs %25green%25 that point to the same file%25%25. The ''key'' is a possible path to a file on disk holding the css data, while the ''value'' is the coresponding URL for that %25green%25same file%25%25. They keys are tested in turn, and for each named file that exists, the browser is instructed to load the corresponding URL. This allows for PMWiki to only load the css file if it exists. ([[PmWiki:WhySeeIfCSSExists|Why see if a CSS exists?]]) The default value for this variable is:%0a%0a->[@%0a$PageCSSListFmt = array(%0a 'pub/css/local.css' => '$PubDirUrl/css/local.css',%0a 'pub/css/{$Group}.css' => '$PubDirUrl/css/{$Group}.css',%0a 'pub/css/{$FullName}.css' => '$PubDirUrl/css/{$FullName}.css');%0a@]%0a%0a->Note that the default (as of version pmwiki-2.1.beta26) makes no reference to $FarmPubDirUrl for css configuration files. If you wish to be able to place css configuration files in both the field's @@pub@@ directory, and the farm's @@pub@@ directory, you may want to add these lines to your @@local/config.php@@ file (as described in [[Cookbook:SharedPages]]):%0a%0a-> %25green%25# this adds farm.css to all wikis%0a->[@%0a$PageCSSListFmt = array(%0a '$FarmD/pub/css/farm.css' => '$FarmPubDirUrl/css/farm.css',%0a 'pub/css/local.css' => '$PubDirUrl/css/local.css',%0a 'pub/css/$Group.css' => '$PubDirUrl/css/$Group.css',%0a 'pub/css/$FullName.css' => '$PubDirUrl/css/$FullName.css');%0a@]%0a%0a-> %25green%25# this enables farm css files in a similar manner to a local wiki%0a->[@%0a$PageCSSListFmt = array(%0a '$FarmD/pub/css/local.css' => '$FarmPubDirUrl/css/local.css',%0a '$FarmD/pub/css/$Group.css' => '$FarmPubDirUrl/css/$Group.css',%0a '$FarmD/pub/css/$FullName.css' => '$FarmPubDirUrl/css/$FullName.css',%0a 'pub/css/local.css' => '$PubDirUrl/css/local.css',%0a 'pub/css/$Group.css' => '$PubDirUrl/css/$Group.css',%0a 'pub/css/$FullName.css' => '$PubDirUrl/css/$FullName.css');%0a@]%0a%0a->Note the difference between CSS configuration files and CSS files associated with a skin. Skin files, including associated CSS, can be put in either the farm or the field @@pub/skins@@ directory, and the program will find them.%0a%0a:$PubDirUrl: is the URL that refers to the @@pub@@ directory. That directory contains all the files and subdirectories that must be directly accessible from a browser (e.g. CSS and HTML files). Most prominent here is the @@skins@@ subdirectory.%0a->The following may work for you'^[[Cookbook:CleanUrls#multiviews|#]]^'%0a->[@ $ScriptUrl = 'http://'.$_SERVER['HTTP_HOST'].'/pmwiki/pmwiki.php';%0a $PubDirUrl = 'http://'.$_SERVER['HTTP_HOST'].'/pmwiki/pub';@]%0a%0a%25rfloat%25{$ScriptUrl}%0a:$ScriptUrl: is the URL that you want people's browsers to use when accessing PmWiki, either as a field or farm. It's used whenever PmWiki needs to generate a link to another PmWiki page or action. PmWiki is usually fairly good about "guessing" the correct value for $ScriptUrl on its own, but sometimes an admin needs to set it explicitly because of URL manipulations by the webserver (such as Cookbook:CleanUrls, mod_rewrite, bizarre PHP configurations, and so on).%0a%0a:$SkinDir:Set by ''scripts/skins.php'' to be the base url of the current skin's directory (i.e., within a 'pub/skins/' directory). This variable is typically used inside of a skin .tmpl file to provide access to .css files and graphic images associated with the skin. See [[SkinTemplates#security|security note]] regarding use.%0a%0a:$SkinDirUrl:Set by ''scripts/skins.php'' to be the base path of the current skin's directory (i.e., within a 'pub/skins/' directory). This variable is typically used inside of a skin .tmpl file to provide access to secondary files. See [[SkinTemplates#security|security note]] regarding use.%0a%0a:$WorkDir: This variable is a string that gives a local path to a directory where the pmwiki engine can create temporary files etc. %0a: :PmWiki needs this for a variety of things, such as building merged edits, caching mailposts entries, keeping track of the last modification time of the site, other types of cache, etc. Do not confuse this variable with $WikiDir; the reason that both $WorkDir and $WikiDir refer by default to the directory [@wiki.d/@] is merely to simplify things for the administrator. %0a%0a:$WikiDir: A `PageStore-object that refers to how wiki pages are stored. %0a: :This can be a simple reference to a directory (typically ''wiki.d/''), or something more advanced such as a `MySQL backend or a .dbm-file. Do not confuse this variable with $WorkDir; the reason that both $WorkDir and $WikiDir refer by default to the directory [@wiki.d/@] is merely to simplify things for the administrator.%0a: :To store groups of pages in subdirectories add [@$WikiDir = new PageStore('wiki.d/$Group/$FullName');@] to the start of your config file. '^[[Cookbook:PerGroupSubDirectories|#]]^'%0a%0a:$WikiLibDirs: An array of `PageStore objects that specify where to look for pages. %0a: :By default it is set up to look in ''wiki.d/'' and ''wikilib.d/'', but can be changed to look other places. %0a: :For example, to exclude the pages that are bundled in the PmWiki distribution, use the line below. (Note that some features such as editing and search rely on having certain pages available, so you may need to copy them to the $WikiDir.)%0a->[@$WikiLibDirs = array(&$WikiDir); @]%0a: :Another example%0a->[@%0a ## for any page name, use the version located in wiki.d if it exists,%0a ## use the version located in wikilib2.d, if a wiki.d version does not, and%0a ## the version located in wikilib.d, if neither of the above exists%0a $WikiLibDirs = array(&$WikiDir,%0a new PageStore('wikilib2.d/{$FullName}'),%0a new PageStore('$FarmD/wikilib.d/{$FullName}'));%0a@]%0a: : See also [[(http://www.pmwiki.org/wiki/Category/)CustomPageStore]].%0a%0a%0a:$LocalDir: The filesystem location of the ''local/'' directory, holding [[local customization(s)]] and [[(PmWiki:)per group customizations]] files. Typically set in a [[WikiFarm(s)]]'s ''farmconfig.php''. (Note that farm configuration files always occur in ''$FarmD/local/farmconfig.php'', regardless of any setting for $LocalDir.)%0a%0a%0a!!See also%0a* [[Layout Variables]] for URL layout options%0a* [[Link Variables]] - variables that control the display of links in pages%0a* [[Edit Variables]] - variables used when editing pages%0a* [[Upload Variables]] - variables used for uploads/attachments -time=1420736312 +rev=70 +targets=PmWiki.PathVariables,PmWiki.WhySeeIfCSSExists,Cookbook.SharedPages,Cookbook.CleanUrls,PmWiki.SkinTemplates,Cookbook.PerGroupSubDirectories,PmWiki.LocalCustomizations,PmWiki.PerGroupCustomizations,PmWiki.WikiFarms,PmWiki.LayoutVariables,PmWiki.LinkVariables,PmWiki.EditVariables,PmWiki.UploadVariables +text=(:Summary:variables used to specify various locations on the server:)%0a%0aWhen dealing with file or path variables, one has to recognize the difference between working with URLs and files on disk. For example:%0a* The include() statements are used to include other files (on disk) into the currently running PmWiki script. Thus they require paths on the server's filesystem. %0a* The $ScriptUrl and $PubDirUrl variables are used to tell a ''browser'', connecting via the webserver, how to execute the pmwiki script ($ScriptUrl) and the base url for getting files from PmWiki's pub/ directory ($PubDirUrl).%0a%0aNote that a browser needs a URL (https://example.com/pmwiki/pub) while an include statement requires a server file path ($FarmD/scripts/something.php).%0a%0a:$FarmD: The directory on the server where the farm is located (i.e., the directory containing the farm's copy of ''pmwiki.php'' and the ''scripts/'' directory). This directory is automatically determined by pmwiki.php when it runs, and can be used to distinguish the farm's ''cookbook/'' and ''pub/'' subdirectories from a field's subdirectories.%0a%0a:$UrlScheme: Contains either "http" or "https", the currently used protocol to access the wiki.%0a%0a:$FarmPubDirUrl: is the url that refers to the @@pub@@ directory for an entire farm. It defaults to the same value as $PubDirUrl. %0a%0a:$PageCSSListFmt: is an associative array which PmWiki uses to find any local css configuration files. It consists of a set of (''key'',''value'') pairs %25green%25 that point to the same file%25%25. The ''key'' is a possible path to a file on disk holding the css data, while the ''value'' is the coresponding URL for that %25green%25same file%25%25. They keys are tested in turn, and for each named file that exists, the browser is instructed to load the corresponding URL. This allows for PMWiki to only load the css file if it exists. ([[PmWiki:WhySeeIfCSSExists|Why see if a CSS exists?]]) The default value for this variable is:%0a%0a->[@%0a$PageCSSListFmt = array(%0a 'pub/css/local.css' => '$PubDirUrl/css/local.css',%0a 'pub/css/{$Group}.css' => '$PubDirUrl/css/{$Group}.css',%0a 'pub/css/{$FullName}.css' => '$PubDirUrl/css/{$FullName}.css');%0a@]%0a%0a->Note that the default (as of version pmwiki-2.1.beta26) makes no reference to $FarmPubDirUrl for css configuration files. If you wish to be able to place css configuration files in both the field's @@pub@@ directory, and the farm's @@pub@@ directory, you may want to add these lines to your @@local/config.php@@ file (as described in [[Cookbook:SharedPages]]):%0a%0a-> %25green%25# this adds farm.css to all wikis%0a->[@%0a$PageCSSListFmt = array(%0a '$FarmD/pub/css/farm.css' => '$FarmPubDirUrl/css/farm.css',%0a 'pub/css/local.css' => '$PubDirUrl/css/local.css',%0a 'pub/css/$Group.css' => '$PubDirUrl/css/$Group.css',%0a 'pub/css/$FullName.css' => '$PubDirUrl/css/$FullName.css');%0a@]%0a%0a-> %25green%25# this enables farm css files in a similar manner to a local wiki%0a->[@%0a$PageCSSListFmt = array(%0a '$FarmD/pub/css/local.css' => '$FarmPubDirUrl/css/local.css',%0a '$FarmD/pub/css/$Group.css' => '$FarmPubDirUrl/css/$Group.css',%0a '$FarmD/pub/css/$FullName.css' => '$FarmPubDirUrl/css/$FullName.css',%0a 'pub/css/local.css' => '$PubDirUrl/css/local.css',%0a 'pub/css/$Group.css' => '$PubDirUrl/css/$Group.css',%0a 'pub/css/$FullName.css' => '$PubDirUrl/css/$FullName.css');%0a@]%0a%0a->Note the difference between CSS configuration files and CSS files associated with a skin. Skin files, including associated CSS, can be put in either the farm or the field @@pub/skins@@ directory, and the program will find them.%0a%0a:$PubDirUrl: is the URL that refers to the @@pub@@ directory. That directory contains all the files and subdirectories that must be directly accessible from a browser (e.g. CSS and HTML files). Most prominent here is the @@skins@@ subdirectory.%0a->The following may work for you'^[[Cookbook:CleanUrls#multiviews|#]]^'%0a->[@ $ScriptUrl = 'http://'.$_SERVER['HTTP_HOST'].'/pmwiki/pmwiki.php';%0a $PubDirUrl = 'http://'.$_SERVER['HTTP_HOST'].'/pmwiki/pub';@]%0a%0a%25rfloat%25{$ScriptUrl}%0a:$ScriptUrl: is the URL that you want people's browsers to use when accessing PmWiki, either as a field or farm. It's used whenever PmWiki needs to generate a link to another PmWiki page or action. PmWiki is usually fairly good about "guessing" the correct value for $ScriptUrl on its own, but sometimes an admin needs to set it explicitly because of URL manipulations by the webserver (such as Cookbook:CleanUrls, mod_rewrite, bizarre PHP configurations, and so on).%0a%0a:$SkinDir:Set by ''scripts/skins.php'' to be the base url of the current skin's directory (i.e., within a 'pub/skins/' directory). This variable is typically used inside of a skin .tmpl file to provide access to .css files and graphic images associated with the skin. See [[SkinTemplates#security|security note]] regarding use.%0a%0a:$SkinDirUrl:Set by ''scripts/skins.php'' to be the base path of the current skin's directory (i.e., within a 'pub/skins/' directory). This variable is typically used inside of a skin .tmpl file to provide access to secondary files. See [[SkinTemplates#security|security note]] regarding use.%0a%0a:$WorkDir: This variable is a string that gives a local path to a directory where the pmwiki engine can create temporary files etc. %0a: :PmWiki needs this for a variety of things, such as building merged edits, caching mailposts entries, keeping track of the last modification time of the site, other types of cache, etc. Do not confuse this variable with $WikiDir; the reason that both $WorkDir and $WikiDir refer by default to the directory [@wiki.d/@] is merely to simplify things for the administrator. %0a%0a:$WikiDir: A `PageStore-object that refers to how wiki pages are stored. %0a: :This can be a simple reference to a directory (typically ''wiki.d/''), or something more advanced such as a `MySQL backend or a .dbm-file. Do not confuse this variable with $WorkDir; the reason that both $WorkDir and $WikiDir refer by default to the directory [@wiki.d/@] is merely to simplify things for the administrator.%0a: :To store groups of pages in subdirectories add [@$WikiDir = new PageStore('wiki.d/$Group/$FullName');@] to the start of your config file. '^[[Cookbook:PerGroupSubDirectories|#]]^'%0a%0a:$WikiLibDirs: An array of `PageStore objects that specify where to look for pages. %0a: :By default it is set up to look in ''wiki.d/'' and ''wikilib.d/'', but can be changed to look other places. %0a: :For example, to exclude the pages that are bundled in the PmWiki distribution, use the line below. (Note that some features such as editing and search rely on having certain pages available, so you may need to copy them to the $WikiDir.)%0a->[@$WikiLibDirs = array(&$WikiDir); @]%0a: :Another example%0a->[@%0a ## for any page name, use the version located in wiki.d if it exists,%0a ## use the version located in wikilib2.d, if a wiki.d version does not, and%0a ## the version located in wikilib.d, if neither of the above exists%0a $WikiLibDirs = array(&$WikiDir,%0a new PageStore('wikilib2.d/{$FullName}'),%0a new PageStore('$FarmD/wikilib.d/{$FullName}'));%0a@]%0a: : See also [[(https://www.pmwiki.org/wiki/Category/)CustomPageStore]].%0a%0a%0a:$LocalDir: The filesystem location of the ''local/'' directory, holding [[local customization(s)]] and [[(PmWiki:)per group customizations]] files. Typically set in a [[WikiFarm(s)]]'s ''farmconfig.php''. (Note that farm configuration files always occur in ''$FarmD/local/farmconfig.php'', regardless of any setting for $LocalDir.)%0a%0a%0a!!See also%0a* [[Layout Variables]] for URL layout options%0a* [[Link Variables]] - variables that control the display of links in pages%0a* [[Edit Variables]] - variables used when editing pages%0a* [[Upload Variables]] - variables used for uploads/attachments +time=1645302738 blob - 9e616e0ec033d7d416198fd192317f659f620c32 blob + 1e0df9f742c977b033873e78c58bdfcd2ab402c5 --- wikilib.d/PmWiki.PmWiki +++ wikilib.d/PmWiki.PmWiki @@ -7,5 +7,5 @@ name=PmWiki.PmWiki passwdattr=@lock rev=126 targets=PmWiki.WikiWikiWeb,Main.WikiSandbox,PmWiki.BasicEditing,PmWiki.Skins,PmWiki.PmWikiPhilosophy,Cookbook.Cookbook,PmWiki.Installation -text=PmWiki is a [[wiki(WikiWeb)]]-based content-management system (CMS) for collaborative creation and maintenance of websites.%0a%0aPmWiki pages look and act like normal web pages, except they have an "[[Main/WikiSandbox?action=edit|Edit]]" link that makes it easy to modify existing pages and add new pages into the website, using [[basic editing]] rules. You do not need to know or use any HTML or CSS. Page editing can be left open to the public or restricted to small groups of authors.%0a%0a!!Key PmWiki Features%0a%0a-%3c'''Custom look-and-feel''': A site administrator can quickly change the appearance and functions of a PmWiki site by using different [[skins]] and HTML templates. If you can't find an appropriate skin [[http://www.pmwiki.org/wiki/Skins/Skins|already made]], you can easily modify one or create your own.%0a%0a-%3c'''Access control''': PmWiki password protection can be applied to an entire site, to groups of pages, or to individual pages. Password protection controls who can read pages, edit pages, and upload attachments. PmWiki's access control system is completely self-contained, but it can also work in conjunction with existing password databases, such as ''.htaccess'', LDAP servers, and MySQL databases.%0a%0a-%3c'''Customization and plugin architecture''': One principle of the [[PmWikiPhilosophy]] is to only include essential features in the core engine, but make it easy for administrators to customize and add new markup. Hundreds of features are already available by using extensions (called "recipes") that are available from the PmWiki [[(Cookbook:)Cookbook]].%0a%0aPmWiki is written in %25newwin%25[[http://php.net/|PHP]] and distributed under the %25newwin%25[[http://www.gnu.org/copyleft/gpl.html|General Public License]]. It is designed to be simple to [[PmWiki/Installation|install]], customize, and maintain for a variety of applications. This site is running {$Version}.%0a%0aPmWiki is a registered trademark of [[http://www.pmichaud.com/ | Patrick R. Michaud ]]. Since January 2009 PmWiki is actively maintained by [[http://www.pmwiki.org/petko|Petko Yotov]] under the oversight of Dr Michaud.%0a%0aPmWiki's home on the web is at [[(http://)www.pmwiki.org(/)]].%0a +text=PmWiki is a [[wiki(WikiWeb)]]-based content-management system (CMS) for collaborative creation and maintenance of websites.%0a%0aPmWiki pages look and act like normal web pages, except they have an "[[Main/WikiSandbox?action=edit|Edit]]" link that makes it easy to modify existing pages and add new pages into the website, using [[basic editing]] rules. You do not need to know or use any HTML or CSS. Page editing can be left open to the public or restricted to small groups of authors.%0a%0a!!Key PmWiki Features%0a%0a-%3c'''Custom look-and-feel''': A site administrator can quickly change the appearance and functions of a PmWiki site by using different [[skins]] and HTML templates. If you can't find an appropriate skin [[https://www.pmwiki.org/wiki/Skins/Skins|already made]], you can easily modify one or create your own.%0a%0a-%3c'''Access control''': PmWiki password protection can be applied to an entire site, to groups of pages, or to individual pages. Password protection controls who can read pages, edit pages, and upload attachments. PmWiki's access control system is completely self-contained, but it can also work in conjunction with existing password databases, such as ''.htaccess'', LDAP servers, and MySQL databases.%0a%0a-%3c'''Customization and plugin architecture''': One principle of the [[PmWikiPhilosophy]] is to only include essential features in the core engine, but make it easy for administrators to customize and add new markup. Hundreds of features are already available by using extensions (called "recipes") that are available from the PmWiki [[(Cookbook:)Cookbook]].%0a%0aPmWiki is written in %25newwin%25[[https://php.net/|PHP]] and distributed under the %25newwin%25[[https://www.gnu.org/copyleft/gpl.html|General Public License]]. It is designed to be simple to [[PmWiki/Installation|install]], customize, and maintain for a variety of applications. This site is running {$Version}.%0a%0aPmWiki is a registered trademark of [[https://www.pmichaud.com/ | Patrick R. Michaud ]]. Since January 2009 PmWiki is actively maintained by [[https://www.pmwiki.org/petko|Petko Yotov]] under the oversight of Dr Michaud.%0a%0aPmWiki's home on the web is at [[(https://)www.pmwiki.org(/)]].%0a time=1359922077 blob - e7408432785b8a1d574efe977ec334489176bca3 blob + c99a97f8dfefb511eebdbb71f4fdcdd6c255011e --- wikilib.d/PmWiki.RefCount +++ wikilib.d/PmWiki.RefCount @@ -1,10 +1,9 @@ -version=pmwiki-2.2.30 ordered=1 urlencoded=1 -agent=Mozilla/5.0 (X11; Linux x86_64; rv:5.0) Gecko/20100101 Firefox/5.0 -author=Petko +version=pmwiki-2.3.5 ordered=1 urlencoded=1 +author=simon charset=UTF-8 -csum=refactored +csum=hlt php (+9) name=PmWiki.RefCount -rev=38 +rev=39 targets=PmWiki.WikiAdministrator,PmWiki.LocalCustomizations,PmWiki.RefCount -text=(:Summary: Link references counts on pages:)%0aRefCount performs link reference counts on pages in the PmWiki database (i.e., counts of links between pages). Before using RefCount, it must be enabled by the [[wiki administrator]] by placing the following line in a [[local customization(s)]] file:%0a%0a->[@include_once("$FarmD/scripts/refcount.php");@]%0a%0aTo use refcount add [@?action=refcount@] to the URL of any wiki page to bring up the reference count form. For example:%0a%0a->%25newwin%25[[{$FullName}?action=refcount]]%0a%0aThe refcount form contains the following controls:%0a[[#refcountcontrols]]%0a*'''Show''' ~ This selects which pages will appear in the output%0a**all ~ Shows all references %0a**missing ~ Shows only references to pages that don't exist%0a**existing ~ Shows only references to pages that do exist%0a**orphaned ~ Shows pages that exist but don't have any references to them. There is no way to browse to an orphaned page.%0a*'''page names in group''' ~ Selects which group(s) to the referenced pages can be in%0a*'''referenced from pages in''' ~ Selects which group(s) the referencing pages can be in%0a*'''Display referencing pages''' ~ Includes a link to the referencing page -- this can make for a very long output unless you limit the groups searched%0a[[#refcountcontrolsend]]%0a%0aThe output is a table where each row of the table contains a page name or link reference, the number of (non-RecentChanges) pages that contain links to the page and the number of Recent Changes pages with links to the page.%0a%0a -time=1315670897 +text=(:Summary: Link references counts on pages:)%0aRefCount performs link reference counts on pages in the PmWiki database (i.e., counts of links between pages). Before using RefCount, it must be enabled by the [[wiki administrator]] by placing the following line in a [[local customization(s)]] file:%0a%0a->%25hlt php%25[@include_once("$FarmD/scripts/refcount.php");@]%0a%0aTo use refcount add [@?action=refcount@] to the URL of any wiki page to bring up the reference count form. For example:%0a%0a->%25newwin%25[[{$FullName}?action=refcount]]%0a%0aThe refcount form contains the following controls:%0a[[#refcountcontrols]]%0a*'''Show''' ~ This selects which pages will appear in the output%0a**all ~ Shows all references %0a**missing ~ Shows only references to pages that don't exist%0a**existing ~ Shows only references to pages that do exist%0a**orphaned ~ Shows pages that exist but don't have any references to them. There is no way to browse to an orphaned page.%0a*'''page names in group''' ~ Selects which group(s) to the referenced pages can be in%0a*'''referenced from pages in''' ~ Selects which group(s) the referencing pages can be in%0a*'''Display referencing pages''' ~ Includes a link to the referencing page -- this can make for a very long output unless you limit the groups searched%0a[[#refcountcontrolsend]]%0a%0aThe output is a table where each row of the table contains a page name or link reference, the number of (non-RecentChanges) pages that contain links to the page and the number of Recent Changes pages with links to the page.%0a%0a +time=1653632997 blob - 26eb569e2aef4125ce973a179da615cc93394c33 blob + a13d301a7bb0b8e5031cc5c70f96afae64055adb --- wikilib.d/PmWiki.ReleaseNotes +++ wikilib.d/PmWiki.ReleaseNotes @@ -1,10 +1,10 @@ -version=pmwiki-2.2.129 ordered=1 urlencoded=1 +version=pmwiki-2.3.19 ordered=1 urlencoded=1 author=Petko charset=UTF-8 -csum=Version 2.2.130 (2020-07-04) * Update documentation. (+99) +csum=2.3.20 (+141) name=PmWiki.ReleaseNotes -rev=694 -targets=PmWiki.Upgrades,PmWiki.ChangeLog,PmWiki.Download,PmWiki.RoadMap,Skins.SkinChange,PmWiki.LayoutVariables,Cookbook.ToggleNext,PmWiki.SecurityVariables,PmWiki.Forms,PmWiki.TableOfContents,Cookbook.SectionEdit,Cookbook.RecipeCheck,PmWiki.OtherVariables,PmWiki.BlockMarkup,Cookbook.DeObMail,Cookbook.FixURL,PmWiki.EditVariables,Cookbook.NotSavedWarning,Cookbook.EditHelp,Cookbook.AutoTOC,Cookbook.DeltaBytesRecentChanges,Cookbook.RowspanInSimpleTables,Cookbook.LocalCSS,PmWiki.LinkVariables,Cookbook.PreviewChanges,PmWiki.PagelistVariables,PmWiki.MarkupExpressions,PmWiki.DebugVariables,PmWiki.Notify,PmWiki.BasicVariables,PmWiki.WikiTrails,SiteAdmin.AuthList,PmWiki.PathVariables,Site.UploadQuickReference,Cookbook.PmForm,PmWiki.Troubleshooting,PmWiki.CustomMarkup,PmWiki.PageDirectives,PmWiki.UploadVariables,PmWiki.I18nVariables,PmWiki.PageHistory,PmWiki.Uploads,PmWiki.Passwords,PmWiki.SiteAnalyzer,Site.Site,SiteAdmin.SiteAdmin,PmWiki.Blocklist,PITS.00961,Site.PageActions,Site.EditForm,Site.PageNotFound,PmWiki.PageLists,PmWiki.Drafts,Cookbook.Cookbook,Cookbook.DebuggingForCookbookAuthors,PmWiki.SkinTemplates,PmWiki.ReleaseNotesArchive -text=(:title Release Notes:)(:Summary: Notes about new versions, important for upgrades:)%0aSee also: [[Upgrades]], [[Change log]], [[Download]] and [[(PmWiki:)Road map]].%0a(:comment The {*$:Released} variable is used in [[News/]]. :)%0a%0a!! Version 2.2.130 {*$:Released} (2020-07-04) [[#v22130]]%0aThis is a documentation update version.%0a%0a!! Version 2.2.129 {*$:Released} (2020-05-21) [[#v22129]]%0aThis version adds the styles for the "simpletable" class of tables from the "pmwiki-responsive" skin into the old "pmwiki" skin, and the documentation was updated.%0a%0a!! Version 2.2.128 {*$:Released} (2020-04-26) [[#v22128]]%0aThis version only includes some cosmetic changes and updates the documentation.%0a%0a!! Version 2.2.127 {*$:Released} (2020-03-23) [[#v22127]]%0aThis version sets the maximum height of the edit form textarea after reports for a jumping behavior on mobile devices (the PmWiki-responsive skin only). The core table of content classes "pmtoc-show" and "pmtoc-hide" now replace the previous classes "show" and "hide" to prevent conflicts with other frameworks. The functionality of the recipe Skins:SkinChange was added to the core (disabled by default). The documentation was updated.%0a%0a!! Version 2.2.126 {*$:Released} (2020-02-01) [[#v22126]]%0aThis version fixes a bug with $PmTOC['MinNumber'] set to -1, and updates the .htaccess format for caches.php. The documentation was updated.%0a%0a!! Version 2.2.124, 2.2.125 {*$:Released} (2020-01-27) [[#v22124]] [[#v22125]]%0aThis version adds a variable $SetCookieFunction to override the core "pmsetcookie" function. A new feature ToggleNext was included in the core, documented at Cookbook:ToggleNext. The documentation was updated.%0a%0a!! Version 2.2.123 {*$:Released} (2019-12-31) [[#v22123]]%0aThis version allows link URLs to be escaped with [@[=link address=]@] if they contain any special characters, including quotes, parentheses and pipes. The obfuscated e-mails will now work from headers, footers and sidebars. A [[forms|form]] attribute "formnovalidate" was added to the core and to the "Cancel" button in the edit form. Core [[table of contents]] will now work better with Cookbook:SectionEdit. Cookbook:RecipeCheck was included in the core -- if you have this recipe already installed, you can simply comment it out from your config.php. The code that handles $EnableRCDiffBytes was refactored to also show the bytes changed in the page histories. New upload extensions [[https://developers.google.com/speed/webp | "webp"]] (images) and [[https://www.opus-codec.org/ | "opus"]] (audio) were added. The documentation was updated.%0a%0a!! Version 2.2.122 {*$:Released} (2019-11-19) [[#v22122]]%0aVersion 2.2.121 was released by mistake and contained some experimental code that was meant to be tested first. %0a%0aThis version fixes a bug with ObfuscateLinkIMap() and international characters. New configuration variables $DefaultUnsetPageTextVars, $DefaultEmptyPageTextVars can set default values for page text variables. The built-in table of contents and numbered headings can now be enabled independently. A pagelist template pseudovariable [@{$$EachCount}@] was added, containing the number of the page in the current "each" loop. Input form elements and the [@(:searchbox:)@] field now can have ARIA accessibility attributes.%0a%0aThe documentation was updated.%0a%0a!! Version 2.2.120 {*$:Released} (2019-10-13) [[#v22120]]%0aThis version fixes a bug with existing complex customization of GUIEdit buttons. Very long [[table of contents|tables of contents]] will now be scrollable. A new "input datalist" [[Forms|form]] element (list of suggestions to other input fields), and a new "details+summary" [[block markup|block section]] (toggle sections without JavaScript) were added. The documentation was updated.%0a%0a!! Version 2.2.119 {*$:Released} (2019-10-03) [[#v22119]]%0aThis version updates the core for PHP 7.4. Required input fields now feature @@required="required"@@ attributes and modern browsers prevent sending the edit or upload form with empty required fields. Attachlist @@ext=@@ and @@names=@@ arguments now accept patterns and negatives like @@ext=jpg,png@@, @@ext=-pdf@@, or @@names=-th*---*.jpg@@. The Redirect function can now have a 3rd argument with the full URL. The scroll position in the edit text area will be remembered on save-and-edit and preview. A bug was fixed with pagelist while preview. The documentation was updated.%0a%0aA number of features currently provided by recipes were added to the core and disabled by default. You can still use the recipes, or you can disable them and enable the core features. The following features were added:%0a* e-mail obfuscation functions based on Cookbook:DeObMail; see instructions to enable%0a* a FixUrl button based on Cookbook:FixURL, see $EnableGuiEditFixUrl%0a* $EnableNotSavedWarning based on Cookbook:NotSavedWarning%0a* $EnableEditAutoText based on Cookbook:EditHelp%0a* $PmTOC, [@(:toc:)@], [@(:notoc:)@], Table of contents/Numbered headings, based on a simplified variant of Cookbook:AutoTOC%0a* $EnableSortable, basic sortable tables%0a* $EnableRCDiffBytes based on Cookbook:DeltaBytesRecentChanges%0a* $EnableSimpleTableRowspan replicating the markup from Cookbook:RowspanInSimpleTables%0a* $WikiPageCSSFmt enables CSS in a wiki page, based on Cookbook:LocalCSS%0a* $EnableHighlight code highlight feature compatible with "highlight.js"%0a* $AddLinkCSS['othergroup'] and $AddLinkCSS['samedomain'] can contain custom CSS classes for in-wiki links to other groups and for URL links to the same site.%0a%0aThe above new features are disabled by default, see the documentation for more information on how to enable them, or test them on pmwiki.org where most of these are enabled. Please report if you notice any problems.%0a%0a!! Version 2.2.118 {*$:Released} (2019-08-28) [[#v22118]]%0aThis version integrates the features of the recipe Cookbook:PreviewChanges into the core. If you currently use this recipe, please uninstall it and add to config.php:%0a $EnablePreviewChanges = 1;%0a%0aThe documentation was updated.%0a%0a!! Version 2.2.117 {*$:Released} (2019-07-28) [[#v22117]]%0aThis version adds handling of "partial content" requests for file downloads. New video file extensions 'm4v' and '3gp' were added. The Upload form now includes a new text field "Uploader" pre-filled with the name of the editor, and a new variable $EnableUploadAuthorRequired was added (defaults to $EnablePostAuthorRequired). The documentation was updated.%0a%0a!! Version 2.2.116 {*$:Released} (2019-06-19) [[#v22116]]%0aThis version fixes pagelists with case insensitive matches of page (text) variables for international wikis. If your international wiki pagelists rely on case-sensitive variable matches, please see $PageListVarFoldFn. The documentation was updated.%0a%0a!! Version 2.2.115 {*$:Released} (2019-05-13) [[#v22115]]%0aIn this version the responsive skin in large "desktop" mode changes the search form background to transparent, for easier custom styling of the header. The documentation was updated.%0a%0a!! Version 2.2.114 {*$:Released} (2019-04-02) [[#v22114]]%0aThis version adds a skin directive @@%3c!--IncludeTemplate ... -->@@ and the variable $SkinTemplateIncludeLevel. The core variable documentation format identifiers were moved to the definition term element to allow CSS ":target" styling, and the header and link text of the vardoc table can now be translated. Input forms have a new HTML5 element "tel", a new attribute "pattern" and two bugs were fixed with the classnames of the new elements and with the identifiers of "select" lists. The documentation was updated.%0a%0a!! Version 2.2.113 {*$:Released} (2019-03-01) [[#v22113]]%0aThis version adds a new [@(:input button:)@] form element. All form elements can now accept custom data-* attributes, which can be disabled by setting $EnableInputDataAttr to 0. Both additions are meant for easier integration with custom JavaScript functions or some frameworks.%0a%0aThe documentation was updated.%0a%0a!! Version 2.2.112 {*$:Released} (2019-01-09) [[#v22112]]%0aThis version includes a fix for PHP 7.3, and the documentation was updated.%0a%0a!! Version 2.2.111 {*$:Released} (2018-12-08) [[#v22111]]%0aThis version updates core .htaccess files to be compatible with both Apache 2.4 and earlier versions, and the variable $DenyHtaccessContent was added with the updated content. In case of difficulties or questions please contact us.%0a%0aA CSS value in the pmwiki-responsive skin was fixed. The [[MarkupExpression(s)]] [@{(ftime )}@] now accepts @@tz=@@ (time zone) and @@locale=@@ (language locale) arguments. The documentation was updated.%0a%0a!! Version 2.2.110 {*$:Released} (2018-11-05) [[#v22110]]%0aThis version prevents a warning with the [@{(substr )}@] markup expression when non-number arguments are typed. A new variable $PageListSortCmpFunction allows custom functions to order page lists. A new variable $MarkupMarkupLevel indicates when the processing happens inside [@(:markup:)@] blocks. %0a%0aThe default style for @@[=[@escaped code@]=]@@ dropped white spaces inconsistently and was fixed. If you rely on the previous behavior please add this to your pub/css/local.css file to revert it:%0a%0a code.escaped { white-space: nowrap; }%0a%0aThe documentation was updated.%0a%0a!! Version 2.2.109 {*$:Released} (2018-07-09) [[#v22109]]%0aThis version fixes a bug with the Path: InterMap prefix which was broken in 2.2.108. The function pmcrypt() was updated to prevent more strings from causing "invalid hash" warnings in PHP 7. The variable $EnableMarkupDiag was added to help diagnose all markup calls. The documentation was updated.%0a%0a!! Version 2.2.108 {*$:Released} (2018-07-05) [[#v22108]]%0aThis version adds the $PCCFOverrideFunction variable allowing a custom function to override PCCF(). $AuthUserPageFmt can now be an array of page names. The page cache file name can now be customized. Form checkbox labels now have the same tooltip title as the checkbox. Ordered lists with the [@%25reversed%25@] WikiStyle will have descending numbers. Minor fixes to refcount.php, vardoc.php, and pmcrypt(). The default InterMap PmWiki URLs have now the HTTPS protocol. The documentation was updated.%0a%0a!! Version 2.2.107 {*$:Released} (2018-02-02) [[#v22107]]%0aThis version includes more fixes for PHP 7.2 for forms and pagelists. A new variable $MailFunction allows administrators and developers to write replacement functions for the PHP function "mail()". Styles were improved for right-to-left text blocks embedded into left-to-right texts (and vice versa). The documentation was updated.%0a%0a!! Version 2.2.106 {*$:Released} (2017-12-01) [[#v22106]]%0aThis version has a rewrite of the function PageListSort() to allow it to work with PHP 7.2, and fixes a bug with the backtick (escape) [@`WikiWord@] markup. The helper function pmsetcookie() and the variables $EnableCookieSecure, $EnableCookieHTTPOnly were added to allow easy setting of secure cookies. The documentation was updated.%0a%0a!! Version 2.2.105 {*$:Released} (2017-11-07) [[#v22105]]%0aThis version fixes a bug with the PQA() function causing invalid HTML with attributes glued together. The function @@HandleUpload()@@ was refactored and @@UploadSetVars($pagename)@@ was added to allow upload-managing add-ons to set variables more easily.%0a%0aIf you upgrade from 2.2.98 or earlier, and you have custom markup rules relative to author signatures, please see note about [[#v2299|change in 2.2.99]] (documented November 2017).%0a%0a!! Version 2.2.104 {*$:Released} (2017-10-11) [[#v22104]]%0aThis version fixes a bug with [[WikiTrails#pathtrail|path WikiTrails]] reported today.%0a%0a!! Version 2.2.103 {*$:Released} (2017-10-01) [[#v22103]]%0aThis version is a major upgrade on the internal processing of markups and patterns, all core scripts were updated to be compatible with PHP version 7.2. Whether you use that PHP version or another one, with any local configurations and custom add-ons, there should be no change for what you see, but if any problems please contact us immediately.%0a%0aPagelists can now have optimized @@list=grouphomes@@ and @@fmt=#grouphomes@@ arguments to list only the home pages of your wiki groups, whether they are named Group.HomePage, Group.Group, or a custom Group.$DefaultName. Minor bugs in older xlpage scripts were fixed, the responsive skin is now compatible with even older PmWiki/PHP versions, web subtitles (*.vtt) were added as an allowed extension, input form fields can now have a "title" attribute (usually rendered as a tooltip/help balloon when the mouse cursor is over the input element), and a configuration variable $AuthLDAPReferrals was added for wikis running AuthUser over LDAP to force enable or disable referrals when needed.%0a%0aThe documentation was updated.%0a%0a!! Version 2.2.102 {*$:Released} (2017-08-05) [[#v22102]]%0aThis version reverts the patterns for text variables changed in 2.2.99, because we found that a longer text variable content may cause a blank page or an internal server error. In the page [[SiteAdmin.AuthList]] an input box was added to allow filtering of the groups or pages.%0a%0a!! Version 2.2.101 {*$:Released} (2017-07-30) [[#v22101]]%0aThis version renames the internal constructor of the PageStore class to be compatible with both PHP 5 and PHP 7. Previously, the PageStore class had two constructors for PHP 4 and PHP 5 compatibility of which one was silently ignored, but recent PHP 7 versions display strict or deprecated notices when the PHP 4 constructor is used.%0a%0aIf you must use PmWiki 2.2.101 or newer on a PHP 4 installation, please contact me so I can provide you with a workaround.%0a%0a!! Version 2.2.100 {*$:Released} (2017-07-30) [[#v22100]]%0aThis version provides a workaround for an incompatibility with our Subversion version control system, where the $Author wiki variable was considered a Subversion variable. A fix for the responsive skin adds some spacing above the WikiText block. The documentation was updated.%0a%0a!! Version 2.2.99 {*$:Released} (2017-06-26) [[#v2299]]%0aThis version fixes a bug where an incomplete text variable without a closing parenthesis like "[@(:Var:Value@]" could hide the remaining of the page.%0a%0aA bug was fixed where previewing a page didn't show changes to be done by replace-on-save patterns (the function ReplaceOnSave was refactored). Markup rules for previewing author signatures are no longer needed and were removed. %25note%25 Note that if you had custom markup rules processed before or after the @@[=~~=][=~=]@@ or @@[=~~=][=~~=]@@ author signatures may need to be set to [@'%3c[[~'@] (second argument of the @@Markup@@ call).%0a%0aA bug and a warning for PHP 4 installations were fixed. Two minor bugs with the [@[[%3c%3c]]@] line break for the responsive skin and the $Version variable link in the documentation were fixed. %0a%0aThe InterMap prefix to Wikipedia was corrected to use the secure HTTPS protocol and the documentation was updated.%0a%0a!! Version 2.2.98 (2017-05-31) [[#v2298]]%0aThis version adds a new skin that is better adaptable to both large and small screens, desktop and mobile devices (touchscreens). The new skin "pmwiki-responsive" is not enabled by default but available as an option, and as a base for customized copies. It requires a relatively modern browser (post-2009). The old skin is still available and enabled by default.%0a%0aThe Vardoc links now use MakeLink() to allow a custom LinkPage function. The function ReplaceOnSave() was refactored to allow easier calling from recipes. Markup processing functions now can access besides $pagename, a $markupid variable that contains the "name" of the processed markup rule, allowing a single function to process multiple markup rules. The "*.mkv" video extension was added to the list of allowed uploads.%0a%0aA bug was fixed with the [@(:markup:)@] output where a leading space was lost. Note that the "markup" frame is now wrapped in a %3cpre> block with a "pre-wrap" style instead of %3ccode>.%0a%0aA number of other (minor) bugs were fixed: see ChangeLog, and the documentation was updated.%0a%0a!! Version 2.2.97 (2017-04-07) [[#v2297]]%0aThis version fixes a bug concerning $ScriptUrl when $EnablePathInfo is set, introduced in 2.2.96 and reported by 3 users.%0a%0a!! Version 2.2.96 (2017-04-05) [[#v2296]]%0aThis version fixes a severe PHP code injection vulnerability, reported by Gabriel Margiani. PmWiki versions 2.2.56 to 2.2.95 are concerned.%0a%0aOnly certain local customizations enable the vulnerability. Your website may be at risk if your local configuration or recipes call too early some core functions like CondAuth(), RetrievePageName() or FmtPageName(), before the $pagename variable is sanitized by ResolvePageName() in stdconfig.php. A specific URL launched by a malicious visitor may trigger the vulnerability.%0a%0aMost recipes call core functions from a $HandleActions function, or from a Markup expression rule, these do not appear to be affected by the current exploit.%0a%0aIf your wiki may be at risk, it is recommended to upgrade to version 2.2.96 or most recent at the earliest opportunity. If you cannot immediately upgrade, you should place the following line in your local (farm)config.php file:%0a%0a [@$pagename = preg_replace('![${}\'"\\\\]+!', '', $pagename);@]%0a%0aPlace this line near the top of the file but after you include scripts/xlpage-utf-8.php or other character encoding file.%0a%0aThis version filters the $pagename variable to exclude certain characters. A new variable $pagename_unfiltered is added in case a recipe requires the previous behavior. The documentation was updated.%0a%0a!! Version 2.2.95 (2017-02-28) [[#v2295]]%0aThis is a documentation update version.%0a%0a!! Version 2.2.94 (2017-01-31) [[#v2294]]%0aThis version allows webmasters to configure and use both .html and .htm extensions. The cached information about whether a page exists or not will now be cleared when that page is created or deleted. The documentation was updated.%0a%0a!! Version 2.2.93 (2016-12-31) [[#v2293]]%0aThis is a documentation update version.%0a%0a!! Version 2.2.92 (2016-11-30) [[#v2292]]%0aThis version allows administrators to disable the "nopass" password by setting $AllowPassword to false. The function FmtPageName() will now expand PageVariables with asterisks like [@{*$FullName}@]. The documentation was updated.%0a%0a!! Version 2.2.91 (2016-09-30) [[#v2291]]%0aThis is a documentation update version.%0a%0a!! Version 2.2.90 (2016-08-31) [[#v2290]]%0aThis version adds a parameter to the upload form which can improve analytics from the server logs. Two new CSS classes were added to help skin developers: @@imgonly@@ and @@imgcaption@@, for standalone embedded pictures with or without a caption. A bug with the plus-links was fixed. The documentation was updated.%0a%0a!! Version 2.2.89 (2016-07-30) [[#v2289]]%0aThis version allows to set a default class name for simple tables. The [@(:searchbox:)@] directive can now have a "placeholder" attribute, and the input type can be changed from "text" to "search" for HTML5 websites. The edit form elements have now identifier attributes to allow easier styling. All core scripts will now inject CSS into the skin only if it hasn't already been defined. The vardoc.php script now recognizes and links to the documentation for the variables $pagename, $Author and $Skin. The documentation was updated.%0a%0a!! Version 2.2.88 (2016-06-29) [[#v2288]]%0aThis version fixes invalid HTML output of some WikiTrail links. The function PHSC() can now have an optional fourth argument for a safe replacement of htmlspecialchars(). A new page variable [@{$SiteAdminGroup}@] was added and the documentation was updated. %0a%0a!! Version 2.2.87 (2016-05-31) [[#v2287]]%0aThis version adds the $HTMLTagAttr variable to be used in the %3chtml> tag in skins for additional attributes like "lang" or "manifest". To enable it, use it in your skin, for example:%0a%0a %3chtml xmlns="http://www.w3.org/1999/xhtml" $HTMLTagAttr>%0a%0aThe variable $EnableRevUserAgent, if set to 1, will cause the User-Agent string from browsers to be stored with each page history entry (as opposed to only storing the last user agent string). The output variable $DiffUserAgent can be used in history templates like $DiffStartFmt.%0a%0aA wrong page variable in [[Site.UploadQuickReference]] was corrected, and the documentation was updated.%0a%0a!! Version 2.2.86 (2016-04-28) [[#v2286]]%0aThis version adds updates for PHP 7, for the PageStore() class and for the $DefaultPasswords default/unset definitions (no action should be needed upon upgrades). The documentation was updated.%0a%0a!! Version 2.2.85 (2016-03-31) [[#v2285]]%0aThis version adds Scalable Vector Graphics (*.svg, *.svgz) as allowed uploads and as embeddable picture extensions (with the html tag %3cimg/>). The documentation was updated.%0a%0a!! Version 2.2.84 (2016-02-21) [[#v2284]]%0aThis version fixes "indent" and "outdent" styles for right-to-left languages. A new variable $EnableLinkPlusTitlespaced allows "plus links" [@[[Link|+]]@] to display the "Spaced Title" of the page instead the "Title". The documentation was updated.%0a%0a!! Version 2.2.83 (2015-12-31) [[#v2283]]%0aThis is a documentation update version.%0a%0a!! Version 2.2.82 (2015-11-30) [[#v2282]]%0aThis version enables stripmagic() to process arrays recursively and updates the documentation.%0a%0a!! Version 2.2.81 (2015-10-31) [[#v2281]]%0aThis version fixes an inconsistency with single line page text variables. International wikis enabling UTF-8 will now be able to use the CSS classes "rtl" and "ltr" to override the text direction when inserting right to left languages. The documentation was updated.%0a%0a!! Version 2.2.80 (2015-09-30) [[#v2280]]%0aThis version modifies the [@(:searchbox:)@] directive to use type="search" semantic input, and updates the documentation.%0a%0a!! Version 2.2.79 (2015-08-27) [[#v2279]]%0aThis version adds WikiStyles for the CSS basic colors "fuchsia", "olive", "lime", "teal", "aqua", "orange" and "gray"/"grey". New input elements "email", "url", "number", "date", and "search" can now be used in wiki forms. %0a%0aNote: the "target" attribute of input forms which was added in the previous version broke the PmForm processor, and was removed until we find a solution. If you don't use PmForm and require this attribute (or others), the usual way to add it is to redefine the $InputAttrs array in your local configuration.%0a%0aA new variable $EnableROSEscape can be set to 1 if $ROSPatterns and $ROEPatterns should not process source text wrapped with [@[=...=]@] or @@[=[@...@]=]@@. By default "replace on edit" patterns are performed even in such text.%0a%0aThe insMarkup() function in guiedit.js was refactored to allow custom input ids and/or custom functions to process the selected text.%0a%0aThe documentation was updated.%0a%0a!! Version 2.2.78 (2015-07-21) [[#v2278]]%0aThis version updates the $RobotPattern list with currently active user agents. {-Input forms can have a "target" attribute-} (removed in 2.2.79). The documentation was updated.%0a%0aNote, this release broke the Cookbook:PmForm module. Please do upgrade to 2.2.79 or newer if your wiki uses PmForm.%0a%0a!! Version 2.2.77 (2015-06-19) [[#v2277]]%0aThis version extends the [@(:if attachments:)@] conditional to specify file and page names. A [@{$WikiTitle}@] page variable was added. A MatchNames() function was introduced as a generic way to match array values the same way MatchPageNames() does currently with lists of pages -- recipe authors can use it to get a subset of attachments for example. The PageStore() class was slightly optimized when recoding pages from-to UTF-8. The documentation was updated.%0a%0a!! Version 2.2.76 (2015-05-31) [[#v2276]]%0aThis version improves support for arrays in form elements: setting default values and recovering values from posted forms. A new "label" argument to checkbox and radio input elements allows easy insertion of clickable text labels after the form elements. Division blocks wrapping standalone images, and standalone image captions, now receive CSS classes allowing greater control via stylesheets. The documentation was updated.%0a%0a!! Version 2.2.75 (2015-04-26) [[#v2275]]%0aThis version adds a pmcrypt($pass, $salt) function which can be used as a replacement for the PHP crypt() function when encrypting passwords. From PHP 5.6 on, crypt() should not be used without a $salt parameter and would raise a notice. If pmcrypt() is called with a $salt parameter it will simply call crypt() in order to check a password. If it is called without a $salt parameter, pmcrypt() will create a password hash with the password_hash() function or with crypt() depending on your installation. You can replace any calls to crypt() with pmcrypt(), notably in config.php when defining $DefaultPasswords entries.%0a%0aMarkup was added for the semantic HTML5 tags article, section, nav, header, footer, aside, address.%0a%0aA bug with the uploads feature was fixed when $EnableReadOnly is set, and the documentation was updated.%0a%0a!! Version 2.2.74 (2015-03-28) [[#v2274]]%0aThis version allows the translation of the word "OK" in authentication forms. The documentation was updated to the latest state on pmwiki.org.%0a%0a!! Version 2.2.73 (2015-02-28) [[#v2273]]%0aThis release only updates the documentation to the latest state on pmwiki.org.%0a%0a!! Version 2.2.72 (2015-01-27) [[#v2272]]%0aThis version improves the ?action=ruleset display for markup rules potentially incompatible with PHP 5.5 when the function debug_backtrace() is not available. It restores the ability to set a custom function handling the [=(:markup:)=] demos. A variable $AbortFunction was added allowing administrators to override the core Abort() function. The documentation was updated.%0a%0a!! Version 2.2.71 (2014-12-29) [[#v2271]]%0aThis version removes the hard word wrap in [@(:markup:)@] wikicode examples, and instead of %3cpre> tags, it wraps it in %3ccode> tags. This allows newcomers to copy and paste the code in their wikis without inserted line breaks (which often cause the markup to not work).%0a%0aThe release also adds back-tracing for markup rules potentially incompatible with PHP 5.5. Such rules, often added by recipes, can trigger "Deprecated: preg_replace()" warnings. To find out which recipes may trigger the warnings, enable diagnostic tools in config.php with @@$EnableDiag = 1;@@ then open a page with the 'ruleset' action, eg. [@[[HomePage?action=ruleset]]@]. The PHP-5.5-incompatible rules will be flagged with filenames, line numbers and patterns. See also the pages [[(PmWiki:)Troubleshooting]] and [[(PmWiki:)CustomMarkup]] on pmwiki.org.%0a%0aThe variable $DraftActionsPattern was added, the pagelist "request" parameter can now contain a list of allowed or disallowed parameters that can be overridden by the user, the "input default source" parameter can now contain multiple pages, and a minor bug was fixed in upload.php ('strict' warning). See the updated documentation for more information. %0a%0a!! Version 2.2.70 (2014-11-08) [[#v2270]]%0aThis release only updates the documentation to the latest state on pmwiki.org.%0a%0a!! Version 2.2.69 (2014-10-13) [[#v2269]]%0aThis version fixes a bug when dates are defined as relative to other dates, eg. "2014-10-13 -3 days". The documentation was updated; note that the instructions in Site.UploadQuickReference were updated to reflect the display of the upload form in current browsers.%0a%0a!! Version 2.2.68 (2014-09-01) [[#v2268]]%0aThis version adds a Skins: InterMap prefix pointing to the Skins section on PmWiki.org, a "signature" markup in the edit quick reference, new WikiStyles clear, min-width and max-width and the documentation was updated.%0a%0a!! Version 2.2.67 (2014-08-02) [[#v2267]]%0aThis version fixes an inconsistency with input forms when values are taken from PageTextVariables. The documentation was updated to the latest state on pmwiki.org.%0a%0a!! Version 2.2.66 (2014-07-02) [[#v2266]]%0aThis version fixes a minor longstanding bug in the default Notification format when a page is deleted. In custom patterns, the "_" character will no longer be considered a function name. The documentation was updated.%0a%0a!! Version 2.2.65 (2014-06-07) [[#rel2.2.65]]%0aThis version fixes Pagelist handling of [@{$$PseudoVars}@] when they contain page variables. File permissions handling was improved when the current directory is owned by "root". The documentation was updated.%0a%0a!! Version 2.2.64 (2014-05-08) [[#rel2.2.64]]%0aThis version adds the [="{(mod)}"=] markup expression for modulo/remainder calculations, and the "tel:" and "geo:" URI schemes which, on compatible devices like smartphones, allow the creation of links to dial telephone numbers and open map/location applications. %0a%0aThe $SysMergePassthru switch was added, if enabled, it allows the "Simultaneous Edits" conflict resolution to use the passthru() function instead of popen().%0a%0aThe documentation was updated.%0a%0a!! Version 2.2.63 (2014-04-05) [[#rel2.2.63]]%0aThis version allows for form elements to have custom attributes containing a dash in the attribute names and enables the attributes 'required', 'placeholder' and 'autocomplete' for HTML5 forms. A minor bug with pagelist [={$$RequestVariables}=] appearing on some installations was fixed. The documentation was updated.%0a%0a!! Version 2.2.62 (2014-02-28) [[#rel2.2.62]]%0aThis version adds the variable $EnableTableAutoValignTop which allows to make advanced tables compatible with HTML5. For developers, a fourth argument $template was added to the Markup_e() function, and a callback template 'return' was added. The documentation was updated.%0a%0a!! Version 2.2.61 (2014-01-31) [[#rel2.2.61]]%0aThis version removes unnecessary snippets of code and adds the variable $TableCellAlignFmt which allows to make simple tables compatible with HTML5. The documentation was updated.%0a%0a!! Version 2.2.60 (2014-01-12) [[#rel2.2.60]]%0aThis version reverts the changes to the pmwiki.css file made in 2.2.59. %0a%0a!! Version 2.2.59 (2014-01-11) [[#rel2.2.59]]%0aThis version has an improvement for Blocklist when multiple text fields are posted. A bug with some nested markup conditionals was fixed. The default skin switched font sizes from points (fixed) to percents (relative). A couple of other minor bugs were fixed and the documentation was updated.%0a%0a!! Version 2.2.58 (2013-12-25) [[#rel2.2.58]]%0aThis version enables customization of [=(:input auth_form:)=], and fixes a couple of minor bugs. The documentation was updated.%0a%0a!! Version 2.2.57 (2013-11-03)%0aThis version enables the use of the Attach: link format in the [[PmWiki/PageDirectives#attachlist|[=(:attachlist:)=]]] directive. The documentation was updated.%0a%0a!! Version 2.2.56 (2013-09-30)%0aThis version aims to fix a PHP 5.5 compatibility issue with a deprecated feature of the preg_replace() function. The PageStore() class now detects and works around a bug with the iconv() function, and the documentation was updated.%0a%0a!! Version 2.2.55 (2013-09-16)%0aThis version adds the variable $EnableDraftAtomicDiff. If enabled, publishing from a draft version will clear the history of intermediate draft edits, and the published version will contain a single combined diff from the previous published version. The documentation was updated.%0a%0a!! Version 2.2.54 (2013-08-13)%0aThis version fixes a bug when old versions are restored from draft pages. The documentation was updated.%0a%0a!! Version 2.2.53 (2013-07-08)%0aThis version enables a message to be shown when a post is blocked because of too many unapproved links. The documentation was updated.%0a%0a!! Version 2.2.52 (2013-06-08)%0aThis version hides warnings about a deprecated feature in PHP 5.5 installations (preg_replace with /e eval flag). Three new upload extensions were added: docx, pptx and xlsx produced by recent versions of some office suites. The documentation was updated.%0a%0a!! Version 2.2.51 (2013-05-08)%0aThis version updates the addresses for the remote blocklists. A minor XSS vulnerability for open wikis, which was discovered today, was fixed. The documentation was updated.%0a%0a!! Version 2.2.50 (2013-04-08)%0aThis release only updates the documentation to the latest state on pmwiki.org.%0a%0a!! Version 2.2.49 (2013-03-09)%0aThis version adds an array $UploadBlacklist containing forbidden strings of an uploaded filename (case insensitive). Some Apache installations try to execute a file which has ".php", ".pl" or ".cgi" anywhere in the filename, for example, "test.php.txt" may be executed. To disallow such files to be uploaded via the PmWiki interface, add to config.php such a line:%0a%0a $UploadBlacklist = array('.php', '.pl', '.cgi', '.py', '.shtm', '.phtm', '.pcgi', '.asp', '.jsp', '.sh');%0a%0aThe documentation was updated.%0a%0a!! Version 2.2.48 (2013-02-11)%0aThis version fixes a bug introduced yesterday with some links. %0a%0a!! Version 2.2.47 (2013-02-10)%0aThis version enables tooltip titles in links to anchors in the same page, and the documentation was updated.%0a%0a!! Version 2.2.46 (2013-01-07)%0aThis version adds $UploadPermAdd and $UploadPermSet variables, and the documentation was updated.%0a%0aIf your wiki has uploads enabled, it is recommended to set the variable $UploadPermAdd to 0. %0a%0aThe $UploadPermAdd variable sets additional unix permissions applied to newly uploaded files, and should be 0 (recommended as of 2013). If uploaded files cannot be downloaded and displayed on the website, for example with the error 403 Forbidden, set this value to 0444 (core setting, default since 2004). %0a $UploadPermAdd = 0; # recommended%0a%0aThe $UploadPermSet variable unconditionally sets the file permissions on newly uploaded files. Only advanced administrators should use it.%0a%0a%0a!! Version 2.2.45 (2012-12-02)%0aThis version fixes some PHP notices appearing on some installations. The documentation was updated.%0a%0a!! Version 2.2.44 (2012-10-21)%0aThis version improves the display of consecutive whitespaces in page histories, and fixes the definition of PageTextVariables containing a dash. The documentation was updated.%0a%0a%0a!! Version 2.2.43 (2012-09-20)%0aThis version makes it possible to use HTML attribute names that contain dashes, and removes a warning when editing and previewing Site.EditForm. The documentation was updated.%0a%0a!! Version 2.2.42 (2012-08-20)%0aThis version provides a workaround for cases when a wiki page contains a character nonexistent in the active encoding. The documentation was updated.%0a%0a!! Version 2.2.41 (2012-08-12)%0aThis version changes the internal $KeepToken separator to be compatible with more encodings. The documentation was updated.%0a%0a!! Version 2.2.40 (2012-07-21)%0aThis version provides a helper function replacing htmlspecialchars() and compatible with PHP 5.4. The documentation was updated.%0a%0a!! Version 2.2.39 (2012-06-25)%0aThis version provides a fix for links to attachments containing international characters. The documentation was updated.%0a%0a!! Version 2.2.38 (2012-05-21)%0aThis version fixes a "parameter count" warning which appeared on some websites.%0a%0a!! Version 2.2.37 (2012-05-01)%0aThis version provides a workaround for installations with broken iconv() function, while optimizing the recode function. This should fix the "Unable to retrieve edit form" problem in some wikis. Dots in [[#anchor_1.2]] sections are now better supported, PageVariables are expanded in PageList template defaults, and the documentation is updated.%0a%0a!! Version 2.2.36 (2011-12-28)%0aThis version fixes the recode function to try to recover Windows-1252 characters in ISO-8859-1 files. A new variable $EnableOldCharset enables the $page["=oldcharset"] entry which will be used in the future. A couple of minor bugs were fixed and the documentation was updated.%0a%0a!! [[#v2235]] Version 2.2.35 (2011-11-11)%0aThis release fixes a critical PHP injection vulnerability, reported today by Egidio Romano. PmWiki versions 2.2.X, 2.1.X, 2.0.X and 2.0.beta33 and newer are vulnerable. When you upgrade, please read carefully the Release notes for all PmWiki versions since yours.%0a%0aIf you cannot upgrade, it is recommended to disable Searches at the earliest opportunity (even if your wiki skin doesn't have a search form). Add to config.php such a line:%0a if ($action == 'search') $action = 'browse';%0a%0aIf your old version wiki allows editing by not entirely trusted visitors, even on limited pages like a WikiSandbox, you should also disable PageLists. Add to config.php this line:%0a $EnablePageList = 0;%0a%0aThis version has an important change for international wikis: the XLPage() function no longer loads encoding scripts such as xlpage-utf-8.php. When you upgrade, you need to include those scripts from config.php, before calling XLPage():%0a%0a include_once("scripts/xlpage-utf-8.php"); # if your wiki uses UTF-8%0a XLPage('bg','PmWikiBg.XLPage');%0a%0aAll links can now have tooltip titles. Previously, only images and external links could have tooltip titles, now this feature is enabled for internal links. To set a tooltip title, add it in quotes after the link address:%0a[@%0a [[Main.HomePage"This is a tooltip title"]]%0a [[Main.HomePage"This is a tooltip title"|Home]]%0a [[http://www.pmwiki.org"Home of PmWiki"]]%0a Attach:image.jpg"Tooltip title of the image"%0a@]%0a%0aThe following new upload extensions were added: svg, xcf, ogg, flac, ogv, mp4, webm, odg, epub. A couple of minor optimizations were added (MarkupExpressions and rendering of page history) and the documentation was updated.%0a%0a!! Version 2.2.34 (2011-10-10)%0aThis version resets the timestamps of the default pages Site(Admin).AuthUser which are expected in case of upgrades from the versions 2.1.*. Core MarkupExpressions which manipulate strings should now work better with international characters. The documentation was updated to its latest state from pmwiki.org.%0a%0a!! Version 2.2.33 (2011-09-23) [[#v2233]]%0aThis version fixes a security bug introduced in 2.2.32 which left the groups Site and SiteAdmin open for reading and editing because the pages Site.GroupAttributes and SiteAdmin.GroupAttributes didn't have all necessary attributes. %0a%0aAll wikis running 2.2.32 should upgrade. If you cannot immediately upgrade, you can set the attributes from your wiki:%0a* open the attributes page [=[[SiteAdmin.GroupAttributes?action=attr]]=] and set a "read" and an "edit" password, @@ @lock @@ is recommended.%0a* open the attributes page [=[[Site.GroupAttributes?action=attr]]=] and set an "edit" password, @@ @lock @@ is recommended. Do not set a "read" password here.%0a%0aThe release also fixes the refcount.php script to produce valid HTML, and updates intermap.txt entries PITS: and Wikipedia: to point to their current locations.%0a%0a!! Version 2.2.32 (2011-09-18)%0aThis is the first version shipping with the core documentation in the UTF-8 encoding. PmWiki will automatically convert it on the fly for wikis using an older encoding.%0a%0aIt is recommended that all '''new''' PmWiki installations enable UTF-8. Migration of ''existing'' wikis from an older encoding to UTF-8 shouldn't be rushed: it is not trivial and will be documented in the future.%0a%0aA required HTML xmlns attribute was added to the print skin template. The history rendering is now faster when many lines are added or removed.%0a%0a%25note%25 Note: Due to a manipulation error, a version 2.2.31 was created before it was ready for a release.%0a%0a!! Version 2.2.30 (2011-08-13)%0aThis version fixes a $Charset definition in international iso-8859-*.php files. This will help for a future transition to UTF-8. %0a%0aA variable $EnableRangeMatchUTF8 was added, set it to 1 to enable range matches of pagenames in UTF-8 like [A-D]. Previously the range matches were always enabled in UTF-8, but we found out that on some installations this feature breaks all pagelists, even those without range matches. In case the feature worked for you, you can re-enable it.%0a%0a!! Version 2.2.29 (2011-07-24)%0aThis release fixes Attach links that were broken with the Path fix in 2.2.28 earlier today.%0a%0a!! Version 2.2.28 (2011-07-24)%0aThis release fixes 2 potential XSS vulnerabilities and a bug with Path: links.%0a%0a!! Version 2.2.27 (2011-06-19)%0aThis release fixes a validation bug on pages after a redirection. A new block WikiStyle [@%25justify%25@] was added, allowing left and right aligned text. The page history now accepts a URL parameter @@?nodiff=1@@ which hides the rendering of edit differences, showing only timestamps, authors, summaries and "Restore" links; it allows to restore a vandalized page with a huge contents or history which otherwise would break the memory or time limits of the server.%0a%0a!! Version 2.2.26 (2011-05-21)%0aThis release fixes a redundant removal of link hashes from WikiTrails, and updates the documentation to the most recent version from PmWiki.org.%0a%0a!! Version 2.2.25 (2011-03-22)%0aThis release only updates the documentation to the latest state on pmwiki.org.%0a%0a!! Version 2.2.24 (2011-02-15)%0aThis version reverts the way existing PageVariables are processed, like version 2.2.21 or earlier, but it adds a special variable $authpage which can be used in PageVar definitions. It is the same as the $page array, but exists only if the visitor has read permissions. For example, an administrator can set to config.php:%0a%0a $FmtPV['$LastModifiedSummary'] = '@$authpage["csum"]'; # instead of '@$page["csum"]'%0a%0aThen, the edit summary metadata will only be available if the user has read permissions.%0a%0a!! Version 2.2.23 (2011-01-25)%0aThis version sets the default value of $EnablePageVarAuth to 0 until we investigate a reported problem with authentication.%0a%0a!! Version 2.2.22 (2011-01-16)%0aThis version adds the variable $EnableXLPageScriptLoad which, if set to 0, will prevent authors to load scripts from XLPage and to accidentally change the encoding of the wiki. If you use it, make sure you include the required files, eg. xlpage-utf-8.php from local config files.%0a%0aPageVariables should now respect authentications: without read permissions, the title, description, change summary, author of a protected page are unavailable. PageVariables that are computed without reading the page are still available (eg. $Group, $Namespaced, $Version etc.). Administrators can revert the previous behavior by adding to config.php such a line:%0a%0a@@ $EnablePageVarAuth = 0; @@%0a%0a!! Version 2.2.21 (2010-12-14)%0aDue to a mis-configuration of a local svn repository, some of the changes intended for 2.2.20 didn't make it in the correct branch. This release corrects this.%0a%0a!! Version 2.2.20 (2010-12-14)%0aThis version fixes a potential XSS vulnerability, reported today. An AuthUser bug with excluding users from authgroups was fixed. A new InterMap prefix PmL10n: was added, it leads to the Localization section on PmWiki.org and should help the work of translators. A couple of other minor bugs were fixed and the documentation was updated.%0a%0a!! Version 2.2.19 (2010-11-10)%0aThis is a documentation-update release.%0a%0a!! Version 2.2.18 (2010-09-04)%0aThis version fixes 3 minor bugs, and updates the documentation.%0a%0a!! Version 2.2.17 (2010-06-20)%0aThis version adds a variable $PostConfig containing functions and scripts to be loaded after stdconfig.php. Tabindex was added as a valid form field attribute. Protected downloads now respect existing browser caches. AuthUser now allows more flexible cookbook recipe integration. A couple of bugs were fixed and the documentation was updated.%0a%0a!! Version 2.2.16 (2010-05-10)%0aThis version fixes a bug with parsing html attributes which could allow XSS injection. Wikis allowing unprotected editing are encouraged to upgrade.%0a%0aA bug with the "center" button of the GUI edit toolbar was corrected.%0a%0aThe "exists" conditional now accepts wildcards, for example:%0a [@(:if exists Main.*:)There are pages in the Main group (:if:)@]%0a%0aThe documentation was updated.%0a%0a!! Version 2.2.15 (2010-03-27)%0aThis version adds some minor bugfixes and optimizations notably a bug with @@[=(:template none:)=]@@ introduced in the last version 2.2.14.%0a%0a!! Version 2.2.14 (2010-02-27)%0aThis release corrects inline styles for WikiTrail links. Undefined include/template @@ [={$$variables}=] @@ are now removed from the included section, like Page(Text)Variables, and can be used in conditional expressions. If needed, this change can be reverted by adding to config.php such a line:%0a%0a[@%0a $EnableUndefinedTemplateVars = 1; # keep and display unset {$$variables}%0a@]%0a%0aPageList templates now accept the sections @@ !first @@ and @@ !last @@ for markup to appear for every page in list ''except'' the first or last one.%0a%0a"Title" attributes were added to external links. You can have tooltip titles on external links, including InterMap and attachments, by adding the link title in double quotes after the URL:%0a [=[[http://www.pmwiki.org"Home of PmWiki"| External link]]=]%0a%0aFor international wikis, PmWiki now automatically translates the titles of technical pages like GroupAttributes or RecentChanges -- just define these strings as usual in XLPage, for example, in French:%0a 'AllRecentChanges' => 'Tous les changements récents',%0a%0aSome minor optimizations were done and the documentation was updated.%0a%0a!! Version 2.2.13 (2010-02-21)%0aThis release fixes a bug with $DiffKeepNum introduced in 2.2.10 -- the count of revisions was incorrect and a page could drop more revisions than it should.%0a%0aThe [[page history]] layout was modified with a rough consensus in the community. The history now defaults to "source" view with word-level highlighting of the differences. Authors can see the changes in rendered output by clicking on the link "Show changes to output". Admins can switch back the default by adding such a line to config.php:%0a%0a $DiffShow['source'] = (@$_REQUEST['source']=='y')?'y':'n';%0a%0aTo disable word-level highlighting and show plain text changes:%0a%0a $EnableDiffInline = 0;%0a%0aIn the page history rendering, a few minor bugs were fixed and the code was slightly optimized.%0a%0aThe documentation was updated.%0a%0a!! Version 2.2.12 (2010-02-17)%0aThis release adds simple word-level highlighting of differences in the page history, when "Show changes to markup" is selected. To enable the feature, add to config.php such a line:%0a $EnableDiffInline = 1;%0a%0aThis feature is like what the InlineDiff recipe provides, but not exactly the same, and the implementation is simpler. It is enabled on PmWiki.org and can be improved -- your comments are welcome.%0a%0a!! Version 2.2.11 (2010-02-14)%0aThis release adds two new table directives for header cells, [=(:head:) and (:headnr:)=]. They work the same way as [=(:cell:) and (:cellnr:)=] except that create %3cth> instead of %3ctd> html tags.%0a%0aThe pagerev.php script was refactored into separate functions to allow easier integration of recipes displaying the page history.%0a%0aA couple of minor bugs were fixed and the documentation was updated.%0a%0a!! Version 2.2.9, 2.2.10 (2010-01-17)%0aMost important in this release is the official change of $EnableRelativePageVars to 1. The change is about how [={$Variable}=] in included pages is understood by PmWiki.%0a* When $EnableRelativePageVars is set to 0, [={$Name}=] displays the name of the currently browsed page. Even if [={$Name}=] is in an included page, it will display the name of the browsed page.%0a* When $EnableRelativePageVars is set to 1, [={$Name}=] displays the name of the physical page where it written. If [={$Name}=] is in an included page, it will display the name of the included page.%0a* [={*$Name}=] always displays the name of the currently browsed page, regardless of $EnableRelativePageVars.%0a%0aSo, if your wiki relies on page variables from included pages, and doesn't have $EnableRelativePageVars set to 1, after upgrading to 2.2.9, you can revert to the previous behavior by adding to config.php such a line:%0a $EnableRelativePageVars = 0;%0a%0aMore information about page variables can be found at:%0a http://www.pmwiki.org/wiki/PmWiki/PageVariables%0a%0aThis release adds a new variable $EnablePageTitlePriority which defines how to treat multiple [=(:title..:)=] directives. If set to 1, the first title directive will be used, and if a page defines a title, directives from included pages cannot override it. PmWiki default is 0, for years, the last title directive was used (it could come from an included page or GroupFooter).%0a%0aThis release also adds a new variable $DiffKeepNum, specifying the minimum number (default 20) of edits that will be kept even if some of them are older than the limit of $DiffKeepDays.%0a%0aA number of bugs were fixed and the documentation was updated.%0a%0a!! Version 2.2.8 (2009-12-07)%0aThis release fixes another PHP 5.3 compatibility issue with conditional markup. The Author field now handles apostrophes correctly. The documentation was updated.%0a%0a!! Version 2.2.7 (2009-11-08)%0aThis release fixes most PHP 5.3 compatibility issues. Unfortunately some specific builds for Windows may still have problems, which are unrelated to PmWiki. Notably, on Windows, all passwords need to be 4 characters or longer.%0a%0aUpload names with spaces are now correctly quoted. The documentation was updated.%0a%0a!! Version 2.2.6 (2009-10-04)%0aWith this release it is now possible to display recently uploaded files to the RecentChanges pages -- if you have been using the RecentUploadsLog recipe, please uninstall it and follow the instructions at http://www.pmwiki.org/wiki/Cookbook/RecentUploadsLog.%0a%0aThe release also introduces $MakeUploadNamePatterns to allow custom filename normalization for attachements. It is now possible to replace $PageListFilters and $FPLTemplateFunctions with custom functions. Notify should now work in safe_mode. Some bugs were fixed, among which one with conditional markup with dates. The documentation was updated.%0a%0a!! Version 2.2.5 (2009-08-25)%0aThis release adds a new markup for Pagelist templates, [@(:template none:)@] which allows a message to be set when the search found no pages. The FPLTemplate() function was broken into configurable sub-parts to allow development hooks. A number of bugs were fixed, and the documentation was updated.%0a%0a!! Version 2.2.4 (2009-07-16)%0aThis release fixes a bug introduced earlier today with HTML entities in XLPages.%0a%0a!! Version 2.2.3 (2009-07-16)%0aThis release fixes six potential XSS vulnerabilities, reported by Michael Engelke. The vulnerabilities may affect wikis open for editing and may allow the injection of external JavaScripts in their pages. Public open wikis should upgrade.%0a%0aA new variable $EnableUploadGroupAuth was added; if set to 1, it allows password-protected [[uploads]] to be checked against the Group password. %0a%0aIt is now possible to use @@ @_site_edit, @_site_read, @_site_admin@@ or @@ @_site_upload @@ global [[passwords]] in GroupAttributes pages.%0a%0aA number of other small bugs were fixed, and the documentation was updated.%0a%0a!! Version 2.2.2 (2009-06-21)%0aThe major news in this release is a fix of an AuthUser vulnerability.%0a%0aThe vulnerability affects only wikis that (1) rely on the AuthUser core module %0afor User:Password authentication, -AND- (2) where the PHP installation runs %0awith the variable "magic_quotes_gpc" disabled.%0a%0aAll PmWiki 2.1.x versions from pmwiki-2.1.beta6 on, all 2.2.betaX, 2.2.0, and %0a2.2.1 are affected.%0a%0aThe PmWiki [[SiteAnalyzer]] can detect if your wiki needs to upgrade:%0a http://www.pmwiki.org/wiki/PmWiki/SiteAnalyzer%0a%0aIf your wiki is vulnerable, you should do one of the following at the earliest %0aopportunity:%0a%0a* Upgrade to a version of PmWiki at least 2.2.2 or greater.%0a* Turn on magic_quotes_gpc in the php.ini file or in a .htaccess file.%0a%0aAlternatively, you can temporarily disable AuthUser until you upgrade.%0a%0aNote that even if your wiki does not have the AuthUser vulnerability at the %0amoment, you are strongly encouraged to upgrade to PmWiki version 2.2.2 or %0alater, as some future configuration of your hosting server might put you at %0arisk.%0a%0aThis release also comes with minor updates in the local documentation; fixes %0awere applied for international wikis - notably global variables in %0axlpage-utf-8.php and a new variable $EnableNotifySubjectEncode, which allows %0ae-mail clients to correctly display the Subject header; and a number of other %0asmall bugs were fixed.%0a%0a!! Version 2.2.1 (2009-03-28)%0aThis release comes with an updated local documentation; [[wiki trails]] now work cross-group; guiedit.php now produces valid HTML, and other small bugs were fixed. We also added $EnableRedirectQuiet, which allows redirects to take place without any mention of "redirected from page ....".%0a%0a[[#v220]]%0a!! Version 2.2.0 (2009-01-18)%0a%0aThis is a summary of changes from 2.1.x to 2.2.0.%0a%0a* Several pages that were formerly in the [[Site]].* group are now in a separate [[SiteAdmin]].* group, which is read-restricted by default. The affected pages include Site.AuthUser, Site.AuthList, Site.NotifyList, Site.Blocklist, and Site.ApprovedUrls . If upgrading from an earlier version of PmWiki, PmWiki will prompt to automatically copy these pages to their new location if needed. If a site wishes to continue using the old Site.* group for these pages, simply set%0a%0a-> $SiteAdminGroup = $SiteGroup;%0a%0a-> when carrying out this upgrade inspect your config files for lines such as%0a--> $BlocklistDownload['Site.Blocklist-PmWiki'] = array('format' => 'pmwiki');%0a->as you may wish to fix then, eg%0a--> $BlocklistDownload[$SiteAdminGroup . '.Blocklist-PmWiki'] = array('format' => 'pmwiki');%0a%0a* Important Change in Passwords in PmWiki 2.2 indicating that the group can be edited even if a site password is set will be done by @@"@nopass"@@ prior it was done by @@"nopass"@@%0a-> When migrating a wiki you will have to manually modify the permission or by a script replace in all the page concerned @@passwdread=nopass:@@ by @@passwdread=@nopass@@ (see PITS:00961) --isidor%0a%0a* PmWiki now ships with WikiWords entirely disabled by default. To re-enable them, set either $LinkWikiWords or $EnableWikiWords to 1. To get the 2.1 behavior where WikiWords are spaced and parsed but don't form links, use the following:%0a-> $EnableWikiWords = 1;%0a-> $LinkWikiWords = 0;%0a%0a* It's now easy to disable the rule that causes lines with leading spaces to be treated as preformatted text -- simply set $EnableWSPre=0; to disable this rule.%0a%0a--> '''Important:''' There is ongoing discussion that the leading whitespace rule may be disabled ''by default'' in a future versions of PmWiki. If you want to make sure that the rule will continue to work in future upgrades, set $EnableWSPre=1; in ''local/config.php''.%0a%0a* The $ROSPatterns variable has changed somewhat -- replacement strings are no longer automatically passed through FmtPageName() prior to substitution (i.e., it must now be done explicitly).%0a%0a* Page variables and page links inside of [@(:include:)@] pages are now treated as relative to the included page, instead of the currently browsed page. In short, the idea is that links and page variables should be evaluated with respect to the page in which they are written, as opposed to the page in which they appear. This seems to be more in line with what authors expect. There are a number of important ramifications of this change:%0a%0a[[#relativeurls]]%0a** We now have a new [@{*$var}@] form of page variable, which always refers to "the currently displayed page". Pages such as Site.PageActions and Site.EditForm that are designed to work on "the currently browsed page" should generally switch to using [@{*$FullName}@] instead of [@{$FullName}@].%0a%0a** The $EnableRelativePageLinks and $EnableRelativePageVars settings control the treatment of links and page variables in included pages. However, to minimize disruption to existing sites, $EnableRelativePageVars defaults to '''disabled'''. This will give existing sites an opportunity to convert any absolute [@{$var}@] references to be [@{*$var}@] instead.%0a%0a** Eventually $EnableRelativePageVars will be enabled by default, so we highly recommend setting [@$EnableRelativePageVars = 1;@] in ''local/config.php'' to see how a site will react to the new interpretation. Administrators should especially check any customized versions of the following:%0a---> [[Site.PageActions]]%0a---> [[Site.EditForm]]%0a---> [[Site.PageNotFound]]%0a---> SideBar pages with ?action= links for the current page%0a---> $GroupHeaderFmt, $GroupFooterFmt%0a---> [[Page lists]] that refer to the current group or page, etc in sidebars, headers, and footers%0a%0a** The [@(:include:)@] directive now has a [@basepage=@] option whereby an author can explicitly specify the page upon which relative links and page variables should be based. If no basepage= option is specified, the included page is assumed to be the base.%0a%0a* Sites that want to retain the pre-2.2 behavior of [@(:include:)@] and other items can set [@$Transition['version'] = 2001900;@] to automatically retain the 2.1.x defaults.%0a%0a* Text inserted via [@(:include:)@] can contain "immediate substitutions" of the form [@{$$option}@] -- these are substituted with the value of any options provided to the include directive.%0a%0a* PmWiki now recognizes when it is being accessed via "https:" and switches its internal links appropriately. This can be overridden by explicitly setting $ScriptUrl and $PubDirUrl.%0a%0a* A new $EnableLinkPageRelative option allows PmWiki to generate relative urls for page links instead of absolute urls.%0a%0a* Draft handling capabilities have been greatly improved. When $EnableDrafts is set, then the "Save" button is relabeled to "Publish" and a "Save draft" button appears. In addition, an $EnablePublishAttr configuration variable adds a new "publish" authorization level to distinguish editing from publishing. See [[PmWiki:Drafts]] for more details.%0a%0a[[#ptvstart]]%0a* There is a new [@{$:var}@] "page text variable" available that is able to grab text excerpts out of markup content. For example, [@{SomePage$:Xyz}@] will be replaced by a definition of "Xyz" in SomePage. Page text variables can be defined using definition markup, a line beginning with the variable name and a colon, or a special directive form (that doesn't display anything on output):%0a%0a-->[@%0a:Xyz: some value # definition list form%0aXyz: some value # colon form%0a(:Xyz: some value:) # directive form%0a@]%0a[[#ptvend]]%0a%0a* The [@(:pagelist:)@] command can now filter pages based on the contents of page variables and/or page text variables. For example, the following directive displays only those pages that have an "Xyz" page text variable with "some value":%0a%0a-->[@(:pagelist $:Xyz="some value":)@]%0a%0a Wildcards also work here, thus the following pagelist command lists pages where the page's title starts with the letter "a":%0a%0a-->[@(:pagelist $Title=A* :)@]%0a%0a* The if= option to [@(:pagelist)@] can be used to filter pages based on conditional markup:%0a%0a-->[@(:pagelist if="auth upload {=$FullName}":)@] pages with upload permission%0a-->[@(:pagelist if="date today.. {=$Name}":)@] pages with names that are dates later than today%0a%0a* Spaces no longer separate wildcard patterns -- use commas. (Most people have been doing this already.)%0a%0a* Because page variables are now "relative", the [@{$PageCount}, {$GroupCount}, {$GroupPageCount}@] variables used in pagelist templates are now [@{$$PageCount}, {$$GroupCount}, {$$GroupPageCount}@].%0a%0a* One can now use [@{$$option}@] in a pagelist template to obtain the value of any 'option=' provided to the [@(:pagelist:)@] command.%0a%0a* The [@(:pagelist:)@] directive no longer accepts parameters from urls or forms by default. In order to have it accept such parameters (which was the default in 2.1 and earlier), add a [@request=1@] option to the [@(:pagelist:)@] directive.%0a%0a* The [@count=@] option to pagelists now accepts negative values to count from the end of the list. Thus [@count=5@] returns the the first five pages in the list, and [@count=-5@] returns the last five pages in the list. In addition, ranges of pages may be specified, as in [@count=10..19@] or [@count=-10..-5@].%0a%0a* Pagelist templates may have special [@(:template first ...:)@] and [@(:template last ...:)@] sections to specify output for the first or last page in the list or a group. There's also a [@(:template defaults ...:)@] to allow a template to specify default options.%0a%0a* PmWiki comes with an ability to cache the results of certain [@(:pagelist:)@] directives, to speed up processing on subsequent visits to the page. To enable this feature, set $PageListCacheDir to the name of a writable directory (e.g., ''work.d/'').%0a%0a* [[#elseifelse]]The [@(:if ...:)@] conditional markup now also understands [@(:elseif ...:)@] and [@(:else:)@]. In addition, markup can nest conditionals by placing digits after if/elseif/else, as in [@(:if1 ...)@], [@(:elseif1 ...:)@], [@(:else1:)@], etc.%0a%0a* The [@(:if date ...:)@] conditional markup can now perform date comparisons for dates other than the current date and time.%0a%0a* [[WikiTrails]] can now specify #anchor identifiers to use only sections of pages as a trail.%0a%0a* A new [@(:if ontrail ...:)@] condition allows testing if a page is listed on a trail.%0a%0a* The extensions .odt, .ods, and .odp (from OpenOffice.org) are now recognized as valid attachment types by default.%0a%0a* A new [[blocklist]] capability has been added to the core distribution. It allows blocking of posts based on IP address, phrase, or regular expression, and can also make use of publicly available standard blocklists. See [[PmWiki.Blocklist]] for details.%0a%0a* There is a new [[SiteAdmin.AuthList]] page that can display a summary of all password and permissions settings for pages on a site. This page is restricted to administrators by default.%0a%0a* There are new [@{$PasswdRead}@], [@{$PasswdEdit}@], etc. variables that display the current password settings for a page (assuming the browser has attr permissions or whatever permissions are set in $PasswdVarAuth).%0a%0a* Forms creation via the [@(:input:)@] markup has been internally refactored somewhat (and may still undergo some changes prior to 2.2.0 release). The new [@(:input select ...:)@] markup can be used to create select boxes, and [@(:input default ...:)@] can be used to set default control values, including for radio buttons and checkboxes.%0a%0a* The [@(:input textarea:)@] markup now can take values from other sources, including page text variables from other pages.%0a%0a* Specifying [@focus=1@] on an [@(:input:)@] control causes that control to receive the input focus when a page is loaded. If a page has multiple controls requesting the focus, then the first control with the lowest value of [@focus=@] "wins".%0a%0a* PmWiki now provides a ''scripts/creole.php'' module to enable Creole standard markup. To enable this, add [@include_once('scripts/creole.php')@] to a local customization file.%0a%0a* PmWiki adds a new [@{(...)}@] ''markup expression'' capability, which allows various simple string and data processing (e.g., formatting of dates and times). This is extensible so that recipe authors and system administrators can easily add custom expression operators.%0a%0a* It's now possible to configure PmWiki to automatically create Category pages whenever a page is saved with category links and the corresponding category doesn't already exist. Pages are created only if the author has appropriate write permissions into the group. To enable this behavior, add the following to ''local/config.php'':%0a%0a-->[@$AutoCreate['/^Category\\./'] = array('ctime' => $Now);@]%0a%0a* Sites with wikiwords enabled can now set $WikiWordCount['WikiWord'] to -1 to indicate that 'WikiWord' should not be spaced according to $SpaceWikiWords.%0a%0a* WikiWords that follow # or & are no longer treated as WikiWords.%0a%0a* Links to non-existent group home pages (e.g., [@[[Group.]]@] and [@[[Group/]]@]) will now go to the first valid entry of $PagePathFmt, instead of being hardcoded to "Group.Group". For example, to set PmWiki to default group home pages to [@$DefaultName@], use%0a%0a-->[@$PagePathFmt = array('{$Group}.$1', '$1.{$DefaultName}', '$1.$1');@]%0a%0a* PmWiki now provides a $CurrentTimeISO and $TimeISOFmt variables, for specifying dates in ISO format.%0a%0a* [[(Cookbook:)Cookbook]] authors can use the internal PmWiki function UpdatePage (temporarily documented at [[(Cookbook:)DebuggingForCookbookAuthors]]) to change page text while preserving history/diff information, updating page revision numbers, updating RecentChanges pages, sending email notifications, etc.%0a%0a* [[Skin templates]] are now required to have %3c!--HTMLHeader--> and %3c!--HTMLFooter--> directives. Setting $EnableSkinDiag causes PmWiki to return an error if this isn't the case for a loaded skin. Skins that explicitly do not want HTMLHeader or HTMLFooter sections can use %3c!--NoHTMLHeader--> and %3c!--NoHTMLFooter--> to suppress the warning.%0a%0a* Added a new "pre" wikistyle for preformatted text blocks.%0a%0a* The xlpage-utf-8.php script now understands how to space UTF-8 wikiwords. %0a%0a* Searches on utf-8 site are now case-insensitive for utf-8 characters.%0a%0a* Many Abort() calls now provide a link to pages on pmwiki.org that can explain the problem in more detail and provide troubleshooting assistance.%0a%0a* PmWiki no longer reports "?cannot acquire lockfile" if the visitor is simply browsing pages or performing other read-only actions.%0a%0a* The $EnableReadOnly configuration variable can be set to signal PmWiki that it is to run in "read-only" mode (e.g., for distribution on read-only media). Attempts to perform actions that write to the disk are either ignored or raise an error via Abort().%0a%0a* Including authuser.php no longer automatically calls ResolvePageName().%0a%0a* Authentication using Active Directory is now simplified. In Site.AuthUser or the $AuthUser variable, set "ldap://name.of.ad.server/" with no additional path information (see PmWiki.AuthUser for more details).%0a%0a* Pages are now saved with a "charset=" attribute to identify the character set in effect when the page was saved.%0a%0a* The phpdiff.php algorithm has been optimized to be smarter about finding smaller diffs.%0a%0a* Removed the (deprecated) "#wikileft h1" and "#wikileft h5" styles from the pmwiki default skin.%0a%0a* The mailposts.php and compat1x.php scripts have been removed from the distribution.%0a%0a----%0aBugs and other requests can be reported to the PmWiki Issue Tracking %0aSystem at http://www.pmwiki.org/wiki/PITS/PITS. Any help%0ain testing, development, and/or documentation is greatly appreciated..%0a%0a[[(PmWiki:)Release Notes archive]] - notes for versions older than 2.2.0.%0a%0a%0a%0a%0a -time=1593841805 +rev=781 +targets=PmWiki.Upgrades,PmWiki.ChangeLog,PmWiki.Download,PmWiki.RoadMap,PmWiki.EditVariables,PmWiki.BasicVariables,PmWiki.AuthUser,PmWiki.SecurityVariables,Cookbook.PmSyntax,PmWiki.WikiStyles,PmWiki.LayoutVariables,PmWiki.PageVariables,Cookbook.MarkupDirectiveFunctions,PmWiki.OtherVariables,PmWiki.PagelistVariables,Cookbook.CustomSyntax,PmWiki.Notify,Cookbook.LocalTimes,Cookbook.RecentUploadsLog,Cookbook.DiffDelay,PmWiki.PageLists,Cookbook.ReindexCategories,Cookbook.PageListMultiTargets,PITS.01095,PmWiki.Functions,PITS.01461,Cookbook.RecipeCheck,Skins.SkinChange,Cookbook.ToggleNext,PmWiki.Links,PmWiki.Forms,PmWiki.TableOfContents,Cookbook.SectionEdit,PmWiki.BlockMarkup,Cookbook.DeObMail,Cookbook.FixURL,Cookbook.NotSavedWarning,Cookbook.EditHelp,Cookbook.AutoTOC,Cookbook.DeltaBytesRecentChanges,Cookbook.RowspanInSimpleTables,Cookbook.LocalCSS,PmWiki.LinkVariables,Cookbook.PreviewChanges,PmWiki.MarkupExpressions,PmWiki.DebugVariables,PmWiki.WikiTrails,SiteAdmin.AuthList,PmWiki.PathVariables,Site.UploadQuickReference,Cookbook.PmForm,PmWiki.Troubleshooting,PmWiki.CustomMarkup,PmWiki.PageDirectives,PmWiki.UploadVariables,PmWiki.I18nVariables,PmWiki.PageHistory,PmWiki.Uploads,PmWiki.Passwords,PmWiki.SiteAnalyzer,Site.Site,SiteAdmin.SiteAdmin,PITS.00961,Site.PageActions,Site.EditForm,Site.PageNotFound,PmWiki.Drafts,PmWiki.Blocklist,Cookbook.Cookbook,Cookbook.DebuggingForCookbookAuthors,PmWiki.SkinTemplates,PmWiki.ReleaseNotesArchive +text=(:title Release Notes:)(:Summary: Notes about new versions, important for upgrades:)%0aSee also: [[Upgrades]], [[Change log]], [[(PmWiki:)Download]] and [[(PmWiki:)Road map]].%0a(:comment The {*$:Released} variable is used in [[News/]]. :)%0a%0a!! Version 2.3.20 {*$:Released} (2023-02-12) [[#v2320]]%0aThis version fixes an unidentified variable warning introduced yesterday in 2.3.19.%0a%0a!! Version 2.3.19 {*$:Released} (2023-02-11) [[#v2319]]%0aThis version includes fixes for recent PHP versions, new helper functions, new variables allowing more customization, and the documentation was updated.%0a%0aWork is underway to define and implement a new family of self-contained recipes "Modules" which should be easier to install, configure and update. It may be possible to easily update your modules and skins either from a remote Git/SVN repository, or by simply dropping a ZIP file into the "modules" directory, and use a wiki-based editor to enable and configure them. Nothing will change for existing recipes, and they will not need to be updated; this will be an entirely optional new interface. Let me know if you can suggest features/scopes added to the wishlist.%0a%0aPmWiki too may be able to run directly from the read-only release ZIP archive, without the need to unzip it first. Again, this will be entirely optional, the current ways will continue to work as before, and slightly faster than the ZIP version (approx. 2%25 faster in my benchmarks).%0a%0a%0a!! Version 2.3.18 {*$:Released} (2023-01-15) [[#v2318]]%0a%0aThis version fixes a bug user groups in with conditional markup, includes updates for PHP 8, minor improvements to the edit textarea and to the syntax highlighting. A helper function pm_json_encode() was added for servers where the PHP-JSON extension is not enabled.%0a%0aThe documentation was updated.%0a%0a!! Version 2.3.17 {*$:Released} (2022-12-17) [[#v2317]]%0a%0aThis release has updates for recent PHP versions.%0a%0aThe edit textarea had some improvements. Edit buttons and the automatic edit text will now insert their wiki markup in a way which allows for the "undo" function in the text area to work (with Ctrl+Z). The edit textarea (with $EnableEditAutoText enabled) now accepts 4 new keyboard shortcuts: Ctrl+L and Ctrl+Shift+L to convert the selected text to lowercase or uppercase, and Ctrl+Shift+ArrowUp or ArrowDown to move the line with the cursor up or down.%0a%0aA new variable $EnableBaseNameConfig was added - it allows to enable automatic inclusion of local configuration for the "basename" of the current page, for example Group.Page-Draft to include local/Group.Page.php if it exists.%0a%0aConditional markup %25pmhlt%25[@(:if auth @admins,@editors:)@] can now check if the current user belongs to selected usergroups (with [[AuthUser]]).%0a%0aA few minor bugs and omissions were fixed, and the documentation was updated.%0a%0a!! Version 2.3.16 {*$:Released} (2022-11-28) [[#v2316]]%0a%0aThis version fixes a bug with some skins introduced in 2.3.15 last week, and reverts PrePrintFmt(). %0a%0aNew WikiStyles 'notoc' and 'overflow' were added. PmTOC Table of contents, and the list of included pages in the edit form, now use classnames instead of style attributes.%0a%0aPmSyntax fixes a font-size alignment bug with nested programming languages, and has been optimized for large pages.%0a%0aA few more minor bugs were fixed, including for PHP 8, and the documentation was updated.%0a%0a%0a!! Version 2.3.15 {*$:Released} (2022-11-21) [[#v2315]]%0a%0aSecurity: Closed a potential XSS vulnerability discovered today. Your wiki may be at risk if untrusted people can edit your pages.%0a%0aHTTP headers: CSP updated, XSSP added. Both can be disabled or modified by changing the $HTTPHeaders values.%0a%0aCookies: Added a new variable $CookieSameSite default to 'Lax' per current browser defaults and expectations. Updated pmsetcookie() added an argument $samesite, and refactored to work with old and current PHP versions. Added function pm_session_start() as a replacement for session_start() with respect for local preferences ($CookieSameSite, $EnableCookieSecure, $EnableCookieHTTPOnly). %0a%0a[[Cookbook:PmSyntax|PmSyntax]]: A new CSS variable @@--pmsyntax-fontsize-editform@@ allows to set the font size of the edit form separately from highlighted elements in the documentation. Fixed the [@[[Highlight]]@] label could change fonts when clicked.%0a%0aResponsive skin: The font size for "pre" and "code" elements is now scalable/relative to the paragraph font size rather than fixed. This works better in headings or small text blocks.%0a%0aGUI edit buttons: Part of these functions were rewritten to avoid 'unsafe inline' JavaScript. While default and most custom buttons should work without change, you should no longer need to url-encode some characters like %25 or add backslashes. If you have such buttons, you may need to update their declarations to strip the extra backslashes. %0a%0a[[WikiStyles]]: Refactored to move all inline WikiStyles to the $HTMLStylesFmt array in the header of the HTML page.%0a%0aTables and block markup: Replaced inline @@style="..."@@ attributes with class names. %0a%0aThe function PrintFmt() was refactored to process skin parts, skin functions, markup, and wiki pages, before sending the HTTP and HTML headers. This allows for wikistyles and recipes in sidebars and footers to add their configuration to the headers.%0a%0aIf you have questions or difficulties upgrading, please contact us.%0a%0a!! Version 2.3.14 {*$:Released} (2022-11-03) [[#v2314]]%0a%0aThis version includes fixes for recent PHP versions and for 2 minor bugs (searchbox wrongly encoded entities and %25pmhlt%25[@{(ftime %25L)}@] format). Inline JavaScript for focusing form fields is now replaced with native attributes. In the Edit form, the "Minor edit" label can now toggle the checkbox.%0a%0aThe "disabled obsolete markup" tooltip now includes the file path and the line number of the markup rule definition.%0a%0aPmSyntax now recognizes %25pmhlt%25[@(:template requires? ...:)@] which is used by some recipes.%0a%0aThe documentation was updated.%0a%0a!! Version 2.3.13 {*$:Released} (2022-10-07) [[#v2313]]%0aThis version closes a potential XSS vulnerability, reported by lukystreik. A new variable $FailedLoginsFunction will allow to define a function limiting the number of failed logins. The documentation was updated.%0a%0a!! Version 2.3.12 {*$:Released} (2022-09-25) [[#v2312]]%0aThis version has a few fixes for PHP8. Complex conditionals with empty page variables could cause errors, now fixed. Form elements with values like "0" could appear empty, now fixed. The PSFT() function and the %25pmhlt%25[@{(ftime)}@] markup expression now recognize a "%25L" format as a human-readable localizable timestamp. A new helper function PrintAuthForm() was split from PmWikiAuth() to allow recipes to call it directly. The documentation was updated.%0a%0a!! Version 2.3.11 {*$:Released} (2022-08-30) [[#v2311]]%0a%0aThis version fixes the function stripmagic(), when used with arrays (a recent update for PHP 8 broke it).%0a%0aNew [[PageVariables]] derived from a Group's homepage are now available: %25pmhlt%25 [@{$GroupHomePage}@], [@{$GroupHomePageName}@], [@{$GroupHomePageTitle}@], [@{$GroupHomePageTitlespaced}@].%0a%0aA new helper function should simplify recipes with custom markup directives of the format:%0a%0a-> %25pmhlt%25 [@(:mydirective arg=val param="other value":)...(:mydirectiveend:)@].%0a%0aSee the documentation at Cookbook:MarkupDirectiveFunctions.%0a%0aThe core documentation was updated.%0a%0a%0a!! Version 2.3.10 {*$:Released} (2022-08-20) [[#v2310]]%0a%0aThis version includes updates for PHP 8. Wildcard $DefaultUnsetPageTextVars should now work with forms. PmSyntax fixed text alignment between the edit area and the colored block in some cases. The documentation was updated.%0a%0a!! Version 2.3.9 {*$:Released} (2022-08-18) [[#v239]]%0a%0aThis version includes updates for PHP 8. Non-wildcard $DefaultUnsetPageTextVars should now work with %25pmhlt%25[@(:input default:)@]. PmSyntax now handles blocks with simpler selectors, possibly created by recipes. The documentation was updated.%0a%0a!! Version 2.3.8 {*$:Released} (2022-07-22) [[#v238]]%0a%0aThis version fixes a bug caused by a recent update for PHP 8 with the include markup:%0a%0a %25pmhlt%25[@(:include Page1 Page2 Page3:)@]%0a%0aWhen the first page doesn't exist, it didn't check for the other pages (now fixed).%0a%0aIn addition, PmSyntax was improved when more than one inline blocks are on the same line, and the documentation was updated.%0a%0a%0a!! Version 2.3.7 {*$:Released} (2022-06-28) [[#v237]]%0a%0aThis version sets default HTTP headers X-Frame-Options (reported by Imagine Dragon) and Content-Security-Policy to disallow embedding in external websites by default and clickjacking attempts.%0a%0aShould you require the previous behavior, you can add this line to local/config.php:%0a%0a-> %25hlt php%25[@unset($HTTPHeaders['XFO'], $HTTPHeaders['CSP']);@]%0a%0a$EnableHighlight will now remember any links to PmWiki variables and restore them after the highlighting. %0a%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%0aThe documentation was updated.%0a%0a%0a!! Version 2.3.6 {*$:Released} (2022-06-19) [[#v236]]%0a%0aThis version contains fixes for PHP 8. A form attribute "lang" was added. %0a%0aSortable tables now allow for table headers to have markup such as bold (except links), and will use a case-insensitive natural ordering. %0a%0aSearchbox now has a default placeholder %25pmhlt%25 [@"$[Search]"@] and can have the submit button removed with the argument [@label=""@] (users need to press Enter on their keyboards to search).%0a%0a$EnableHighlight-formatted code blocks are now converted to plain text to prevent warnings; there is an ongoing discussion in the mailing list so this solution may evolve.%0a%0aFor developers: $UploadVerifyFunction can now modify $upname, and a variable $PageIndexTermsFunction can configure a replacement function for PageIndexTerms().%0a%0aThe documentation was updated.%0a%0a%0a!!Version 2.3.5 {*$:Released} (2022-05-23) [[#v235]]%0a%0aThis version fixes a bug with %25pmhlt%25 @@[=(:pagelist list=grouphomes:)=]@@. A new helper function DisableSkinParts() allows for simpler disabling of headers, footers and sidebars from recipes. When a file is uploaded, new variables with the file path and URL are now available to recipes.%0a%0aThe version also contains fixes for PHP 8 and documentation updates.%0a%0a%0a!!Version 2.3.4 {*$:Released} (2022-04-22) [[#v234]]%0a%0aThis version includes fixes for PHP 8 and documentation updates.%0a%0a%0a!!Version 2.3.3 {*$:Released} (2022-03-26) [[#v233]]%0a%0aThis version includes fixes for PHP 8 and documentation updates.%0a%0a%0a!!Version 2.3.2 {*$:Released} (2022-02-09) [[#v232]]%0a%0aThis version includes bug fixes and updates for PHP 8.1. The core variable $EnableIncludedPages introduced in 2.3.0 was renamed to $EnableListIncludedPages to avoid ambiguity. With LocalTimes, is now possible to configure the number of days the "plus" button will pull from the page history, and the function will better recognize some older RecentUploads formats. PmSyntax was updated so that "%25pmhlt%25@@\\@@" line breaks in tables and headings are treated like in the core, staying in the same context; and the different PmSyntax blocks will now be processed in parallel.%0a%0aThe code configuring and loading pmwiki-utils.js was moved to a new file scripts/utils.php, and a new variable $EnablePmUtils was added to allow administrators to easily disable these functions. The script pmwiki-utils.js will now be included in the page header rather than the footer, which may reduce the number of page redraws. The individual functions will now be processed in parallel.%0a%0aThe documentation was updated.%0a%0a%0a!!Version 2.3.1 {*$:Released} (2022-01-15) [[#v231]]%0a%0aThere was an omission in the release script which unexpectedly deleted the $VersionNum variable which broke some settings. This quick release fixes it.%0a%0a!!Version 2.3.0 {*$:Released} (2022-01-15) [[#v230]]%0a%0aJanuary 2022 is the 20th year anniversary of the release of PmWiki version 0.1, and 13 years since I (Petko) became core developer. This merited additional work and effort with hopefully interesting and useful new production.%0a%0a'''PHP 5.3 - 8.1 compatibility''' %0a* PmWiki 2.3.0 includes updates for PHP 8.0 and 8.1.%0a* Consequently, it requires PHP version 5.3 (released 2009) or more recent.%0a%0a'''PmSyntax'''. A new function PmSyntax was added to the core, and enabled on pmwiki.org. %0a* It highlights PmWiki syntax in the documentation, and possibly in the basic edit form. %0a* It only highlights PmWiki markup, and is independent from Highlight.js. See Cookbook:PmSyntax and $EnablePmSyntax. %0a* It should highlight most core language features and those of many recipes, see [[https://www.pmwiki.org/wiki/Test/PmSyntax|this mashup of various markups]]. %0a* Developers can add custom rules in the $CustomSyntax array, see Cookbook:CustomSyntax. %0a* The %25pmhlt%25 [@(:markup:)@] directive can now have @@class=norender@@ to only show the source code without processing it. This may be useful, together with PmSyntax, in 2 cases: writing/discussing markup code without actually running it, or working on PageList Templates where you want to see and edit them highlighted.%0a%0a'''Improvements to the edit form'''%0a* PmSyntax (above) can be enabled to highlight the PmWiki markup the edit form, and should work in recent standards-compliant browsers.%0a* The variable $EnableNotSavedWarning is now enabled by default. Add to config.php @@$EnableNotSavedWarning = 0;@@ to disable it.%0a* A new variable {- $EnableIncludedPages -} $EnableListIncludedPages (from 2.3.2) allows listing of other pages included from the currently edited page, with links to see or edit them. When the variable is enabled, the list of pages appears in the edit form, after the text area, in a collapsed %3cdetails> element. The list includes pages from which text, text variables, or templates are included from the edited page. This is enabled on pmwiki.org if you wish to preview it.%0a* The $EnableEditAutoText function will now feel more like other text editors by removing the automatically inserted bullet when Enter is pressed twice.%0a%0a'''Dates and times, monitoring, review'''%0a* The %25pmhlt%25 [@{(ftime)}@] Markup expression now accepts a new format '[@%25o@]' for the ordinal suffix of the date.%0a* The [[Notify]] feature now accepts a @@tz=@@ timezone specifier for individual subscribers. See [[Notify#tz]].%0a* A function based on Cookbook:LocalTimes was added to the core. See [[Cookbook:LocalTimes|the recipe page]] for the differences. You can continue using the recipe, or disable it and enable the core function.%0a* New core variables $EnableLocalTimes, $CurrentLocalTime.%0a* New markup %25pmhlt%25[@@2022-01-09T08:35:00Z@]%25%25 output as a %3ctime> element, formatted via $TimeFmt; localized if $EnableLocalTimes. %0a* Added a variable $EnableRecentUploads which makes it easy to enable the Recent Uploads feature on AllRecentChanges. This is a basic format that may be good enough for many wikis. For more options, see Cookbook:RecentUploadsLog.%0a* The default $RecentChangesFmt now use the variable $CurrentLocalTime instead of $CurrentTime. In the wiki source text it saves the timestamps in a portable time format in GMT, which is then shown formatted per $TimeFmt (wiki timezone). It looks just like $CurrentTime did previously, but can be converted to the visitor's time zone if LocalTimes is enabled. If you have custom $RecentChangesFmt entries that use $CurrentTime, nothing will change for you, but you may want to update these with $CurrentLocalTime if you want to benefit from localization.%0a* The "page history" page now has CSS classes for the delay between edits: diffday, diffweek, diffmonth, diffyear. These allow styling of vertical spacing between individual edits in page histories. See Cookbook:DiffDelay for an example.%0a* The page history can now have a "hidden" edit type, in addition to "minor". This is intended to be used by recipes in order to hide, rather than delete, some edits from the page history. A couple of new recipes using this feature will be added in the next few days.%0a%0a'''PageLists, categories, backlinks'''%0a* [[PageLists]] now accept a new argument @@category=Name@@ which lists only pages declared in the category with the markup %25pmhlt%25 [@[[!Name]]@], and does not include pages simply linking to [@[[Category/Name]]@] (unless they also contain [@[[!Name]]@]).%0a** The differentiation between links to !Name and Category.Name requires the pages containing category links to be re-indexed; see Cookbook:ReindexCategories which can automate this.%0a* Also in PageLists, the arguments @@link=@@ and @@category=@@ now accept multiple and negative specifiers, and wildcards. See [[PageLists#wildcards]]. If you previously used the recipe Cookbook:PageListMultiTargets, please disable it when you upgrade to 2.3.0.%0a* Category links can now have a different text, like %25pmhlt%25 [@[[!Name|Text]]@], and the markup generally behaves like other links, see PITS:01095.%0a%0a'''Styles''' (core skin PmWiki-responsive)%0a* Collapsible sections details+summary will now change the cursor to the "pointer" style over the clickable element, and the color will change to "navy". %0a* The core table of contents function ($PmTOC) has had its styles updated, in order to properly indent long sub-headings.%0a%0a'''Core helper functions'''%0a* A new helper function %25hlt php%25@@PSFT()@@ can now be used as an ''almost'' drop-in replacement for @@strftime()@@ and @@gmstrftime()@@ which became deprecated in PHP 8.1. Please review the documentation at [[Functions#PSFT]]. If you have local configurations or recipes using @@strftime()@@ you can change for @@PSFT()@@ now.%0a* A helper function %25hlt php%25@@DownloadUrl($pagename, $path)@@ was added, see [[Functions#DownloadUrl]]. It can simplify the handling of attached files by recipes.%0a%0aLast but not least, '''the documentation''' in English has been updated with the latest development (and in German by MFWolff).%0a%0aSee also [[Upgrades#v22v23|Upgrading from version 2.2.145 to 2.3.0]].%0a%0aAs always, if you have any questions or difficulties, please let us know.%0a%0a%0a!! Version 2.2.145 {*$:Released} (2021-12-11) [[#v22145]]%0aThis version includes a minor change in search patterns: searches and pagelists with a wrong or undefined $SearchPatterns (@@list=abc@@ argument) will now use $SearchPatterns["default"] rather than an empty array (effectively all pages). This was likely the intended behavior, a way for admins to restrict search locations.%0a%0aIt also includes updates for PHP 8, a fix of an emoji for non-UTF8 wikis, and the latest pages of the documentation.%0a%0a!! Version 2.2.144 {*$:Released} (2021-11-06) [[#v22144]]%0aThis version includes fixes for PHP 8 and an update to @@intermap.txt@@. The conditional markup "exists" was optimized when called multiple times. The functions %25hlt php%25@@CondExists()@@, @@MatchPageNames()@@, and @@MatchNames()@@, can now be called with an additional argument (false) when a case-sensitive match is needed. The documentation was updated.%0a%0a!! Version 2.2.143 {*$:Released} (2021-10-02) [[#v22143]]%0aThis version should prevent some errors from local customization or recipes with recent PHP versions, by disabling obsolete markup rules and replacement patterns. If such markup appears on a page, it will not be processed, it will be rendered like this: %25frame%25@@⚠(:my-obsolete-directive params:)@@%25%25 and a tooltip title should have some additional information.%0a%0aCare should be taken if you have custom calls to the deprecated function [[PmWiki/Functions#PCCF|%25hlt php%25@@PCCF()@@]], and incompatible custom replacement patterns processed via [[PmWiki/Functions#PPRE|@@PPRE()@@]] or [[PmWiki/Functions#PPRA|@@PPRA()@@]] are silently skipped, which may not work as expected. (Previously they wouldn't work at all.)%0a%0aIf you experience any difficulties, please do let us know and we'll try to provide a fix.%0a%0aThe documentation was updated.%0a%0a!! Version 2.2.142 {*$:Released} (2021-08-31) [[#v22142]]%0aThis version hides some PHP 8 notices, and adds 2 new form element attributes "accept" and "autofocus". %0a%0aThe documentation was updated.%0a%0a%0a!! Version 2.2.141 {*$:Released} (2021-07-09) [[#v22141]]%0aThis version adds ways to define 2 custom functions:%0a* $MultiFactorAuthFunction to enable custom MFA/2FA with [[AuthUser]]%0a* $PageIndexFoldFunction to define a custom function normalizing the page terms while indexing and searching (by default PmWiki converts the terms to lowercase).%0a%0aThe documentation was updated.%0a%0a!! Version 2.2.140 {*$:Released} (2021-06-26) [[#v22140]]%0aThis version has updates for PHP 8. %0a%0aThe API of the source code highlighting library has changed and the PmWiki loader function was adapted; if you use this feature, please upgrade Highlight.js to version 11.0.0 or newer. %0a%0aNote: since version 11, Highlight.js doesn't preserve HTML in the preformatted blocks and issues a console warning, so you should only use the [@(space)[=escaped=]@] or the @@[=[@escaped@]=]@@ markup blocks.%0a%0aThe documentation was updated.%0a%0a!! Version 2.2.139 {*$:Released} (2021-05-05) [[#v22139]]%0aThis version removes empty "title" attributes in HTML tags (links and images), fixes warnings which appear with PHP 8 and updates the documentation.%0a%0a!! Version 2.2.138 {*$:Released} (2021-03-02) [[#v22138]]%0aThis version fixes a bug when a details directive has markup in the summary attribute, and the documentation was updated.%0a%0a!! Version 2.2.137 {*$:Released} (2021-02-26) [[#v22137]]%0aThis version fixes a bug introduced earlier today with entities encoded twice in PQA() quoted arguments.%0a%0a!! Version 2.2.136 {*$:Released} (2021-02-26) [[#v22136]]%0aThis version fixes a XSS vulnerability for WikiStyles reported today by Igor Sak-Sakovskiy.%0a%0aThe fix adds a second argument $keep to the core function PQA($attr, $keep=true) which by default escapes HTML special characters and places the values in Keep() containers. If you have custom functions that call PQA() and expect the previous behavior, call PQA() with a second argument set to false.%0a%0aIf you have any questions or difficulties, please let us know.%0a%0a!! Version 2.2.135 {*$:Released} (2021-01-31) [[#v22135]]%0aThis version fixes a number of PHP8 compatibility issues. This is a work in progress, if you uncover others, please report them at PITS:01461.%0a%0aA work is underway to implement session tokens to prevent CSRF vulnerabilities -- suggested by Dominique Faure. I wanted to rework these functions but the PHP8 compatibilities are more urgent so at the moment the PmToken functions are transparent/non-functional.%0a%0aA defunct syndicated blocklist was disabled, a minor code refactoring was done for PmTOC to better support manual edit section links, and the documentation was updated.%0a%0a%0a!! Version 2.2.134 {*$:Released} (2020-11-30) [[#v22134]]%0aThis is a documentation update version.%0a%0a!! Version 2.2.133 {*$:Released} (2020-10-25) [[#v22133]]%0aThis version fixes a potential vulnerability to CWE-384: Session Fixation, reported by Dominique Faure. The fix regenerates the session identifier at the moment someone logs in. In case this is not desirable, a wiki admin can set the new variable $EnableAuthPostRegenerateSID to false.%0a%0aThis version also fixes an unintended variable evaluation in link markups. The CSS from Cookbook:RecipeCheck will now be injected only when needed. The responsive skin styles contained a reduced padding value for numbered and bulleted lists in order to save space, but in longer lists it could clip the item numbers. This value was removed from the styles because it was complex to reliably override it from local configuration. If you need to enable the previous values, add to pub/css/local.css the following:%0a%0a%25hlt css%25[@%0aul, ol { padding: 0 0 0 20px; }%0a@media screen and (min-width:50em) {%0a ul, ol { padding: 0 0 0 40px; }%0a}@]%0a%0a!! Version 2.2.132 {*$:Released} (2020-09-30) [[#v22132]]%0aThis is a documentation update version.%0a%0a!! Version 2.2.131 {*$:Released} (2020-08-30) [[#v22131]]%0aThis is a documentation update version.%0a%0a!! Version 2.2.130 {*$:Released} (2020-07-04) [[#v22130]]%0aThis is a documentation update version.%0a%0a!! Version 2.2.129 {*$:Released} (2020-05-21) [[#v22129]]%0aThis version adds the styles for the "simpletable" class of tables from the "pmwiki-responsive" skin into the old "pmwiki" skin, and the documentation was updated.%0a%0a!! Version 2.2.128 {*$:Released} (2020-04-26) [[#v22128]]%0aThis version only includes some cosmetic changes and updates the documentation.%0a%0a!! Version 2.2.127 {*$:Released} (2020-03-23) [[#v22127]]%0aThis version sets the maximum height of the edit form textarea after reports for a jumping behavior on mobile devices (the PmWiki-responsive skin only). The core table of content classes "pmtoc-show" and "pmtoc-hide" now replace the previous classes "show" and "hide" to prevent conflicts with other frameworks. The functionality of the recipe Skins:SkinChange was added to the core (disabled by default). The documentation was updated.%0a%0a!! Version 2.2.126 {*$:Released} (2020-02-01) [[#v22126]]%0aThis version fixes a bug with $PmTOC['MinNumber'] set to -1, and updates the .htaccess format for caches.php. The documentation was updated.%0a%0a!! Version 2.2.124, 2.2.125 {*$:Released} (2020-01-27) [[#v22124]] [[#v22125]]%0aThis version adds a variable $SetCookieFunction to override the core "pmsetcookie" function. A new feature ToggleNext was included in the core, documented at Cookbook:ToggleNext. The documentation was updated.%0a%0a!! Version 2.2.123 {*$:Released} (2019-12-31) [[#v22123]]%0aThis version allows link URLs to be [[Links#escaped | escaped]] with [@[=link address=]@] if they contain any special characters, including quotes, parentheses and pipes. The obfuscated e-mails will now work from headers, footers and sidebars. A [[forms|form]] attribute "formnovalidate" was added to the core and to the "Cancel" button in the edit form. Core [[table of contents]] will now work better with Cookbook:SectionEdit. Cookbook:RecipeCheck was included in the core -- if you have this recipe already installed, you can simply comment it out from your config.php. The code that handles $EnableRCDiffBytes was refactored to also show the bytes changed in the page histories. New upload extensions [[https://developers.google.com/speed/webp | "webp"]] (images) and [[https://www.opus-codec.org/ | "opus"]] (audio) were added. The documentation was updated.%0a%0a!! Version 2.2.122 {*$:Released} (2019-11-19) [[#v22122]]%0aVersion 2.2.121 was released by mistake and contained some experimental code that was meant to be tested first. %0a%0aThis version fixes a bug with ObfuscateLinkIMap() and international characters. New configuration variables $DefaultUnsetPageTextVars, $DefaultEmptyPageTextVars can set default values for page text variables. The built-in table of contents and numbered headings can now be enabled independently. A pagelist template pseudovariable [@{$$EachCount}@] was added, containing the number of the page in the current "each" loop. Input form elements and the [@(:searchbox:)@] field now can have ARIA accessibility attributes.%0a%0aThe documentation was updated.%0a%0a!! Version 2.2.120 {*$:Released} (2019-10-13) [[#v22120]]%0aThis version fixes a bug with existing complex customization of GUIEdit buttons. Very long [[table of contents|tables of contents]] will now be scrollable. A new "input datalist" [[Forms|form]] element (list of suggestions to other input fields), and a new "details+summary" [[block markup|block section]] (toggle sections without JavaScript) were added. The documentation was updated.%0a%0a!! Version 2.2.119 {*$:Released} (2019-10-03) [[#v22119]]%0aThis version updates the core for PHP 7.4. Required input fields now feature @@required="required"@@ attributes and modern browsers prevent sending the edit or upload form with empty required fields. Attachlist @@ext=@@ and @@names=@@ arguments now accept patterns and negatives like @@ext=jpg,png@@, @@ext=-pdf@@, or @@names=-th*---*.jpg@@. The Redirect function can now have a 3rd argument with the full URL. The scroll position in the edit text area will be remembered on save-and-edit and preview. A bug was fixed with pagelist while preview. The documentation was updated.%0a%0aA number of features currently provided by recipes were added to the core and disabled by default. You can still use the recipes, or you can disable them and enable the core features. The following features were added:%0a* e-mail obfuscation functions based on Cookbook:DeObMail; see instructions to enable%0a* a FixUrl button based on Cookbook:FixURL, see $EnableGuiEditFixUrl%0a* $EnableNotSavedWarning based on Cookbook:NotSavedWarning%0a* $EnableEditAutoText based on Cookbook:EditHelp%0a* $PmTOC, [@(:toc:)@], [@(:notoc:)@], Table of contents/Numbered headings, based on a simplified variant of Cookbook:AutoTOC%0a* $EnableSortable, basic sortable tables%0a* $EnableRCDiffBytes based on Cookbook:DeltaBytesRecentChanges%0a* $EnableSimpleTableRowspan replicating the markup from Cookbook:RowspanInSimpleTables%0a* $WikiPageCSSFmt enables CSS in a wiki page, based on Cookbook:LocalCSS%0a* $EnableHighlight code highlight feature compatible with "highlight.js"%0a* $AddLinkCSS['othergroup'] and $AddLinkCSS['samedomain'] can contain custom CSS classes for in-wiki links to other groups and for URL links to the same site.%0a%0aThe above new features are disabled by default, see the documentation for more information on how to enable them, or test them on pmwiki.org where most of these are enabled. Please report if you notice any problems.%0a%0a!! Version 2.2.118 {*$:Released} (2019-08-28) [[#v22118]]%0aThis version integrates the features of the recipe Cookbook:PreviewChanges into the core. If you currently use this recipe, please uninstall it and add to config.php:%0a $EnablePreviewChanges = 1;%0a%0aThe documentation was updated.%0a%0a!! Version 2.2.117 {*$:Released} (2019-07-28) [[#v22117]]%0aThis version adds handling of "partial content" requests for file downloads. New video file extensions 'm4v' and '3gp' were added. The Upload form now includes a new text field "Uploader" pre-filled with the name of the editor, and a new variable $EnableUploadAuthorRequired was added (defaults to $EnablePostAuthorRequired). The documentation was updated.%0a%0a!! Version 2.2.116 {*$:Released} (2019-06-19) [[#v22116]]%0aThis version fixes pagelists with case insensitive matches of page (text) variables for international wikis. If your international wiki pagelists rely on case-sensitive variable matches, please see $PageListVarFoldFn. The documentation was updated.%0a%0a!! Version 2.2.115 {*$:Released} (2019-05-13) [[#v22115]]%0aIn this version the responsive skin in large "desktop" mode changes the search form background to transparent, for easier custom styling of the header. The documentation was updated.%0a%0a!! Version 2.2.114 {*$:Released} (2019-04-02) [[#v22114]]%0aThis version adds a skin directive @@%3c!--IncludeTemplate ... -->@@ and the variable $SkinTemplateIncludeLevel. The core variable documentation format identifiers were moved to the definition term element to allow CSS ":target" styling, and the header and link text of the vardoc table can now be translated. Input forms have a new HTML5 element "tel", a new attribute "pattern" and two bugs were fixed with the classnames of the new elements and with the identifiers of "select" lists. The documentation was updated.%0a%0a!! Version 2.2.113 {*$:Released} (2019-03-01) [[#v22113]]%0aThis version adds a new [@(:input button:)@] form element. All form elements can now accept custom data-* attributes, which can be disabled by setting $EnableInputDataAttr to 0. Both additions are meant for easier integration with custom JavaScript functions or some frameworks.%0a%0aThe documentation was updated.%0a%0a!! Version 2.2.112 {*$:Released} (2019-01-09) [[#v22112]]%0aThis version includes a fix for PHP 7.3, and the documentation was updated.%0a%0a!! Version 2.2.111 {*$:Released} (2018-12-08) [[#v22111]]%0aThis version updates core .htaccess files to be compatible with both Apache 2.4 and earlier versions, and the variable $DenyHtaccessContent was added with the updated content. In case of difficulties or questions please contact us.%0a%0aA CSS value in the pmwiki-responsive skin was fixed. The [[MarkupExpression(s)]] [@{(ftime )}@] now accepts @@tz=@@ (time zone) and @@locale=@@ (language locale) arguments. The documentation was updated.%0a%0a!! Version 2.2.110 {*$:Released} (2018-11-05) [[#v22110]]%0aThis version prevents a warning with the [@{(substr )}@] markup expression when non-number arguments are typed. A new variable $PageListSortCmpFunction allows custom functions to order page lists. A new variable $MarkupMarkupLevel indicates when the processing happens inside [@(:markup:)@] blocks. %0a%0aThe default style for @@[=[@escaped code@]=]@@ dropped white spaces inconsistently and was fixed. If you rely on the previous behavior please add this to your pub/css/local.css file to revert it:%0a%0a code.escaped { white-space: nowrap; }%0a%0aThe documentation was updated.%0a%0a!! Version 2.2.109 {*$:Released} (2018-07-09) [[#v22109]]%0aThis version fixes a bug with the Path: InterMap prefix which was broken in 2.2.108. The function pmcrypt() was updated to prevent more strings from causing "invalid hash" warnings in PHP 7. The variable $EnableMarkupDiag was added to help diagnose all markup calls. The documentation was updated.%0a%0a!! Version 2.2.108 {*$:Released} (2018-07-05) [[#v22108]]%0aThis version adds the $PCCFOverrideFunction variable allowing a custom function to override PCCF(). $AuthUserPageFmt can now be an array of page names. The page cache file name can now be customized. Form checkbox labels now have the same tooltip title as the checkbox. Ordered lists with the [@%25reversed%25@] WikiStyle will have descending numbers. Minor fixes to refcount.php, vardoc.php, and pmcrypt(). The default InterMap PmWiki URLs have now the HTTPS protocol. The documentation was updated.%0a%0a!! Version 2.2.107 {*$:Released} (2018-02-02) [[#v22107]]%0aThis version includes more fixes for PHP 7.2 for forms and pagelists. A new variable $MailFunction allows administrators and developers to write replacement functions for the PHP function "mail()". Styles were improved for right-to-left text blocks embedded into left-to-right texts (and vice versa). The documentation was updated.%0a%0a!! Version 2.2.106 {*$:Released} (2017-12-01) [[#v22106]]%0aThis version has a rewrite of the function PageListSort() to allow it to work with PHP 7.2, and fixes a bug with the backtick (escape) [@`WikiWord@] markup. The helper function pmsetcookie() and the variables $EnableCookieSecure, $EnableCookieHTTPOnly were added to allow easy setting of secure cookies. The documentation was updated.%0a%0a!! Version 2.2.105 {*$:Released} (2017-11-07) [[#v22105]]%0aThis version fixes a bug with the PQA() function causing invalid HTML with attributes glued together. The function @@HandleUpload()@@ was refactored and @@UploadSetVars($pagename)@@ was added to allow upload-managing add-ons to set variables more easily.%0a%0aIf you upgrade from 2.2.98 or earlier, and you have custom markup rules relative to author signatures, please see note about [[#v2299|change in 2.2.99]] (documented November 2017).%0a%0a!! Version 2.2.104 {*$:Released} (2017-10-11) [[#v22104]]%0aThis version fixes a bug with [[WikiTrails#pathtrail|path WikiTrails]] reported today.%0a%0a!! Version 2.2.103 {*$:Released} (2017-10-01) [[#v22103]]%0aThis version is a major upgrade on the internal processing of markups and patterns, all core scripts were updated to be compatible with PHP version 7.2. Whether you use that PHP version or another one, with any local configurations and custom add-ons, there should be no change for what you see, but if any problems please contact us immediately.%0a%0aPagelists can now have optimized @@list=grouphomes@@ and @@fmt=#grouphomes@@ arguments to list only the home pages of your wiki groups, whether they are named Group.HomePage, Group.Group, or a custom Group.$DefaultName. Minor bugs in older xlpage scripts were fixed, the responsive skin is now compatible with even older PmWiki/PHP versions, web subtitles (*.vtt) were added as an allowed extension, input form fields can now have a "title" attribute (usually rendered as a tooltip/help balloon when the mouse cursor is over the input element), and a configuration variable $AuthLDAPReferrals was added for wikis running AuthUser over LDAP to force enable or disable referrals when needed.%0a%0aThe documentation was updated.%0a%0a!! Version 2.2.102 {*$:Released} (2017-08-05) [[#v22102]]%0aThis version reverts the patterns for text variables changed in 2.2.99, because we found that a longer text variable content may cause a blank page or an internal server error. In the page [[SiteAdmin.AuthList]] an input box was added to allow filtering of the groups or pages.%0a%0a!! Version 2.2.101 {*$:Released} (2017-07-30) [[#v22101]]%0aThis version renames the internal constructor of the PageStore class to be compatible with both PHP 5 and PHP 7. Previously, the PageStore class had two constructors for PHP 4 and PHP 5 compatibility of which one was silently ignored, but recent PHP 7 versions display strict or deprecated notices when the PHP 4 constructor is used.%0a%0aIf you must use PmWiki 2.2.101 or newer on a PHP 4 installation, please contact me so I can provide you with a workaround.%0a%0a!! Version 2.2.100 {*$:Released} (2017-07-30) [[#v22100]]%0aThis version provides a workaround for an incompatibility with our Subversion version control system, where the $Author wiki variable was considered a Subversion variable. A fix for the responsive skin adds some spacing above the WikiText block. The documentation was updated.%0a%0a!! Version 2.2.99 {*$:Released} (2017-06-26) [[#v2299]]%0aThis version fixes a bug where an incomplete text variable without a closing parenthesis like "[@(:Var:Value@]" could hide the remaining of the page.%0a%0aA bug was fixed where previewing a page didn't show changes to be done by replace-on-save patterns (the function ReplaceOnSave was refactored). Markup rules for previewing author signatures are no longer needed and were removed. %25note%25 Note that if you had custom markup rules processed before or after the @@[=~~=][=~=]@@ or @@[=~~=][=~~=]@@ author signatures may need to be set to [@'%3c[[~'@] (second argument of the @@Markup@@ call).%0a%0aA bug and a warning for PHP 4 installations were fixed. Two minor bugs with the [@[[%3c%3c]]@] line break for the responsive skin and the $Version variable link in the documentation were fixed. %0a%0aThe InterMap prefix to Wikipedia was corrected to use the secure HTTPS protocol and the documentation was updated.%0a%0a!! Version 2.2.98 (2017-05-31) [[#v2298]]%0aThis version adds a new skin that is better adaptable to both large and small screens, desktop and mobile devices (touchscreens). The new skin "pmwiki-responsive" is not enabled by default but available as an option, and as a base for customized copies. It requires a relatively modern browser (post-2009). The old skin is still available and enabled by default.%0a%0aThe Vardoc links now use MakeLink() to allow a custom LinkPage function. The function ReplaceOnSave() was refactored to allow easier calling from recipes. Markup processing functions now can access besides $pagename, a $markupid variable that contains the "name" of the processed markup rule, allowing a single function to process multiple markup rules. The "*.mkv" video extension was added to the list of allowed uploads.%0a%0aA bug was fixed with the [@(:markup:)@] output where a leading space was lost. Note that the "markup" frame is now wrapped in a %3cpre> block with a "pre-wrap" style instead of %3ccode>.%0a%0aA number of other (minor) bugs were fixed: see ChangeLog, and the documentation was updated.%0a%0a!! Version 2.2.97 (2017-04-07) [[#v2297]]%0aThis version fixes a bug concerning $ScriptUrl when $EnablePathInfo is set, introduced in 2.2.96 and reported by 3 users.%0a%0a!! Version 2.2.96 (2017-04-05) [[#v2296]]%0aThis version fixes a severe PHP code injection vulnerability, reported by Gabriel Margiani. PmWiki versions 2.2.56 to 2.2.95 are concerned.%0a%0aOnly certain local customizations enable the vulnerability. Your website may be at risk if your local configuration or recipes call too early some core functions like CondAuth(), RetrievePageName() or FmtPageName(), before the $pagename variable is sanitized by ResolvePageName() in stdconfig.php. A specific URL launched by a malicious visitor may trigger the vulnerability.%0a%0aMost recipes call core functions from a $HandleActions function, or from a Markup expression rule, these do not appear to be affected by the current exploit.%0a%0aIf your wiki may be at risk, it is recommended to upgrade to version 2.2.96 or most recent at the earliest opportunity. If you cannot immediately upgrade, you should place the following line in your local (farm)config.php file:%0a%0a [@$pagename = preg_replace('![${}\'"\\\\]+!', '', $pagename);@]%0a%0aPlace this line near the top of the file but after you include scripts/xlpage-utf-8.php or other character encoding file.%0a%0aThis version filters the $pagename variable to exclude certain characters. A new variable $pagename_unfiltered is added in case a recipe requires the previous behavior. The documentation was updated.%0a%0a!! Version 2.2.95 (2017-02-28) [[#v2295]]%0aThis is a documentation update version.%0a%0a!! Version 2.2.94 (2017-01-31) [[#v2294]]%0aThis version allows webmasters to configure and use both .html and .htm extensions. The cached information about whether a page exists or not will now be cleared when that page is created or deleted. The documentation was updated.%0a%0a!! Version 2.2.93 (2016-12-31) [[#v2293]]%0aThis is a documentation update version.%0a%0a!! Version 2.2.92 (2016-11-30) [[#v2292]]%0aThis version allows administrators to disable the "nopass" password by setting $AllowPassword to false. The function FmtPageName() will now expand PageVariables with asterisks like [@{*$FullName}@]. The documentation was updated.%0a%0a!! Version 2.2.91 (2016-09-30) [[#v2291]]%0aThis is a documentation update version.%0a%0a!! Version 2.2.90 (2016-08-31) [[#v2290]]%0aThis version adds a parameter to the upload form which can improve analytics from the server logs. Two new CSS classes were added to help skin developers: @@imgonly@@ and @@imgcaption@@, for standalone embedded pictures with or without a caption. A bug with the plus-links was fixed. The documentation was updated.%0a%0a!! Version 2.2.89 (2016-07-30) [[#v2289]]%0aThis version allows to set a default class name for simple tables. The [@(:searchbox:)@] directive can now have a "placeholder" attribute, and the input type can be changed from "text" to "search" for HTML5 websites. The edit form elements have now identifier attributes to allow easier styling. All core scripts will now inject CSS into the skin only if it hasn't already been defined. The vardoc.php script now recognizes and links to the documentation for the variables $pagename, $Author and $Skin. The documentation was updated.%0a%0a!! Version 2.2.88 (2016-06-29) [[#v2288]]%0aThis version fixes invalid HTML output of some WikiTrail links. The function PHSC() can now have an optional fourth argument for a safe replacement of htmlspecialchars(). A new page variable [@{$SiteAdminGroup}@] was added and the documentation was updated. %0a%0a!! Version 2.2.87 (2016-05-31) [[#v2287]]%0aThis version adds the $HTMLTagAttr variable to be used in the %3chtml> tag in skins for additional attributes like "lang" or "manifest". To enable it, use it in your skin, for example:%0a%0a %3chtml xmlns="http://www.w3.org/1999/xhtml" $HTMLTagAttr>%0a%0aThe variable $EnableRevUserAgent, if set to 1, will cause the User-Agent string from browsers to be stored with each page history entry (as opposed to only storing the last user agent string). The output variable $DiffUserAgent can be used in history templates like $DiffStartFmt.%0a%0aA wrong page variable in [[Site.UploadQuickReference]] was corrected, and the documentation was updated.%0a%0a!! Version 2.2.86 (2016-04-28) [[#v2286]]%0aThis version adds updates for PHP 7, for the PageStore() class and for the $DefaultPasswords default/unset definitions (no action should be needed upon upgrades). The documentation was updated.%0a%0a!! Version 2.2.85 (2016-03-31) [[#v2285]]%0aThis version adds Scalable Vector Graphics (*.svg, *.svgz) as allowed uploads and as embeddable picture extensions (with the html tag %3cimg/>). The documentation was updated.%0a%0a!! Version 2.2.84 (2016-02-21) [[#v2284]]%0aThis version fixes "indent" and "outdent" styles for right-to-left languages. A new variable $EnableLinkPlusTitlespaced allows "plus links" [@[[Link|+]]@] to display the "Spaced Title" of the page instead the "Title". The documentation was updated.%0a%0a!! Version 2.2.83 (2015-12-31) [[#v2283]]%0aThis is a documentation update version.%0a%0a!! Version 2.2.82 (2015-11-30) [[#v2282]]%0aThis version enables stripmagic() to process arrays recursively and updates the documentation.%0a%0a!! Version 2.2.81 (2015-10-31) [[#v2281]]%0aThis version fixes an inconsistency with single line page text variables. International wikis enabling UTF-8 will now be able to use the CSS classes "rtl" and "ltr" to override the text direction when inserting right to left languages. The documentation was updated.%0a%0a!! Version 2.2.80 (2015-09-30) [[#v2280]]%0aThis version modifies the [@(:searchbox:)@] directive to use type="search" semantic input, and updates the documentation.%0a%0a!! Version 2.2.79 (2015-08-27) [[#v2279]]%0aThis version adds WikiStyles for the CSS basic colors "fuchsia", "olive", "lime", "teal", "aqua", "orange" and "gray"/"grey". New input elements "email", "url", "number", "date", and "search" can now be used in wiki forms. %0a%0aNote: the "target" attribute of input forms which was added in the previous version broke the PmForm processor, and was removed until we find a solution. If you don't use PmForm and require this attribute (or others), the usual way to add it is to redefine the $InputAttrs array in your local configuration.%0a%0aA new variable $EnableROSEscape can be set to 1 if $ROSPatterns and $ROEPatterns should not process source text wrapped with [@[=...=]@] or @@[=[@...@]=]@@. By default "replace on edit" patterns are performed even in such text.%0a%0aThe insMarkup() function in guiedit.js was refactored to allow custom input ids and/or custom functions to process the selected text.%0a%0aThe documentation was updated.%0a%0a!! Version 2.2.78 (2015-07-21) [[#v2278]]%0aThis version updates the $RobotPattern list with currently active user agents. {-Input forms can have a "target" attribute-} (removed in 2.2.79). The documentation was updated.%0a%0aNote, this release broke the Cookbook:PmForm module. Please do upgrade to 2.2.79 or newer if your wiki uses PmForm.%0a%0a!! Version 2.2.77 (2015-06-19) [[#v2277]]%0aThis version extends the [@(:if attachments:)@] conditional to specify file and page names. A [@{$WikiTitle}@] page variable was added. A MatchNames() function was introduced as a generic way to match array values the same way MatchPageNames() does currently with lists of pages -- recipe authors can use it to get a subset of attachments for example. The PageStore() class was slightly optimized when recoding pages from-to UTF-8. The documentation was updated.%0a%0a!! Version 2.2.76 (2015-05-31) [[#v2276]]%0aThis version improves support for arrays in form elements: setting default values and recovering values from posted forms. A new "label" argument to checkbox and radio input elements allows easy insertion of clickable text labels after the form elements. Division blocks wrapping standalone images, and standalone image captions, now receive CSS classes allowing greater control via stylesheets. The documentation was updated.%0a%0a!! Version 2.2.75 (2015-04-26) [[#v2275]]%0aThis version adds a pmcrypt($pass, $salt) function which can be used as a replacement for the PHP crypt() function when encrypting passwords. From PHP 5.6 on, crypt() should not be used without a $salt parameter and would raise a notice. If pmcrypt() is called with a $salt parameter it will simply call crypt() in order to check a password. If it is called without a $salt parameter, pmcrypt() will create a password hash with the password_hash() function or with crypt() depending on your installation. You can replace any calls to crypt() with pmcrypt(), notably in config.php when defining $DefaultPasswords entries.%0a%0aMarkup was added for the semantic HTML5 tags article, section, nav, header, footer, aside, address.%0a%0aA bug with the uploads feature was fixed when $EnableReadOnly is set, and the documentation was updated.%0a%0a!! Version 2.2.74 (2015-03-28) [[#v2274]]%0aThis version allows the translation of the word "OK" in authentication forms. The documentation was updated to the latest state on pmwiki.org.%0a%0a!! Version 2.2.73 (2015-02-28) [[#v2273]]%0aThis release only updates the documentation to the latest state on pmwiki.org.%0a%0a!! Version 2.2.72 (2015-01-27) [[#v2272]]%0aThis version improves the ?action=ruleset display for markup rules potentially incompatible with PHP 5.5 when the function debug_backtrace() is not available. It restores the ability to set a custom function handling the [=(:markup:)=] demos. A variable $AbortFunction was added allowing administrators to override the core Abort() function. The documentation was updated.%0a%0a!! Version 2.2.71 (2014-12-29) [[#v2271]]%0aThis version removes the hard word wrap in [@(:markup:)@] wikicode examples, and instead of %3cpre> tags, it wraps it in %3ccode> tags. This allows newcomers to copy and paste the code in their wikis without inserted line breaks (which often cause the markup to not work).%0a%0aThe release also adds back-tracing for markup rules potentially incompatible with PHP 5.5. Such rules, often added by recipes, can trigger "Deprecated: preg_replace()" warnings. To find out which recipes may trigger the warnings, enable diagnostic tools in config.php with @@$EnableDiag = 1;@@ then open a page with the 'ruleset' action, eg. [@[[HomePage?action=ruleset]]@]. The PHP-5.5-incompatible rules will be flagged with filenames, line numbers and patterns. See also the pages [[(PmWiki:)Troubleshooting]] and [[(PmWiki:)CustomMarkup]] on pmwiki.org.%0a%0aThe variable $DraftActionsPattern was added, the pagelist "request" parameter can now contain a list of allowed or disallowed parameters that can be overridden by the user, the "input default source" parameter can now contain multiple pages, and a minor bug was fixed in upload.php ('strict' warning). See the updated documentation for more information. %0a%0a!! Version 2.2.70 (2014-11-08) [[#v2270]]%0aThis release only updates the documentation to the latest state on pmwiki.org.%0a%0a!! Version 2.2.69 (2014-10-13) [[#v2269]]%0aThis version fixes a bug when dates are defined as relative to other dates, eg. "2014-10-13 -3 days". The documentation was updated; note that the instructions in Site.UploadQuickReference were updated to reflect the display of the upload form in current browsers.%0a%0a!! Version 2.2.68 (2014-09-01) [[#v2268]]%0aThis version adds a Skins: InterMap prefix pointing to the Skins section on PmWiki.org, a "signature" markup in the edit quick reference, new WikiStyles clear, min-width and max-width and the documentation was updated.%0a%0a!! Version 2.2.67 (2014-08-02) [[#v2267]]%0aThis version fixes an inconsistency with input forms when values are taken from PageTextVariables. The documentation was updated to the latest state on pmwiki.org.%0a%0a!! Version 2.2.66 (2014-07-02) [[#v2266]]%0aThis version fixes a minor longstanding bug in the default Notification format when a page is deleted. In custom patterns, the "_" character will no longer be considered a function name. The documentation was updated.%0a%0a!! Version 2.2.65 (2014-06-07) [[#rel2.2.65]]%0aThis version fixes Pagelist handling of [@{$$PseudoVars}@] when they contain page variables. File permissions handling was improved when the current directory is owned by "root". The documentation was updated.%0a%0a!! Version 2.2.64 (2014-05-08) [[#rel2.2.64]]%0aThis version adds the [="{(mod)}"=] markup expression for modulo/remainder calculations, and the "tel:" and "geo:" URI schemes which, on compatible devices like smartphones, allow the creation of links to dial telephone numbers and open map/location applications. %0a%0aThe $SysMergePassthru switch was added, if enabled, it allows the "Simultaneous Edits" conflict resolution to use the passthru() function instead of popen().%0a%0aThe documentation was updated.%0a%0a!! Version 2.2.63 (2014-04-05) [[#rel2.2.63]]%0aThis version allows for form elements to have custom attributes containing a dash in the attribute names and enables the attributes 'required', 'placeholder' and 'autocomplete' for HTML5 forms. A minor bug with pagelist [={$$RequestVariables}=] appearing on some installations was fixed. The documentation was updated.%0a%0a!! Version 2.2.62 (2014-02-28) [[#rel2.2.62]]%0aThis version adds the variable $EnableTableAutoValignTop which allows to make advanced tables compatible with HTML5. For developers, a fourth argument $template was added to the Markup_e() function, and a callback template 'return' was added. The documentation was updated.%0a%0a!! Version 2.2.61 (2014-01-31) [[#rel2.2.61]]%0aThis version removes unnecessary snippets of code and adds the variable $TableCellAlignFmt which allows to make simple tables compatible with HTML5. The documentation was updated.%0a%0a!! Version 2.2.60 (2014-01-12) [[#rel2.2.60]]%0aThis version reverts the changes to the pmwiki.css file made in 2.2.59. %0a%0a!! Version 2.2.59 (2014-01-11) [[#rel2.2.59]]%0aThis version has an improvement for Blocklist when multiple text fields are posted. A bug with some nested markup conditionals was fixed. The default skin switched font sizes from points (fixed) to percents (relative). A couple of other minor bugs were fixed and the documentation was updated.%0a%0a!! Version 2.2.58 (2013-12-25) [[#rel2.2.58]]%0aThis version enables customization of [=(:input auth_form:)=], and fixes a couple of minor bugs. The documentation was updated.%0a%0a!! Version 2.2.57 (2013-11-03)%0aThis version enables the use of the Attach: link format in the [[PmWiki/PageDirectives#attachlist|[=(:attachlist:)=]]] directive. The documentation was updated.%0a%0a!! Version 2.2.56 (2013-09-30)%0aThis version aims to fix a PHP 5.5 compatibility issue with a deprecated feature of the preg_replace() function. The PageStore() class now detects and works around a bug with the iconv() function, and the documentation was updated.%0a%0a!! Version 2.2.55 (2013-09-16)%0aThis version adds the variable $EnableDraftAtomicDiff. If enabled, publishing from a draft version will clear the history of intermediate draft edits, and the published version will contain a single combined diff from the previous published version. The documentation was updated.%0a%0a!! Version 2.2.54 (2013-08-13)%0aThis version fixes a bug when old versions are restored from draft pages. The documentation was updated.%0a%0a!! Version 2.2.53 (2013-07-08)%0aThis version enables a message to be shown when a post is blocked because of too many unapproved links. The documentation was updated.%0a%0a!! Version 2.2.52 (2013-06-08)%0aThis version hides warnings about a deprecated feature in PHP 5.5 installations (preg_replace with /e eval flag). Three new upload extensions were added: docx, pptx and xlsx produced by recent versions of some office suites. The documentation was updated.%0a%0a!! Version 2.2.51 (2013-05-08)%0aThis version updates the addresses for the remote blocklists. A minor XSS vulnerability for open wikis, which was discovered today, was fixed. The documentation was updated.%0a%0a!! Version 2.2.50 (2013-04-08)%0aThis release only updates the documentation to the latest state on pmwiki.org.%0a%0a!! Version 2.2.49 (2013-03-09)%0aThis version adds an array $UploadBlacklist containing forbidden strings of an uploaded filename (case insensitive). Some Apache installations try to execute a file which has ".php", ".pl" or ".cgi" anywhere in the filename, for example, "test.php.txt" may be executed. To disallow such files to be uploaded via the PmWiki interface, add to config.php such a line:%0a%0a $UploadBlacklist = array('.php', '.pl', '.cgi', '.py', '.shtm', '.phtm', '.pcgi', '.asp', '.jsp', '.sh');%0a%0aThe documentation was updated.%0a%0a!! Version 2.2.48 (2013-02-11)%0aThis version fixes a bug introduced yesterday with some links. %0a%0a!! Version 2.2.47 (2013-02-10)%0aThis version enables tooltip titles in links to anchors in the same page, and the documentation was updated.%0a%0a!! Version 2.2.46 (2013-01-07)%0aThis version adds $UploadPermAdd and $UploadPermSet variables, and the documentation was updated.%0a%0aIf your wiki has uploads enabled, it is recommended to set the variable $UploadPermAdd to 0. %0a%0aThe $UploadPermAdd variable sets additional unix permissions applied to newly uploaded files, and should be 0 (recommended as of 2013). If uploaded files cannot be downloaded and displayed on the website, for example with the error 403 Forbidden, set this value to 0444 (core setting, default since 2004). %0a $UploadPermAdd = 0; # recommended%0a%0aThe $UploadPermSet variable unconditionally sets the file permissions on newly uploaded files. Only advanced administrators should use it.%0a%0a%0a!! Version 2.2.45 (2012-12-02)%0aThis version fixes some PHP notices appearing on some installations. The documentation was updated.%0a%0a!! Version 2.2.44 (2012-10-21)%0aThis version improves the display of consecutive whitespaces in page histories, and fixes the definition of PageTextVariables containing a dash. The documentation was updated.%0a%0a%0a!! Version 2.2.43 (2012-09-20)%0aThis version makes it possible to use HTML attribute names that contain dashes, and removes a warning when editing and previewing Site.EditForm. The documentation was updated.%0a%0a!! Version 2.2.42 (2012-08-20)%0aThis version provides a workaround for cases when a wiki page contains a character nonexistent in the active encoding. The documentation was updated.%0a%0a!! Version 2.2.41 (2012-08-12)%0aThis version changes the internal $KeepToken separator to be compatible with more encodings. The documentation was updated.%0a%0a!! Version 2.2.40 (2012-07-21)%0aThis version provides a helper function replacing htmlspecialchars() and compatible with PHP 5.4. The documentation was updated.%0a%0a!! Version 2.2.39 (2012-06-25)%0aThis version provides a fix for links to attachments containing international characters. The documentation was updated.%0a%0a!! Version 2.2.38 (2012-05-21)%0aThis version fixes a "parameter count" warning which appeared on some websites.%0a%0a!! Version 2.2.37 (2012-05-01)%0aThis version provides a workaround for installations with broken iconv() function, while optimizing the recode function. This should fix the "Unable to retrieve edit form" problem in some wikis. Dots in [[#anchor_1.2]] sections are now better supported, PageVariables are expanded in PageList template defaults, and the documentation is updated.%0a%0a!! Version 2.2.36 (2011-12-28)%0aThis version fixes the recode function to try to recover Windows-1252 characters in ISO-8859-1 files. A new variable $EnableOldCharset enables the $page["=oldcharset"] entry which will be used in the future. A couple of minor bugs were fixed and the documentation was updated.%0a%0a!! [[#v2235]] Version 2.2.35 (2011-11-11)%0aThis release fixes a critical PHP injection vulnerability, reported today by Egidio Romano. PmWiki versions 2.2.X, 2.1.X, 2.0.X and 2.0.beta33 and newer are vulnerable. When you upgrade, please read carefully the Release notes for all PmWiki versions since yours.%0a%0aIf you cannot upgrade, it is recommended to disable Searches at the earliest opportunity (even if your wiki skin doesn't have a search form). Add to config.php such a line:%0a if ($action == 'search') $action = 'browse';%0a%0aIf your old version wiki allows editing by not entirely trusted visitors, even on limited pages like a WikiSandbox, you should also disable PageLists. Add to config.php this line:%0a $EnablePageList = 0;%0a%0aThis version has an important change for international wikis: the XLPage() function no longer loads encoding scripts such as xlpage-utf-8.php. When you upgrade, you need to include those scripts from config.php, before calling XLPage():%0a%0a include_once("scripts/xlpage-utf-8.php"); # if your wiki uses UTF-8%0a XLPage('bg','PmWikiBg.XLPage');%0a%0aAll links can now have tooltip titles. Previously, only images and external links could have tooltip titles, now this feature is enabled for internal links. To set a tooltip title, add it in quotes after the link address:%0a[@%0a [[Main.HomePage"This is a tooltip title"]]%0a [[Main.HomePage"This is a tooltip title"|Home]]%0a [[http://www.pmwiki.org"Home of PmWiki"]]%0a Attach:image.jpg"Tooltip title of the image"%0a@]%0a%0aThe following new upload extensions were added: svg, xcf, ogg, flac, ogv, mp4, webm, odg, epub. A couple of minor optimizations were added (MarkupExpressions and rendering of page history) and the documentation was updated.%0a%0a!! Version 2.2.34 (2011-10-10)%0aThis version resets the timestamps of the default pages Site(Admin).AuthUser which are expected in case of upgrades from the versions 2.1.*. Core MarkupExpressions which manipulate strings should now work better with international characters. The documentation was updated to its latest state from pmwiki.org.%0a%0a!! Version 2.2.33 (2011-09-23) [[#v2233]]%0aThis version fixes a security bug introduced in 2.2.32 which left the groups Site and SiteAdmin open for reading and editing because the pages Site.GroupAttributes and SiteAdmin.GroupAttributes didn't have all necessary attributes. %0a%0aAll wikis running 2.2.32 should upgrade. If you cannot immediately upgrade, you can set the attributes from your wiki:%0a* open the attributes page [=[[SiteAdmin.GroupAttributes?action=attr]]=] and set a "read" and an "edit" password, @@ @lock @@ is recommended.%0a* open the attributes page [=[[Site.GroupAttributes?action=attr]]=] and set an "edit" password, @@ @lock @@ is recommended. Do not set a "read" password here.%0a%0aThe release also fixes the refcount.php script to produce valid HTML, and updates intermap.txt entries PITS: and Wikipedia: to point to their current locations.%0a%0a!! Version 2.2.32 (2011-09-18)%0aThis is the first version shipping with the core documentation in the UTF-8 encoding. PmWiki will automatically convert it on the fly for wikis using an older encoding.%0a%0aIt is recommended that all '''new''' PmWiki installations enable UTF-8. Migration of ''existing'' wikis from an older encoding to UTF-8 shouldn't be rushed: it is not trivial and will be documented in the future.%0a%0aA required HTML xmlns attribute was added to the print skin template. The history rendering is now faster when many lines are added or removed.%0a%0a%25note%25 Note: Due to a manipulation error, a version 2.2.31 was created before it was ready for a release.%0a%0a!! Version 2.2.30 (2011-08-13)%0aThis version fixes a $Charset definition in international iso-8859-*.php files. This will help for a future transition to UTF-8. %0a%0aA variable $EnableRangeMatchUTF8 was added, set it to 1 to enable range matches of pagenames in UTF-8 like [A-D]. Previously the range matches were always enabled in UTF-8, but we found out that on some installations this feature breaks all pagelists, even those without range matches. In case the feature worked for you, you can re-enable it.%0a%0a!! Version 2.2.29 (2011-07-24)%0aThis release fixes Attach links that were broken with the Path fix in 2.2.28 earlier today.%0a%0a!! Version 2.2.28 (2011-07-24)%0aThis release fixes 2 potential XSS vulnerabilities and a bug with Path: links.%0a%0a!! Version 2.2.27 (2011-06-19)%0aThis release fixes a validation bug on pages after a redirection. A new block WikiStyle [@%25justify%25@] was added, allowing left and right aligned text. The page history now accepts a URL parameter @@?nodiff=1@@ which hides the rendering of edit differences, showing only timestamps, authors, summaries and "Restore" links; it allows to restore a vandalized page with a huge contents or history which otherwise would break the memory or time limits of the server.%0a%0a!! Version 2.2.26 (2011-05-21)%0aThis release fixes a redundant removal of link hashes from WikiTrails, and updates the documentation to the most recent version from PmWiki.org.%0a%0a!! Version 2.2.25 (2011-03-22)%0aThis release only updates the documentation to the latest state on pmwiki.org.%0a%0a!! Version 2.2.24 (2011-02-15)%0aThis version reverts the way existing PageVariables are processed, like version 2.2.21 or earlier, but it adds a special variable $authpage which can be used in PageVar definitions. It is the same as the $page array, but exists only if the visitor has read permissions. For example, an administrator can set to config.php:%0a%0a $FmtPV['$LastModifiedSummary'] = '@$authpage["csum"]'; # instead of '@$page["csum"]'%0a%0aThen, the edit summary metadata will only be available if the user has read permissions.%0a%0a!! Version 2.2.23 (2011-01-25)%0aThis version sets the default value of $EnablePageVarAuth to 0 until we investigate a reported problem with authentication.%0a%0a!! Version 2.2.22 (2011-01-16)%0aThis version adds the variable $EnableXLPageScriptLoad which, if set to 0, will prevent authors to load scripts from XLPage and to accidentally change the encoding of the wiki. If you use it, make sure you include the required files, eg. xlpage-utf-8.php from local config files.%0a%0aPageVariables should now respect authentications: without read permissions, the title, description, change summary, author of a protected page are unavailable. PageVariables that are computed without reading the page are still available (eg. $Group, $Namespaced, $Version etc.). Administrators can revert the previous behavior by adding to config.php such a line:%0a%0a@@ $EnablePageVarAuth = 0; @@%0a%0a!! Version 2.2.21 (2010-12-14)%0aDue to a mis-configuration of a local svn repository, some of the changes intended for 2.2.20 didn't make it in the correct branch. This release corrects this.%0a%0a!! Version 2.2.20 (2010-12-14)%0aThis version fixes a potential XSS vulnerability, reported today. An AuthUser bug with excluding users from authgroups was fixed. A new InterMap prefix PmL10n: was added, it leads to the Localization section on PmWiki.org and should help the work of translators. A couple of other minor bugs were fixed and the documentation was updated.%0a%0a!! Version 2.2.19 (2010-11-10)%0aThis is a documentation-update release.%0a%0a!! Version 2.2.18 (2010-09-04)%0aThis version fixes 3 minor bugs, and updates the documentation.%0a%0a!! Version 2.2.17 (2010-06-20)%0aThis version adds a variable $PostConfig containing functions and scripts to be loaded after stdconfig.php. Tabindex was added as a valid form field attribute. Protected downloads now respect existing browser caches. AuthUser now allows more flexible cookbook recipe integration. A couple of bugs were fixed and the documentation was updated.%0a%0a!! Version 2.2.16 (2010-05-10)%0aThis version fixes a bug with parsing html attributes which could allow XSS injection. Wikis allowing unprotected editing are encouraged to upgrade.%0a%0aA bug with the "center" button of the GUI edit toolbar was corrected.%0a%0aThe "exists" conditional now accepts wildcards, for example:%0a [@(:if exists Main.*:)There are pages in the Main group (:if:)@]%0a%0aThe documentation was updated.%0a%0a!! Version 2.2.15 (2010-03-27)%0aThis version adds some minor bugfixes and optimizations notably a bug with @@[=(:template none:)=]@@ introduced in the last version 2.2.14.%0a%0a!! Version 2.2.14 (2010-02-27)%0aThis release corrects inline styles for WikiTrail links. Undefined include/template @@ [={$$variables}=] @@ are now removed from the included section, like Page(Text)Variables, and can be used in conditional expressions. If needed, this change can be reverted by adding to config.php such a line:%0a%0a[@%0a $EnableUndefinedTemplateVars = 1; # keep and display unset {$$variables}%0a@]%0a%0aPageList templates now accept the sections @@ !first @@ and @@ !last @@ for markup to appear for every page in list ''except'' the first or last one.%0a%0a"Title" attributes were added to external links. You can have tooltip titles on external links, including InterMap and attachments, by adding the link title in double quotes after the URL:%0a [=[[http://www.pmwiki.org"Home of PmWiki"| External link]]=]%0a%0aFor international wikis, PmWiki now automatically translates the titles of technical pages like GroupAttributes or RecentChanges -- just define these strings as usual in XLPage, for example, in French:%0a 'AllRecentChanges' => 'Tous les changements récents',%0a%0aSome minor optimizations were done and the documentation was updated.%0a%0a!! Version 2.2.13 (2010-02-21)%0aThis release fixes a bug with $DiffKeepNum introduced in 2.2.10 -- the count of revisions was incorrect and a page could drop more revisions than it should.%0a%0aThe [[page history]] layout was modified with a rough consensus in the community. The history now defaults to "source" view with word-level highlighting of the differences. Authors can see the changes in rendered output by clicking on the link "Show changes to output". Admins can switch back the default by adding such a line to config.php:%0a%0a $DiffShow['source'] = (@$_REQUEST['source']=='y')?'y':'n';%0a%0aTo disable word-level highlighting and show plain text changes:%0a%0a $EnableDiffInline = 0;%0a%0aIn the page history rendering, a few minor bugs were fixed and the code was slightly optimized.%0a%0aThe documentation was updated.%0a%0a!! Version 2.2.12 (2010-02-17)%0aThis release adds simple word-level highlighting of differences in the page history, when "Show changes to markup" is selected. To enable the feature, add to config.php such a line:%0a $EnableDiffInline = 1;%0a%0aThis feature is like what the InlineDiff recipe provides, but not exactly the same, and the implementation is simpler. It is enabled on PmWiki.org and can be improved -- your comments are welcome.%0a%0a!! Version 2.2.11 (2010-02-14)%0aThis release adds two new table directives for header cells, [=(:head:) and (:headnr:)=]. They work the same way as [=(:cell:) and (:cellnr:)=] except that create %3cth> instead of %3ctd> html tags.%0a%0aThe pagerev.php script was refactored into separate functions to allow easier integration of recipes displaying the page history.%0a%0aA couple of minor bugs were fixed and the documentation was updated.%0a%0a!! Version 2.2.9, 2.2.10 (2010-01-17)%0aMost important in this release is the official change of $EnableRelativePageVars to 1. The change is about how [={$Variable}=] in included pages is understood by PmWiki.%0a* When $EnableRelativePageVars is set to 0, [={$Name}=] displays the name of the currently browsed page. Even if [={$Name}=] is in an included page, it will display the name of the browsed page.%0a* When $EnableRelativePageVars is set to 1, [={$Name}=] displays the name of the physical page where it written. If [={$Name}=] is in an included page, it will display the name of the included page.%0a* [={*$Name}=] always displays the name of the currently browsed page, regardless of $EnableRelativePageVars.%0a%0aSo, if your wiki relies on page variables from included pages, and doesn't have $EnableRelativePageVars set to 1, after upgrading to 2.2.9, you can revert to the previous behavior by adding to config.php such a line:%0a $EnableRelativePageVars = 0;%0a%0aMore information about page variables can be found at:%0a http://www.pmwiki.org/wiki/PmWiki/PageVariables%0a%0aThis release adds a new variable $EnablePageTitlePriority which defines how to treat multiple [=(:title..:)=] directives. If set to 1, the first title directive will be used, and if a page defines a title, directives from included pages cannot override it. PmWiki default is 0, for years, the last title directive was used (it could come from an included page or GroupFooter).%0a%0aThis release also adds a new variable $DiffKeepNum, specifying the minimum number (default 20) of edits that will be kept even if some of them are older than the limit of $DiffKeepDays.%0a%0aA number of bugs were fixed and the documentation was updated.%0a%0a!! Version 2.2.8 (2009-12-07)%0aThis release fixes another PHP 5.3 compatibility issue with conditional markup. The Author field now handles apostrophes correctly. The documentation was updated.%0a%0a!! Version 2.2.7 (2009-11-08)%0aThis release fixes most PHP 5.3 compatibility issues. Unfortunately some specific builds for Windows may still have problems, which are unrelated to PmWiki. Notably, on Windows, all passwords need to be 4 characters or longer.%0a%0aUpload names with spaces are now correctly quoted. The documentation was updated.%0a%0a!! Version 2.2.6 (2009-10-04)%0aWith this release it is now possible to display recently uploaded files to the RecentChanges pages -- if you have been using the RecentUploadsLog recipe, please uninstall it and follow the instructions at http://www.pmwiki.org/wiki/Cookbook/RecentUploadsLog.%0a%0aThe release also introduces $MakeUploadNamePatterns to allow custom filename normalization for attachements. It is now possible to replace $PageListFilters and $FPLTemplateFunctions with custom functions. Notify should now work in safe_mode. Some bugs were fixed, among which one with conditional markup with dates. The documentation was updated.%0a%0a!! Version 2.2.5 (2009-08-25)%0aThis release adds a new markup for Pagelist templates, [@(:template none:)@] which allows a message to be set when the search found no pages. The FPLTemplate() function was broken into configurable sub-parts to allow development hooks. A number of bugs were fixed, and the documentation was updated.%0a%0a!! Version 2.2.4 (2009-07-16)%0aThis release fixes a bug introduced earlier today with HTML entities in XLPages.%0a%0a!! Version 2.2.3 (2009-07-16)%0aThis release fixes six potential XSS vulnerabilities, reported by Michael Engelke. The vulnerabilities may affect wikis open for editing and may allow the injection of external JavaScripts in their pages. Public open wikis should upgrade.%0a%0aA new variable $EnableUploadGroupAuth was added; if set to 1, it allows password-protected [[uploads]] to be checked against the Group password. %0a%0aIt is now possible to use @@ @_site_edit, @_site_read, @_site_admin@@ or @@ @_site_upload @@ global [[passwords]] in GroupAttributes pages.%0a%0aA number of other small bugs were fixed, and the documentation was updated.%0a%0a!! Version 2.2.2 (2009-06-21)%0aThe major news in this release is a fix of an AuthUser vulnerability.%0a%0aThe vulnerability affects only wikis that (1) rely on the AuthUser core module %0afor User:Password authentication, -AND- (2) where the PHP installation runs %0awith the variable "magic_quotes_gpc" disabled.%0a%0aAll PmWiki 2.1.x versions from pmwiki-2.1.beta6 on, all 2.2.betaX, 2.2.0, and %0a2.2.1 are affected.%0a%0aThe PmWiki [[SiteAnalyzer]] can detect if your wiki needs to upgrade:%0a http://www.pmwiki.org/wiki/PmWiki/SiteAnalyzer%0a%0aIf your wiki is vulnerable, you should do one of the following at the earliest %0aopportunity:%0a%0a* Upgrade to a version of PmWiki at least 2.2.2 or greater.%0a* Turn on magic_quotes_gpc in the php.ini file or in a .htaccess file.%0a%0aAlternatively, you can temporarily disable AuthUser until you upgrade.%0a%0aNote that even if your wiki does not have the AuthUser vulnerability at the %0amoment, you are strongly encouraged to upgrade to PmWiki version 2.2.2 or %0alater, as some future configuration of your hosting server might put you at %0arisk.%0a%0aThis release also comes with minor updates in the local documentation; fixes %0awere applied for international wikis - notably global variables in %0axlpage-utf-8.php and a new variable $EnableNotifySubjectEncode, which allows %0ae-mail clients to correctly display the Subject header; and a number of other %0asmall bugs were fixed.%0a%0a!! Version 2.2.1 (2009-03-28)%0aThis release comes with an updated local documentation; [[wiki trails]] now work cross-group; guiedit.php now produces valid HTML, and other small bugs were fixed. We also added $EnableRedirectQuiet, which allows redirects to take place without any mention of "redirected from page ....".%0a%0a[[#v220]]%0a!! Version 2.2.0 (2009-01-18)%0a%0aThis is a summary of changes from 2.1.x to 2.2.0.%0a%0a* Several pages that were formerly in the [[Site]].* group are now in a separate [[SiteAdmin]].* group, which is read-restricted by default. The affected pages include Site.AuthUser, Site.AuthList, Site.NotifyList, Site.Blocklist, and Site.ApprovedUrls . If upgrading from an earlier version of PmWiki, PmWiki will prompt to automatically copy these pages to their new location if needed. If a site wishes to continue using the old Site.* group for these pages, simply set%0a%0a-> $SiteAdminGroup = $SiteGroup;%0a%0a-> when carrying out this upgrade inspect your config files for lines such as%0a--> $BlocklistDownload['Site.Blocklist-PmWiki'] = array('format' => 'pmwiki');%0a->as you may wish to fix then, eg%0a--> $BlocklistDownload[$SiteAdminGroup . '.Blocklist-PmWiki'] = array('format' => 'pmwiki');%0a%0a* Important Change in Passwords in PmWiki 2.2 indicating that the group can be edited even if a site password is set will be done by @@"@nopass"@@ prior it was done by @@"nopass"@@%0a-> When migrating a wiki you will have to manually modify the permission or by a script replace in all the page concerned @@passwdread=nopass:@@ by @@passwdread=@nopass@@ (see PITS:00961) --isidor%0a%0a* PmWiki now ships with WikiWords entirely disabled by default. To re-enable them, set either $LinkWikiWords or $EnableWikiWords to 1. To get the 2.1 behavior where WikiWords are spaced and parsed but don't form links, use the following:%0a-> $EnableWikiWords = 1;%0a-> $LinkWikiWords = 0;%0a%0a* It's now easy to disable the rule that causes lines with leading spaces to be treated as preformatted text -- simply set $EnableWSPre=0; to disable this rule.%0a%0a--> '''Important:''' There is ongoing discussion that the leading whitespace rule may be disabled ''by default'' in a future versions of PmWiki. If you want to make sure that the rule will continue to work in future upgrades, set $EnableWSPre=1; in ''local/config.php''.%0a%0a* The $ROSPatterns variable has changed somewhat -- replacement strings are no longer automatically passed through FmtPageName() prior to substitution (i.e., it must now be done explicitly).%0a%0a* Page variables and page links inside of [@(:include:)@] pages are now treated as relative to the included page, instead of the currently browsed page. In short, the idea is that links and page variables should be evaluated with respect to the page in which they are written, as opposed to the page in which they appear. This seems to be more in line with what authors expect. There are a number of important ramifications of this change:%0a%0a[[#relativeurls]]%0a** We now have a new [@{*$var}@] form of page variable, which always refers to "the currently displayed page". Pages such as Site.PageActions and Site.EditForm that are designed to work on "the currently browsed page" should generally switch to using [@{*$FullName}@] instead of [@{$FullName}@].%0a%0a** The $EnableRelativePageLinks and $EnableRelativePageVars settings control the treatment of links and page variables in included pages. However, to minimize disruption to existing sites, $EnableRelativePageVars defaults to '''disabled'''. This will give existing sites an opportunity to convert any absolute [@{$var}@] references to be [@{*$var}@] instead.%0a%0a** Eventually $EnableRelativePageVars will be enabled by default, so we highly recommend setting [@$EnableRelativePageVars = 1;@] in ''local/config.php'' to see how a site will react to the new interpretation. Administrators should especially check any customized versions of the following:%0a---> [[Site.PageActions]]%0a---> [[Site.EditForm]]%0a---> [[Site.PageNotFound]]%0a---> SideBar pages with ?action= links for the current page%0a---> $GroupHeaderFmt, $GroupFooterFmt%0a---> [[Page lists]] that refer to the current group or page, etc in sidebars, headers, and footers%0a%0a** The [@(:include:)@] directive now has a [@basepage=@] option whereby an author can explicitly specify the page upon which relative links and page variables should be based. If no basepage= option is specified, the included page is assumed to be the base.%0a%0a* Sites that want to retain the pre-2.2 behavior of [@(:include:)@] and other items can set [@$Transition['version'] = 2001900;@] to automatically retain the 2.1.x defaults.%0a%0a* Text inserted via [@(:include:)@] can contain "immediate substitutions" of the form [@{$$option}@] -- these are substituted with the value of any options provided to the include directive.%0a%0a* PmWiki now recognizes when it is being accessed via "https:" and switches its internal links appropriately. This can be overridden by explicitly setting $ScriptUrl and $PubDirUrl.%0a%0a* A new $EnableLinkPageRelative option allows PmWiki to generate relative urls for page links instead of absolute urls.%0a%0a* Draft handling capabilities have been greatly improved. When $EnableDrafts is set, then the "Save" button is relabeled to "Publish" and a "Save draft" button appears. In addition, an $EnablePublishAttr configuration variable adds a new "publish" authorization level to distinguish editing from publishing. See [[PmWiki:Drafts]] for more details.%0a%0a[[#ptvstart]]%0a* There is a new [@{$:var}@] "page text variable" available that is able to grab text excerpts out of markup content. For example, [@{SomePage$:Xyz}@] will be replaced by a definition of "Xyz" in SomePage. Page text variables can be defined using definition markup, a line beginning with the variable name and a colon, or a special directive form (that doesn't display anything on output):%0a%0a-->[@%0a:Xyz: some value # definition list form%0aXyz: some value # colon form%0a(:Xyz: some value:) # directive form%0a@]%0a[[#ptvend]]%0a%0a* The [@(:pagelist:)@] command can now filter pages based on the contents of page variables and/or page text variables. For example, the following directive displays only those pages that have an "Xyz" page text variable with "some value":%0a%0a-->[@(:pagelist $:Xyz="some value":)@]%0a%0a Wildcards also work here, thus the following pagelist command lists pages where the page's title starts with the letter "a":%0a%0a-->[@(:pagelist $Title=A* :)@]%0a%0a* The if= option to [@(:pagelist)@] can be used to filter pages based on conditional markup:%0a%0a-->[@(:pagelist if="auth upload {=$FullName}":)@] pages with upload permission%0a-->[@(:pagelist if="date today.. {=$Name}":)@] pages with names that are dates later than today%0a%0a* Spaces no longer separate wildcard patterns -- use commas. (Most people have been doing this already.)%0a%0a* Because page variables are now "relative", the [@{$PageCount}, {$GroupCount}, {$GroupPageCount}@] variables used in pagelist templates are now [@{$$PageCount}, {$$GroupCount}, {$$GroupPageCount}@].%0a%0a* One can now use [@{$$option}@] in a pagelist template to obtain the value of any 'option=' provided to the [@(:pagelist:)@] command.%0a%0a* The [@(:pagelist:)@] directive no longer accepts parameters from urls or forms by default. In order to have it accept such parameters (which was the default in 2.1 and earlier), add a [@request=1@] option to the [@(:pagelist:)@] directive.%0a%0a* The [@count=@] option to pagelists now accepts negative values to count from the end of the list. Thus [@count=5@] returns the the first five pages in the list, and [@count=-5@] returns the last five pages in the list. In addition, ranges of pages may be specified, as in [@count=10..19@] or [@count=-10..-5@].%0a%0a* Pagelist templates may have special [@(:template first ...:)@] and [@(:template last ...:)@] sections to specify output for the first or last page in the list or a group. There's also a [@(:template defaults ...:)@] to allow a template to specify default options.%0a%0a* PmWiki comes with an ability to cache the results of certain [@(:pagelist:)@] directives, to speed up processing on subsequent visits to the page. To enable this feature, set $PageListCacheDir to the name of a writable directory (e.g., ''work.d/'').%0a%0a* [[#elseifelse]]The [@(:if ...:)@] conditional markup now also understands [@(:elseif ...:)@] and [@(:else:)@]. In addition, markup can nest conditionals by placing digits after if/elseif/else, as in [@(:if1 ...)@], [@(:elseif1 ...:)@], [@(:else1:)@], etc.%0a%0a* The [@(:if date ...:)@] conditional markup can now perform date comparisons for dates other than the current date and time.%0a%0a* [[WikiTrails]] can now specify #anchor identifiers to use only sections of pages as a trail.%0a%0a* A new [@(:if ontrail ...:)@] condition allows testing if a page is listed on a trail.%0a%0a* The extensions .odt, .ods, and .odp (from OpenOffice.org) are now recognized as valid attachment types by default.%0a%0a* A new [[blocklist]] capability has been added to the core distribution. It allows blocking of posts based on IP address, phrase, or regular expression, and can also make use of publicly available standard blocklists. See [[PmWiki.Blocklist]] for details.%0a%0a* There is a new [[SiteAdmin.AuthList]] page that can display a summary of all password and permissions settings for pages on a site. This page is restricted to administrators by default.%0a%0a* There are new [@{$PasswdRead}@], [@{$PasswdEdit}@], etc. variables that display the current password settings for a page (assuming the browser has attr permissions or whatever permissions are set in $PasswdVarAuth).%0a%0a* Forms creation via the [@(:input:)@] markup has been internally refactored somewhat (and may still undergo some changes prior to 2.2.0 release). The new [@(:input select ...:)@] markup can be used to create select boxes, and [@(:input default ...:)@] can be used to set default control values, including for radio buttons and checkboxes.%0a%0a* The [@(:input textarea:)@] markup now can take values from other sources, including page text variables from other pages.%0a%0a* Specifying [@focus=1@] on an [@(:input:)@] control causes that control to receive the input focus when a page is loaded. If a page has multiple controls requesting the focus, then the first control with the lowest value of [@focus=@] "wins".%0a%0a* PmWiki now provides a ''scripts/creole.php'' module to enable Creole standard markup. To enable this, add [@include_once('scripts/creole.php')@] to a local customization file.%0a%0a* PmWiki adds a new [@{(...)}@] ''markup expression'' capability, which allows various simple string and data processing (e.g., formatting of dates and times). This is extensible so that recipe authors and system administrators can easily add custom expression operators.%0a%0a* It's now possible to configure PmWiki to automatically create Category pages whenever a page is saved with category links and the corresponding category doesn't already exist. Pages are created only if the author has appropriate write permissions into the group. To enable this behavior, add the following to ''local/config.php'':%0a%0a-->[@$AutoCreate['/^Category\\./'] = array('ctime' => $Now);@]%0a%0a* Sites with wikiwords enabled can now set $WikiWordCount['WikiWord'] to -1 to indicate that 'WikiWord' should not be spaced according to $SpaceWikiWords.%0a%0a* WikiWords that follow # or & are no longer treated as WikiWords.%0a%0a* Links to non-existent group home pages (e.g., [@[[Group.]]@] and [@[[Group/]]@]) will now go to the first valid entry of $PagePathFmt, instead of being hardcoded to "Group.Group". For example, to set PmWiki to default group home pages to [@$DefaultName@], use%0a%0a-->[@$PagePathFmt = array('{$Group}.$1', '$1.{$DefaultName}', '$1.$1');@]%0a%0a* PmWiki now provides a $CurrentTimeISO and $TimeISOFmt variables, for specifying dates in ISO format.%0a%0a* [[(Cookbook:)Cookbook]] authors can use the internal PmWiki function UpdatePage (temporarily documented at [[(Cookbook:)DebuggingForCookbookAuthors]]) to change page text while preserving history/diff information, updating page revision numbers, updating RecentChanges pages, sending email notifications, etc.%0a%0a* [[Skin templates]] are now required to have %3c!--HTMLHeader--> and %3c!--HTMLFooter--> directives. Setting $EnableSkinDiag causes PmWiki to return an error if this isn't the case for a loaded skin. Skins that explicitly do not want HTMLHeader or HTMLFooter sections can use %3c!--NoHTMLHeader--> and %3c!--NoHTMLFooter--> to suppress the warning.%0a%0a* Added a new "pre" wikistyle for preformatted text blocks.%0a%0a* The xlpage-utf-8.php script now understands how to space UTF-8 wikiwords. %0a%0a* Searches on utf-8 site are now case-insensitive for utf-8 characters.%0a%0a* Many Abort() calls now provide a link to pages on pmwiki.org that can explain the problem in more detail and provide troubleshooting assistance.%0a%0a* PmWiki no longer reports "?cannot acquire lockfile" if the visitor is simply browsing pages or performing other read-only actions.%0a%0a* The $EnableReadOnly configuration variable can be set to signal PmWiki that it is to run in "read-only" mode (e.g., for distribution on read-only media). Attempts to perform actions that write to the disk are either ignored or raise an error via Abort().%0a%0a* Including authuser.php no longer automatically calls ResolvePageName().%0a%0a* Authentication using Active Directory is now simplified. In Site.AuthUser or the $AuthUser variable, set "ldap://name.of.ad.server/" with no additional path information (see PmWiki.AuthUser for more details).%0a%0a* Pages are now saved with a "charset=" attribute to identify the character set in effect when the page was saved.%0a%0a* The phpdiff.php algorithm has been optimized to be smarter about finding smaller diffs.%0a%0a* Removed the (deprecated) "#wikileft h1" and "#wikileft h5" styles from the pmwiki default skin.%0a%0a* The mailposts.php and compat1x.php scripts have been removed from the distribution.%0a%0a----%0aBugs and other requests can be reported to the PmWiki Issue Tracking %0aSystem at http://www.pmwiki.org/wiki/PITS/PITS. Any help%0ain testing, development, and/or documentation is greatly appreciated..%0a%0a[[(PmWiki:)Release Notes archive]] - notes for versions older than 2.2.0.%0a%0a%0a%0a%0a +time=1676190664 title=Release Notes blob - 93f1a810c452c2c004c654fd5e4c86eaea2aeb8a blob + 08f98bb33c89d6eab84bfdaf972043a048d2921f --- wikilib.d/PmWiki.Requirements +++ wikilib.d/PmWiki.Requirements @@ -1,9 +1,9 @@ -version=pmwiki-2.2.120 ordered=1 urlencoded=1 -author=Petko +version=pmwiki-2.3.17 ordered=1 urlencoded=1 +author=Gregor charset=UTF-8 -csum= +csum= (+94) name=PmWiki.Requirements -rev=61 +rev=67 targets=Cookbook.InstallOnIIS,Cookbook.Standalone,Cookbook.WikiOnAStick -text=(:Summary:Pre-requisites for running the PmWiki wiki engine:)(:Audience: administrators (basic) :)%0aPrerequisites for running the PmWiki wiki engine:%0a# [[http://php.net/ | PHP]] 4.3 or later%0a** PHP 5.3 or later is recommended%0a** for PHP 5.5 to 7.4 compatibility use the current version of PmWiki%0a# Some sort of webserver that can run PHP scripts.%0a%0aPmWiki has been reported to work with the following OS/webserver combinations:%0a* Apache 1.3 or 2.0, on roughly anything (Unix, Linux, Windows, and Mac OS X)%0a** [[http://httpd.apache.org/ | Apache 2.4]] or later is recommended%0a* [[http://www.lighttpd.net/|lighttpd]] (1.4.19 php-fastcgi ssl) on Linux%0a* [[http://nginx.org/|nginx]] (0.8.47) on Windows%0a* Microsoft [[Cookbook:InstallOnIIS|Internet Information Server]], on Windows%0a* Linux + [[http://www.litespeedtech.com/|LiteSpeedWeb Server]] Standard Edition %0a* appWeb (a small, php-enabled webserver) executing on a Linksys NSLU2 Network Storage Link device%0a%0aPmWiki has been reported not to work on:%0a* Mac OS before Mac OS X because there's no PHP available%0a* Specific Release Candidate builds of PHP 5.3 for Windows may not work correctly with passwords%0a%0aThe [[(Cookbook:)Standalone]] recipe provides a special, bare-bones webserver application that can be used to run PmWiki in places where another webserver isn't available.%0aPmWiki can also be run from a [[Cookbook:WikiOnAStick | USB drive]]. -time=1572357953 +text=(:Summary:Pre-requisites for running the PmWiki wiki engine:)(:Audience: administrators (basic) :)%0aPrerequisites for running the PmWiki wiki engine:%0a# [[https://php.net/ | PHP]] 5.3 or later%0a** for PHP 5.5 to 8.1 compatibility use the current version of PmWiki%0a# Some sort of webserver that can run PHP scripts.%0a%0aPmWiki has been reported to work with the following OS/webserver combinations:%0a* Apache 1.3 or 2.0, on roughly anything (Unix, Linux, Windows, and Mac OS X)%0a** [[https://httpd.apache.org/ | Apache 2.4]] or later is recommended%0a* [[https://www.lighttpd.net/|lighttpd]] (1.4.19 php-fastcgi ssl) on Linux%0a* [[https://nginx.org/|nginx]] (0.8.47) on Windows ([[https://www.nginx.com/resources/wiki/start/topics/recipes/pmwiki/|configuration example]])%0a* Microsoft [[Cookbook:InstallOnIIS|Internet Information Server]], on Windows%0a* Linux + [[https://www.litespeedtech.com/|LiteSpeedWeb Server]] Standard Edition %0a* appWeb (a small, php-enabled webserver) executing on a Linksys NSLU2 Network Storage Link device%0a* Linux + [[https://www.hiawatha-webserver.org/|Hiawatha]]%0a%0aPmWiki has been reported not to work on:%0a* Mac OS before Mac OS X because there's no PHP available%0a* Specific Release Candidate builds of PHP 5.3 for Windows may not work correctly with passwords%0a%0aThe [[(Cookbook:)Standalone]] recipe provides a special, bare-bones webserver application that can be used to run PmWiki in places where another webserver isn't available.%0aPmWiki can also be run from a [[Cookbook:WikiOnAStick | USB drive]]. +time=1673640372 blob - 5462a1659b29e4ccef56ffd38d393a607fc349d5 blob + 5961604dfc675b8685d379895613a59582ed669a --- wikilib.d/PmWiki.Search +++ wikilib.d/PmWiki.Search @@ -1,12 +1,12 @@ -version=pmwiki-2.2.123 ordered=1 urlencoded=1 -author=Petko +version=pmwiki-2.3.12 ordered=1 urlencoded=1 +author=simon charset=UTF-8 -csum=See also $EnablePageListProtect (+98) +csum=pm hlt (+63) ctime=1150411168 description=A page for advanced and customized search options name=PmWiki.Search -rev=132 +rev=133 targets=PmWiki.WikiTrails,PmWiki.PageLists,Site.PageListTemplates,Site.LocalTemplates,Cookbook.PagelistTemplateSamples,Cookbook.Cookbook,PmWiki.PagelistVariables,PmWiki.Search,Site.AllRecentChanges,PITS.PITS,Group.Name -text=(:description A page for advanced and customized search options:)%0a(:Summary:Targeting and customizing search results:)%0a(:if !equal {$Action} "search":)%0a>>rframe width=300pcx font-size=smaller%3c%3c%0a-%3c '''This page uses [[#example|custom]] searches.'''%0aFor regular searches, view another page.%0a>>%3c%3c%0aPmWiki provides a basic search function. While it is not powered by a "search engine", it can be tweaked to produce results that are ''targeted'' and ''customized.'' %0a%0a!! Targeted searches%0aSearches can be targeted to restrict the search to certain pages. For example, a search can be restricted based on groups, where, for instance, "group=PmWiki" searches only the PmWiki group, and "group=-PmWiki" searches only pages that are not in the PmWiki group. In addition to groups, searches can be restricted based on page names ("name="), [[wiki trails]] ("trail="), backlinks ("link=") and other criteria (e.g. "list=normal") and capped at a maximum number ("count="). For documentation about each of these parameters, see [[page lists]]. %0a%0a!! Customized display%0aThe display of search results can be customized to control the format, content and order of the returned results. %0a:fmt=: select format and content by specifying a pagelist template that determines layout, such as list styles, and page elements, such as title and description. %0a:order=: allows results to be sorted according to different criteria, such as name and title. For documentation about each of these parameters, see [[page lists]]. %0aFor examples of pagelist template formats see [[Site.Page List Templates]], (:if2 exists Site.LocalTemplates:)[[Site.Local Templates]],(:if2end:) and [[Cookbook:Pagelist Template Samples]].%0a%0aThe [@(:pagelist request=1 req=1:)@] directives can be used instead of [@(:searchresults:)@] to remove the "Results of search for" message.%0aNeither of these directives work for the [@(:searchresults:)@] or [@(:searchbox:)@] directives.%0a:req=1: disables the pagelist until search results are returned.%0a:request=1: see [[PmWiki/PageLists#pagelistrequest|pagelists]]%0aThis can be used in many more cases than the default pmwiki search. %0aData from pages with PTVs, etc can be searched, filtered, and reordered.%0aNote that the default ordering is of text strings, ie. 1, 10, 2, 3 and not the numeric value 1, 2, 3, 10, but a custom pagelist sort function (see the [[cookbook/]]) can return any order required.%0a%0a!! Anyone, anywhere%0a'''Readers''' can create targeted and customized search results simply by typing the relevant parameters , e.g. "group=PmWiki", into search boxes together with their search string. '''Authors''' can predefine such targeted and customized searches by incorporating the parameters into pages using the [@(:searchbox:)@] and [@(:searchresults:)@] directives (documented at [[PageLists]]).%0a%0a[@(:searchresults:)@] can be customized by editing page [@Site.Search@].%0a%0aSee also%0a* $EnablePageListProtect to exclude from results pages where the visitor has no read permissions.%0a* $PageSearchForm %0a* $SearchBoxOpt%0a* $SearchPatterns%0a* $SearchBoxInputType%0a%0a%0a[[#example]]%0a!!Try it: this page generates custom searches%0aAny search that is run from this page will automatically generate pre-defined sets of search results that: '''''target''''' different clusters of pages (documentation, cookbook and PITS, if available); use '''''customized''''' formats, content and ordering; and '''''reveal''''' the specific parameters used to generate each search result. Whether you use the search box below, or the regular search box that appears at the top of this page, any search that you run from this page will provide the customized results. %0a(:searchbox size=20:)%0a%0a%0a(:ifend:)%0a(:if equal {$Action} "search":)%0a[[{$Name}|back]]\%0a%0a(:table border=0 width=100%25:)\%0a%0a(:cell width=30%25:)\%0a%0a!!!! [[Site/AllRecentChanges?q=PmWiki/+order%253Dname&action=search|All Documentation]]%0a(:searchresults group=PmWiki fmt=#onegroupdesc order=name:)%0a(:if expr exists Cookbook.Cookbook and equal {$Action} "search":)%0a(:cell width=35%25:)\%0a%0a!!!! [[Cookbook.Cookbook|All Cookbook Recipes]]%0a(:searchresults group=Cookbook fmt=#summary order=name:)%0a(:if expr exists PITS.PITS and equal {$Action} "search":)%0a(:cell width=35%25:)\%0a%0a!!!! [[PITS.PITS|PITS (Issue Tracking)]]%0a(:searchresults group=PITS fmt=#summary name=0* order=-name:)%0a(:if equal {$Action} "search":)%0a(:tableend:)%0a%0aNote: The strings that were used to target and format each search result are shown above in ''italics'' and can be entered directly into a regular search box.%0a%0a(:title Search:)%0a(:if false:)%0a%0a[[#onegroupdesc]]%0a[[{=$Group}/{=$Name}]] %25font-size=smaller font-style=italic%25{=$Description}%25%25\\%0a[[#onegroupdescend]]%0a%0a[[#summary]]%0a[[{=$Group}/{=$Name}]] %25font-size=smaller font-style=italic%25{=$:Summary}%25%25\\%0a[[#summaryend]]%0a(:ifend:) -time=1579104687 +text=(:description A page for advanced and customized search options:)%0a(:Summary:Targeting and customizing search results:)%0a(:if !equal {$Action} "search":)%0a>>rframe width=300pcx font-size=smaller%3c%3c%0a-%3c '''This page uses [[#example|custom]] searches.'''%0aFor regular searches, view another page.%0a>>%3c%3c%0aPmWiki provides a basic search function. While it is not powered by a "search engine", it can be tweaked to produce results that are ''targeted'' and ''customized.'' %0a%0a!! Targeted searches%0aSearches can be targeted to restrict the search to certain pages. For example, a search can be restricted based on groups, where, for instance, "group=PmWiki" searches only the PmWiki group, and "group=-PmWiki" searches only pages that are not in the PmWiki group. In addition to groups, searches can be restricted based on page names ("name="), [[wiki trails]] ("trail="), backlinks ("link=") and other criteria (e.g. "list=normal") and capped at a maximum number ("count="). For documentation about each of these parameters, see [[page lists]]. %0a%0a!! Customized display%0aThe display of search results can be customized to control the format, content and order of the returned results. %0a:fmt=: select format and content by specifying a pagelist template that determines layout, such as list styles, and page elements, such as title and description. %0a:order=: allows results to be sorted according to different criteria, such as name and title. For documentation about each of these parameters, see [[page lists]]. %0aFor examples of pagelist template formats see [[Site.Page List Templates]], (:if2 exists Site.LocalTemplates:)[[Site.Local Templates]],(:else2:)[=Site.LocalTemplates=],(:if2end:) and [[Cookbook:Pagelist Template Samples]].%0a%0aThe %25pmhlt%25[@(:pagelist request=1 req=1:)@] directives can be used instead of [@(:searchresults:)@] to remove the "Results of search for" message.%0aNeither of these directives work for the %25pmhlt%25[@(:searchresults:)@] or [@(:searchbox:)@] directives.%0a:req=1: disables the pagelist until search results are returned.%0a:request=1: see [[PmWiki/PageLists#pagelistrequest|pagelists]]%0aThis can be used in many more cases than the default pmwiki search. %0aData from pages with PTVs, etc can be searched, filtered, and reordered.%0aNote that the default ordering is of text strings, ie. 1, 10, 2, 3 and not the numeric value 1, 2, 3, 10, but a custom pagelist sort function (see the [[cookbook/]]) can return any order required.%0a%0a!! Anyone, anywhere%0a'''Readers''' can create targeted and customized search results simply by typing the relevant parameters , e.g. "group=PmWiki", into search boxes together with their search string. '''Authors''' can predefine such targeted and customized searches by incorporating the parameters into pages using the %25pmhlt%25[@(:searchbox:)@] and [@(:searchresults:)@] directives (documented at [[PageLists]]).%0a%0a%25pmhlt%25[@(:searchresults:)@]%25%25 can be customized by editing page [@Site.Search@].%0a%0aSee also%0a* $EnablePageListProtect to exclude from results pages where the visitor has no read permissions.%0a* $PageSearchForm %0a* $SearchBoxOpt%0a* $SearchPatterns%0a* $SearchBoxInputType%0a%0a%0a[[#example]]%0a!!Try it: this page generates custom searches%0aAny search that is run from this page will automatically generate pre-defined sets of search results that: '''''target''''' different clusters of pages (documentation, cookbook and PITS, if available); use '''''customized''''' formats, content and ordering; and '''''reveal''''' the specific parameters used to generate each search result. Whether you use the search box below, or the regular search box that appears at the top of this page, any search that you run from this page will provide the customized results. %0a(:searchbox size=20:)%0a%0a%0a(:ifend:)%0a(:if equal {$Action} "search":)%0a[[{$Name}|back]]\%0a%0a(:table border=0 width=100%25:)\%0a%0a(:cell width=30%25:)\%0a%0a!!!! [[Site/AllRecentChanges?q=PmWiki/+order%253Dname&action=search|All Documentation]]%0a(:searchresults group=PmWiki fmt=#onegroupdesc order=name:)%0a(:if expr exists Cookbook.Cookbook and equal {$Action} "search":)%0a(:cell width=35%25:)\%0a%0a!!!! [[Cookbook.Cookbook|All Cookbook Recipes]]%0a(:searchresults group=Cookbook fmt=#summary order=name:)%0a(:if expr exists PITS.PITS and equal {$Action} "search":)%0a(:cell width=35%25:)\%0a%0a!!!! [[PITS.PITS|PITS (Issue Tracking)]]%0a(:searchresults group=PITS fmt=#summary name=0* order=-name:)%0a(:if equal {$Action} "search":)%0a(:tableend:)%0a%0aNote: The strings that were used to target and format each search result are shown above in ''italics'' and can be entered directly into a regular search box.%0a%0a(:title Search:)%0a(:if false:)%0a%0a[[#onegroupdesc]]%0a[[{=$Group}/{=$Name}]] %25font-size=smaller font-style=italic%25{=$Description}%25%25\\%0a[[#onegroupdescend]]%0a%0a[[#summary]]%0a[[{=$Group}/{=$Name}]] %25font-size=smaller font-style=italic%25{=$:Summary}%25%25\\%0a[[#summaryend]]%0a(:ifend:) +time=1664219392 title=Search blob - 139609eb25e721731690946d29849d8a5a764dd5 blob + 73edfe9364d611f472385ceaf40bb4e45ae1ad2f --- wikilib.d/PmWiki.Security +++ wikilib.d/PmWiki.Security @@ -1,9 +1,9 @@ -version=pmwiki-2.2.110 ordered=1 urlencoded=1 +version=pmwiki-2.3.7 ordered=1 urlencoded=1 author=simon charset=UTF-8 -csum=secure cookies +csum=http+s, hlt php; suggest removal of register globals Q&A (+399) name=PmWiki.Security -rev=106 -targets=Category.Security,PmWiki.PageHistory,PmWiki.Passwords,PmWiki.PasswordsAdmin,PmWiki.AuthUser,PmWiki.UrlApprovals,PmWiki.AnalyzeResults,PmWiki.SiteAnalyzer,PmWiki.Blocklist,PmWiki.Notify,PmWiki.SecurityVariables,Cookbook.Security,Cookbook.HtpasswdForm,Cookbook.SecureAttachments,Cookbook.WebServerSecurity,Cookbook.FarmSecurity,Cookbook.DeObMail,Cookbook.SpamFilters,Cookbook.AuditImages,Cookbook.PrivateGroups,Cookbook.OnlyOneLogin,Cookbook.RecipeCheck,Cookbook.SessionGuard,Cookbook.TrackChanges,Cookbook.SwitchToSSLMode,PmWiki.ContactUs,PITS.PITS,Category.Spam,PmWiki.DeletingPages,PmWiki.AvailableActions,Cookbook.DeleteAction,Cookbook.Captchas,Cookbook.Captcha,Site.AuthForm,Cookbook.LimitWikiGroups,Cookbook.LimitNewPagesInWikiGroups,Cookbook.AuthDNS,Cookbook.PersistentLogin,PmWiki.Drafts,PmWiki.EditVariables,PmWiki.Uploads,PmWiki.UploadsAdmin,PmWiki.UploadVariables -text=(:Summary: Resources for securing your PmWiki installation:)%0aAspects of PmWiki [[!security]] are found on the following pages:%0a%0aPages distributed in a PmWiki release:%0a* [[PmWiki/Page history]] {PmWiki/PageHistory$:Summary}%0a* [[PmWiki/Passwords]] {PmWiki/Passwords$:Summary}%0a* [[PmWiki/Passwords Admin]] {PmWiki/PasswordsAdmin$:Summary}%0a* [[PmWiki/AuthUser]] {PmWiki/AuthUser$:Summary}%0a* [[PmWiki/Url Approvals]] {PmWiki/UrlApprovals$:Summary}%0a* [[(PmWiki:)Site Analyzer]] {PmWiki/SiteAnalyzer$:Summary}%0a* [[PmWiki/Blocklist]] {PmWiki/Blocklist$:Summary}%0a* [[PmWiki/Notify]] {PmWiki/Notify$:Summary}%0a* [[PmWiki/Security variables]] {PmWiki/SecurityVariables$:Summary}%0a%0a[[Cookbook(:/)]] pages%0a%0a* [[Cookbook:Security | Security recipes]] from the Cookbook%0a* [[Cookbook:HtpasswdForm]] Form based management of users and passwords using .htpasswd/.htgroup files%0a* [[Cookbook:Secure attachments]] Protecting uploaded attachments%0a* [[Cookbook:Web server security]] Making the server more secure with .htaccess%0a* [[Cookbook:Farm security]] Making Farm installations secure%0a* [[Cookbook:DeObMail]] Hide e-mail address%0a* [[Cookbook:Spam filters]] Automatic blocking of some spambots%0a* [[Cookbook:Audit images]] Check to see what images have been uploaded to your wiki.%0a* [[Cookbook:Private groups]] Create and secure private groups on a public wiki%0a* [[Cookbook:Only one login]] Only allow 1 login at the same time for a username%0a* [[Cookbook:Recipe check]] Check for new versions of recipes on pmwiki.org%0a* [[Cookbook:Session guard]] Protects against Session Theft%0a* [[Cookbook:TrackChanges]] Ways to more easily detect and verify all recent edits%0a* [[Cookbook:SwitchToSSLMode]] One approach to forcing https instead of http%0a%0a>>faq%3c%3c [[#faq]]%0a%0aQ: How do I report a possible security vulnerability of PmWiki?%0a%0aA: [[http://www.pmichaud.com|Pm]] wrote about this in [[http://pmichaud.com/pipermail/pmwiki-users/2006-September/031793.html | a post to pmwiki-users from September 2006]]. In a nutshell he differentiates two cases:%0a## The possible vulnerability isn't already known publicly: In this case please [[contact us]] by private mail.%0a## The possible vulnerability is already known publicly: In this case feel free to discuss the vulnerability in public (e.g. on [[http://www.pmichaud.com/mailman/listinfo/pmwiki-users | pmwiki-users]] or in the [[(PITS:)PITS]]).%0aSee [[http://pmichaud.com/pipermail/pmwiki-users/2006-September/031793.html | his post mentioned above]] for details and rationals.%0a%0aQ: What about the botnet security advisory at %25newwin%25[[http://isc.sans.org/diary.php?storyid=1672]]?%0a%0aA: Sites that are running with PHP's ''register_globals'' setting set to "On" and versions of PmWiki prior to 2.1.21 may be vulnerable to a botnet exploit that is taking advantage of a bug in PHP. The vulnerability can be closed by turning ''register_globals'' off, upgrading to PmWiki 2.1.21 or later, or upgrading to PHP versions 4.4.3 or 5.1.4. [[%3c%3c]]In addition, there is a test at [[PmWiki:SiteAnalyzer]] that can be used to determine if your site is vulnerable.%0a%0a[[#wikivandalism]]%0a!! Wiki Vandalism and [[!Spam]]%0a:Assumptions: you are using a [[PmWiki/Blocklist]] and [[PmWiki/Url approvals]].%0a: :You don't want to resort to [[PmWiki/password(s)]] protecting the entire wiki, that's not the point after all.%0a: :Ideally these protections will be invoked in @@config.php@@%0a%0a%0aQ: How do I stop pages being [[PmWiki/DeletingPages|deleted]], eg password protect a page from deletion?%0aA: Use Cookbook:DeleteAction and password protect the page deletion [[(available) action(s)]] by adding [@$DefaultPasswords['delete'] = '*';@] to @@config.php@@ or password protect the action with @@$HandleAuth['delete'] = 'edit';@@%0a->or @@$HandleAuth['delete'] = 'admin';@@ to require the edit or admin password respectively.%0a%0aQ: How do I stop pages being replaced with an empty (all spaces) page?%0aA: Add [@block: /^\s*$/@] to your [[PmWiki/blocklist]].%0a%0aQ: how do I stop pages being completely replaced by an inane comment such as ''excellent site'', ''great information'', where the content cannot be blocked?%0aA: Try using the newer [[PmWiki/Blocklist#automaticblocklists | automatic blocklists]] that pull information and IP addresses about known wiki defacers.%0a%0aA: (OR) Try using [[Cookbook:Captchas]] or [[Cookbook:Captcha]] (note these are different).%0a%0aA: (OR) Set an edit password, but make it publicly available on the [[{$SiteGroup}.AuthForm]] template.%0a%0aQ: How do I password protect the creation of new groups?%0aA: See [[Cookbook:Limit Wiki Groups]] {Cookbook.LimitWikiGroups$:Summary}%0a%0aQ: How do I password protect the creation of new pages?%0aA: See [[Cookbook:Limit new pages in Wiki Groups]] {Cookbook.LimitNewPagesInWikiGroups$:Summary}%0a%0aQ: How do I take a whitelist approach where users from known or trusted IP addresses can edit, and others require a password?%0aA: Put these lines to local/config.php:%0a[@%0a## Allow passwordless editing from own turf, pass for others.%0aif ($action=='edit'%0a && !preg_match("/^90\\.68\\./", $_SERVER['REMOTE_ADDR']) ) %0a { $DefaultPasswords['edit'] = pmcrypt('foobar'); }%0a@]%0aReplace 90.68. with the preferred network prefix and foobar with the default password for others.%0a%0aFor a single IP, you may use %0a[@%0aif($_SERVER['REMOTE_ADDR'] == '127.0.0.1') { # your IP address here%0a $_POST['authpw'] = 'xxx'; # the admin password%0a}%0a@]%0a%0aPlease note the security issues : this means that you have your admin passwords in clear in config.php and someone with access to the filesystem can read them (for example a technician of your hosting provider) ; your IP address may change from time to time (unless you have a fixed IP contract with your ISP). When that happens, someone with your old IP address will be logged in automatically as admin on your wiki. It is extremely unlikely to become a problem, but you should know it is possible ; if you are behind a router, all other devices which pass through that router will have the same IP address for PmWiki - your wifi phone, your wife's netbook, a neighbour using your wifi connection, etc. All these people become admins of your wiki. Again, you should evaluate if this is a security risk ; In some cases, your ISP will route your traffic through the same proxy as other people. In such a case, thousands of people may have the same IP address.%0a%0aA: See also Cookbook:AuthDNS & Cookbook:PersistentLogin%0a%0aQ: How do I password protect [[PmWiki/AvailableActions|page actions]]?%0aA: See [[PmWiki/Passwords]] for setting in config.php %0a-> @@$HandleAuth['[==]''pageactionname''[==]'] = 'pageactionname'; # along with :@@%0a-> @@$DefaultPasswords['[==]''pageactionname''[==]'] = pmcrypt('secret phrase');@@%0aA: or %0a-> @@$HandleAuth['[==]''pageactionname''[==]'] = 'anotherpageactionname';@@%0a%0aQ: How do I moderate all postings?%0aA: Enable [[PmWiki.Drafts]]%0a* Set $EnableDrafts, this relabels the "Save" button to "Publish" and a "Save draft" button appears. %0a* Set $EnablePublishAttr, this adds a new "publish" authorization level to distinguish editing from publishing.%0a%0aQ: How do I make a read only wiki?%0aA: In config.php [[PmWiki/PasswordsAdmin | set]] an "edit" password.%0a%0aQ: How do I restrict access to [[PmWiki/Uploads|uploaded attachments]]?%0aA: See%0a* [[PmWiki/UploadsAdmin#direct_download|instructions]] for denying public access to the uploads directory%0a* see [[Cookbook:Secure attachments]] {Cookbook.SecureAttachments$:Summary}%0a%0aQ: How do I hide the IP addresses in the "diff" pages?%0aA: If the user fills an author name, the IP address is not displayed. To require an author name, set in config.php such a line:%0a%0a $EnablePostAuthorRequired = 1;%0a%0aA: The IP address can also be seen in a tooltip title when the mouse cursor is over the author name. To disable the tooltip, set in config.php:%0a[@%0a$DiffStartFmt = %0a "%3cdiv class='diffbox'>%3cdiv class='difftime'>%3ca name='diff\$DiffGMT' href='#diff\$DiffGMT'>\$DiffTime%3c/a>%0a \$[by] %3cspan class='diffauthor'>\$DiffAuthor%3c/span> - \$DiffChangeSum%3c/div>";%0a@]%0a%0aQ: How do I stop some Apache installations executing a file which has ".php", ".pl" or ".cgi" anywhere in the filename%0aA: Use $UploadBlacklist%0a%0aQ: How do I stop random people from viewing the ?action=source (wiki markup) of my pages? I have [@(:if auth edit:)@] text that I don't want the world to see.%0aA: [@$HandleAuth['source'] = 'edit';@] or [@$HandleAuth['source'] = 'admin';@]%0a%0aQ: How to I %25newwin%25[[https://en.wikipedia.org/wiki/Secure_cookie|secure]] my [[https://developer.mozilla.org/en-US/docs/Web/HTTP/Cookies#Secure_and_HttpOnly_cookies|cookies]]?%0aA: See $EnableCookieSecure and $EnableCookieHTTPOnly -time=1543726253 +rev=108 +targets=Category.Security,!Security,PmWiki.PageHistory,PmWiki.Passwords,PmWiki.PasswordsAdmin,PmWiki.AuthUser,PmWiki.UrlApprovals,PmWiki.AnalyzeResults,PmWiki.SiteAnalyzer,PmWiki.Blocklist,PmWiki.Notify,PmWiki.SecurityVariables,Cookbook.Security,Cookbook.HtpasswdForm,Cookbook.SecureAttachments,Cookbook.WebServerSecurity,Cookbook.FarmSecurity,Cookbook.DeObMail,Cookbook.SpamFilters,Cookbook.AuditImages,Cookbook.PrivateGroups,Cookbook.OnlyOneLogin,Cookbook.RecipeCheck,Cookbook.SessionGuard,Cookbook.TrackChanges,Cookbook.SwitchToSSLMode,Cookbook.OpenPass,PmWiki.ContactUs,PITS.PITS,Category.Spam,!Spam,PmWiki.DeletingPages,PmWiki.AvailableActions,Cookbook.DeleteAction,Cookbook.Captchas,Cookbook.Captcha,Site.AuthForm,Cookbook.LimitWikiGroups,Cookbook.LimitNewPagesInWikiGroups,Cookbook.AuthDNS,Cookbook.PersistentLogin,PmWiki.Drafts,PmWiki.EditVariables,PmWiki.Uploads,PmWiki.UploadsAdmin,PmWiki.UploadVariables,Cookbook.OpenPass-Talk +text=(:Summary: Resources for securing your PmWiki installation:)%0aAspects of PmWiki [[!security]] are found on the following pages:%0a%0aPages distributed in a PmWiki release:%0a* [[PmWiki/Page history]] {PmWiki/PageHistory$:Summary}%0a* [[PmWiki/Passwords]] {PmWiki/Passwords$:Summary}%0a* [[PmWiki/Passwords Admin]] {PmWiki/PasswordsAdmin$:Summary}%0a* [[PmWiki/AuthUser]] {PmWiki/AuthUser$:Summary}%0a* [[PmWiki/Url Approvals]] {PmWiki/UrlApprovals$:Summary}%0a* [[(PmWiki:)Site Analyzer]] {PmWiki/SiteAnalyzer$:Summary}%0a* [[PmWiki/Blocklist]] {PmWiki/Blocklist$:Summary}%0a* [[PmWiki/Notify]] {PmWiki/Notify$:Summary}%0a* [[PmWiki/Security variables]] {PmWiki/SecurityVariables$:Summary}%0a%0a[[Cookbook(:/)]] pages%0a%0a* [[Cookbook:Security | Security recipes]] from the Cookbook%0a* [[Cookbook:HtpasswdForm]] Form based management of users and passwords using .htpasswd/.htgroup files%0a* [[Cookbook:Secure attachments]] Protecting uploaded attachments%0a* [[Cookbook:Web server security]] Making the server more secure with .htaccess%0a* [[Cookbook:Farm security]] Making Farm installations secure%0a* [[Cookbook:DeObMail]] Hide e-mail address%0a* [[Cookbook:Spam filters]] Automatic blocking of some spambots%0a* [[Cookbook:Audit images]] Check to see what images have been uploaded to your wiki.%0a* [[Cookbook:Private groups]] Create and secure private groups on a public wiki%0a* [[Cookbook:Only one login]] Only allow 1 login at the same time for a username%0a* [[Cookbook:Recipe check]] Check for new versions of recipes on pmwiki.org%0a* [[Cookbook:Session guard]] Protects against Session Theft%0a* [[Cookbook:TrackChanges]] Ways to more easily detect and verify all recent edits%0a* [[Cookbook:SwitchToSSLMode]] One approach to forcing https instead of http%0a* [[Cookbook:OpenPass]] Set a global password to resist spambots but make sure humans are informed of the password?%0a%0a>>faq%3c%3c [[#faq]]%0a%0aQ: How do I report a possible security vulnerability of PmWiki?%0a%0aA: [[https://www.pmichaud.com|Pm]] wrote about this in [[https://pmichaud.com/pipermail/pmwiki-users/2006-September/031793.html | a post to pmwiki-users from September 2006]]. In a nutshell he differentiates two cases:%0a## The possible vulnerability isn't already known publicly: In this case please [[contact us]] by private mail.%0a## The possible vulnerability is already known publicly: In this case feel free to discuss the vulnerability in public (e.g. on [[https://www.pmichaud.com/mailman/listinfo/pmwiki-users | pmwiki-users]] or in the [[(PITS:)PITS]]).%0aSee [[https://pmichaud.com/pipermail/pmwiki-users/2006-September/031793.html | his post mentioned above]] for details and rationals.%0a%0aQ: What about the botnet security advisory at %25newwin%25[[https://isc.sans.edu/diary/Reports+of+Bots+exploiting+pmwiki+and+tikiwiki/1672]]?%0a%0aA: Sites that are running with PHP's ''register_globals'' setting set to "On" and versions of PmWiki prior to 2.1.21 may be vulnerable to a botnet exploit that is taking advantage of a bug in PHP. The vulnerability can be closed by turning ''register_globals'' off, upgrading to PmWiki 2.1.21 or later, or upgrading to PHP versions 4.4.3 or 5.1.4. [[%3c%3c]]In addition, there is a test at [[PmWiki:SiteAnalyzer]] that can be used to determine if your site is vulnerable.%0a%0a[[#wikivandalism]]%0a!! Wiki Vandalism and [[!Spam]]%0a:Assumptions: you are using a [[PmWiki/Blocklist]] and [[PmWiki/Url approvals]].%0a: :You don't want to resort to [[PmWiki/password(s)]] protecting the entire wiki, that's not the point after all.%0a: :Ideally these protections will be invoked in @@config.php@@%0a%0a%0aQ: How do I stop pages being [[PmWiki/DeletingPages|deleted]], eg password protect a page from deletion?%0aA: Use Cookbook:DeleteAction and password protect the page deletion [[(available) action(s)]] by adding %25hlt php%25[@$DefaultPasswords['delete'] = '*';@] to @@config.php@@ or password protect the action with @@$HandleAuth['delete'] = 'edit';@@%0a->or %25hlt php%25@@$HandleAuth['delete'] = 'admin';@@ to require the edit or admin password respectively.%0a%0aQ: How do I stop pages being replaced with an empty (all spaces) page?%0aA: Add [@block: /^\s*$/@] to your [[PmWiki/blocklist]].%0a%0aQ: how do I stop pages being completely replaced by an inane comment such as ''excellent site'', ''great information'', where the content cannot be blocked?%0aA: Try using the newer [[PmWiki/Blocklist#automaticblocklists | automatic blocklists]] that pull information and IP addresses about known wiki defacers.%0a%0aA: (OR) Try using [[Cookbook:Captchas]] or [[Cookbook:Captcha]] (note these are different).%0a%0aA: (OR) Set an edit password, but make it publicly available on the [[{$SiteGroup}.AuthForm]] template.%0a%0aQ: How do I password protect the creation of new groups?%0aA: See [[Cookbook:Limit Wiki Groups]] {Cookbook.LimitWikiGroups$:Summary}%0a%0aQ: How do I password protect the creation of new pages?%0aA: See [[Cookbook:Limit new pages in Wiki Groups]] {Cookbook.LimitNewPagesInWikiGroups$:Summary}%0a%0aQ: How do I take a whitelist approach where users from known or trusted IP addresses can edit, and others require a password?%0aA: Put these lines to @@local/config.php@@:%0a-> %25hlt php%25[@%0a## Allow passwordless editing from own turf, pass for others.%0aif ($action=='edit'%0a && !preg_match("/^90\\.68\\./", $_SERVER['REMOTE_ADDR']) ) %0a { $DefaultPasswords['edit'] = pmcrypt('foobar'); }%0a@]%0aReplace @@90.68.@@ with the preferred network prefix and @@foobar@@ with the default password for others.%0a%0aFor a single IP, you may use %0a->%25hlt php%25[@%0aif($_SERVER['REMOTE_ADDR'] == '127.0.0.1') { # your IP address here%0a $_POST['authpw'] = 'xxx'; # the admin password%0a}%0a@]%0a%0aPlease note the security issues: this means that you have your admin passwords in clear in @@config.php@@ and someone with access to the filesystem can read them (for example a technician of your hosting provider); your IP address may change from time to time (unless you have a fixed IP contract with your ISP). When that happens, someone with your old IP address will be logged in automatically as admin on your wiki. It is extremely unlikely to become a problem, but you should know it is possible; if you are behind a router, all other devices which pass through that router will have the same IP address for PmWiki - your wifi phone, your wife's netbook, a neighbour using your wifi connection, etc. All these people become admins of your wiki. Again, you should evaluate if this is a security risk; In some cases, your ISP will route your traffic through the same proxy as other people. In such a case, thousands of people may have the same IP address.%0a%0aA: See also Cookbook:AuthDNS & Cookbook:PersistentLogin%0a%0aQ: How do I password protect [[PmWiki/AvailableActions|page actions]]?%0aA: See [[PmWiki/Passwords]] for setting in @@config.php@@ %0a-> %25hlt php%25@@$HandleAuth['[==]''pageactionname''[==]'] = 'pageactionname'; # along with :@@%0a-> %25hlt php%25@@$DefaultPasswords['[==]''pageactionname''[==]'] = pmcrypt('secret phrase');@@%0aA: or %0a-> %25hlt php%25@@$HandleAuth['[==]''pageactionname''[==]'] = 'anotherpageactionname';@@%0a%0aQ: How do I moderate all postings?%0aA: Enable [[PmWiki.Drafts]]%0a* Set $EnableDrafts, this relabels the "Save" button to "Publish" and a "Save draft" button appears. %0a* Set $EnablePublishAttr, this adds a new "publish" authorization level to distinguish editing from publishing.%0a%0aQ: How do I make a read only wiki?%0aA: In @@config.php@@ [[PmWiki/PasswordsAdmin | set]] an "edit" password.%0a%0aQ: How do I restrict access to [[PmWiki/Uploads|uploaded attachments]]?%0aA: See%0a* [[PmWiki/UploadsAdmin#direct_download|instructions]] for denying public access to the uploads directory%0a* [[Cookbook:Secure attachments]] {Cookbook.SecureAttachments$:Summary}%0a%0aQ: How do I hide the IP addresses in the "diff" pages?%0aA: If the user fills an author name, the IP address is not displayed. To require an author name, set in @@config.php@@ such a line:%0a%0a $EnablePostAuthorRequired = 1;%0a%0aA: The IP address can also be seen in a tooltip title when the mouse cursor is over the author name. To disable the tooltip, set in @@config.php@@:%0a%25hlt php%25[@%0a$DiffStartFmt = %0a "%3cdiv class='diffbox'>%3cdiv class='difftime'>%3ca name='diff\$DiffGMT' href='#diff\$DiffGMT'>\$DiffTime%3c/a>%0a \$[by] %3cspan class='diffauthor'>\$DiffAuthor%3c/span> - \$DiffChangeSum%3c/div>";%0a@]%0a%0aQ: How do I stop some Apache installations executing a file which has ".php", ".pl" or ".cgi" anywhere in the filename%0aA: Use $UploadBlacklist%0a%0aQ: How do I stop random people from viewing the ?action=source (wiki markup) of my pages? I have %25pmhlt%25[@(:if auth edit:)@] text that I don't want the world to see.%0aA: %25hlt php%25[@$HandleAuth['source'] = 'edit';@] or [@$HandleAuth['source'] = 'admin';@]%0a%0aQ: How to I %25newwin%25[[https://en.wikipedia.org/wiki/Secure_cookie|secure]] my [[https://developer.mozilla.org/en-US/docs/Web/HTTP/Cookies#Secure_and_HttpOnly_cookies|cookies]]?%0aA: See $EnableCookieSecure and $EnableCookieHTTPOnly%0a%0aQ: How do I set a global password to resist spambots, and informed humans of the password?%0aA: See [[Cookbook:OpenPass-Talk]] +time=1657916635 blob - a1a71a6f9e3bda948bb1bf2edaa1ea8983399718 blob + e5cd87b4dfbf89ee95e7319ea34583440601d092 --- wikilib.d/PmWiki.SecurityVariables +++ wikilib.d/PmWiki.SecurityVariables @@ -1,10 +1,10 @@ -version=pmwiki-2.2.123 ordered=1 urlencoded=1 +version=pmwiki-2.3.14 ordered=1 urlencoded=1 author=Petko charset=UTF-8 -csum=$SetCookieFunction (+2) +csum=$CookieSameSite (+265) ctime=1156512569 name=PmWiki.SecurityVariables -rev=46 -targets=PmWiki.SecurityVariables,PmWiki.PasswordsAdmin,PmWiki.AuthUser,PmWiki.Functions,PmWiki.AvailableActions,PmWiki.EditVariables,PmWiki.UploadVariables,PmWiki.Security,PmWiki.PagelistVariables -text=(:Summary:variables crucial for site security:)%0a:$AllowPassword: This variable contains the special "nopass" password which was used in the past to leave pages or groups accessible without a password. Recent PmWiki versions use "@nopass" instead. If your wiki is old and/or may contain pages with the "nopass" password, you should not change it. If that variable is empty or set to false, PmWiki will not check if pages have a special "allowed password".%0a%0a:$DefaultPasswords: Specifies default passwords for user admin or actions (edit, read, upload). See [[PmWiki/PasswordsAdmin#settingsitewidepasswords]].%0a%0a:$DenyHtaccessContent: Specifies the default content for @@.htaccess@@ files created by PmWiki in new directories under wiki.d. The Apache server [[https://httpd.apache.org/docs/2.4/upgrading.html#run-time|changed these directives in version 2.4]]. The default value should work for both new and older server versions.%0a%0a:$EnablePostAttrClearSession: A switch to control whether or not changing a page's attributes causes any existing passwords to be forgotten. The default is that changing attributes forgets any passwords entered; this can be changed by setting $EnablePostAttrClearSession to zero.%0a%0a:$EnableSessionPasswords: Control whether passwords are saved as part of the session. If set to zero, then session passwords are never saved (although any [[AuthUser]] authentications are still remembered).%0a%0a:$SetCookieFunction:A custom function name to send cookies to the browser, instead of @@[[Functions#pmsetcookie|pmsetcookie()]]@@. Should accept the same arguments as @@pmsetcookie()@@.%0a%0a:$EnableCookieSecure:Set to 1 to enable the "[[https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Set-Cookie|Secure]]" flag for core PmWiki cookies (will only be transmitted via HTTPS). This includes author, preference, and cache core cookies and any custom cookies set via [[Functions#pmsetcookie|pmsetcookie()]].\\%0aNote: for the session cookie, you need to also add this line: [@ @ini_set('session.cookie_secure', true); @]\\%0aAdd these lines near the beginning of config.php.%0a%0a:$EnableCookieHTTPOnly:Set to 1 to enable the "[[https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Set-Cookie|HttpOnly]]" flag for core PmWiki cookies (will not be made available to JavaScript). This includes author, preference, and cache core cookies and any custom cookies set via [[Functions#pmsetcookie|pmsetcookie()]].\\%0aNote: for the session cookie, you need to also add this line: [@ @ini_set('session.cookie_httponly', true); @]\\%0aAdd these lines near the beginning of config.php.%0a%0a:$SessionEncode: Function to use to encode sensitive information in sessions. Set this to NULL if you want to not use any encoding. (See also $SessionDecode below.)%0a%0a:$SessionDecode: Function to reverse the decoding given by $SessionEncode above. Set this to NULL if sensitive session values are not encoded.%0a%0a:$HandleAuth:This sets the required authentication Level that is necessary to perform an [[PmWiki/AvailableActions|action]]. When using the following example in your @@config.php@@ you need to be authenticated as editor in order to view the page history:%0a $HandleAuth['diff'] = 'edit';%0a%0a:$PageAttributes:Set the string shown on the attributes page when entering a password for an action.%0a%0a:$AuthLDAPBindDN:For sites using [[AuthUser]] with LDAP authentication, this specifies the distinguished name (DN) to be used to bind to the LDAP server to check identity.%0a%0a:$AuthLDAPBindPassword:For [[AuthUser]] with LDAP authentication, this specifies the password used for binding (in conjunction with $AuthLDAPBindDN above).%0a%0a:$AuthLDAPReferrals:Specifies whether to automatically follow referrals returned by the LDAP server, set 1 to enable or 0 to disable. By default this variable is unset, and the connection follows referrals if they are enabled on the server side (they usually are).%0a%0a:$EnablePublishAttr:Adds a new "publish" authorization level to distinguish editing of drafts from publishing - See $EnableDrafts.%0a%0a:$EnablePageVarAuth: In PmWiki versions 2.2.22 and 2.2.23 this variable should be set to 0. In 2.2.24 it will no longer be used.%0a%0a:$RobotActions: An array controlling which [[AvailableActions|actions]] can be reached by web bots. The array keys are the actions, if the value is 1 or true then the action is reachable. If an action is not defined as a key, or if the value for that key evaluates to false or zero, when a bot requests this action it will be refused. By default, only the actions "browse", "rss" and "dc" are reachable by bots. For example:\\%0a@@$RobotActions['download'] = 1; @@ # '''allow''' bots to download files with disabled $EnableDirectDownload (page permissions are respected)\\%0a@@$RobotActions['rss'] = 0; @@ # '''disallow''' bots from getting the RSS feed\\%0a@@$RobotActions['print'] = 1; @@ # allow bots to get the print view\\%0aThe variable can have custom actions used by cookbook recipes as keys.%0a%0a:$RobotPattern: A regular expression pattern with known user-agent strings for bots. %0a%0a:$EnableRobotCloakActions: Setting this flag to 1 will eliminate any forbidden ?action= values from page links returned to robots, which will reduce bandwidth loads from robots even further.%0a%0a%0aSee also:%0a* [[Security]]%0a* $EnablePageListProtect%0a* $EnableDirectDownload%0a -time=1579174392 +rev=51 +targets=PmWiki.SecurityVariables,PmWiki.PasswordsAdmin,PmWiki.AuthUser,PmWiki.Functions,PmWiki.AvailableActions,Cookbook.FailedLoginFunction,PmWiki.EditVariables,PmWiki.UploadVariables,PmWiki.Security,PmWiki.PagelistVariables +text=(:Summary:variables crucial for site security:)%0a:$AllowPassword: This variable contains the special "nopass" password which was used in the past to leave pages or groups accessible without a password. Recent PmWiki versions use "@nopass" instead. If your wiki is old and/or may contain pages with the "nopass" password, you should not change it. If that variable is empty or set to false, PmWiki will not check if pages have a special "allowed password".%0a%0a:$DefaultPasswords: Specifies default passwords for user admin or actions (edit, read, upload). See [[PmWiki/PasswordsAdmin#settingsitewidepasswords]].%0a%0a:$DenyHtaccessContent: Specifies the default content for @@.htaccess@@ files created by PmWiki in new directories under wiki.d. The Apache server [[https://httpd.apache.org/docs/2.4/upgrading.html#run-time|changed these directives in version 2.4]]. The default value should work for both new and older server versions.%0a%0a:$EnablePostAttrClearSession: A switch to control whether or not changing a page's attributes causes any existing passwords to be forgotten. The default is that changing attributes forgets any passwords entered; this can be changed by setting $EnablePostAttrClearSession to zero.%0a%0a:$EnableSessionPasswords: Control whether passwords are saved as part of the session. If set to zero, then session passwords are never saved (although any [[AuthUser]] authentications are still remembered).%0a%0a:$SetCookieFunction:A custom function name to send cookies to the browser, instead of @@[[Functions#pmsetcookie|pmsetcookie()]]@@. Should accept the same arguments as @@pmsetcookie()@@.%0a%0a:$EnableCookieSecure:Set to 1 to enable the "[[https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Set-Cookie|Secure]]" flag for core PmWiki cookies (will only be transmitted via HTTPS). This includes author, preference, and cache core cookies and any custom cookies set via @@pmsetcookie()@@.\\%0aNote: the session cookie and all other PmWiki cookies are affected.%0a%0a:$EnableCookieHTTPOnly:Set to 1 to enable the "[[https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Set-Cookie|HttpOnly]]" flag for core PmWiki cookies (will not be made available to JavaScript). This includes author, preference, and cache core cookies and any custom cookies set via @@pmsetcookie()@@.\\%0aNote: the session cookie and all other PmWiki cookies are affected.%0a%0a:$CookieSameSite: The "[[https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Set-Cookie|SameSite]]" flag for cookies sent via @@pmsetcookie()@@, default to 'Lax'. See [[https://techcommunity.microsoft.com/t5/iis-support-blog/samesite-lax-in-the-new-world/ba-p/1156292|article]] about the implications.%0a%0a:$SessionEncode: Function to use to encode sensitive information in sessions. Set this to NULL if you want to not use any encoding. (See also $SessionDecode below.)%0a%0a:$SessionDecode: Function to reverse the decoding given by $SessionEncode above. Set this to NULL if sensitive session values are not encoded.%0a%0a:$HandleAuth:This sets the required authentication Level that is necessary to perform an [[PmWiki/AvailableActions|action]]. When using the following example in your @@config.php@@ you need to be authenticated as editor in order to view the page history:%0a $HandleAuth['diff'] = 'edit';%0a%0a:$PageAttributes:Set the string shown on the attributes page when entering a password for an action.%0a%0a:$AuthLDAPBindDN:For sites using [[AuthUser]] with LDAP authentication, this specifies the distinguished name (DN) to be used to bind to the LDAP server to check identity.%0a%0a:$AuthLDAPBindPassword:For [[AuthUser]] with LDAP authentication, this specifies the password used for binding (in conjunction with $AuthLDAPBindDN above).%0a%0a:$AuthLDAPReferrals:Specifies whether to automatically follow referrals returned by the LDAP server, set 1 to enable or 0 to disable. By default this variable is unset, and the connection follows referrals if they are enabled on the server side (they usually are).%0a%0a:$MultiFactorAuthFunction: ([[AuthUser]] only) A custom function to perform a check for multi-factor-authentication (MFA, 2FA). Called by AuthUserId() if the password authentication has succeeded. This function is called with arguments the username and password, and should return true if the 2FA has succeeded, false otherwise.%0a%0a:$FailedLoginsFunction: ([[AuthUser]] only) A custom function to perform a check for multiple failed logins, see Cookbook:FailedLoginFunction.%0a%0a:$EnablePublishAttr:Adds a new "publish" authorization level to distinguish editing of drafts from publishing - See $EnableDrafts.%0a%0a:$EnablePageVarAuth: In PmWiki versions 2.2.22 and 2.2.23 this variable should be set to 0. In 2.2.24 it will no longer be used.%0a%0a:$RobotActions: An array controlling which [[AvailableActions|actions]] can be reached by web bots. The array keys are the actions, if the value is 1 or true then the action is reachable. If an action is not defined as a key, or if the value for that key evaluates to false or zero, when a bot requests this action it will be refused. By default, only the actions "browse", "rss" and "dc" are reachable by bots. For example:\\%0a@@$RobotActions['download'] = 1; @@ # '''allow''' bots to download files with disabled $EnableDirectDownload (page permissions are respected)\\%0a@@$RobotActions['rss'] = 0; @@ # '''disallow''' bots from getting the RSS feed\\%0a@@$RobotActions['print'] = 1; @@ # allow bots to get the print view\\%0aThe variable can have custom actions used by cookbook recipes as keys.%0a%0a:$RobotPattern: A regular expression pattern with known user-agent strings for bots. %0a%0a:$EnableRobotCloakActions: Setting this flag to 1 will eliminate any forbidden ?action= values from page links returned to robots, which will reduce bandwidth loads from robots even further.%0a%0a%0aSee also:%0a* [[Security]]%0a* $EnablePageListProtect%0a* $EnableDirectDownload%0a +time=1669022081 blob - 59891ba1fa948b28eaddb28282655c7d5c2681b8 blob + 4248af7827f4756d5bc1991d63d7f0bf376ebc45 --- wikilib.d/PmWiki.SitePageActions +++ wikilib.d/PmWiki.SitePageActions @@ -1,10 +1,10 @@ -version=pmwiki-2.2.115 ordered=1 urlencoded=1 +version=pmwiki-2.2.145 ordered=1 urlencoded=1 author=simon charset=UTF-8 -csum=How to hide +csum=http+s (+5) ctime=1160022336 name=PmWiki.SitePageActions -rev=18 +rev=24 targets=Site.PageActions,Cookbook.Cookbook,PmWiki.AvailableActions,PmWiki.BasicEditing,PmWiki.Skins,PmWiki.WikiStyles,PmWiki.LayoutVariables,PmWiki.AccessKeys,Site.Preferences,PmWiki.Internationalizations,PmWiki.Links,PmWiki.PageVariables,PmWiki.SitePageActions,PmWiki.ConditionalMarkup,PmWiki.DocumentationIndex,PmWiki.MailingLists,PmWiki.PageDirectives -text=(:Summary: how site page actions work:)%0a%25audience%25 authors (basic)%0a%0aThe [[Site.PageActions]] page is used as the source of the [[http://www.pmwiki.org/wiki/PmWiki/AvailableActions#defaultactions|default wiki commands]] shown in the default PmWiki skin at the top right of the page. It displays as follows:%0a[[%3c%3c]]%0a(:div id="wikicmds" class="float":)%0a(:include Site.PageActions:)%0a(:divend:)%0a[[%3c%3c]]%0aNote that there are many other [[available actions]] from the [[Cookbook:Cookbook|Cookbook]], and PmWiki diagnostics and scripts.%0a%0aThis page gives a brief explanation of how [[Site.PageActions]] are displayed and formatted, and pointers to where more information can be found.%0a%0aBelow is what is shipped as [[Site.PageActions]] with PmWiki version 2.2:%0a->[@%0a* %25item rel=nofollow class=browse accesskey='$[ak_view]'%25 [[{*$FullName} | $[View] ]]%0a* %25item rel=nofollow class=edit accesskey='$[ak_edit]'%25 [[{*$FullName}?action=edit | $[Edit] ]]%0a* %25item rel=nofollow class=diff accesskey='$[ak_history]'%25 [[{*$FullName}?action=diff | $[History] ]]%0a(:if auth upload:)%0a* %25item rel=nofollow class=upload accesskey='$[ak_attach]'%25 [[{*$FullName}?action=upload | $[Attach] ]]%0a(:ifend:)%0a* %25item rel=nofollow class=print accesskey='$[ak_print]'%25 [[{*$FullName}?action=print | $[Print] ]]%0a(:if group Site,SiteAdmin,Cookbook,Profiles,PmWiki*:) (:comment delete if and ifend to enable backlinks:)%0a* %25item rel=nofollow class=backlinks accesskey='$[ak_backlinks]'%25 [[{*$Name}?action=search&q=link={*$FullName} | $[Backlinks] ]]%0a(:ifend:)%0a(:if enabled AuthPw:)%0a* %25item rel=nofollow class=logout accesskey="$[ak_logout]"%25'' [-[[{*$FullName}?action=logout | $[Logout] ]]-]''%0a(:ifend:)%0a@]%0a%0aTo start with, we'll look at just the first line, and take it apart. This will also give us a good handle on how most of the other lines work.%0a%0a!! List%0aEach line is an item in an unordered [[http://www.pmwiki.org/wiki/PmWiki/MarkupMasterIndex#Lists|list]], marked up by an unindented '@@*@@'. %0aYou can find out more about lists on the [[Basic Editing]] page.%0a%0aPmWiki will normally display an unordered list as a set of bulleted items, but they can appear differently depending on the context and styles they are displayed in. This difference in display is generally controlled by CSS defined in the [[Skins|Skin]]: for the PageActions links, the list items are displayed inline.%0a%0a!! Style%0aFollowing the '[@*@]', on the line we have [@%25item ... %25@] which is a [[WikiStyles|WikiStyle]]. It is used to control the properties of a given output element, like its size or color. By default they apply to the text between them and the end of the line or a closing [@%25%25@], whichever is sooner. So, for example, one can enter [@"this %25blue%25text%25%25 is blue"@] and it will appear as "this %25blue%25text%25%25 is blue".%0a%0aIn this case the WikiStyle starts with the word [@item@], and that says to apply the given style to the entire list item as opposed to just the text that follows. In particular, it causes PmWiki to generate HTML of%0a%0a->[@%3cli class='edit'>...%3c/li>@]%0a%0ainstead of%0a%0a->[@%3cli>%3cspan class='edit'>...%3c/span>%3c/li>@]%0a%0aSetting the class attribute of the list item allows CSS properties to be applied to the item that corresponds to the current action. For example, to have the current action display with a background color of blue, a wiki administrator can do:%0a%0a->@@$HTMLStylesFmt[]@@[@ = ' .{$Action} { background-color: blue; }';@]%0a%0aThen if the current action is 'edit' (as in "?action=edit"), the list item corresponding to the edit action will be drawn with a blue background.%0a%0aThe other property inside the [@%25item ... %25@] WikiStyle is the accesskey='$[ak_view]' statement. [[AccessKeys]] are keyboard shortcuts for tasks that would otherwise require a mouse. They can be attached to links or to form elements and the WikiStyle will use whichever it finds first on the line. In this case they will attach to the link [@[[{*$FullName} | $[View] ]]@].%0a%0a!! Accesskey%0aAn accesskey can be defined in a number of locations, but essentially it is a phrase translation following the model used for internationalizations. PmWiki's accesskey defaults are defined in @@scripts/prefs.php@@, but can be overridden in lots of different places, including skins, language translation pages (XLPage), and even per-browser preferences (see [[Site.Preferences]]).%0a%0aThe [@$[...]@] markup defines phrase translations, used for internationalizations (and access keys, as noted above). In the first line of [[Site.PageActions]] it is used in both [@$[ak_view]@] and [@$[View]@]. Essentially [@$[View]@] tells PmWiki to substitute the current translation of "View". If no translation is defined for "View", then PmWiki just uses the phrase inside the brackets.%0a%0aYou can most easily see this working in the other languages sections of PmWiki. For example, at [[(http://pmwiki.org/wiki/)PmWikiDe/PmWikiDe]] you'll notice that the default "View", "Edit", "History", and "Print" actions are displayed as "Artikel", "Bearbeiten", "Historie", and "Druckansicht".%0aThis is because the PmWikiDe group is loading in a set of translations from [[(http://pmwiki.org/wiki/)PmWikiDe.XLPage]] %0a%0aThat page defines things like%0a%0a->[@'View' => 'Artikel'%0a'Edit' => 'Bearbeiten'%0a'History' => 'Historie'%0a'Print' => 'Druckansicht'@]%0a%0awhich says that things like [@$[View]@] and [@$[Edit]@] should be replaced by "Artikel" and "Bearbeiten".%0a%0aThis makes it very easy for PmWiki to support multiple languages, since a recipe author can simply put any translatable prompts or phrases inside of [@$[...]@], and leave it to others to actually build the translation tables (either locally or on [[(http://)pmwiki.org]] for others to use). More information about [@$[...]@] is available at [[PmWiki/Internationalizations]].%0a%0a!! Link%0aAll that leaves on the first line to be explained is the [[PmWiki.Links|link]] itself: [@[[{*$FullName} | $[View] ]]@]. Links are not complex, but this one is using both the internationalization feature and a [[PageVariables|Page Variable]]. The [@$[View]@] has already been explained and it shows up in the link text section of link markup, so that, if viewed in English, the link will appear as [[[[{*$FullName} |$[View]]].%0a%0aThe link target section contains the [@{*$FullName}@] variable. This variable expands to the full name of the page on which it is being displayed, including the group and page names. For simple browsing, this is good enough, because viewing a page is the default action to perform on a page. Later lines use link targets like [@{*$FullName}?action=edit@] which says to go to the currently displayed page and start editing it.%0a%0a!! If%0aThis explains what all of the '[@*@]' lines are about. That only leaves the [@(:if auth upload:)@] and [@(:ifend:)@] lines, and they go together. The first starts some [[Conditional Markup]] and the second ends it. The [@(:if test :)@] markup only lets the following text be displayed if the test succeeds. The text that conditionally displayed ends at the next [@(:if...:)@] statement so an empty [@(:ifend:)@] is a convenient way to end the conditional block. The particular test being used here is [@auth upload@] which is only true if the current user is authorized to upload files to the wiki. Thus, the conditional block says to only display a link to perform an upload if the user is actually allowed to upload.%0a%0aDepending on the security and permissions model on a given site, its not unusual to see many more conditional markups that test if, for example, a user has editing rights to the current page. More information on all the different conditions can be found at the [[Conditional Markup]] page, and a general index of all the PmWiki documentation can be found at [[Documentation Index]].%0a%0aHopefully this bit of documentation has answered your questions about the [[Site.PageActions]] page. %0aIf not, you may wish to consult the helpful people on one of the [[MailingLists|PmWiki Mailing Lists]].%0a%0a!! Hiding actions%0aIn a wiki page, [@(:noaction:)@], see the [[PmWiki/PageDirectives#noaction | noaction]] page directive%0a%0aIn a @@local/Group.Page.php@@ place%0a->[@SetTmplDisplay('PageActionFmt',0);@]%0a%0a!! Group PageActions%0aNote that any Group can have a PageActions page, not just '''Site'''. If a page named [@Group.PageActions@] exists, it will be used, otherwise, [@Site.PageActions@], much like for the SideBar pages.%0a -time=1559731018 +text=(:Summary: how site page actions work:)%0a%25audience%25 authors (basic)%0a%0aThe [[Site.PageActions]] page is used as the source of the [[https://www.pmwiki.org/wiki/PmWiki/AvailableActions#defaultactions|default wiki commands]] shown in the default PmWiki skin at the top right of the page. It displays as follows:%0a[[%3c%3c]]%0a(:div id="wikicmds" class="float":)%0a(:include Site.PageActions:)%0a(:divend:)%0a[[%3c%3c]]%0aNote that there are many other [[available actions]] from the [[Cookbook:Cookbook|Cookbook]], and PmWiki diagnostics and scripts.%0a%0aThis page gives a brief explanation of how [[Site.PageActions]] are displayed and formatted, and pointers to where more information can be found.%0a%0aBelow is what is shipped as [[Site.PageActions]] with PmWiki version 2.2:%0a->[@%0a* %25item rel=nofollow class=browse accesskey='$[ak_view]'%25 [[{*$FullName} | $[View] ]]%0a* %25item rel=nofollow class=edit accesskey='$[ak_edit]'%25 [[{*$FullName}?action=edit | $[Edit] ]]%0a* %25item rel=nofollow class=diff accesskey='$[ak_history]'%25 [[{*$FullName}?action=diff | $[History] ]]%0a(:if auth upload:)%0a* %25item rel=nofollow class=upload accesskey='$[ak_attach]'%25 [[{*$FullName}?action=upload | $[Attach] ]]%0a(:ifend:)%0a* %25item rel=nofollow class=print accesskey='$[ak_print]'%25 [[{*$FullName}?action=print | $[Print] ]]%0a(:if group Site,SiteAdmin,Cookbook,Profiles,PmWiki*:) (:comment delete if and ifend to enable backlinks:)%0a* %25item rel=nofollow class=backlinks accesskey='$[ak_backlinks]'%25 [[{*$Name}?action=search&q=link={*$FullName} | $[Backlinks] ]]%0a(:ifend:)%0a(:if enabled AuthPw:)%0a* %25item rel=nofollow class=logout accesskey="$[ak_logout]"%25'' [-[[{*$FullName}?action=logout | $[Logout] ]]-]''%0a(:ifend:)%0a@]%0a%0aTo start with, we'll look at just the first line, and take it apart. This will also give us a good handle on how most of the other lines work.%0a%0a!! List%0aEach line is an item in an unordered [[https://www.pmwiki.org/wiki/PmWiki/MarkupMasterIndex#Lists|list]], marked up by an unindented '@@*@@'. %0aYou can find out more about lists on the [[Basic Editing]] page.%0a%0aPmWiki will normally display an unordered list as a set of bulleted items, but they can appear differently depending on the context and styles they are displayed in. This difference in display is generally controlled by CSS defined in the [[Skins|Skin]]: for the PageActions links, the list items are displayed inline.%0a%0a!! Style%0aFollowing the '[@*@]', on the line we have [@%25item ... %25@] which is a [[WikiStyles|WikiStyle]]. It is used to control the properties of a given output element, like its size or color. By default they apply to the text between them and the end of the line or a closing [@%25%25@], whichever is sooner. So, for example, one can enter [@"this %25blue%25text%25%25 is blue"@] and it will appear as "this %25blue%25text%25%25 is blue".%0a%0aIn this case the WikiStyle starts with the word [@item@], and that says to apply the given style to the entire list item as opposed to just the text that follows. In particular, it causes PmWiki to generate HTML of%0a%0a->[@%3cli class='edit'>...%3c/li>@]%0a%0ainstead of%0a%0a->[@%3cli>%3cspan class='edit'>...%3c/span>%3c/li>@]%0a%0aSetting the class attribute of the list item allows CSS properties to be applied to the item that corresponds to the current action. For example, to have the current action display with a background color of blue, a wiki administrator can do:%0a%0a->@@$HTMLStylesFmt[]@@[@ = ' .{$Action} { background-color: blue; }';@]%0a%0aThen if the current action is 'edit' (as in "?action=edit"), the list item corresponding to the edit action will be drawn with a blue background.%0a%0aThe other property inside the [@%25item ... %25@] WikiStyle is the accesskey='$[ak_view]' statement. [[AccessKeys]] are keyboard shortcuts for tasks that would otherwise require a mouse. They can be attached to links or to form elements and the WikiStyle will use whichever it finds first on the line. In this case they will attach to the link [@[[{*$FullName} | $[View] ]]@].%0a%0a!! Accesskey%0aAn accesskey can be defined in a number of locations, but essentially it is a phrase translation following the model used for internationalizations. PmWiki's accesskey defaults are defined in @@scripts/prefs.php@@, but can be overridden in lots of different places, including skins, language translation pages (XLPage), and even per-browser preferences (see [[Site.Preferences]]).%0a%0aThe [@$[...]@] markup defines phrase translations, used for internationalizations (and access keys, as noted above). In the first line of [[Site.PageActions]] it is used in both [@$[ak_view]@] and [@$[View]@]. Essentially [@$[View]@] tells PmWiki to substitute the current translation of "View". If no translation is defined for "View", then PmWiki just uses the phrase inside the brackets.%0a%0aYou can most easily see this working in the other languages sections of PmWiki. For example, at [[(https://pmwiki.org/wiki/)PmWikiDe/PmWikiDe]] you'll notice that the default "View", "Edit", "History", and "Print" actions are displayed as "Artikel", "Bearbeiten", "Historie", and "Druckansicht".%0aThis is because the PmWikiDe group is loading in a set of translations from [[(https://pmwiki.org/wiki/)PmWikiDe.XLPage]] %0a%0aThat page defines things like%0a%0a->[@'View' => 'Artikel'%0a'Edit' => 'Bearbeiten'%0a'History' => 'Historie'%0a'Print' => 'Druckansicht'@]%0a%0awhich says that things like [@$[View]@] and [@$[Edit]@] should be replaced by "Artikel" and "Bearbeiten".%0a%0aThis makes it very easy for PmWiki to support multiple languages, since a recipe author can simply put any translatable prompts or phrases inside of [@$[...]@], and leave it to others to actually build the translation tables (either locally or on [[(https://)pmwiki.org]] for others to use). More information about [@$[...]@] is available at [[PmWiki/Internationalizations]].%0a%0a!! Link%0aAll that leaves on the first line to be explained is the [[PmWiki.Links|link]] itself: [@[[{*$FullName} | $[View] ]]@]. Links are not complex, but this one is using both the internationalization feature and a [[PageVariables|Page Variable]]. The [@$[View]@] has already been explained and it shows up in the link text section of link markup, so that, if viewed in English, the link will appear as [[[[{*$FullName} |$[View]]].%0a%0aThe link target section contains the [@{*$FullName}@] variable. This variable expands to the full name of the page on which it is being displayed, including the group and page names. For simple browsing, this is good enough, because viewing a page is the default action to perform on a page. Later lines use link targets like [@{*$FullName}?action=edit@] which says to go to the currently displayed page and start editing it.%0a%0a!! If%0aThis explains what all of the '[@*@]' lines are about. That only leaves the [@(:if auth upload:)@] and [@(:ifend:)@] lines, and they go together. The first starts some [[Conditional Markup]] and the second ends it. The [@(:if test :)@] markup only lets the following text be displayed if the test succeeds. The text that conditionally displayed ends at the next [@(:if...:)@] statement so an empty [@(:ifend:)@] is a convenient way to end the conditional block. The particular test being used here is [@auth upload@] which is only true if the current user is authorized to upload files to the wiki. Thus, the conditional block says to only display a link to perform an upload if the user is actually allowed to upload.%0a%0aDepending on the security and permissions model on a given site, its not unusual to see many more conditional markups that test if, for example, a user has editing rights to the current page. More information on all the different conditions can be found at the [[Conditional Markup]] page, and a general index of all the PmWiki documentation can be found at [[Documentation Index]].%0a%0aHopefully this bit of documentation has answered your questions about the [[Site.PageActions]] page. %0aIf not, you may wish to consult the helpful people on one of the [[MailingLists|PmWiki Mailing Lists]].%0a%0a!! Hiding actions%0aIn a wiki page, [@(:noaction:)@], see the [[PmWiki/PageDirectives#noaction | noaction]] page directive%0a%0aIn a @@local/Group.Page.php@@ place%0a->[@SetTmplDisplay('PageActionFmt',0);@]%0a%0a!! Group PageActions%0aNote that any Group can have a PageActions page, not just '''Site'''. If a page named [@Group.PageActions@] exists, it will be used, otherwise, [@Site.PageActions@], much like for the SideBar pages.%0a +time=1641088811 blob - 8277040018bdf50519d81531c9c461b4ab9e8af4 blob + 86ea7e26dba85d5329cd05911d187363f5e99cd9 --- wikilib.d/PmWiki.SitePreferences +++ wikilib.d/PmWiki.SitePreferences @@ -1,10 +1,9 @@ -version=pmwiki-2.2.30 ordered=1 urlencoded=1 -agent=Mozilla/5.0 (X11; Linux x86_64; rv:5.0) Gecko/20100101 Firefox/5.0 -author=OliverBetz +version=pmwiki-2.3.7 ordered=1 urlencoded=1 +author=simon charset=UTF-8 -csum= +csum=hlt php (+27) name=PmWiki.SitePreferences -rev=12 +rev=13 targets=Site.Preferences,PmWiki.AccessKeys,Site.EditForm -text=(:Summary: Customisable browser setting preferences: Access keys, edit form:)%0aThe page [[{$SiteGroup}.Preferences]] contains customisable browser preference settings.%0aThese include [[access keys]] (keyboard shortcuts to certain actions like edit, history, browse) and settings of the [[{$SiteGroup}.EditForm]] (width and height of the edit textarea) as well as the name of the edit form in use.%0a%0aA different page than [[{$SiteGroup}.Preferences]] can be chosen by making a copy of that page under a new name, customising it, and setting a cookie which will point to this page for the browser being used, through %0a%0a ?setprefs=`SomeGroup.`CustomPreferences %0a%0a`SomeGroup.`CustomPreferences being the name of the new customised preference page.%0a%0a!!Notes and Comments%0a%0aNote that in order to enable parsing of [[{$SiteGroup}.Preferences]] by default, a line like the following needs to be added to local/config.php:%0a%0a XLPage('prefs', "Site.Preferences");%0a -time=1315670897 +text=(:Summary: Customisable browser setting preferences: Access keys, edit form:)%0aThe page [[{$SiteGroup}.Preferences]] contains customisable browser preference settings.%0aThese include [[access keys]] (keyboard shortcuts to certain actions like edit, history, browse) and settings of the [[{$SiteGroup}.EditForm]] (width and height of the edit textarea) as well as the name of the edit form in use.%0a%0aA different page than [[{$SiteGroup}.Preferences]] can be chosen by making a copy of that page under a new name, customising it, and setting a cookie which will point to this page for the browser being used, through %0a%0a @@?setprefs=`SomeGroup.`CustomPreferences@@ %0a%0a@@`SomeGroup.`CustomPreferences@@ being the name of the new customised preference page.%0a%0a!!Notes and Comments%0a%0aNote that in order to enable parsing of [[{$SiteGroup}.Preferences]] by default, a line like the following needs to be added to @@local/config.php@@:%0a%0a-> %25hlt php%25@@XLPage('prefs', "Site.Preferences");@@%0a +time=1656810326 blob - 0653efc8fa9c6343f267a49ac7d165b850900fdb blob + 3ff2081beff484cbef9d79323288eadae16cef48 --- wikilib.d/PmWiki.SkinTemplates +++ wikilib.d/PmWiki.SkinTemplates @@ -1,9 +1,9 @@ -version=pmwiki-2.2.118 ordered=1 urlencoded=1 -author=Petko +version=pmwiki-2.3.9 ordered=1 urlencoded=1 +author=simon charset=UTF-8 -csum=add !! FAQ heading when there are questions and answers +csum=more hlt html, pm hlt, hlt php (+249) name=PmWiki.SkinTemplates -rev=72 -targets=PmWiki.Skins,PmWiki.BasicVariables,PmWiki.PathVariables,PmWiki.LayoutVariables,PmWiki.PageVariables,PmWiki.PageDirectives,Skins.TestPageDirectives,PmWiki.Internationalizations,Cookbook.HideSearchBar -text=(:Summary:[[PmWiki/Skin(s)]] templates (.tmpl files):)%0a%25define=box block bgcolor=#f9f9fc border='1px solid #666666' margin=10px padding=5px%25%0aThis page describes the skin template files (.tmpl) that are used to create PmWiki ''skins'', and how PmWiki uses them. As described in the [[skins]] page, a skin is a collection of files that specifies the layout for PmWiki pages. Each skin must include a template file that provides the skeleton for displaying a PmWiki page.%0a%0a!! [[#findingprocessing]]Finding and Processing Templates%0a%0aWhen you set the value of the $Skin variable in a configuration file like @@local/config.php@@, like this%0a-> [@%0a## Use the Foo Skin.%0a$Skin = 'foo';%0a@]%0a%0ait tells PmWiki to search for a skin of that name, and use it. The usual result of the search is for PmWiki to load a template file from the appropriate skin directory. In this example, that would probably be the file @@pub/skins/foo/foo.tmpl@@.%0a%0aThe actual processing that PmWiki goes through to find a template file is important for those who are making complex skins, so its worth mentioning what those steps are:%0a%0a>>rframe width=25pct margin-left:2em font-size:smaller%3c%3c%0a!! [[#security]]Security Note%0aThe default value for @@[=$=]SkinLibDirs@@ has server-side and client-side files stored in the same publicly-accessible directory. That is, @@$SkinDir@@ and @@$SkinDirUrl@@ point to the same place. This is done for convenience (both for the skin user, and the skin writer), but it is not necessary.%0a%0aIt has the side effect that its possible to construct a URL ([[http://www.pmwiki.org/pmwiki/pub/skins/pmwiki/pmwiki.tmpl|like this one]]) that will let you look at the contents of the the @@.tmpl@@ or @@.php@@ files that a skin uses. This is usually not an issue as skin files should not contain any sensitive information.%0a%0aStill, a purist might want to move their @@.tmpl@@ and @@.php@@ files out of the directories that are accessible as URLs, and modify their @@[=$=]SkinLibDirs@@ array to reflect this.%0a>>%3c%3c%0a%0a#When @@$PageTemplateFmt@@ is blank (as it should be), PmWiki gathers the names of all candidate skins. It starts with any action-specific skin that is specified in @@[[LayoutVariables#ActionSkin|$ActionSkin]][$action]@@. Thus, if the current action is 'login', and @@$ActionSkin['login']@@ is @@'Bar'@@, then PmWiki will look for a skin named 'Bar'. %0a%0a#If no skin has been found yet, it looks for the skin(s) named in the @@$Skin@@ variable (which is allowed to be an array) and uses the first skin it can find. If it gets to the end of the list without finding a skin, it issues an error.%0a%0a#To attempt to find a skin, PmWiki first consults the @@[[LayoutVariables#SkinLibDirs|[=$=]SkinLibDirs]]@@ variable to know where to look. Skins consist of server-side files that are loaded by PmWiki (such as .php and .tmpl files) and client-side files (such as .css files and images) that will be requested by the user's browser when they look at a skinned PmWiki page. @@$SkinLibDirs@@ is an array of key/value pairs. The key is a directory to look in for the server-side files, while the corresponding value is a URL that points to the public client-side resources used by the skin. The default value of @@[=$=]SkinLibDirs@@ is:%0a -> [@%0a$SkinLibDirs = array(%0a "./pub/skins/\$Skin" => "$PubDirUrl/skins/\$Skin",%0a "$FarmD/pub/skins/\$Skin" => "$FarmPubDirUrl/skins/\$Skin");%0a@]%0a%0a So, using the above definitions, PmWiki would try to find the skin 'foo' by looking for a directory called @@./pub/skins/foo@@ and then for @@$FarmD/pub/skins/foo@@ (with the value of @@$FarmD@@ replaced by the root server directory for Farm files). The first such directory that was found would be assumed to contain the skin it was looking for. It would then set @@$SkinDir@@ to the name of this directory and @@$SkinDirUrl@@ to the corresponding URL.%0a%0a#Once a valid skin directory has been found, PmWiki starts processing the files in that directory, looking for a @@.php@@ skin file to run. It first looks for one with the same name as the skin. So, if the skin is 'foo', it looks for @@foo.php@@. If no such file is found, it then checks for a file named @@skin.php@@. If one of these @@.php@@ files is found, PmWiki loads and runs it. This allows a skin to define custom markup, or custom configuration parameters. It also allows a skin to choose between which of several different @@.tmpl@@ files to load.%0a%0a To specify which @@.tmpl@@ file to load, simply call @@LoadPageTemplate()@@ inside the skin @@.php@@ file, with the name of the @@.tmpl@@ file to be loaded:%0a%0a -> @@LoadPageTemplate($pagename, "$SkinDir/xyz.tmpl");@@%0a%0a For example, a skin might specify a special template to be used if the action is 'print':%0a%0a -> [@%0aif ($GLOBALS['action'] == 'print')%0a LoadPageTemplate($pagename, "$SkinDir/print.tmpl");%0a@]%0a%0a When the action is something else, PmWiki will fall back to loading the default @@.tmpl@@ file instead.%0a%0a#If no appropriate @@.php@@ file is found, or if that file doesn't load a template, then PmWiki falls back to looking for a template with the same name as the skin, or, failing that, any @@.tmpl@@ file at all, so long as its the only one in the directory. If it finds one, it will load and process it. If not, it will issue an error.%0a%0a!![[#fileformat]]Template file format%0a%0aA template file is basically an HTML file that also contains variable substitutions (indicated by '$') and special directives embedded in HTML comments. The following special directives are ''required'' in the template file. %0a# The directive [@%3c!--PageText-->@] belongs to the %3cbody> section of the HTML document, and tells PmWiki where the main content of each wiki page should be placed. %0a# The directive [@%3c!--HTMLHeader-->@], which goes somewhere in the %3chead> section of the HTML document.%0a# The directive [@%3c!--HTMLFooter-->@] directive, which typically goes before the final %3c/body> tag and is used by some recipes to insert things at the end of the HTML document. [- %25green%25''Prior to PmWiki 2.2.0 the [@%3c!--HTMLFooter-->@] directive was optional.'' -]%0a%0aWhen PmWiki displays a page, it replaces the directives and variable substitutions with the values appropriate to the current page. For example, the [@%3c!--PageText-->@] directive is replaced with the page's contents, while any instances of $PageUrl are replaced with the url (address) of the current page.%0a%0a%25note%25 Note: your skin template shouldn't have a %3cmeta/> tag specifying the charset (encoding), as PmWiki adds this tag when needed.%0a%0aThere is a long list of variables available for substitution in pages; some of the%0amost useful include:%0a-> [@%0a$PageUrl the url of the current page%0a$ScriptUrl the base url to the pmwiki.php script%0a$Title the page's title (e.g., "`SkinTemplates")%0a$Titlespaced the page's title with spaces (e.g., "Skin Templates")%0a$Group the name of the current group (e.g., "`PmWiki")%0a$FullName the page's full name (e.g., "`PmWiki.SkinTemplates")%0a$LastModified the page's last modification time%0a$PageLogoUrl the url of a site logo%0a$WikiTitle the site's title%0a$SkinDirUrl the url of the skin's folder%0a@]%0a%0aThis last variable, $SkinDirUrl, is particularly useful in templates as it allows the skin designer to refer to other files (such as images or style sheets) in the skin folder without having to know the exact url.%0a%0aThe template is not limited to using the variables listed here; nearly any PHP global variable that begins with a capital letter can be used in a skin template. [[Page variables]] can also be used in templates.%0a%0a!![[#directives]] Skin directives%0a%0aBesides the required [@%3c!--PageText-->@] and [@%3c!--HTMLHeader-->@] directives, PmWiki provides other built-in directives for generating page output. It's not necessary to use any of these directives, but they can often add capabilities to a skin %0a%0a:[@%3c!--wiki:Main.SomePage-->@]:%0a:[@%3c!--page:Main.SomePage-->@]:%0a: :The [@%3c!--wiki:Main.SomePage-->@] directive outputs the contents of `Main.SomePage. $-substitutions are allowed in directives, thus a directive like [@%3c!--wiki:$Group.SomePage-->@] will include "`SomePage" of the current group. %0a%0a: :If multiple pages are listed in the directive, then only the first available page is used. Thus [@%3c!--wiki:$Group.SomePage Site.SomePage-->@] will display the contents of `SomePage in the current group if it exists, and `Site.SomePage if it doesn't. To always display `Site.SomePage, even if $`Group.SomePage exists, use two consecutive [@%3c!--wiki:...-->@] directives.%0a%0a: :The [@%3c!--wiki:...-->@] directive only displays pages for which the browser has read permissions. The [@%3c!--page:...-->@] directive displays pages even if the browser doesn't have read permission.%0a%0a%0a:[@%3c!--file:somefile.txt-->@]:%0a: :The directive [@%3c!--file:somefile.txt-->@] outputs the contents of another file (on the local filesystem) at the point of the directive. If the file to be included is a .php script, then the PHP script is executed and its output is sent to the browser. Like the [@%3c!--wiki:...-->@] directive above, $-substitutions are available to be able to output files based on the current page name or group.%0a%0a:[@%3c!--markup:...-->@]:%0a: :The markup directive processes any text that follows the colon as wiki markup and displays that in the output. %0a%0a:[@%3c!--function:SomeFunction args-->@]:%0a: :This directive calls a PHP function named "`SomeFunction", passing the ''current page's name'' as first argument, and the optional ''text following the function name'' as second argument. PHP functions called in this manner are typically defined in a local customization file. Args allows only one argument, which has to be split in your function. [@%3c!--function:SomeFunction arg1 arg2 arg3-->@] will call [@SomeFunction($pagename, "arg1 arg2 arg3")@] when the skin is processed. However variables can be used (like $LastModifiedBy).%0a%0a:[@%3c!--IncludeTemplate: header.tmpl-->@]:%0a:[@%3c!--IncludeTemplate: {$Group}.tmpl default.tmpl-->@]:%0a: : This directive allows the inclusion of another template file. The arguments are file names in the skin's directory, and the first one found will be included in the main template. This feature is available from PmWiki 2.2.114 but disabled by default; it needs to be enabled in your skin file pub/skins/myskin/myskin.php with the line @@SDV($GLOBALS['SkinTemplateIncludeLevel'], 1);@@ where 1 is the number of allowed levels of inclusion, ie if an included template also can contain the IncludeTemplate directive, set this number to 2, up to a maximum of 10.%0a%0a!![[#sections]] Page sections%0a%0aA template file can designate "sections" that are included or excluded from the output based on [[page directives]] or other criteria. A section always begins with [@%3c!--Page...Fmt-->@] and continues to the next section, the end of the template file, or [@%3c!--/Page...Fmt-->@]. For example, a template can specify a [@%3c!--PageLeftFmt-->@] section that is excluded from the output whenever the [@(:noleft:)@] directive is encountered in the page's contents. PmWiki's predefined sections (and their corresponding page directives) are:%0a-> [@%0a%3c!--PageHeaderFmt--> (:noheader:)%0a%3c!--PageFooterFmt--> (:nofooter:)%0a%3c!--PageTitleFmt--> (:notitle:)%0a%3c!--PageLeftFmt--> (:noleft:)%0a%3c!--PageRightFmt--> (:noright:)%0a%3c!--PageActionFmt--> (:noaction:)%0a@]%0a%0aSkin designers can define custom sections and markups, but currently all section names in the template must begin with "Page" and end with "Fmt". As mentioned you also have to define the corresponding markup (for example in your config.php) like this: %0a%0a->[@Markup('noxyz', 'directives', '/\\(:noxyz:\\)/ei',%0a "SetTmplDisplay('PageXYZFmt',0)");@] %0a%0aAnd, better, compatible with PHP version 5.5, for PmWiki 2.2.58+ :%0a%0a->[@Markup('noxyz', 'directives', '/\\(:noxyz:\\)/i',%0a "HideXYZ");%0afunction HideXYZ() {%0a SetTmplDisplay('PageXYZFmt',0);%0a}%0a@] %0a%0aSee also: the recipe Skins:TestPageDirectives can help you test your skins with combinations of the above directives.%0a%0a!![[#i18n]] Internationalization (i18n)[[#Internationalization]]%0a%0aSkins can also be [[internationaliz(ations)]]ed by using [@$[...]@] substitutions. Any string placed inside of [@$[...]@] is treated as a "translatable phrase", and the phrase is looked up in the current translation tables for a corresponding output phrase. If a translation is available, then the translated phrase is substituted at that point, otherwise the original phrase is left intact.%0a%0aFor example, the substitution [@$[Edit]@] will display the current translation of "Edit" if it is known, otherwise it displays "Edit". Thus, the same template can be used for multiple languages, displaying "Editer" when French translations are loaded, "Bearbeiten" when German translations are loaded, and "Edit" when no translation is available.%0a%0a!! FAQ%0a>>faq%3c%3c [[#faq]]%0a%0aQ: How do I customize the CSS styling of my PmWiki layout?[[#customcss]]%0a%0aA: See [[Skins]] for how to change the default PmWiki skin. See also [[http://www.pmwiki.org/wiki/Skins/Skins|Skins]], where you will find pre-made templates you can use to customize the appearance of your site. You can also create a file called ''local.css'' in the ''pub/css/'' directory and add CSS selectors there (this file gets automatically loaded if it exists). Or, styles can be added directly into a local customization file by using something like:%0a%0a-> [@$HTMLStylesFmt[] = '.foo { color:blue; }';@]%0a%0a%0aQ: Where can the mentioned "translation table" be found for adding translated phrases?%0aA: See [[Internationalizations]].%0a%0aQ: Is it possible to have the edit form in full page width, with no sidebar?%0aA: If the sidebar is marked with [@%3c!--PageLeftFmt-->@], adding [@(:noleft:)@] to Site.EditForm will hide it when a page is edited.%0a%0aQ: Can I easily hide the Home Page title from the homepage?%0aA: Yes, you can use in the wiki page either @@[=(:title Some other title:)=]@@ to change it or @@[=(:notitle:)=]@@ to hide it.%0a%0aQ: Is it possible to hide the Search-Bar in the default PmWiki Skin?%0aA: Yes, please see [[Cookbook:HideSearchBar]].%0a -time=1567167632 +rev=75 +targets=PmWiki.Skins,PmWiki.BasicVariables,PmWiki.PathVariables,PmWiki.LayoutVariables,PmWiki.PageVariables,PmWiki.PageDirectives,Skins.TestPageDirectives,PmWiki.Internationalizations,Skins.Skins,Cookbook.HideSearchBar +text=(:Summary:[[PmWiki/Skin(s)]] templates (.tmpl files):)%0a%25define=box block bgcolor=#f9f9fc border='1px solid #666666' margin=10px padding=5px%25%0aThis page describes the skin template files (.tmpl) that are used to create PmWiki ''skins'', and how PmWiki uses them. As described in the [[skins]] page, a skin is a collection of files that specifies the layout for PmWiki pages. Each skin must include a template file that provides the skeleton for displaying a PmWiki page.%0a%0a!! [[#findingprocessing]]Finding and Processing Templates%0a%0aWhen you set the value of the $Skin variable in a configuration file like @@local/config.php@@, like this%0a-> %25hlt php%25[@%0a## Use the Foo Skin.%0a$Skin = 'foo';%0a@]%0a%0ait tells PmWiki to search for a skin of that name and use it. The usual result of the search is for PmWiki to load a template file from the appropriate skin directory. In this example, that would probably be the file @@pub/skins/foo/foo.tmpl@@.%0a%0aThe actual processing that PmWiki goes through to find a template file is important for those who are making complex skins, so its worth mentioning what those steps are:%0a%0a>>rframe width=25pct margin-left:2em font-size:smaller%3c%3c%0a!! [[#security]]Security Note%0aThe default value for @@[=$=]SkinLibDirs@@ has server-side and client-side files stored in the same publicly-accessible directory. That is, @@$SkinDir@@ and @@$SkinDirUrl@@ point to the same place. This is done for convenience (both for the skin user, and the skin writer), but it is not necessary.%0a%0aIt has the side effect that its possible to construct a URL ([[https://www.pmwiki.org/pmwiki/pub/skins/pmwiki/pmwiki.tmpl|like this one]]) that will let you look at the contents of the the @@.tmpl@@ or @@.php@@ files that a skin uses. This is usually not an issue as skin files should not contain any sensitive information.%0a%0aStill, a purist might want to move their @@.tmpl@@ and @@.php@@ files out of the directories that are accessible as URLs, and modify their @@[=$=]SkinLibDirs@@ array to reflect this.%0a>>%3c%3c%0a%0a#When @@$PageTemplateFmt@@ is blank (as it should be), PmWiki gathers the names of all candidate skins. It starts with any action-specific skin that is specified in @@[[LayoutVariables#ActionSkin|$ActionSkin]][$action]@@. Thus, if the current action is 'login', and @@$ActionSkin['login']@@ is @@'Bar'@@, then PmWiki will look for a skin named 'Bar'. %0a%0a#If no skin has been found yet, it looks for the skin(s) named in the @@$Skin@@ variable (which is allowed to be an array) and uses the first skin it can find. If it gets to the end of the list without finding a skin, it issues an error.%0a%0a#To attempt to find a skin, PmWiki first consults the @@[[LayoutVariables#SkinLibDirs|[=$=]SkinLibDirs]]@@ variable to know where to look. Skins consist of server-side files that are loaded by PmWiki (such as .php and .tmpl files) and client-side files (such as .css files and images) that will be requested by the user's browser when they look at a skinned PmWiki page. @@$SkinLibDirs@@ is an array of key/value pairs. The key is a directory to look in for the server-side files, while the corresponding value is a URL that points to the public client-side resources used by the skin. The default value of @@[=$=]SkinLibDirs@@ is:%0a -> %25hlt php%25[@%0a$SkinLibDirs = array(%0a "./pub/skins/\$Skin" => "$PubDirUrl/skins/\$Skin",%0a "$FarmD/pub/skins/\$Skin" => "$FarmPubDirUrl/skins/\$Skin");%0a@]%0a%0aSo, using the above definitions, PmWiki would try to find the skin '@@foo@@' by looking for a directory called @@./pub/skins/foo@@ and then for @@$FarmD/pub/skins/foo@@ (with the value of @@$FarmD@@ replaced by the root server directory for Farm files). The first such directory that was found would be assumed to contain the skin it was looking for. It would then set @@$SkinDir@@ to the name of this directory and @@$SkinDirUrl@@ to the corresponding URL.%0a%0a#Once a valid skin directory has been found, PmWiki starts processing the files in that directory, looking for a @@.php@@ skin file to run. It first looks for one with the same name as the skin. So, if the skin is 'foo', it looks for @@foo.php@@. If no such file is found, it then checks for a file named @@skin.php@@. If one of these @@.php@@ files is found, PmWiki loads and runs it. This allows a skin to define custom markup, or custom configuration parameters. It also allows a skin to choose between which of several different @@.tmpl@@ files to load.%0a%0a To specify which @@.tmpl@@ file to load, simply call %25hlt php%25@@LoadPageTemplate()@@ inside the skin @@.php@@ file, with the name of the @@.tmpl@@ file to be loaded:%0a%0a -> %25hlt php%25@@LoadPageTemplate($pagename, "$SkinDir/xyz.tmpl");@@%0a%0a For example, a skin might specify a special template to be used if the action is 'print':%0a%0a -> %25hlt php%25[@%0aif ($GLOBALS['action'] == 'print')%0a LoadPageTemplate($pagename, "$SkinDir/print.tmpl");%0a@]%0a%0a When the action is something else, PmWiki will fall back to loading the default @@.tmpl@@ file instead.%0a%0a#If no appropriate @@.php@@ file is found, or if that file doesn't load a template, then PmWiki falls back to looking for a template with the same name as the skin, or, failing that, any @@.tmpl@@ file at all, so long as its the only one in the directory. If it finds one, it will load and process it. If not, it will issue an error.%0a%0a!![[#fileformat]]Template file format%0a%0aA template file is basically an HTML file that also contains variable substitutions (indicated by '$') and special directives embedded in HTML comments. The following special directives are ''required'' in the template file. %0a# The directive %25hlt html%25[@%3c!--PageText-->@] belongs to the %3cbody> section of the HTML document, and tells PmWiki where the main content of each wiki page should be placed. %0a# The directive %25hlt html%25[@%3c!--HTMLHeader-->@], which goes somewhere in the %3chead> section of the HTML document.%0a# The directive %25hlt html%25[@%3c!--HTMLFooter-->@] directive, which typically goes before the final %3c/body> tag and is used by some recipes to insert things at the end of the HTML document. [- %25green%25''Prior to PmWiki 2.2.0 the [@%3c!--HTMLFooter-->@] directive was optional.'' -]%0a%0aWhen PmWiki displays a page, it replaces the directives and variable substitutions with the values appropriate to the current page. For example, the %25hlt html%25[@%3c!--PageText-->@] directive is replaced with the page's contents, while any instances of $PageUrl are replaced with the url (address) of the current page.%0a%0a%25note%25 Note: your skin template shouldn't have a @@%3cmeta/>@@ tag specifying the charset (encoding), as PmWiki adds this tag when needed.%0a%0aThere is a long list of variables available for substitution in pages; some of the%0amost useful include:%0a-> [@%0a$PageUrl the url of the current page%0a$ScriptUrl the base url to the pmwiki.php script%0a$Title the page's title (e.g., "`SkinTemplates")%0a$Titlespaced the page's title with spaces (e.g., "Skin Templates")%0a$Group the name of the current group (e.g., "`PmWiki")%0a$FullName the page's full name (e.g., "`PmWiki.SkinTemplates")%0a$LastModified the page's last modification time%0a$PageLogoUrl the url of a site logo%0a$WikiTitle the site's title%0a$SkinDirUrl the url of the skin's folder%0a@]%0a%0aThis last variable, $SkinDirUrl, is particularly useful in templates as it allows the skin designer to refer to other files (such as images or style sheets) in the skin folder without having to know the exact url.%0a%0aThe template is not limited to using the variables listed here; nearly any PHP global variable that begins with a capital letter can be used in a skin template. [[Page variables]] can also be used in templates.%0a%0a!![[#directives]] Skin directives%0a%0aBesides the required %25hlt html%25[@%3c!--PageText-->@] and [@%3c!--HTMLHeader-->@] directives, PmWiki provides other built-in directives for generating page output. It's not necessary to use any of these directives, but they can often add capabilities to a skin %0a%0a:%25hlt html%25[@%3c!--wiki:Main.SomePage-->@]:%0a:%25hlt html%25[@%3c!--page:Main.SomePage-->@]:%0a: :The %25hlt html%25[@%3c!--wiki:Main.SomePage-->@] directive outputs the contents of @@`Main.SomePage@@. $-substitutions are allowed in directives, thus a directive like [@%3c!--wiki:$Group.SomePage-->@] will include "@@`SomePage@@" of the current group. %0a%0a: :If multiple pages are listed in the directive, then only the first available page is used. Thus %25hlt html%25[@%3c!--wiki:$Group.SomePage Site.SomePage-->@] will display the contents of @@`SomePage@@ in the current group if it exists, and @@`Site.SomePage@@ if it doesn't. To always display @@`Site.SomePage@@, even if @@$`Group.SomePage@@ exists, use two consecutive [@%3c!--wiki:...-->@] directives.%0a%0a: :The %25hlt html%25[@%3c!--wiki:...-->@] directive only displays pages for which the browser has read permissions. The [@%3c!--page:...-->@] directive displays pages even if the browser doesn't have read permission.%0a%0a%0a:%25hlt html%25[@%3c!--file:somefile.txt-->@]:%0a: :The directive %25hlt html%25[@%3c!--file:somefile.txt-->@] outputs the contents of another file (on the local filesystem) at the point of the directive. If the file to be included is a .php script, then the PHP script is executed and its output is sent to the browser. Like the [@%3c!--wiki:...-->@] directive above, $-substitutions are available to be able to output files based on the current page name or group.%0a%0a:%25hlt html%25[@%3c!--markup:...-->@]:%0a: :The markup directive processes any text that follows the colon as wiki markup and displays that in the output. %0a%0a:%25hlt html%25[@%3c!--function:SomeFunction args-->@]:%0a: :This directive calls a PHP function named "@@`SomeFunction@@", passing the ''current page's name'' as first argument, and the optional ''text following the function name'' as second argument. PHP functions called in this manner are typically defined in a local customization file. Args allows only one argument, which has to be split in your function. [@%3c!--function:SomeFunction arg1 arg2 arg3-->@] will call %25hlt php%25[@SomeFunction($pagename, "arg1 arg2 arg3")@] when the skin is processed. However variables can be used (like $LastModifiedBy).%0a%0a:%25hlt html%25[@%3c!--IncludeTemplate: header.tmpl-->@]:%0a:%25hlt html%25[@%3c!--IncludeTemplate: {$Group}.tmpl default.tmpl-->@]:%0a: : This directive allows the inclusion of another template file. The arguments are file names in the skin's directory, and the first one found will be included in the main template. This feature is available from PmWiki 2.2.114 but disabled by default; it needs to be enabled in your skin file @@pub/skins/myskin/myskin.php@@ with the line %25hlt php%25@@SDV($GLOBALS['SkinTemplateIncludeLevel'], 1);@@ where 1 is the number of allowed levels of inclusion, i.e. if an included template also can contain the @@IncludeTemplate@@ directive, set this number to 2, up to a maximum of 10.%0a%0a!![[#sections]] Page sections%0a%0aA template file can designate "sections" that are included or excluded from the output based on [[page directives]] or other criteria. A section always begins with %25hlt html%25[@%3c!--Page...Fmt-->@] and continues to the next section, the end of the template file, or [@%3c!--/Page...Fmt-->@]. For example, a template can specify a [@%3c!--PageLeftFmt-->@] section that is excluded from the output whenever the %25pmhlt%25[@(:noleft:)@] directive is encountered in the page's contents. PmWiki's predefined sections (and their corresponding page directives) are:%0a>>pre%3c%3c%0a-> %25hlt html%25[@%3c!--PageHeaderFmt-->@]@@ @@%25pmhlt%25[@(:noheader:)@]%0a-> %25hlt html%25[@%3c!--PageFooterFmt-->@]@@ @@%25pmhlt%25[@(:nofooter:)@]%0a-> %25hlt html%25[@%3c!--PageTitleFmt-->@]@@ @@%25pmhlt%25[@(:notitle:)@]%0a-> %25hlt html%25[@%3c!--PageLeftFmt-->@]@@ @@%25pmhlt%25[@(:noleft:)@]%0a-> %25hlt html%25[@%3c!--PageRightFmt-->@]@@ @@%25pmhlt%25[@(:noright:)@]%0a-> %25hlt html%25[@%3c!--PageActionFmt-->@]@@ @@%25pmhlt%25[@(:noaction:)@]%0a>>%3c%3c%0a%0aSkin designers can define custom sections and markups, but currently all section names in the template must begin with "Page" and end with "Fmt". %0aAs mentioned you also have to define the corresponding markup (for example in your @@config.php@@) like this: %0a%0a->%25hlt php%25[@Markup('noxyz', 'directives', '/\\(:noxyz:\\)/i',%0a "HideXYZ");%0afunction HideXYZ() {%0a SetTmplDisplay('PageXYZFmt',0);%0a}%0a@] %0a%0aSee also: the recipe Skins:TestPageDirectives can help you test your skins with combinations of the above directives.%0a%0a!![[#i18n]] Internationalization (i18n)[[#Internationalization]]%0a%0aSkins can also be [[internationaliz(ations)]]ed by using %25pmhtl%25[@$[...]@] substitutions. Any string placed inside of [@$[...]@] is treated as a "translatable phrase", and the phrase is looked up in the current translation tables for a corresponding output phrase. If a translation is available, then the translated phrase is substituted at that point, otherwise the original phrase is left intact.%0a%0aFor example, the substitution [@$[Edit]@] will display the current translation of "Edit" if it is known, otherwise it displays "Edit". Thus, the same template can be used for multiple languages, displaying "Editer" when French translations are loaded, "Bearbeiten" when German translations are loaded, and "Edit" when no translation is available.%0a%0a!! FAQ%0a>>faq%3c%3c [[#faq]]%0a%0aQ: How do I customize the CSS styling of my PmWiki layout?[[#customcss]]%0a%0aA: See [[Skins]] for how to change the default PmWiki skin. See also [[Skins/|Skins]], where you will find pre-made templates you can use to customize the appearance of your site. You can also create a file called ''@@local.css@@'' in the ''pub/css/'' directory and add CSS selectors there (this file gets automatically loaded if it exists). Or, styles can be added directly into a local customization file by using something like:%0a%0a-> %25hlt php%25[@$HTMLStylesFmt[] = '.foo { color:blue; }';@]%0a%0a%0aQ: Where can the mentioned "translation table" be found for adding translated phrases?%0aA: See [[Internationalizations]].%0a%0aQ: Is it possible to have the edit form in full page width, with no sidebar?%0aA: If the sidebar is marked with %25hlt html%25[@%3c!--PageLeftFmt-->@], adding %25pmhlt%25[@(:noleft:)@] to Site.EditForm will hide it when a page is edited.%0a%0aQ: Can I easily hide the Home Page title from the homepage?%0aA: Yes, you can use in the wiki page either %25pmhlt%25@@[=(:title Some other title:)=]@@ to change it or @@[=(:notitle:)=]@@ to hide it.%0a%0aQ: Is it possible to hide the Search-Bar in the default PmWiki Skin?%0aA: Yes, please see [[Cookbook:HideSearchBar]].%0a +time=1660938464 blob - 0ab216c0210a65307ba16781f24dd657df9b027b blob + e60358d762673f71ff520bc3860250133877c7bc --- wikilib.d/PmWiki.Skins +++ wikilib.d/PmWiki.Skins @@ -1,9 +1,9 @@ -version=pmwiki-2.2.120 ordered=1 urlencoded=1 -author=MFWolff +version=pmwiki-2.3.17 ordered=1 urlencoded=1 +author=simon charset=UTF-8 -csum=wording +csum=update browsers (+16) name=PmWiki.Skins -rev=131 -targets=Skins.Skins,PmWiki.Skins,Cookbook.Cookbook,PmWiki.BasicVariables,PmWiki.SkinTemplates,Cookbook.Standalone,Cookbook.InstallOnIIS,Site.EditQuickReference -text=(:Summary: Change the look and feel of part or all of PmWiki:)(:Audience: administrators (basic) :)%0aA skin changes the look and feel of a PmWiki page, Group of pages, or the entire wiki.%0aTo see this try some skins out using the links below, or in the [[Skins:Skins|Skins section]] of the PmWiki cookbook.%0a %0a!!What's a skin? [[#what]]%0a%0aTest some skins installed pmwiki.org:%0a* [[PmWiki:Skins?skin=adapt | Adapt ]]%0a* [[PmWiki:Skins?skin=amber | Amber ]]%0a* [[PmWiki:Skins?skin=beeblebrox-gila2 | BeeblebroxNetGila ]]%0a* [[PmWiki:Skins?skin=jhskin | JHSkin ]]%0a* [[PmWiki:Skins?skin=monobook | Monobook ]]%0a* [[PmWiki:Skins?skin=simple | Simple ]]%0a* [[PmWiki:Skins?skin= | PmWiki-responsive (default) ]]%0a%0aAs you see, all skins show the same page contents, but the other elements such as the sidebar, header, and footer, have changed. %0aFor example, different skins may display the sidebar on the left, on the right, or even not at all. %0aSome skins have action links and features that others do not, especially if they were designed to take advantage of particular [[cookbook recipes -> Cookbook:Cookbook]].%0a%0aSo, a skin is just the set of files that determine how pages are displayed in PmWiki. Skins are stored as subfolders of ''pub/skins/''. For example you might create the ''example'' skin in ''pub/skins/example/''. Each skin typically has one or more of the following kinds of files:%0a* A template file, such as ''skin.tmpl'' or ''example.tmpl''. The template is written in HTML or XHTML, and is the skeleton for the skin. It contains special markers that tell PmWiki where to insert the page's contents.%0a* CSS stylesheet files, which can control the skin's appearance, such as ''pmwiki.css'' or ''example.css''.%0a* Image files, for decorating a page with images.%0a* PHP files, such as ''skin.php'' or ''example.php''. These let skins provide extra customization setting or capabilities that HTML and CSS alone cannot.%0a* Documentation files for the administrator, usually with names like ''readme.txt'', ''install.txt'' or ''skinname.txt''. These usually give you information about any special installation steps or nifty features the skin has.%0a%0a!! Where do I get skins? [[#where]]%0a%0aSkins are available in the [[http://www.pmwiki.org/wiki/Skins/Skins|Skins]] collection. %0aThe skins in the collection have been contributed by many PmWiki administrators for all to use, and typically have their own set of customization possibilities. %0aWhen you find a skin you like, follow the link to download the skin package.%0aYou can also [[{$FullName}#make|make your own]] skin.%0a%0a!! How do I use or install a skin? [[#use]]%0a%0aMost skin packages are .zip, .tgz, or .tar.gz files. You should be able to unpack these with most archiving software.%0a%0a# Unpack the skin to ''pub/skins/'' inside your pmwiki folder. Most well-designed skin packages will create a subfolder in ''pub/skins/'' named after the skin.%0a** If the skin did not make a folder of its own, create one and move the skin files to it.%0a%0a# Open up your ''local/config.php'' file, and add a line like%0a-> [@$Skin = 'example';@]%0awhere ''example'' is the name of the skin's folder.%0a%0aReload a page from your wiki in the browser, and you should be able to see the difference.%0a%0aIf you'd like to let your site's visitors choose one skin from a selection of skins you've installed, look at the [[http://www.pmwiki.org/wiki/Skins/SkinChange|Skin Change]] recipe. (That's what we used for the demo above.)%0a%0a!! How can I modify an existing skin? [[#modify]] [[#further]]%0a%0aThere are a number of ways to further customize the appearance of a skin, including %0a* adding statements to /local/config.php that are compatible with your chosen skin; %0a* adding css files to /pub/css/, such as local.css (for your entire wiki) and MyGroup.css (for MyGroup); and %0a* directly editing the skin's files. %0aIf the skin is updated regularly, you probably will want to avoid editing the files in the skin's folder. %0aCheck the skin's page in the Cookbook for specific suggestions.%0a%0aIf you want to modify the default pmwiki or print skins included with the PmWiki distribution, you should copy the pub/skins/pmwiki/ and pub/skins/print/ directories to another name and then use those skins instead of the default ones. While the name of the skin.tmpl and skin.css files don't usually matter, the optional skin.php file MUST match the name of the skin.%0a%0a!! How can I make a skin? [[#make]]%0a%0aThe best way to make your first skin is to modify a copy of PmWiki's default skin. %0a%0a# Make a copy of the folder ''pub/skins/pmwiki'' and name it whatever your new skin should be named.%0a# In your ''local/config.php'' file, set $Skin to be the name of your new skin.%0a# Modify the template and CSS files to suit you.%0a# Test your new skin.%0a# Repeat steps 3 and 4 until you're happy with the results.%0a%0aThe reason we recommend starting with the default PmWiki skin is that it's quite a simple skin, much more so than many of the skins you'll find in [[http://www.pmwiki.org/wiki/Skins/Skins|Skins]]. The starting point is the template (.tmpl) file, which provides the overall layout of the page. Inside of the template file are a number of special substitutions and directives that provide places for PmWiki to insert the data relevant to the current page being displayed. [[Skin Templates]] describes the format and directives in more detail. There are also [[http://www.pmwiki.org/wiki/Skins/SkinGuidelines|skin guidelines]] available on pmwiki.org.%0a%0aIt's beyond the scope of this page to explain how to write HTML (hypertext markup language), XHTML (extensible HTML, which is a bit newer) or CSS (cascading style sheets), but there are many good tutorials on the web for all three of them. One caution: if you run into an HTML tutorial that explains about how to use %3cfont> or %3cblink> tags, or spacer gifs, it's since quite a lot of years out of date, so skip it and find another one. %0a%0aYou should test your skin on a variety of browsers -- ideally as many as you can, on as many different platforms as you can -- but at minimum you should be testing on Internet Explorer 8, Firefox 3, and Chrome, since those are the most common, and have different bugs, it is also useful to test on Opera and Safari. Don't forget to do things like resize windows and change text size during your testing.%0a%0a!!! Tools that you'll need%0a%0aThere are good examples of all these programs available for free. %0a%0a'''HTML and CSS editor(s).''' There are two types of editors: graphical (WYSIWYG, or "what you see is what you get"), and hand-coding or programmer's editors. Graphical editors are less intimidating to novices, but you won't learn as much, or know your code as intimately as you will by using a hand-coding editor. Whichever you choose, get one that has syntax highlighting for the code, because it will help you spot mistakes. Also, live preview features are not that helpful when writing a PmWiki skin, because PmWiki does stuff that the live preview won't, such as substitute values for variables and insert sidebar content.%0a%0a'''Test wiki'''. You don't want to be wreaking havoc on your skin while visitors can see your site. It's a better idea to set up a test wiki, either on your real webserver or on your own machine. Linux or [=MacOS=] computer owners may have webservers and PHP already running on their machines, but Windows users often don't. If that describes you, then you might want to take a look at the [[Cookbook:Standalone]] recipe, which runs PmWiki without needing a complex webserver, or [[Cookbook:InstallOnIIS]]. Or, you can find many local server packages which install a webserver, PHP, and other stuff (e.g. `MySQL), all configured to work together. Try to get a package that has the same software and versions as used on your live setup, since then there will be less to go wrong when the site goes live.%0a%0a'''FTP client''' to transfer files to your webserver. You probably had one of these already.%0a%0a'''Color picker'''. Your editor might include one, or you could pick up a standalone application. Extremely helpful for creating and saving color palettes.%0a%0a!! Print Skins%0aBy default your new skin will use the standard /pub/skins/print/ skin. %0a%0aTo over-ride this add the following to local/config.php:%0a%0a->[@$ActionSkin['print'] = 'yourprintskin';@]%0a%0aThis says to use 'yourprintskin' for ?action=print instead of the default.%0a%0a%0a!! See also%0a(:pagelist fmt=#titlesummary order=name name=PmWiki/SkinTemplates,PmWiki/Installation :)%0a* [[http://www.pmwiki.org/wiki/Skins/Skins|Skins]]%0a* [[http://www.pmwiki.org/wiki/Skins/SkinGuidelines|Skin Guidelines]]%0a* [[Cookbook:Standalone]]%0a%0a!! FAQ%0a>>faq%3c%3c [[#faq]]%0a%0aQ: How do I change the Wiki's default name in the upper left corner of the Main Page?%0a%0aA: Put the following config.php%0a%0a->[@$WikiTitle = 'My Wiki Site';@]%0a%0aThe ''docs/sample-config.php'' file has an example of changing the title.%0a%0a%0aQ: How can I embed PmWiki pages inside a web page?%0a%0aA: Source them through a PHP page, or place them in a frame.%0a%0a%0aQ: How do I change the font or background color of the hints block on the Edit Page?%0a%0aA: Add a CSS style to pub/css/local.css: [@.quickref {background:...; color:... }@]. The hints are provided by the [[Site.EditQuickReference]] page, which is in the PmWiki or Site wikigroup. Edit that page, and change the "bgcolor" or specify the font "color" to get the contrast you need. -time=1571379915 +rev=141 +targets=Skins.Skins,PmWiki.Skins,Cookbook.Cookbook,Skins.SkinChange,PmWiki.BasicVariables,Skins.SkinGuidelines,PmWiki.SkinTemplates,Cookbook.Standalone,Cookbook.InstallOnIIS,PmWiki.GroupCustomizations,Site.EditQuickReference +text=(:Summary: Change the look and feel of part or all of PmWiki:)(:Audience: administrators (basic) :)%0aA skin changes the look and feel of a PmWiki page, Group of pages, or the entire wiki.%0aTo see this try some skins out using the links below, or in the [[Skins:Skins|Skins section]] of the PmWiki cookbook.%0a %0a!!What's a skin? [[#what]]%0a%0aTest some skins installed pmwiki.org:%0a* [[PmWiki:Skins?skin=adapt | Adapt ]]%0a* [[PmWiki:Skins?skin=amber | Amber ]]%0a* [[PmWiki:Skins?skin=beeblebrox-gila2 | BeeblebroxNetGila ]]%0a* [[PmWiki:Skins?skin=jhskin | JHSkin ]]%0a* [[PmWiki:Skins?skin=monobook | Monobook ]]%0a* [[PmWiki:Skins?skin=simple | Simple ]]%0a* [[PmWiki:Skins?skin= | PmWiki-responsive (default) ]]%0a%0aAs you see, all skins show the same page contents, but the other elements such as the sidebar, header, and footer, have changed. %0aFor example, different skins may display the sidebar on the left, on the right, or even not at all. %0aSome skins have action links and features that others do not, especially if they were designed to take advantage of particular [[cookbook recipes -> Cookbook:Cookbook]].%0a%0aSo, a skin is just the set of files that determine how pages are displayed in PmWiki. Skins are stored as subfolders of ''@@pub/skins/@@''. For example you might create the ''@@example@@'' skin in ''@@pub/skins/example/@@''. Each skin typically has one or more of the following kinds of files:%0a* A template file, such as ''@@skin.tmpl@@'' or ''@@example.tmpl@@''. The template is written in HTML or XHTML, and is the skeleton for the skin. It contains special markers that tell PmWiki where to insert the page's contents.%0a* CSS stylesheet files, which can control the skin's appearance, such as ''@@pmwiki.css@@'' or ''@@example.css@@''.%0a* Image files, for decorating a page with images.%0a* PHP files, such as ''@@skin.php@@'' or ''@@example.php@@''. These let skins provide extra customization setting or capabilities that HTML and CSS alone cannot.%0a* Documentation files for the administrator, usually with names like ''@@readme.txt@@'', ''@@install.txt@@'' or ''@@skinname.txt@@''. These usually give you information about any special installation steps or nifty features the skin has.%0a%0a!! Where do I get skins? [[#where]]%0a%0aSkins are available in the [[Skins/|Skins]] collection. %0aThe skins in the collection have been contributed by many PmWiki administrators for all to use, and typically have their own set of customization possibilities. %0aWhen you find a skin you like, follow the link to download the skin package.%0aYou can also [[{$FullName}#make|make your own]] skin.%0a%0a!! How do I use or install a skin? [[#use]]%0a%0aMost skin packages are .zip, .tgz, or .tar.gz files. You should be able to unpack these with most archiving software.%0a%0a# Unpack the skin to ''@@pub/skins/@@'' inside your pmwiki folder. Most well-designed skin packages will create a subfolder in ''@@pub/skins/@@'' named after the skin.%0a** If the skin did not make a folder of its own, create one and move the skin files to it.%0a%0a# Open up your ''@@local/config.php@@'' file, and add a line like%0a-> %25hlt php%25[@$Skin = 'example';@]%0a->where ''@@example@@'' is the name of the skin's folder.%0a%0aReload a page from your wiki in the browser, and you should be able to see the difference.%0a%0aIf you'd like to let your site's visitors choose one skin from a selection of skins you've installed, look at the [[Skins/SkinChange|Skin Change]] recipe. (That's what we used for the demo above.)%0a%0a!! How can I modify an existing skin? [[#modify]] [[#further]]%0a%0aThere are a number of ways to further customize the appearance of a skin, including %0a* adding statements to @@/local/config.php@@ that are compatible with your chosen skin; %0a* adding css files to @@/pub/css/@@, such as @@local.css@@ (for your entire wiki) and @@MyGroup.css@@ (for MyGroup); and %0a* directly editing the skin's files. %0aIf the skin is updated regularly, you probably will want to avoid editing the files in the skin's folder. %0aCheck the skin's page in the Cookbook for specific suggestions.%0a%0aIf you want to modify the default pmwiki or print skins included with the PmWiki distribution, you should copy the @@pub/skins/pmwiki/@@ and @@pub/skins/print/@@ directories to another name and then use those skins instead of the default ones. While the name of the @@skin.tmpl@@ and skin.css files don't usually matter, the optional @@skin.php@@ file MUST match the name of the skin.%0a%0a!! How can I make a skin? [[#make]]%0a%0aThe best way to make your first skin is to modify a copy of PmWiki's default skin. %0a%0a# Make a copy of the folder ''@@pub/skins/pmwiki@@'' and name it whatever your new skin should be named.%0a# In your ''@@local/config.php@@'' file, set $Skin to be the name of your new skin.%0a# Modify the template and CSS files to suit you.%0a# Test your new skin.%0a# Repeat steps 3 and 4 until you're happy with the results.%0a%0aThe reason we recommend starting with the default PmWiki skin is that it's quite a simple skin, much more so than many of the skins you'll find in [[Skins/|Skins]]. The starting point is the template (@@.tmpl@@) file, which provides the overall layout of the page. Inside of the template file are a number of special substitutions and directives that provide places for PmWiki to insert the data relevant to the current page being displayed. [[Skin Templates]] describes the format and directives in more detail. There are also [[Skins/SkinGuidelines|skin guidelines]] available on pmwiki.org.%0a%0aIt's beyond the scope of this page to explain how to write HTML (hypertext markup language), XHTML (extensible HTML, which is a bit newer) or CSS (cascading style sheets), but there are many good tutorials on the web for all three of them. One caution: if you run into an HTML tutorial that explains about how to use %3cfont> or %3cblink> tags, or spacer gifs, it's since quite a lot of years out of date, so skip it and find another one. %0a%0aYou should test your skin on a variety of browsers -- ideally as many as you can, on as many different platforms as you can -- but at minimum you should be testing on the current version of Edge, Firefox, and Chrome, since those are the most common, and have different bugs, it is also useful to test on Safari and mobile browsers. Don't forget to do things like resize windows and change text size during your testing.%0a%0a!!! Tools that you'll need [[#tools]]%0a%0aThere are good examples of all these programs available for free. %0a%0a'''HTML and CSS editor(s).''' There are two types of editors: graphical (WYSIWYG, or "what you see is what you get"), and hand-coding or programmer's editors. Graphical editors are less intimidating to novices, but you won't learn as much, or know your code as intimately as you will by using a hand-coding editor. Whichever you choose, get one that has syntax highlighting for the code, because it will help you spot mistakes. Also, live preview features are not that helpful when writing a PmWiki skin, because PmWiki does stuff that the live preview won't, such as substitute values for variables and insert sidebar content.%0a%0a'''Test wiki'''. You don't want to be wreaking havoc on your skin while visitors can see your site. It's a better idea to set up a test wiki, either on your real webserver or on your own machine. Linux or [=MacOS=] computer owners may have webservers and PHP already running on their machines, but Windows users often don't. If that describes you, then you might want to take a look at the [[Cookbook:Standalone]] recipe, which runs PmWiki without needing a complex webserver, or [[Cookbook:InstallOnIIS]]. Or, you can find many local server packages which install a webserver, PHP, and other stuff (e.g. `MySQL), all configured to work together. Try to get a package that has the same software and versions as used on your live setup, since then there will be less to go wrong when the site goes live.%0a%0a'''FTP client''' to transfer files to your webserver. You probably had one of these already.%0a%0a'''Color picker'''. Your editor might include one, or you could pick up a standalone application. Extremely helpful for creating and saving color palettes.%0a%0a!! Print skins [[#print]]%0aBy default your new skin will use the standard @@/pub/skins/print/@@ skin. %0a%0aTo over-ride this add the following to @@local/config.php@@:%0a%0a->%25hlt php%25[@$ActionSkin['print'] = 'yourprintskin';@]%0a%0aThis says to use 'yourprintskin' for @@?action=print@@ instead of the default.%0a%0aThe default print skin overwrites links to other existing wiki pages so that they also open in the print skin. This can be prevented by adding these lines at the bottom of local/config.php or other [[group customizations]] scripts.%0a%0a%25hlt php%25 [@%0ainclude_once("$FarmD/scripts/prefs.php");%0ainclude_once("$FarmD/scripts/skins.php");%0a$LinkPageExistsFmt = "%3ca class='wikilink' href='\$LinkUrl' title='\$LinkAlt'>\$LinkText%3c/a>";%0a@]%0a%0a%0a!! See also [[#seealso]]%0a(:pagelist fmt=#titlesummary order=name name=PmWiki/SkinTemplates,PmWiki/Installation,Skins/Skins,Skins/SkinGuidelines:)%0a* [[Cookbook:Standalone]]%0a%0a!! FAQ%0a>>faq%3c%3c [[#faq]]%0a%0aQ: How do I change the Wiki's default name in the upper left corner of the Main Page?%0a%0aA: Put the following @@config.php@@%0a%0a->%25hlt php%25[@$WikiTitle = 'My Wiki Site';@]%0a%0aThe ''@@docs/sample-config.php@@'' file has an example of changing the title.%0a%0a%0aQ: How can I embed PmWiki pages inside a web page?%0a%0aA: Source them through a PHP page, or place them in a frame.%0a%0a%0aQ: How do I change the font or background color of the hints block on the Edit Page?%0a%0aA: Add a CSS style to @@pub/css/local.css@@: %25hlt css%25[@.quickref {background:...; color:... }@]. The hints are provided by the [[Site.EditQuickReference]] page, which is in the PmWiki or Site wikigroup. Edit that page, and change the "bgcolor" or specify the font "color" to get the contrast you need. +time=1673206333 blob - 86232e27e92a9e15cf2d0550ad4b197c29492776 blob + 81a612ecfe231c96cf9f84ae95b2e7f1bbe051f5 --- wikilib.d/PmWiki.SpecialCharacters +++ wikilib.d/PmWiki.SpecialCharacters @@ -1,9 +1,9 @@ -version=pmwiki-2.2.84 ordered=1 urlencoded=1 -author=Petko +version=pmwiki-2.3.8 ordered=1 urlencoded=1 +author=simon charset=UTF-8 -csum=replace commercial link with Wikipedia page - full Unicode list +csum=http+s (-14) name=PmWiki.SpecialCharacters -rev=17 +rev=18 targets=PmWiki.SpecialCharactersList,PmWiki.Characters -text=When creating pages it's common to use commercial trademarks, copyright, umlaut, and other non-keyboard symbols. therefore it's important that you have the means to input these special characters. %0a%0a!!!ISO Standard codes%0aPmWiki supports the HTML special character listings by the w3c. [[http://www.w3.org/MarkUp/html-spec/html-spec_13.html | W3C Page of Special Character codes ISO standard.]]%0a%0aHere are some samples: %0a(:markup:)[=%0a© | ¼ | ½ | ® | µ | ¨ =]%0a%0a(:markup:)[=%0aÆ | 32° | Unïted Stätes | ¶ | ¥Yen | PmWiki™=]%0a%0aFor a nice table with all available special characters, see [[https://en.wikipedia.org/wiki/List_of_Unicode_characters|List of Unicode characters]] at Wikipedia.%0a%0a!!!Other ways to do it: %0a%0a!!!!Character Map%0aFind the "Character Map" utility in your computer's System Tools folder. Click the symbol you're interested in, and note the keystroke information at the bottom of the box. You execute these by ''holding "Alt"'' while keying the numbers ''on the numerical keypad'' of your keyboard (not the numbers across the top of the board).%0a%0a[=©=] = Alt+0169 = © | [=®=] = Alt+0174 = ® | [=°=] = Alt+0176 = ° (degrees).%0a%0a!!!!Paste%0a*Use Word or another desktop application to create your text with the special characters that you want. Copy and paste the text to the wiki page you're editing or creating.%0a*Find an instance of a special character in an online document; copy and paste the character to your wiki page: ©%0a%0aThere's a list of special characters at [[PmWiki:SpecialCharactersList]].%0aThere's another illustration at [[PmWiki:Characters]] -time=1459412004 +text=When creating pages it's common to use commercial trademarks, copyright, umlaut, and other non-keyboard symbols. therefore it's important that you have the means to input these special characters. %0a%0a!!!ISO Standard codes%0aPmWiki supports the HTML special character listings by the w3c. [[https://www.w3.org/MarkUp/html-spec/html-spec_13.html | W3C Page of Special Character codes ISO standard.]]%0a%0aHere are some samples: %0a(:markup:)[= © | ¼ | ½ | ® | µ | ¨ =]%0a%0a(:markup:)[= Æ | 32° | Unïted Stätes | ¶ | ¥Yen | PmWiki™ =]%0a%0aFor a nice table with all available special characters, see [[Wikipedia:List_of_Unicode_characters|List of Unicode characters]] at Wikipedia.%0a%0a!!!Other ways to do it: %0a%0a!!!!Character Map%0aFind the "Character Map" utility in your computer's System Tools folder. Click the symbol you're interested in, and note the keystroke information at the bottom of the box. You execute these by ''holding "Alt"'' while keying the numbers ''on the numerical keypad'' of your keyboard (not the numbers across the top of the board).%0a-> @@[=©=] = Alt+0169 = © | [=®=] = Alt+0174 = ® | [=°=] = Alt+0176 = ° (degrees)@@%0a%0a!!!!Paste%0a*Use Word or another desktop application to create your text with the special characters that you want. Copy and paste the text to the wiki page you're editing or creating.%0a*Find an instance of a special character in an online document; copy and paste the character to your wiki page: ©%0a%0aThere's a list of special characters at [[PmWiki:SpecialCharactersList]].%0aThere's another illustration at [[PmWiki:Characters]] +time=1660386258 blob - 23edc8aea21667026322a81435fcc6488474d136 blob + 79e00cec0e34137e32deefb4f9b50c46798d177c --- wikilib.d/PmWiki.TableDirectives +++ wikilib.d/PmWiki.TableDirectives @@ -1,10 +1,10 @@ -version=pmwiki-2.2.123 ordered=1 urlencoded=1 -author=Petko +version=pmwiki-2.3.4 ordered=1 urlencoded=1 +author=simon charset=UTF-8 -csum=style and class are also valid, you can place min-width inside style (+81) +csum=pm hlt, hlt html (+203) name=PmWiki.TableDirectives -rev=95 +rev=96 targets=PmWiki.Tables,PmWiki.TableDirectives,PmWiki.LayoutVariables,PmWiki.Audiences,PmWiki.PmWikiPhilosophy,PmWiki.LocalCustomizations,PmWiki.IncludeOtherPages,Cookbook.AdvancedTableDirectives,Cookbook.BackgroundImages,PmWiki.WikiStyles,PmWiki.TableDirectives-Talk,Cookbook.CreateColumns -text=(:Summary:Directives for table processing:)(:Audience: authors (intermediate) :)(:title Table directives:)%0aSee [[Tables]] for the "simple table" markup. Here you can find the markup for advanced/structural tables. %0a%0aThere are six directives for table processing. All must be at the beginning of a line to have any effect.%0a%0a!!!@@[=(:table [attr...]:)=]@@%0a%0aGenerates a new HTML %3ctable> tag with the attributes provided in ''attr...''.%0aCloses the previous table, if any.%0aValid attributes and values are:%0a* border ''(a positive integer)''%0a* bordercolor ''(a color name or hex number; doesn't display in all browsers)''%0a* cellspacing ''(a positive integer indicating the space between cells)''%0a* cellpadding ''(a positive integer indicating the interior border of a cell)''%0a* width ''(a positive integer or percent)''%0a* bgcolor ''(a color name or hex number)''%0a* align ''(left, center or right)''%0a* summary ''(does not display; used primarily to help visually disabled people navigate)''%0a* style ''(CSS rules for the table)''%0a* class ''(CSS class name for the table)''%0a%0a!!!@@[=(:cellnr [attr...]:), (:cell [attr...]:), (:headnr [attr...]:), (:head [attr...]:) =]@@%0a%0a* The @@ [=(:head:)=] @@ directive opens a new "header cell" of the table (creates @@ %3cth> @@ tag in HTML).%0a* The @@ [=(:cell:)=] @@ directive opens a new "regular cell" of the table (creates @@ %3ctd> @@ tag in HTML).%0a* The directives @@ [=(:headnr:)=] @@ and @@ [=(:cellnr:)=] @@ open a new cell on a new row in the table.%0a%0aThese directives close any previous cell and/or row. Note, the @@ [=(:head:)=] @@ and @@ [=(:headnr:)=] @@ directives exist from PmWiki version 2.2.11 or newer.%0a%0aValid attributes and values are:%0a* align ''(left, center or right)''%0a* valign ''(top, middle or bottom)'' * ''default is "top", see note below''%0a* colspan ''(a positive integer)''%0a* rowspan ''(a positive integer)''%0a* bgcolor ''(a color name or hex number)''%0a* width ''(a positive integer or percent)''%0a* class ''(a CSS class of the cell)''%0a* style ''(custom CSS styles of the cell)''%0a%0a!!! @@ [=(:tableend:)=] @@%0a%0aCloses the previous table cell and closes off any table. Generates %3c/th>, %3c/td>, %3c/tr>, and %3c/table> tags as needed.%0a%0a!!!* valign attribute%0a%0aIf not already set, PmWiki will automatically include the attribute valign='top' with all [@(:cell[nr]:)@] and [@(:head[nr]:)@]. Pm said "Table Directives were created for layout purposes and in that case it makes the most sense for each cell (column) to have its content at the top of the row. The attribute is placed in each cell and not in the row because certain browsers didn't recognize valign='top' in the row tag.%0a%0aSee $EnableTableAutoValignTop on how to disable the automatic insertion of the attribute.%0a%0a!! Notes%0a%0aFor the table, cell, and cellnr tags the author can specify any attributes that would be valid in the HTML %3ctable> or %3ctd> tags. Thus you can specify rowspan, colspan, etc. arguments to build arbitrary tables. However, it's not possible to nest a [@(:table:)@] inside of a [@(:cell:)@] or [@(:cellnr:)@] -- the next paragraph explains why.%0a%0aMany are likely to ask why we didn't just use the standard HTML table markup (%3ctable>, %3ctr>, %3ctd>, %3cth>) instead of creating a new markup, and allowing nested tables as a result. There are two answers: first, the HTML table markup is very ugly for naive authors (see [[PmWiki.Audiences]] and [[PmWikiPhilosophy]] #2), and second, it'd be very easy for authors to create tables that are incorrect HTML and that display incorrectly (or not at all) on some browsers. Even seasoned web professionals sometimes get the table markup wrong, so it's a bit unrealistic to expect the average author to always get it right, or to be able to read arbitrary HTML table markup that someone else has created.%0a%0a-> %25color=green%25 ''Common comment:'' Surely, the average or naive author would not be writing HTML directly, but using a tool, such as [=FrontPage=], or even [=MSWord=], to generate the HTML. This would be a lot simpler than learning even the simplest PmWiki markups.%0a>>%3c%3c%0a%0a-> %25color=green%25 ''Pm's Response:'' And once the HTML has been generated and posted, how is someone else going to edit or modify the table if they don't have the original [=FrontPage or MSWord=] file used to create it? Remember that we're talking about ''collaborative'' authoring. The HTML that those packages generate is among the hardest to read and edit of all!%0a%0aIt's difficult to write the code needed to make PmWiki understand and fix arbitrary table markup, so PmWiki uses the simplified version above. Still, this version is able to handle most table requirements (with the possible exception of nested tables).%0a%0aAnd, this is not to say that nested HTML tables are impossible in PmWiki --they just can't be easily created by wiki authors using the default wiki markup. A site administrator can of course create header/footer HTML code and other [[local customizations]] that make use of nested tables.%0a%0a!! Examples%0a!!!A table using table directive markup.%0a%0a"[@ @]" is a non-breaking space in html. Place it in a cell if a cell is to be empty or the border of the cell will not be drawn properly.%0a%0a(:markup:)%0a(:table border=1 cellpadding=5 cellspacing=0:)%0a(:head:) a1%0a(:cell:) b1%0a(:cell:) c1%0a(:cell:) d1%0a(:headnr:) a2%0a(:cell:) b2%0a(:cell:) c2%0a(:cell:)  %0a(:tableend:)%0a(:markupend:)%0a%0a%0aIn HTML, this is the same as%0a%0a-> [@%0a%3ctable border='1' cellpadding='5' cellspacing='0'>%0a %3ctr>%0a %3cth>a1%3c/th>%0a %3ctd>b1%3c/td>%0a %3ctd>c1%3c/td>%0a %3ctd>d1%3c/td>%0a %3c/tr>%0a %3ctr>%0a %3cth>a2%3c/th>%0a %3ctd>b2%3c/td>%0a %3ctd>c2%3c/td>%0a %3ctd> %3c/td>%0a %3c/tr>%0a%3c/table>%0a@]%0a%0a%0a-----%0a!!!Floating Table with bulleted navigation list%0a%0aWhat if you wanted to create a nice little table like a table of contents in a page like this? In this example, the table is floating right and contains some links in a bulleted list. This is a nice demonstration of how it's possible to build a little table of contents in the page, which might navigate to other pages just within the same wiki group. Note that having a bulleted list ''won't work in a ordinary table'' - it only works inside an table created with table directives such as the example code used here.%0a%0a(:markup:)%0a(:table border=1 width=30%25 align=right bgcolor=#cccc99 cellspacing=0 :)%0a(:cellnr:)%0a'''Navigation Links'''%0a(:cellnr:)%0a*[[Tables]]%0a*[[Table directives]]%0a(:tableend:)%0a(:markupend:)%0a%0a(:markup:)%0a(:table border=1 width=30%25 align=right bgcolor=#cccc99 cellspacing=0 :)%0a(:cellnr colspan=2 align=center:)%0a'''Navigation Links'''%0a(:cellnr align=center:)%0a[[Tables]]%0a(:cell align=center:)%0a[[Table directives]]%0a(:tableend:)%0a(:markupend:)%0a%0aLooking at the markup here, notice that we have used a #cccc99 hex color for the table background. Also, the [@(:cellnr:)@] markup creates a new row, a new cell and closes the row at the end.%0a%0aYou could take this concept a little further: since you might want each page in the group to contain the same table of contents, you can make ONE table like the above and put it in its own page. Then use an [[include (other pages)]] on any of your pages and bring in the table. The float (align) property will be honored in each page where it's included.%0a%0a!! FAQ%0a>>faq%3c%3c [[#faq]]%0a%0aQ: Can I define table headers using the table directive markup?%0aA: Yes, use [@(:head:)@] or [@(:headnr:)@] with PmWiki version 2.2.11 or newer. See also Cookbook:AdvancedTableDirectives.%0a%0aQ: Is it possible to do nested tables?%0aA: Yes, if you nest [[Tables|simple tables]] inside advanced tables. See also Cookbook:AdvancedTableDirectives.%0a%0aQ: Is it possible to add background images to tables and table cells?%0aA: Yes, see Cookbook:BackgroundImages.%0a%0aQ: Is it possible to apply styles to the elements of the table, like an ID to the table row, or a class/style to the TD?%0aA: Yes, see [[PmWiki.WikiStyles#WikiStyleApply | $WikiStyleApply]].%0a%0aQ: Is it possible to automatically generate columns or rows in tables, i.e. without having to do a lot of counting?%0aA: Yes, this is possible with the Cookbook:CreateColumns recipe - it allows you to specify a certain number of columns, and/or to specify a certain number of items per column. Plus, someone has provided some similar markup on the [[(PmWiki:)TableDirectives-Talk]] page.%0a%0aQ: Is it possible to use table captions in table directives similar to simple tables? Tried [@ ! Captiontext ! @] and [@ (:caption:) @]. Didn#t work. How to do?%0aA: Yes, this is possible with the [[Cookbook:AdvancedTableDirectives]] recipe - There you will find a [@(:caption:)@] directive. -time=1579251264 +text=(:Summary:Directives for table processing:)(:Audience: authors (intermediate) :)(:title Table directives:)%0aSee [[Tables]] for the "simple table" markup. Here you can find the markup for advanced/structural tables. %0a%0aThere are six directives for table processing. All must be at the beginning of a line to have any effect.%0a%0a!!!%25pmhlt%25@@[=(:table [attr...]:)=]@@%0a%0aGenerates a new HTML %25hlt html%25@@%3ctable>@@ tag with the attributes provided in ''attr...''.%0aCloses the previous table, if any.%0aValid attributes and values are:%0a* border ''(a positive integer)''%0a* bordercolor ''(a color name or hex number; doesn't display in all browsers)''%0a* cellspacing ''(a positive integer indicating the space between cells)''%0a* cellpadding ''(a positive integer indicating the interior border of a cell)''%0a* width ''(a positive integer or percent)''%0a* bgcolor ''(a color name or hex number)''%0a* align ''(left, center or right)''%0a* summary ''(does not display; used primarily to help visually disabled people navigate)''%0a* style ''(CSS rules for the table)''%0a* class ''(CSS class name for the table)''%0a%0a!!!%25pmhlt%25@@[=(:cellnr [attr...]:), (:cell [attr...]:), (:headnr [attr...]:), (:head [attr...]:) =]@@%0a%0a* The %25pmhlt%25@@ [=(:head:)=] @@ directive opens a new "header cell" of the table (creates %25hlt html%25@@ %3cth> @@ tag in HTML).%0a* The %25pmhlt%25@@ [=(:cell:)=] @@ directive opens a new "regular cell" of the table (creates %25hlt html%25@@ %3ctd> @@ tag in HTML).%0a* The directives %25pmhlt%25@@ [=(:headnr:)=] @@ and @@ [=(:cellnr:)=] @@ open a new cell on a new row in the table.%0a%0aThese directives close any previous cell and/or row. Note, the %25pmhlt%25@@ [=(:head:)=] @@ and @@ [=(:headnr:)=] @@ directives exist from PmWiki version 2.2.11 or newer.%0a%0aValid attributes and values are:%0a* align ''(left, center or right)''%0a* valign ''(top, middle or bottom)'' * ''default is "top", see note below''%0a* colspan ''(a positive integer)''%0a* rowspan ''(a positive integer)''%0a* bgcolor ''(a color name or hex number)''%0a* width ''(a positive integer or percent)''%0a* class ''(a CSS class of the cell)''%0a* style ''(custom CSS styles of the cell)''%0a%0a!!! @@ [=(:tableend:)=] @@%0a%0aCloses the previous table cell and closes off any table. Generates %25hlt html%25@@%3c/th>@@, @@%3c/td>@@, @@%3c/tr>@@, and @@%3c/table>@@ tags as needed.%0a%0a!!!* valign attribute%0a%0aIf not already set, PmWiki will automatically include the attribute valign='top' with all %25pmhlt%25[@(:cell[nr]:)@] and [@(:head[nr]:)@]. Pm said "Table Directives were created for layout purposes and in that case it makes the most sense for each cell (column) to have its content at the top of the row. The attribute is placed in each cell and not in the row because certain browsers didn't recognize valign='top' in the row tag.%0a%0aSee $EnableTableAutoValignTop on how to disable the automatic insertion of the attribute.%0a%0a!! Notes%0a%0aFor the table, cell, and cellnr tags the author can specify any attributes that would be valid in the HTML %25hlt html%25@@%3ctable>@@ or @@%3ctd>@@ tags. Thus you can specify rowspan, colspan, etc. arguments to build arbitrary tables. However, it's not possible to nest a %25pmhlt%25[@(:table:)@] inside of a [@(:cell:)@] or [@(:cellnr:)@] -- the next paragraph explains why.%0a%0aMany are likely to ask why we didn't just use the standard HTML table markup (%25hlt html%25@@%3ctable>@@, @@%3ctr>@@, @@%3ctd>@@, @@%3cth>@@) instead of creating a new markup, and allowing nested tables as a result. There are two answers: first, the HTML table markup is very ugly for naive authors (see [[PmWiki.Audiences]] and [[PmWikiPhilosophy]] #2), and second, it'd be very easy for authors to create tables that are incorrect HTML and that display incorrectly (or not at all) on some browsers. Even seasoned web professionals sometimes get the table markup wrong, so it's a bit unrealistic to expect the average author to always get it right, or to be able to read arbitrary HTML table markup that someone else has created.%0a%0a-> %25color=green%25 ''Common comment:'' Surely, the average or naive author would not be writing HTML directly, but using a tool, such as [=FrontPage=], or even [=MSWord=], to generate the HTML. This would be a lot simpler than learning even the simplest PmWiki markups.%0a>>%3c%3c%0a%0a-> %25color=green%25 ''Pm's Response:'' And once the HTML has been generated and posted, how is someone else going to edit or modify the table if they don't have the original [=FrontPage or MSWord=] file used to create it? Remember that we're talking about ''collaborative'' authoring. The HTML that those packages generate is among the hardest to read and edit of all!%0a%0aIt's difficult to write the code needed to make PmWiki understand and fix arbitrary table markup, so PmWiki uses the simplified version above. These directives are able to handle most table requirements (with the possible exception of nested tables).%0a%0aAnd, this is not to say that nested HTML tables are impossible in PmWiki --they just can't be easily created by wiki authors using the default wiki markup. A site administrator can of course create header/footer HTML code and other [[local customizations]] that make use of nested tables.%0a%0a!! Examples%0a!!!A table using table directive markup.%0a%0a"%25pmhlt%25[@ @]" is a non-breaking space in html. Place it in a cell if a cell is to be empty or the border of the cell will not be drawn properly.%0a%0a(:markup:)%0a(:table border=1 cellpadding=5 cellspacing=0:)%0a(:head:) a1%0a(:cell:) b1%0a(:cell:) c1%0a(:cell:) d1%0a(:headnr:) a2%0a(:cell:) b2%0a(:cell:) c2%0a(:cell:)  %0a(:tableend:)%0a(:markupend:)%0a%0a%0aIn HTML, this is the same as%0a%0a-> %25hlt html%25[@%0a%3ctable border='1' cellpadding='5' cellspacing='0'>%0a %3ctr>%0a %3cth>a1%3c/th>%0a %3ctd>b1%3c/td>%0a %3ctd>c1%3c/td>%0a %3ctd>d1%3c/td>%0a %3c/tr>%0a %3ctr>%0a %3cth>a2%3c/th>%0a %3ctd>b2%3c/td>%0a %3ctd>c2%3c/td>%0a %3ctd> %3c/td>%0a %3c/tr>%0a%3c/table>%0a@]%0a%0a%0a-----%0a!!!Floating Table with bulleted navigation list%0a%0aWhat if you wanted to create a nice little table like a table of contents in a page like this? In this example, the table is floating right and contains some links in a bulleted list. This is a nice demonstration of how it's possible to build a little table of contents in the page, which might navigate to other pages just within the same wiki group. Note that having a bulleted list ''won't work in a ordinary table'' - it only works inside an table created with table directives such as the example code used here.%0a%0a(:markup:)%0a(:table border=1 width=30%25 align=right bgcolor=#cccc99 cellspacing=0 :)%0a(:cellnr:)%0a'''Navigation Links'''%0a(:cellnr:)%0a*[[Tables]]%0a*[[Table directives]]%0a(:tableend:)%0a(:markupend:)%0a%0a(:markup:)%0a(:table border=1 width=30%25 align=right bgcolor=#cccc99 cellspacing=0 :)%0a(:cellnr colspan=2 align=center:)%0a'''Navigation Links'''%0a(:cellnr align=center:)%0a[[Tables]]%0a(:cell align=center:)%0a[[Table directives]]%0a(:tableend:)%0a(:markupend:)%0a%0aLooking at the markup here, notice that we have used a #cccc99 hex color for the table background. Also, the %25pmhlt%25[@(:cellnr:)@] markup creates a new row, a new cell and closes the row at the end.%0a%0aYou could take this concept a little further: since you might want each page in the group to contain the same table of contents, you can make ONE table like the above and put it in its own page. Then use an [[include (other pages)]] on any of your pages and bring in the table. The float (align) property will be honored in each page where it's included.%0a%0a!! FAQ%0a>>faq%3c%3c [[#faq]]%0a%0aQ: Can I define table headers using the table directive markup?%0aA: Yes, use %25pmhlt%25[@(:head:)@] or [@(:headnr:)@] with PmWiki version 2.2.11 or newer. See also Cookbook:AdvancedTableDirectives.%0a%0aQ: Is it possible to do nested tables?%0aA: Yes, if you nest [[Tables|simple tables]] inside advanced tables. See also Cookbook:AdvancedTableDirectives.%0a%0aQ: Is it possible to add background images to tables and table cells?%0aA: Yes, see Cookbook:BackgroundImages.%0a%0aQ: Is it possible to apply styles to the elements of the table, like an ID to the table row, or a class/style to the TD?%0aA: Yes, see [[PmWiki.WikiStyles#WikiStyleApply | $WikiStyleApply]].%0a%0aQ: Is it possible to automatically generate columns or rows in tables, i.e. without having to do a lot of counting?%0aA: Yes, this is possible with the Cookbook:CreateColumns recipe - it allows you to specify a certain number of columns, and/or to specify a certain number of items per column. Plus, someone has provided some similar markup on the [[(PmWiki:)TableDirectives-Talk]] page.%0a%0aQ: Is it possible to use table captions in table directives similar to simple tables? Tried %25pmhlt%25[@ ! Captiontext ! @] and [@ (:caption:) @]. Didn#t work. How to do?%0aA: Yes, this is possible with the [[Cookbook:AdvancedTableDirectives]] recipe - There you will find a %25pmhlt%25[@(:caption:)@] directive. +time=1652474824 title=Table directives blob - 5d3f9c17a84af94068b3d43e60cd97a79a216b28 blob + 5807f3caa2f6d1698be4dc1a17ddaafdd3411a44 --- wikilib.d/PmWiki.TableOfContents +++ wikilib.d/PmWiki.TableOfContents @@ -1,11 +1,11 @@ -version=pmwiki-2.2.126 ordered=1 urlencoded=1 +version=pmwiki-2.3.17 ordered=1 urlencoded=1 author=Petko charset=UTF-8 -csum=only float: right; is required for floating right; already 13px (-42) +csum=%25notoc%25 is enough since 2.3.16 (-6) ctime=1567101340 name=PmWiki.TableOfContents -rev=28 -targets=PmWiki.LayoutVariables,Cookbook.AutoTOC,PmWiki.PathVariables -text=(:title Table of contents:)(:Audience: authors (basic) :)%0a(:Summary:Basic automatic table of contents and numbered headings:)%0aA basic table of contents (TOC) and Numbered headings (NH) are included in PmWiki 2.2.119 and can be enabled with the following in config.php:%0a%0a $PmTOC['Enable'] = 1;%0a%0a!! Usage [[#usage]]%0aThe feature is based on the recipe Cookbook:AutoTOC but is somewhat simpler. %0a%0a* The table of contents is automatic, there is no need to add some markup in the wiki page.%0a* It is inserted right before the first heading in the wiki page.%0a* By default, only pages with 3 or more headings will have a table of contents.%0a* The visitors can close or open the table of contents, and their last choice will be remembered by their browsers in "localStorage". It is then used also for other pages. And it is used, if the Wiki is revisited later, as long as the "localStorage" is not cleared in the meantime.%0a* The feature can automatically number the headings in the page.%0a* Headings in hidden sections ("comment" wikistyle, "display:none") will not be included in the TOC.%0a* Headings with the [@%25block notoc%25@] class will not be included in the TOC.%0a* Headings in [@(:markup:)@] blocks are ignored.%0a%0aThe following directives in the wiki page can control the above features:%0a%0a* [@(:toc:)@] the table of contents will be inserted at this position (rather than the default one), even if there are less than 3 headings in the page.%0a* [@(:notoc:)@] no table of contents will appear on the page, even if there are 3 or more headings, or a [@(:toc:)@] directive. If you have only one heading in a page, you may wish to use [@(:notoc:)@] to ''suppress numbering''.%0a%0aThe TOC will use anchors or identifiers of the headings from the page, if they exist, otherwise it will create a new identifier (hash) based on the structure of the page. The following markups will all create a link with the anchor @@PageUrl%25blue%25#here%25%25@@:%0a%0a* @@!! Heading with id %25blue%25[=%25block id=here%25=]%25%25@@%0a* @@!! Heading with inline anchor %25blue%25[=[[#here]]=]%25%25@@, or%0a* @@!! %25blue%25[=[[#here]]=]%25%25 Heading with inline anchor@@%0a* @@%25blue%25[=[[#here]]=]%25%25\\%0a[=!! Anchor preceding the heading=]@@%0a%0aIf there is no identifier or anchor with a heading, then the anchor will be in the form @@%25blue%25#toc-1.2.1%25%25@@ where 1.2.1 is the structural path to the section, in this example "Section 1, subsection 2, sub-subsection 1".%0a%0a%0a!! Configuration [[#config]]%0aThe following local configuration (in local/config.php) can control the default settings:%0a%0a* @@$PmTOC['Enable'] = 1; @@# enable TOC and/or NH, default is disabled.%0a* @@$PmTOC['MaxLevel'] = 6;@@ # levels of headings that are included in the TOC, by default %3ch1> to %3ch6> headings are included. Set to 3 to only include %3ch1> to %3ch3> headings.%0a* @@$PmTOC['MinNumber'] = 3;@@ # minimum number of headings in the page for the TOC to be generated. Pages with few headings are usually short and do not need a TOC. %0a** @@$PmTOC['MinNumber'] = 2; @@# pages with 2+ headings will have a TOC%0a** @@$PmTOC['MinNumber'] = 9999999; @@# the TOC will not be automatic, only the [@(:toc:)@] directive will create a table of contents in the page. %0a%0a* @@$PmTOC['NumberedHeadings'] = '1.1.1.1.1.1'; @@# the headings will be numbered (default disabled).%0a** You can set here the numerals for the different levels of headings, can be @@1@@ (numeric), @@I@@ or @@i@@ (Roman numerals), @@A@@ or @@a@@ (letters A-Z or a-z). For example, a specification like \\%0a @@$PmTOC['NumberedHeadings'] = 'I.1.a'; @@ \\%0a will number the biggest level headings on a page with uppercase Roman numerals (I, II, ...), the second biggest with numbers, the third with lowercase letters (a, b, ...), and the remaining levels (if any) with numbers.%0a** @@$PmTOC['MinNumber'] = 9999999; @@# only enable Numbered headings without creating a TOC. You still need to set @@$PmTOC['Enable'] = 1;@@%0a%0a* @@$PmTOC['EnableBacklinks'] = 1; @@# insert after the headings "↑" arrows linking back to the table of contents (default disabled).%0a* @@$PmTOC['ParentElement'] = "#wikitext"; @@# the query selector of the parent HTML element where the TOC block to be inserted; by default the TOC is inserted before the first heading; here you can select a different element. If selected, the TOC will be inserted in the element at the top. The [@(:toc:)@] directive in the page can override this element.%0a%0a!! Internationalization [[#i18n]]%0a%0aThe following strings can be translated in XLPage, for example in French:%0a%0a "Contents" => "Sommaire",%0a "show" => "afficher",%0a "hide" => "masquer",%0a %0a%25note%25Note: If you prefer to see the TOC on the right side, you may want to insert the following in your $PubDirUrl/css/local.css file:%0a%0a[@%0a .PmTOCdiv {%0a float: right;%0a margin-left: 5px;%0a }%0a@]%0a%0aSee also: Cookbook:AutoTOC. If you previously used AutoTOC you need to disable it when enabling $PmTOC.%0a -time=1581508870 +rev=47 +targets=Cookbook.AutoTOC,PmWiki.LayoutVariables,PmWiki.PathVariables +text=(:title Table of contents:)(:Audience: authors (basic) :)%0a(:Summary:Basic automatic table of contents and numbered headings:)%0aA basic table of contents (TOC) and Numbered headings (NH) are included in PmWiki 2.2.119 and can be enabled with the following in @@config.php@@:%0a%0a%25hlt php%25[@%0a$PmTOC['Enable'] = 1;%0a@]%0a%0a!! Usage [[#usage]]%0aThe feature is based on the recipe Cookbook:AutoTOC but is somewhat simpler. %0a%0a* The table of contents is automatic, there is no need to add some markup in the wiki page.%0a* It is inserted right before the first heading in the wiki page.%0a* By default, only pages with 3 or more headings will have a table of contents.%0a* The visitors can close or open the table of contents, and their last choice will be remembered by their browsers in "localStorage". It is then used also for other pages. And it is used, if the Wiki is revisited later, as long as the "localStorage" is not cleared in the meantime.%0a* The feature can automatically number the headings in the page.%0a* Headings in hidden sections ("comment" wikistyle, "display:none") will not be included in the TOC.%0a* Headings with the %25pmhlt%25[@%25notoc%25@] class will not be included in the TOC.%0a* Headings in %25pmhlt%25[@(:markup:)@] blocks are ignored.%0a%0aThe following directives in the wiki page can control the above features:%0a%0a* %25pmhlt%25[@(:toc:)@] the table of contents will be inserted at this position (rather than the default one), even if there are less than 3 headings in the page.%0a* %25pmhlt%25[@(:notoc:)@] no table of contents will appear on the page, even if there are 3 or more headings, or a [@(:toc:)@] directive. If you have only one heading in a page, you may wish to use [@(:notoc:)@] to ''suppress numbering''.%0a* Both directives can be placed anywhere in a page, even in included pages such as a sidebar or a header.%0a* On a page with both %25pmhlt%25[@(:toc:)@] and [@(:notoc:)@] the latter wins and there will be no table of contents.%0a%0aThe TOC will use anchors or identifiers of the headings from the page, if they exist, otherwise it will create a new identifier (hash) based on the structure of the page. The following markups will all create a link with the anchor @@PageUrl%25blue%25#here%25%25@@:%0a%0a* %25pmhlt%25[@!! Heading with id %25block id=here%25@]%0a* %25pmhlt%25[@!! Heading with inline anchor [[#here]]@], or%0a* %25pmhlt%25[@!! [[#here]] Heading with inline anchor@]%0a* %25pmhlt%25[@[[#here]]@]\\%0a[@!! Anchor preceding the heading@]%0a%0aIf there is no identifier or anchor with a heading, then the anchor will be in the form @@%25blue%25#toc-1.2.1%25%25@@ where 1.2.1 is the structural path to the section, in this example "Section 1, subsection 2, sub-subsection 1".%0a%0a%0a!! Configuration [[#config]]%0aThe following local configuration (in @@local/config.php@@) can control the default settings:%0a%0a* %25hlt php%25[@$PmTOC['Enable'] = 1; @]@@# enable TOC and/or NH, default is disabled.@@%0a* %25hlt php%25[@$PmTOC['MaxLevel'] = 6; @]@@# heading levels included in the TOC@@ \\%0a by default %25hlt html%25[@%3ch1>@] to [@%3ch6>@] are included. Set to 3 to only include [@%3ch1>@] to [@%3ch3>@].%0a* %25hlt php%25[@$PmTOC['MinNumber'] = 3; @]@@# minimum number of headings in the page for the TOC to be generated.@@ \\%0a Pages with few headings are usually short and do not need a TOC. %0a** %25hlt php%25[@$PmTOC['MinNumber'] = 2; @]@@# pages with 2+ headings will have a TOC@@%0a** %25hlt php%25[@$PmTOC['MinNumber'] = 9999999; @]@@# the TOC will not be automatic, only the (:toc:) directive will create a table of contents in the page. @@%0a%0a* %25hlt php%25[@$PmTOC['NumberedHeadings'] = '1.1.1.1.1.1'; @]@@# the headings will be numbered (default disabled).@@%0a** You can set here the numerals for the different levels of headings, can be 1 (numeric), I or i (Roman numerals), A or a (letters A-Z or a-z). For example, a specification like \\%0a %25hlt php%25[@$PmTOC['NumberedHeadings'] = 'I.1.a'; @] \\%0a will number the biggest level headings on a page with uppercase Roman numerals (I, II, ...), the second biggest with numbers, the third with lowercase letters (a, b, ...), and the remaining levels (if any) with numbers.%0a** %25hlt php%25[@$PmTOC['MinNumber'] = 9999999; @]@@# only enable Numbered headings without creating a TOC. You still need to set $PmTOC['Enable'] = 1;@@%0a%0a* %25hlt php%25[@$PmTOC['EnableBacklinks'] = 1; @]@@# insert after the headings "↑" arrows linking back to the table of contents (default disabled).@@%0a* %25hlt php%25[@$PmTOC['ParentElement'] = "#wikitext"; @]@@# the query selector of the parent HTML element where the TOC block to be inserted@@ \\%0a by default the TOC is inserted before the first heading; here you can select a different element. If selected, the TOC will be inserted in the element at the top. The %25pmhlt%25[@(:toc:)@] directive in the page can override this element.%0a%0a!! Internationalization [[#i18n]]%0a%0aThe following strings can be translated in XLPage, for example in French:%0a%0a "Contents" => "Sommaire",%0a "show" => "afficher",%0a "hide" => "masquer",%0a %0a!! Styles [[#styles]]%0aIf you prefer to see the TOC on the right side, you may want to insert the following in your $PubDirUrl/css/local.css file:%0a%0a%25hlt css%25[@.PmTOCdiv {%0a float: right;%0a margin-left: 5px;%0a }@]%0a%0aYou can modify the table elements font size and maximum table height by defining in your $PubDirUrl/css/local.css file:%0a%0a%25hlt ccs%25[@.PmTOCdiv { %0a font-size: 15px; %0a max-height: 600px;%0a }@]%0a%0aThe default font size is 13px and the default maximum height is 500px, you can define own values. When the table height exceeds the max-height value, there is a scrollbar (overflow:auto).%0a%0aSee also: Cookbook:AutoTOC. If you previously used AutoTOC you need to disable it when enabling $PmTOC.%0a +time=1671297517 title=Table of contents blob - a20ef03b20eda72ddf4f71fa998311d6d1749791 blob + d2b2a2a0da8473dc1ced3e17e88f28daa2ee1b05 --- wikilib.d/PmWiki.Tables +++ wikilib.d/PmWiki.Tables @@ -1,10 +1,10 @@ -version=pmwiki-2.2.118 ordered=1 urlencoded=1 +version=pmwiki-2.3.13 ordered=1 urlencoded=1 author=Petko charset=UTF-8 -csum=Sortable tables [[#sortable]] +csum=Is there a simple way to change the table defaults? I prefer a border and I'm tired of adding it to (+357) ctime=1141945978 name=PmWiki.Tables -rev=81 +rev=108 targets=PmWiki.TableDirectives,Cookbook.RowspanInSimpleTables,Cookbook.FormattingTables,PmWiki.LayoutVariables,PmWiki.WikiStyles -text=(:Audience: authors (basic) :)%0a(:Summary:Simple tables with double pipe markup, one row per line:)%0a%0aPmWiki has two types of table markup; the markup described in this page is useful for creating ''simple'' tables with lots of small cells, while [[table directive markup->table directives]] helps with larger scale or more complex tables. For more possibilities with formatting simple tables, see [[Cookbook:Rowspan in simple tables]] and [[Cookbook:Formatting tables]].%0a%0a!! Table basics%0aSimple tables are created via use of double pipe characters: @@||@@. Lines beginning with this markup denote rows in a table or a formatting line. Within table row lines the double-pipe is used to delimit cells. In the examples below a border is added for illustration (the default is no border).%0a%0aThe first line in the markup contains formatting commands for the table. It only has double pipe characters at the start of the line.%0a%0a(:markup caption='Basic table' class=horiz:)%0a|| border=1%0a|| cell 1 || cell 2 || cell 3 ||%0a|| cell 1 || cell 2 ||%0a(:markupend:)%0a%0aHeader cells can be created by placing ! as the first character of a cell. Note that these are ''table headers'', not ''headings'', so it doesn't extend to !!, !!!, etc.%0a%0a(:markup caption='Table headers' class=horiz:)%0a|| border=1%0a||! cell 1 ||! cell 2 ||! cell 3 ||%0a|| cell 1 || cell 2 || cell 3 ||%0a(:markupend:)%0a%0aA table can have a caption, indicated by [@||!caption!||@]. Any caption must appear prior to other rows of the table.%0a%0a(:markup caption='Table caption' class=horiz:)%0a|| border=1%0a||! A special table !||%0a||! cell 1 ||! cell 2 ||! cell 3 ||%0a|| cell 1 || cell 2 || cell 3 ||%0a(:markupend:)%0a%0a%0a!! Formatting cell contents%0a%0aCell contents may be aligned left, centered, or aligned right. %0a* To left-align contents, place the cell contents next to the leading @@||@@.%0a* To center contents, add a space before and after the cell contents.%0a* To right-align contents, place a space before the cell contents and leave the cell contents next to the trailing @@||@@.%0a%0a(:markup caption='Cell alignments':)%0a|| border=1 width=100%25%0a||!cell 1 ||! cell 2 ||! cell 3||%0a||left-aligned || centered || right-aligned||%0a(:markupend:)%0a%0a(:markup caption='Default cell alignments':)%0a|| border=1 width=100%25%0a||!cell default||!cell left ||%0a||default-aligned||left-aligned ||%0a(:markupend:)%0a%0aNote that header and detail cells have different default alignments.%0a%0aTo get a cell to span multiple columns, follow the cell with empty cells.%0a(At present there is no markup for spanning rows.)%0a%0a(:markup caption='Column spanning':)%0a|| border=1 width=100%25%0a|| |||| right column ||%0a|| || right two columns ||||%0a|| || middle column || ||%0a|| left column || ||||%0a|| left two columns |||| ||%0a|| entire row ||||||%0a|| left column || middle column || right column ||%0a(:markupend:)%0a%0a!! Table attributes%0a%0aAny line that begins with [@||@] but doesn't have a closing [@||@] sets the ''table attributes'' for any tables that follow. These attributes can control the size and position of the table, borders, background color, and cell spacing. (In fact these are just standard HTML attributes that are placed in the %3ctable> tag.)%0a%0aUse the [@width=@] attribute to set a table's width, using either a percentage value, an absolute size, or '''*'''.%0a%0aSee also $SimpleTableDefaultClassName.%0a%0a(:markup caption='Table width':)%0a|| border=1 width=100%25 %0a|| cell 1 || cell 2 || cell 3 ||%0a|| c1 || cellcellcellcell2 || cell 3 ||%0a(:markupend:)%0a%0aThe [@border=@] attribute sets the size of a table's borders.%0a%0a(:markup caption='Bordered table' class=horiz:)%0a|| border=10 width=70%25%0a||!cell 1 ||! cell 2 ||! cell 3||%0a||left-aligned || centered || right-aligned||%0a(:markupend:)%0a%0a(:markup caption='Borderless table' class=horiz:)%0a|| border=0 width=70%25%0a||!cell 1 ||! cell 2 ||! cell 3||%0a||left-aligned || centered || right-aligned||%0a(:markupend:)%0a%0aUse [@align=center@], [@align=left@], and [@align=right@] to center, left, or right align a table. Note that [@align=left@] and [@align=right@] create a ''floating table'', such that text wraps around the table.%0a%0a(:markup caption='Table alignment: center':)%0a|| border=1 align=center width=50%25%0a||!cell 1 ||! cell 2 ||! cell 3||%0a||left-aligned || centered || right-aligned||%0aNotice how text does not wrap with a table using "align=center".%0a(:markupend:)%0a%0a(:markup caption='Table alignment: left':)%0a|| border=1 align=left width=50%25%0a||!cell 1 ||! cell 2 ||! cell 3||%0a||left-aligned || centered || right-aligned||%0aNotice how text wraps to the right of a table using "align=left".%0a(:markupend:)%0a%0a(:markup caption='Table alignment: right':)%0a|| border=1 align=right width=50%25%0a||!cell 1 ||! cell 2 ||! cell 3||%0a||left-aligned || centered || right-aligned||%0aNotice how text wraps to the left of a table using "align=right".%0a(:markupend:)%0a%0aNote: to get a table to align left (but not "float left") requires CSS, as in%0a->[@||style="margin-left:0px;"@]%0a%0aThe [@bgcolor=@] attribute sets the background color for a table. At present there is no way to specify the color of individual rows or cells in this type of table (but see Cookbook:FormattingTables).%0a%0a(:markup class=horiz:)%0a|| border=1 align=center bgcolor=yellow width=70%25%0a||!cell 1 ||! cell 2 ||! cell 3||%0a||left-align || center || right-align||%0a(:markupend:)%0a%0a!! Sortable tables [[#sortable]]%0aTo allow readers to reorder a table, give it the class="sortable" attribute:%0a(:markup:)%0a|| class="sortable simpletable"%0a||! m||!Geographic zone ||!Highest point ||!Country ||%0a|| 3700||Arctic ||Gunnbjørn Fjeld ||Greenland ||%0a|| 8848||North Temperate Zone ||Mount Everest ||Nepal ||%0a|| 5790||North Tropical Zone ||Cayambe ||Ecuador ||%0a|| 6768||South Tropical Zone ||Huáscarán ||Peru ||%0a|| 6960||South Temperate Zone ||Aconcagua ||Argentina ||%0a|| 4892||Antarctic ||Mount Vinson ||(none) ||%0a(:markupend:)%0a%0aNote: this feature has to be enabled in local configuration, see $EnableSortable.%0a%0a!! FAQ%0a>>faq%3c%3c [[#faq]]%0aQ: How do I create a basic table? %0aA: Tables are created via use of the double pipe character: @@||@@. Lines beginning with this markup denote rows in a table; within such lines the double-pipe is used to delimit cells. In the examples below a border is added for illustration (the default is no border).%0a%0a(:markup caption='Basic table' class=horiz:)%0a|| border=1 rules=rows frame=hsides%0a|| cell 1 || cell 2 || cell 3 ||%0a|| cell 1 || cell 2 || cell 3 ||%0a(:markupend:)%0a%0aQ: How do I create cell headers?%0aA: Header cells can be created by placing ! as the first character of a cell. Note that these are ''table headers'', not ''headings'', so it doesn't extend to !!, !!!, etc.%0a%0a(:markup caption='Table headers' class=horiz:)%0a|| border=1 rules=cols frame=vsides%0a||! cell 1 ||! cell 2 ||! cell 3 ||%0a|| cell 1 || cell 2 || cell 3 ||%0a(:markupend:)%0a%0aQ: How do I obtain a table with thin lines and more distance to the content?%0aA: "Thin lines" is tricky and browser dependent, but the following works for Firefox and IE (Nov. 2009):%0a%0a(:markup caption='Thin lines and cell padding' class=horiz:)%0a||border="1" style="border-collapse:collapse" cellpadding="5" width=66%25%0a||!Header ||! Header || '''Header'''||%0a||cells || with || padding||%0a|| || || ||%0a(:markupend:)%0a%0aQ: How do I create an advanced table? %0aA: See [[PmWiki.TableDirectives | table directives]]%0a%0aQ: My tables are by default centered. When I try to use '||align=left' they don't align left as expected. %0aA: Use ||style="margin-left:0px;" instead. %0a%0aQ: How can I specify the width of columns?%0aA: You can define the widths via custom styles, see Cookbook:FormattingTables and $TableCellAttrFmt. Add in config.php :%0a[@$TableCellAttrFmt = 'class=col$TableCellCount';@]%0a-> And add in pub/css/local.css : %0a[@%0atable.column td.col1 { width: 120px; }%0atable.column td.col3 { width: 40px; }%0a@]%0a%0aQ: How can I display a double pipe "||" in cell text using basic table markup?%0aA: Escape it with [@[=||=]@] to display || unchanged.%0a%0aQ: How do I apply styles to the elements of the table, like an ID to the table row, or a class/style to the TD?%0aA: See [[PmWiki/WikiStyles#WikiStyleApply | $WikiStyleApply]].%0a%0aAlternately, use [[table directives]], which allow specifying styling either directly (''style="..."'') or by a ''class="..."'' attribute for CSS. -time=1567372148 +text=(:Audience: authors (basic) :)%0a(:Summary:Simple tables with double pipe markup, one row per line:)%0a%0aPmWiki has two types of table markup; the markup described in this page is useful for creating ''simple'' tables with lots of small cells, while [[table directive markup->table directives]] helps with larger scale or more complex tables. For more possibilities with formatting simple tables, see [[Cookbook:Rowspan in simple tables]] and [[Cookbook:Formatting tables]].%0a%0a!! Table basics%0aSimple tables are created via use of double pipe characters: @@||@@. Lines beginning with this markup denote rows in a table or a formatting line. Within table row lines the double-pipe is used to delimit cells. In the examples below a border is added for illustration (the default is no border).%0a%0aThe first line in the markup (initial double bars "||") is required. After the double bars, there may be optional formatting commands for the table such as border or width.%0a%0a(:markup caption='Basic table' class=horiz:)%0a|| border=1%0a|| cell 1 || cell 2 || cell 3 ||%0a|| cell 1 || cell 2 ||%0a(:markupend:)%0a%0aHeader cells can be created by placing ! as the first character of a cell. Note that these are ''table headers'', not ''headings'', so it doesn't extend to !!, !!!, etc.%0a%0a(:markup caption='Table with borders and headers' class=horiz:)%0a|| border=1%0a||! cell 1 ||! cell 2 ||! cell 3 ||%0a|| cell 1 || cell 2 || cell 3 ||%0a(:markupend:)%0a%0aA table can have a caption, indicated by [@||!caption!||@]. Any caption must appear prior to other rows of the table.%0a%0a(:markup caption='Table caption' class=horiz:)%0a|| border=1%0a||! A special table !||%0a||! cell 1 ||! cell 2 ||! cell 3 ||%0a|| cell 1 || cell 2 || cell 3 ||%0a(:markupend:)%0a%0a%0a!! Formatting cell contents%0a%0aCell contents may be aligned left, centered, or aligned right. %0a* To left-align contents, place the cell contents next to the leading @@||@@.%0a* To center contents, add a space before and after the cell contents.%0a* To right-align contents, place a space before the cell contents and leave the cell contents next to the trailing @@||@@.%0a%0a(:markup caption='Cell alignments':)%0a|| border=1 width=100%25%0a||!cell 1 ||! cell 2 ||! cell 3||%0a||left-aligned || centered || right-aligned||%0a(:markupend:)%0a%0a(:markup caption='Default cell alignments':)%0a|| border=1 width=100%25%0a||!cell default||!cell left ||%0a||default-aligned||left-aligned ||%0a(:markupend:)%0a%0aNote that header and detail cells have different default alignments.%0a%0aTo get a cell to span multiple columns, follow the cell with empty cells.%0a(At present there is no markup for spanning rows.)%0a%0a(:markup caption='Column spanning':)%0a|| border=1 width=100%25%0a|| |||| right column ||%0a|| || right two columns ||||%0a|| || middle column || ||%0a|| left column || ||||%0a|| left two columns |||| ||%0a|| entire row ||||||%0a|| left column || middle column || right column ||%0a(:markupend:)%0a%0a!! Table attributes%0a%0aAny line that begins with [@||@] but doesn't have a closing [@||@] sets the ''table attributes'' for any tables that follow. These attributes can control the size and position of the table, borders, background color, and cell spacing. (In fact these are just standard HTML attributes that are placed in the %3ctable> tag.)%0a%0aUse the [@width=@] attribute to set a table's width, using either a percentage value, an absolute size, or '''*'''.%0a%0aSee also $SimpleTableDefaultClassName.%0a%0a(:markup caption='Table width':)%0a|| border=1 width=100%25 %0a|| cell 1 || cell 2 || cell 3 ||%0a|| c1 || cellcellcellcell2 || cell 3 ||%0a(:markupend:)%0a%0aThe [@border=@] attribute sets the size of a table's borders.%0a%0a(:markup caption='Bordered table' class=horiz:)%0a|| border=10 width=70%25%0a||!cell 1 ||! cell 2 ||! cell 3||%0a||left-aligned || centered || right-aligned||%0a(:markupend:)%0a%0a(:markup caption='Borderless table' class=horiz:)%0a|| border=0 width=70%25%0a||!cell 1 ||! cell 2 ||! cell 3||%0a||left-aligned || centered || right-aligned||%0a(:markupend:)%0a%0aUse [@align=center@], [@align=left@], and [@align=right@] to center, left, or right align a table. Note that [@align=left@] and [@align=right@] create a ''floating table'', such that text wraps around the table.%0a%0a(:markup caption='Table alignment: center':)%0a|| border=1 align=center width=50%25%0a||!cell 1 ||! cell 2 ||! cell 3||%0a||left-aligned || centered || right-aligned||%0aNotice how text does not wrap with a table using "align=center".%0a(:markupend:)%0a%0a(:markup caption='Table alignment: left':)%0a|| border=1 align=left width=50%25%0a||!cell 1 ||! cell 2 ||! cell 3||%0a||left-aligned || centered || right-aligned||%0aNotice how text wraps to the right of a table using "align=left".%0a(:markupend:)%0a%0a(:markup caption='Table alignment: right':)%0a|| border=1 align=right width=50%25%0a||!cell 1 ||! cell 2 ||! cell 3||%0a||left-aligned || centered || right-aligned||%0aNotice how text wraps to the left of a table using "align=right".%0a(:markupend:)%0a%0aNote: to get a table to align left (but not "float left") requires CSS, as in%0a->[@||style="margin-left:0px;"@]%0a%0aThe [@bgcolor=@] attribute sets the background color for a table. At present there is no way to specify the color of individual rows or cells in this type of table (but see Cookbook:FormattingTables).%0a%0a(:markup class=horiz:)%0a|| border=1 align=center bgcolor=yellow width=70%25%0a||!cell 1 ||! cell 2 ||! cell 3||%0a||left-align || center || right-align||%0a(:markupend:)%0a%0a!! Sortable tables [[#sortable]]%0aTo allow readers to reorder a table, give it the class="sortable" attribute:%0a(:markup:)%0a|| class="sortable simpletable"%0a||! m||!Geographic zone ||!Highest point ||!Country ||%0a|| 3700||Arctic ||Gunnbjørn Fjeld ||Greenland ||%0a|| 8848||North Temperate Zone ||Mount Everest ||Nepal ||%0a|| 5790||North Tropical Zone ||Cayambe ||Ecuador ||%0a|| 6768||South Tropical Zone ||Huáscarán ||Peru ||%0a|| 6960||South Temperate Zone ||Aconcagua ||Argentina ||%0a|| 4892||Antarctic ||Mount Vinson ||(none) ||%0a(:markupend:)%0a%0aNote: this feature has to be enabled in local configuration, see $EnableSortable.%0a%0a!! FAQ%0a>>faq%3c%3c [[#faq]]%0aQ: How do I create a basic table? %0aA: Tables are created via use of the double pipe character: @@||@@. Lines beginning with this markup denote rows in a table; within such lines the double-pipe is used to delimit cells. In the examples below a border is added for illustration (the default is no border).%0a%0a(:markup caption='Basic table' class=horiz:)%0a|| border=1 rules=rows frame=hsides%0a|| cell 1 || cell 2 || cell 3 ||%0a|| cell 1 || cell 2 || cell 3 ||%0a(:markupend:)%0a%0aQ: How do I create cell headers?%0aA: Header cells can be created by placing ! as the first character of a cell. Note that these are ''table headers'', not ''headings'', so it doesn't extend to !!, !!!, etc.%0a%0a(:markup caption='Table headers' class=horiz:)%0a|| border=1 rules=cols frame=vsides%0a||! cell 1 ||! cell 2 ||! cell 3 ||%0a|| cell 1 || cell 2 || cell 3 ||%0a(:markupend:)%0a%0aQ: How do I obtain a table with thin lines and more distance to the content?%0aA: "Thin lines" is tricky and browser dependent, but the following works for Firefox and IE (Nov. 2009):%0a%0a(:markup caption='Thin lines and cell padding' class=horiz:)%0a||border="1" style="border-collapse:collapse" cellpadding="5" width=66%25%0a||!Header ||! Header || '''Header'''||%0a||cells || with || padding||%0a|| || || ||%0a(:markupend:)%0a%0aQ: How do I create an advanced table? %0aA: See [[PmWiki.TableDirectives | table directives]]%0a%0aQ: My tables are by default centered. When I try to use '||align=left' they don't align left as expected. %0aA: Use ||style="margin-left:0px;" instead. %0a%0aQ: How can I specify the width of columns?%0aA: You can define the widths via custom styles, see Cookbook:FormattingTables and $TableCellAttrFmt. Add in config.php :%0a[@$TableCellAttrFmt = 'class=col$TableCellCount';@]%0a-> And add in pub/css/local.css : %0a[@%0atable.column td.col1 { width: 120px; }%0atable.column td.col3 { width: 40px; }%0a@]%0a%0aQ: How can I display a double pipe "||" in cell text using basic table markup?%0aA: Escape it with [@[=||=]@] to display || unchanged.%0a%0aQ: How do I apply styles to the elements of the table, like an ID to the table row, or a class/style to the TD?%0aA: See [[PmWiki/WikiStyles#WikiStyleApply | $WikiStyleApply]].%0a%0aAlternately, use [[table directives]], which allow specifying styling either directly (''style="..."'') or by a ''class="..."'' attribute for CSS.%0a%0aQ: Is there a simple way to change the table defaults? I prefer a border and I'm tired of adding it to every table.%0aA: You can set %25hlt php%25 @@$SimpleTableDefaultClassName = 'simpletable';@@ and/or define your own styles in your stylesheet. The "simpletable" class is available in the core skins, and can be redefined or overridden in pub/css/local.css.%0a +time=1666461766 blob - 212a102df67957ca137765ff15bdabae75ed8070 blob + a0aa810238486228b4a0b29c4fb97bfc153ff13e --- wikilib.d/PmWiki.TextFormattingRules +++ wikilib.d/PmWiki.TextFormattingRules @@ -1,10 +1,10 @@ -version=pmwiki-2.2.129 ordered=1 urlencoded=1 +version=pmwiki-2.3.2 ordered=1 urlencoded=1 author=simon charset=UTF-8 -csum=typo (+0) +csum=pm hlt (+127) name=PmWiki.TextFormattingRules post= Save -rev=557 +rev=561 targets=Main.WikiSandbox,Cookbook.MarkupTricks,PmWiki.ListStyles,Cookbook.WikiStylesPlus,PmWiki.PageTextVariables,PmWiki.PageLists,PmWiki.BasicVariables,PmWiki.WikiStyles,PmWiki.WikiWord,PmWiki.Links,Cookbook.NumberedHeaders,PmWiki.EditVariables,PmWiki.Tables,PmWiki.TableDirectives,PmWiki.MarkupMasterIndex -text=(:Summary: A list of some of the markup sequences available:) %0aThis page provides a more complete list of some of the markup sequences available in PmWiki. %0aNote that it's easy to create and edit pages without using any of the markups below, but ''if'' you ever need them, they're here. %0a%0aTo experiment with the rules, please edit the [[Main/Wiki Sandbox]].%0a----%0a%0a!! [[#Paragraphs]] Paragraphs%0a%0aTo create paragraphs, simply enter text. Use a blank line to start a new paragraph.%0a%0aWords on two lines in a row will '''wrap and fill''' as needed (the normal XHTML behavior). To turn off the automatic filling, use the [@(:linebreaks:)@] directive above the paragraph.%0a%0a* Use [@\@] (single backslash) at the end of a line to join the current line to the next one.%0a* Use [@\\@] (two backslashes) at the end of a line to force a line break.%0a* Use [@\\\@] (three backslashes) at the end of a line to force 2 line breaks, n backslashes will force n-1 line breaks%0a* Use [@[[%3c%3c]]@] to force a line break that will clear floating elements both left and right.%0a%0a%0a!! [[#IndentedParagraphs]] Indented Paragraphs ''(Quotes)''%0a%0aArrows ([@->@]) at the beginning of a paragraph can be used to produce an indented paragraph. More hyphens at the beginning ([@--->@]) produce larger indents.%0a%0a(:markup:)%0a->Four score and seven years ago our fathers placed upon this continent a new nation, conceived in liberty and dedicated to the proposition that all men are created equal.%0a(:markupend:)%0a%0aInverted Arrows ([@-%3c@]) at the beginning of a paragraph can be used to produce a paragraph with a hanging indent. Adding hyphens at the beginning ([@---%3c@]) causes all the text to indent.%0a%0a(:markup:)%0a-%3cFour score and seven years ago our fathers placed upon this continent a new nation, conceived in liberty and dedicated to the proposition that all men are created equal. %0a(:markupend:)%0a%0a(:markup:)%0a--%3cFour score and seven years ago our fathers placed upon this continent a new nation, conceived in liberty and dedicated to the proposition that all men are created equal. And that food would be good too.%0a(:markupend:)%0a%0aBlocks of text to which [@(:linebreaks:)@] has been applied can be indented by preceding the first line of the block with indention arrows ([@->@]) and aligning subsequent lines under the first. An unindented line stops the block indentation. See [[Cookbook:Markup Tricks]] for an example.%0a%0a%0a!! [[#BulletedLists]] Bulleted and Numbered Lists%0a%0aBullet lists are made by placing asterisks at the beginning of the line. Numbered lists are made by placing number-signs (#) at the beginning of the line. More asterisks/number-signs increases the level of bullet:%0a%0a(:markup:) %0a* First-level list item%0a** Second-level list item%0a### Order this%0a#### And this (optional)%0a### Then this%0a** Another second-level item%0a* A first-level item: cooking%0a## Prepare the experiment%0a### Unwrap the pop-tart%0a### Insert the pop-tart into the toaster%0a## Begin cooking the pop tart%0a## Stand back%0a(:markupend:)%0a%0a(:markup:)%0a# A list is terminated%0aby the first line that is not a list.%0a# Also terminate a list using the escape sequence [@[==]@]%0a[==]%0a# Continue a list item by lining%0a up the text with leading whitespace.%0a# Use a forced linebreak \\%0a to force a newline in your list item.%0a(:markupend:)%0a%0a(:markup:)%0a## Text between list items can cause numbering to restart%0a## %25item value=3%25 this can be dealt with%0a(:markupend:)%0a%0aAlso see: [[PmWiki:ListStyles]], [[Cookbook:WikiStylesPlus]].%0a%0a%0a!! [[#DefinitionLists]] Definition Lists%0a>>rframe%3c%3c%0a'''Powerful new%25red%25*%25%25 feature'''\\%0aWhen you define terms using this markup\\%0aPmWiki will recognize them as [[PageTextVariables]]\\%0athat you can use on any page or [[PageList(s)]].\\%0a[-%25red%25* Added%25%25 in PmWiki version %25red%252.2.0%25%25-]%0a>>%3c%3c%0aDefinition lists are made by placing colons at the left margin (and between each term and definition):%0a%0a(:markup:)%0a:term:definition of term%0a(:markupend:)%0a%0a[[#WhitespaceRules]]%0a!! Whitespace Rules%0a%0aWhitespace indentation in lists. Any line that begins with whitespace ''and aligns'' with a previous list item (whether bulleted, numbers or definitional) is considered to be "within" that list item. Text folds and wraps as normal, and the [@(:linebreaks:)@] directive is honored. %0a%0a(:markup:) %0a# First-level item\\%0a Whitespace used to continue item on a new line%0a# Another first-level item%0a # Whitespace combined with a single # to create a new item one level deeper%0a(:markupend:)%0a%0aThis rule also apply on definition lists, but only the number of leading colons is significant for the following whitespace indented lines.%0a%0a(:markup:)%0a:Item: Definition text%0a dispatched on several%0a lines%0a::SubItem: Same kind%0a of multiline%0a definition%0a(:markupend:)%0a%0aOtherwise, lines that begin with whitespace are treated as ''preformatted text'', using a monospace font and not generating linebreaks except where explicitly indicated in the markup. Note to administrators: Starting with version 2.2.0-beta41, this feature can be modified using $EnableWSPre. (Another way to create preformatted text blocks is by using the [=[@...@]=] markup.)%0a%0a!! [[#HorizontalLine]] Horizontal Line%0a%0aFour or more dashes ([=----=]) at the beginning of a line produce a horizontal line.%0a%0a[[#Emphasis]]%0a!! Emphasis and character formatting%0a%0a* Enclose text in doubled single-quotes ([=''text''=]), i.e., ''two apostrophes'', for emphasis (usually ''italics'')%0a* Enclose text in tripled single-quotes ([='''text'''=]), i.e. ''three apostrophes'', for strong (usually '''bold''')%0a* Enclose text in five single-quotes ([='''''text'''''=]), or triples within doubles (''five apostrophes''), for strong emphasis (usually '''''bold italics''''')%0a* Enclose text in doubled at-signs ([=@@text@@=]) for @@monospace@@ text%0a* Use [=[+large+]=] for [+large+] text, [=[++larger++]=] for [++larger++], [=[-small-]=] for [-small-] text, and [=[--smaller--]=] for [--smaller--].%0a* Emphasis can be used multiple times within a line, but cannot span across markup line boundaries (i.e., you can't put a paragraph break in the middle of bold text).%0a* [='~italic~'=] and [='*bold*'=] are available if enabled in config.php%0a%0aOther styling %0a(:markup:)%0a'+big+', '-small-', '^super^', '_sub_', %0a%0a{+insert or underscore+}, %0a%0a{-delete or strikethrough or strikeout-}%0a(:markupend:)%0a* [@`WikiWord@] `WikiWord neutralisation%0a%0aSee also [[Wiki Styles]] for advanced text formatting options.%0a%0a[[#References]]%0a!! Links / References%0a%0a* Use words and phrases in double brackets (e.g., [=[[text formatting rules]]=]) to create links to other pages on this wiki.%0a* On some PmWiki installations, capitalized words joined together (e.g., [[WikiWord]]s) can also be used to make references to other pages without needing the double-brackets.%0a* Precede [=URLs=] with "@@http:@@", "@@ftp:@@", "@@gopher:@@", "@@mailto:@@", or "@@news:@@" to create links automatically, as in http://www.pmichaud.com/toast.%0a* [=URLs=] ending with @@.gif@@, @@.jpg@@, or @@.png@@ are displayed as images in the page%0a* Links with arbitrary text can be created as either [=[[=]''target'' | ''text'']] or [=[[=]''text'' -> ''target''[=]]=]. ''Text'' can be an image URL, in which case the image becomes the link to the remote ''url'' or ''[[WikiWord]]''.%0a* [[#Anchors]] Anchor targets within pages (#-links) can be created using @@[=[[#target]]=]@@.%0a* to have any special characters, including quotes, spaces, parentheses and pipes in link addresses escape them using [@[=link address=]@]%0aSee [[Links]] for details.%0a%0a[[#Headings]]%0a!!Headings%0a%0aHeadings are made by placing an exclamation mark ('''!''') at the left margin. More exclamation marks increase the level of heading. For example,%0a%0a(:markup:)%0a!! Level 2 Heading%0a!!! Level 3 Heading%0a!!!! Level 4 Heading%0a!!!!! Level 5 Heading%0a(:markupend:)%0a%0aNote that level 1 heading is already used as page title (at least in the PmWiki skin), so you should start with level 2 headings to create well formed, search engine optimized web pages.%0a%0aSee [[Cookbook:Numbered Headers]] for numbered headings.%0a%0a[[#EscapeSequence]]%0a!!Escape sequences%0a%0aAnything placed between [=[= and =]=] is not interpreted by PmWiki, but paragraphs are reformatted. This makes it possible to turn off special formatting interpretations and neutralise [=WikiWords=] that are not links (even easier is to use a tick ` in front, like [=`WikiWord=]). \\%0aThis is useful to allow for escaped [@[=link address=]@] to have any special characters, including quotes, spaces, parentheses and pipes.%0a%0aFor preformatted text blocks, use the [=[@...@]=] markup. It does neither reformat paragraphs nor process wiki markup:%0a%0a(:markup:)%0a[@%0aCode goes here like [[PmWiki.PmWiki]]%0a'$CurrentTime $[by] $AuthorLink: [=$ChangeSummary=]'; #just some code%0a@]%0a(:markupend:)%0a%0aThe multiline @@[=[@...@]=]@@ is a block markup, and in order to change the styling of these preformatted text blocks, you need to apply a "block" WikiStyle.%0a%0a(:markup:)[=%25block blue%25[@ %0a The font color of %0a this text is blue%0a@]=]%0a%0aIt is also useful to use [@[= =]@] within other wiki structures, as this enables the inclusion of new lines in text values. The example below shows how to include a multi-line value in a hidden form field.%0a%0a->[@(:input hidden message "[=Line1%0aLine2=]":)@]%0a%0aNote that "Replace on save" and "Replace on edit" patterns like [@~~@][@~~@] can replace strings even within escape sequences, use $EnableROSEscape to control that.%0a%0a!! Comments%0a[@ (:comment Some information:) @] can be very kind to subsequent authors, especially around complicated bits of markup.%0a%0a[[#SpecialCharacters]]%0a!! Special Characters%0a(:include SpecialCharacters:)%0a%0a[[#Tables]]%0a!! Tables%0a%0a[[Tables]] are defined by enclosing cells with '||'. %0aA cell with leading and trailing spaces is centered; a cell with leading spaces is right-aligned; all other cells are left-aligned. An empty cell will cause the previous cell to span multiple columns. (There is currently no mechanism for spanning multiple rows.) A line beginning with '||' specifies the table attributes for subsequent tables. A '!' as the first character in a cell provides emphasis that can be used to provide headings.%0a%0a(:markup:)%0a||border=1 width=50%25%0a||!Table||!Heading||!Example||%0a||!Left || Center || Right||%0a||A ||! a B || C||%0a|| || single || ||%0a|| || multi span ||||%0a(:markupend:)%0a%0aSee [[Table Directives]] for advanced tables.%0a%0a!!!Can't find it here?%0aSee [[Markup Master Index]].%0a -time=1590307653 +text=(:Summary: A list of some of the markup sequences available:) %0aThis page provides a more complete list of some of the markup sequences available in PmWiki. %0aNote that it's easy to create and edit pages without using any of the markups below, but ''if'' you ever need them, they're here. %0a%0aTo experiment with the rules, please edit the [[Main/Wiki Sandbox]].%0a----%0a%0a!! [[#Paragraphs]] Paragraphs%0a%0aTo create paragraphs, simply enter text. Use a blank line to start a new paragraph.%0a%0aWords on two lines in a row will '''wrap and fill''' as needed (the normal XHTML behavior). To turn off the automatic filling, use the %25pmhlt%25[@(:linebreaks:)@] directive above the paragraph.%0a%0a* Use %25pmhlt%25[@\@] (single backslash) at the end of a line to join the current line to the next one.%0a* Use %25pmhlt%25[@\\@] (two backslashes) at the end of a line to force a line break.%0a* Use %25pmhlt%25[@\\\@] (three backslashes) at the end of a line to force 2 line breaks, n backslashes will force n-1 line breaks%0a* Use %25pmhlt%25[@[[%3c%3c]]@] to force a line break that will clear floating elements both left and right.%0a%0a%0a!! [[#IndentedParagraphs]] Indented Paragraphs ''(Quotes)''%0a%0aArrows (%25pmhlt%25[@->@]) at the beginning of a paragraph can be used to produce an indented paragraph. More hyphens at the beginning (%25pmhlt%25[@--->@]) produce larger indents.%0a%0a%25define=narrow width=30em max-width=100pct%25%0a>>narrow%3c%3c%0a(:markup:)%0a->Four score and seven years ago our fathers placed upon this continent a new nation, conceived in liberty and dedicated to the proposition that all men are created equal.%0a(:markupend:)%0a>>%3c%3c%0a%0aInverted Arrows (%25pmhlt%25[@-%3c@]) at the beginning of a paragraph can be used to produce a paragraph with a hanging indent. Adding hyphens at the beginning (%25pmhlt%25[@---%3c@]) causes all the text to indent.%0a%0a>>narrow%3c%3c%0a(:markup:)%0a-%3cFour score and seven years ago our fathers placed upon this continent a new nation, conceived in liberty and dedicated to the proposition that all men are created equal. %0a(:markupend:)%0a%0a(:markup:)%0a--%3cFour score and seven years ago our fathers placed upon this continent a new nation, conceived in liberty and dedicated to the proposition that all men are created equal.%0a(:markupend:)%0a>>%3c%3c%0a%0aBlocks of text to which %25pmhlt%25[@(:linebreaks:)@] has been applied can be indented by preceding the first line of the block with indention arrows (%25pmhlt%25[@->@]) and aligning subsequent lines under the first. An unindented line stops the block indentation. See [[Cookbook:Markup Tricks]] for an example.%0a%0a%0a!! [[#BulletedLists]] Bulleted and Numbered Lists%0a%0aBullet lists are made by placing asterisks at the beginning of the line. Numbered lists are made by placing number-signs (%25pmhlt%25[@#@]) at the beginning of the line. More asterisks/number-signs increases the level of bullet:%0a%0a(:markup:) %0a* First-level list item%0a** Second-level list item%0a### Order this%0a#### And this (optional)%0a### Then this%0a** Another second-level item%0a* A first-level item: cooking%0a## Prepare the experiment%0a### Unwrap the pop-tart%0a### Insert the pop-tart into the toaster%0a## Begin cooking the pop tart%0a## Stand back%0a(:markupend:)%0a%0a(:markup:)%0a# A list is terminated%0aby the first line that is not a list.%0a# Also terminate a list using the escape sequence [@[==]@]%0a[==]%0a# Continue a list item by lining%0a up the text with leading whitespace.%0a# Use a forced linebreak \\%0a to force a newline in your list item.%0a(:markupend:)%0a%0a(:markup:)%0a## Text between list items can cause numbering to restart%0a## %25item value=3%25 this can be dealt with%0a(:markupend:)%0a%0aAlso see: [[PmWiki:ListStyles]], [[Cookbook:WikiStylesPlus]].%0a%0a%0a!! [[#DefinitionLists]] Definition Lists%0a%0aDefinition lists are made by placing colons at the left margin (and between each term and definition).%0aWhen you define terms using this markup%0aPmWiki will recognize them as [[PageTextVariables]]%0athat you can use on any page or [[PageList(s)]].%0a(:markup:)%0a:term:definition of term%0a(:markupend:)%0a%0a[[#WhitespaceRules]]%0a!! Whitespace Rules%0a%0aWhitespace indentation in lists. Any line that begins with whitespace ''and aligns'' with a previous list item (whether bulleted, numbers or definitional) is considered to be "within" that list item. Text folds and wraps as normal, and the %25pmhlt%25[@(:linebreaks:)@] directive is honored. %0a%0a%0a(:markup:) %0a# First-level item\\%0a Whitespace used to continue item on a new line%0a# Another first-level item%0a # Whitespace combined with a single # to create a new item one level deeper%0a(:markupend:)%0a%0aThis rule also apply on definition lists, but only the number of leading colons is significant for the following whitespace indented lines.%0a%0a(:markup:)%0a:Item: Definition text%0a dispatched on several%0a lines%0a::SubItem: Same kind%0a of multiline%0a definition%0a(:markupend:)%0a%0aOtherwise, lines that begin with whitespace are treated as ''preformatted text'', using a monospace font and not generating linebreaks except where explicitly indicated in the markup. Note to administrators: Starting with version 2.2.0-beta41, this feature can be modified using $EnableWSPre. (Another way to create preformatted text blocks is by using the %25pmhlt%25[=[@...@]=] markup.)%0a%0a!! [[#HorizontalLine]] Horizontal Line%0a%0aFour or more dashes (%25pmhlt%25[@----@]) at the beginning of a line produce a horizontal line.%0a%0a[[#Emphasis]]%0a!! Emphasis and character formatting%0a%0a* Enclose text in doubled single-quotes (%25pmhlt%25[@''text''@]), i.e., ''two apostrophes'', for emphasis (usually ''italics'')%0a* Enclose text in tripled single-quotes (%25pmhlt%25[@'''text'''@]), i.e. ''three apostrophes'', for strong (usually '''bold''')%0a* Enclose text in five single-quotes (%25pmhlt%25[@'''''text'''''@]), or triples within doubles (''five apostrophes''), for strong emphasis (usually '''''bold italics''''')%0a* Enclose text in doubled at-signs (%25pmhlt%25[@@@text@@@]) for @@monospace@@ text%0a* Use %25pmhlt%25[@[+large+]@] for [+large+] text, [@[++larger++]@] for [++larger++], [@[-small-]@] for [-small-] text, and [@[--smaller--]@] for [--smaller--].%0a* Emphasis can be used multiple times within a line, but cannot span across markup line boundaries (i.e., you can't put a paragraph break in the middle of bold text).%0a* %25pmhlt%25[@'~italic~'@] and [@'*bold*'@] are available if enabled in @@config.php@@%0a%0aOther styling %0a(:markup:)%0a'+big+', '-small-', '^super^', '_sub_', %0a%0a{+insert or underscore+}, %0a%0a{-delete or strikethrough or strikeout-}%0a(:markupend:)%0a* %25pmhlt%25[@`WikiWord@] `WikiWord neutralisation%0a%0aSee also [[Wiki Styles]] for advanced text formatting options.%0a%0a[[#References]]%0a!! Links / References%0a%0a* Use words and phrases in double brackets (e.g., %25pmhlt%25[@[[text formatting rules]]@]) to create links to other pages on this wiki.%0a* On some PmWiki installations, capitalized words joined together (e.g., [[WikiWord]]s) can also be used to make references to other pages without needing the double-brackets.%0a* Precede [=URLs=] with "@@http:@@", "@@ftp:@@", "@@gopher:@@", "@@mailto:@@", or "@@news:@@" to create links automatically, as in http://www.pmichaud.com/toast.%0a* [=URLs=] ending with @@.gif@@, @@.jpg@@, or @@.png@@ are displayed as images in the page%0a* Links with arbitrary text can be created as either %25pmhlt%25[@target | text]]@] or [@[[text -> target]]@]. ''Text'' can be an image URL, in which case the image becomes the link to the remote ''url'' or ''[[WikiWord]]''.%0a* [[#Anchors]] Anchor targets within pages (#-links) can be created using %25pmhlt%25[@[[#target]]@].%0a* to have any special characters, including quotes, spaces, parentheses and pipes in link addresses escape them using %25pmhlt%25[@[=link address=]@]%0aSee [[Links]] for details.%0a%0a[[#Headings]]%0a!!Headings%0a%0aHeadings are made by placing an exclamation mark ('''!''') at the left margin. More exclamation marks increase the level of heading. For example,%0a%0a(:markup:)%0a!! Level 2 Heading%0a!!! Level 3 Heading%0a!!!! Level 4 Heading%0a!!!!! Level 5 Heading%0a(:markupend:)%0a%0aNote that level 1 heading is already used as page title (at least in the PmWiki skin), so you should start with level 2 headings to create well formed, search engine optimized web pages.%0a%0aSee [[Cookbook:Numbered Headers]] for numbered headings.%0a%0a[[#EscapeSequence]]%0a!!Escape sequences%0a%0aAnything placed between %25pmhlt%25[@[= and =]@] is not interpreted by PmWiki, but paragraphs are reformatted. This makes it possible to turn off special formatting interpretations and neutralise [=WikiWords=] that are not links (even easier is to use a tick ` in front, like %25pmhlt%25[@`WikiWord@]). \\%0aThis is useful to allow for escaped %25pmhlt%25[@[=link address=]@] to have any special characters, including quotes, spaces, parentheses and pipes.%0a%0aFor preformatted text blocks, use the %25pmhlt%25[=[@...@]=] markup. It does neither reformat paragraphs nor process wiki markup:%0a%0a(:markup:)%0a[@%0aCode goes here like [[PmWiki.PmWiki]]%0a'$CurrentTime $[by] $AuthorLink: [=$ChangeSummary=]'; #just some code%0a@]%0a(:markupend:)%0a%0aThe multiline @@[=[@...@]=]@@ is a block markup, and in order to change the styling of these preformatted text blocks, you need to apply a "block" WikiStyle.%0a%0a(:markup:)[=%25block blue%25[@ %0a The font color of %0a this text is blue%0a@]=]%0a%0aIt is also useful to use %25pmhlt%25[@[= =]@] within other wiki structures, as this enables the inclusion of new lines in text values. The example below shows how to include a multi-line value in a hidden form field.%0a%0a->%25pmhlt%25[@(:input hidden message "[=Line1%0aLine2=]":)@]%0a%0aNote that "Replace on save" and "Replace on edit" patterns like %25pmhlt%25[@~~@][@~~@] can replace strings even within escape sequences, use $EnableROSEscape to control that.%0a%0a!! Comments%0a%25pmhlt%25[@ (:comment Some information:) @] can be very kind to subsequent authors, especially around complicated bits of markup.%0a%0a[[#SpecialCharacters]]%0a!! Special Characters%0a(:include SpecialCharacters:)%0a%0a[[#Tables]]%0a!! Tables%0a%0a[[Tables]] are defined by enclosing cells with '%25pmhlt%25[@||@]'. %0aA cell with leading and trailing spaces is centered; a cell with leading spaces is right-aligned; all other cells are left-aligned. An empty cell will cause the previous cell to span multiple columns. (There is currently no mechanism for spanning multiple rows.) A line beginning with '[@||@]' specifies the table attributes for subsequent tables. A '!' as the first character in a cell provides emphasis that can be used to provide headings.%0a%0a(:markup:)%0a||border=1 width=50%25%0a||!Table ||!Heading||!Example||%0a||!Left || Center || Right||%0a||A ||! a B || C||%0a|| || single || ||%0a|| || multi span ||||%0a(:markupend:)%0a%0aSee [[Table Directives]] for advanced tables.%0a%0a!!!Can't find it here?%0aSee [[Markup Master Index]].%0a +time=1647244348 blob - ea1375b4949494b3b4bf0065df5f0d19b88aa58b blob + 2611ed0abddf31739673a5159792ec6ec06d8c8d --- wikilib.d/PmWiki.Troubleshooting +++ wikilib.d/PmWiki.Troubleshooting @@ -1,9 +1,9 @@ -version=pmwiki-2.2.129 ordered=1 urlencoded=1 +version=pmwiki-2.3.13 ordered=1 urlencoded=1 author=Petko charset=UTF-8 -csum=category link (+8) +csum=add #obsolete (+539) name=PmWiki.Troubleshooting -rev=157 -targets=PmWiki.HowToGetAssistance,PmWiki.MailingLists,PmWiki.Questions,PITS.PITS,PmWiki.CustomMarkup,PmWiki.Functions,PmWiki.Upgrades,Cookbook.Cookbook,PmWiki.CustomPagelistSortOrder,Cookbook.PccfToPcfOverride,PmWiki.DebugVariables,PmWiki.SecurityVariables,PmWiki.FilePermissions,PmWiki.Installation,PmWiki.InitialSetupTasks,PmWiki.BasicVariables,PmWiki.WikiGroup,PmWiki.LocalCustomizations,PmWiki.UploadsAdmin,PmWiki.Tables,PmWiki.LayoutVariables -text=(:Summary:Advice for troubleshooting an installation, keywords: deprecated, preg_replace, crypt, blank pages, headers, .flock, upgrade, create_function:)%0a(:Audience: administrators :)%0a%0aPmWiki is pretty robust and can automatically adapt to a very wide variety of environments. %0aHowever, sometimes things don't go as we expect, so we're cataloging common errors and their fixes here.%0a%0a!! Troubleshooting Frequently Asked Questions%0a%0a->%25note%25 Note: This page on pmwiki.org is probably not the best place to post questions. Consider [[PmWiki:HowToGetAssistance | seeking assistance]] from the pmwiki-users [[mailing list(s)]], or post your question on the [[PmWiki:Questions]] page.%0a%0a>>faq%3c%3c [[#faq]]%0a%0a[[#track-errors]]%0aQ: How to track errors and know if they come from the PmWiki core or from a local configuration or addon/recipe?%0a%0aA: The PHP programming language has recently deprecated or removed a number of functions that were heavily used in the past by PmWiki and many addons/recipes/skins. The PmWiki core no longer relies on these functions but some addons still do -- here is how to track these.%0a%0aA: The PmWiki architecture allows addons (recipes, skins) and local configuration to register actions to be performed by PmWiki at a later point of the process. That's why the PHP warning may indicate a line in pmwiki.php, even if this was caused by a recipe. %0a%0aA: It is recommended to get the latest versions of PmWiki and all your addons -- known bugs would have been fixed. This assumes the errors appear with the latest versions.%0a%0aA: (1) First disable or comment out all addons and local configuration (config.php, farmconfig.php, Group.php) and test your wiki. If the warning persists, please notify us ASAP with some information on how to reproduce the bug and on your installation (PHP version). If the error doesn't appear, go to (2).%0a%0aA: (2) Enable one local configuration or one addon and test your wiki to see if the error appears.%0a%0aA: (3) If the error doesn't appear, the problem is likely elsewhere. If you have more addons to enable, go back to (2).%0a%0aA: (4) If the error appears, it was likely caused by the last configuration or addon that you enabled. Search the documentation and the cookbook for more recent versions, or contact the addon maintainer, or leave a message on the talk page. If that doesn't work, contact us at [[PITS:PITS|our issue trackig system]]. Developers can find documentation on how to update old addons at [[CustomMarkup]] and [[Functions]].%0a%0aA: (5) Disable again the faulty addon and if you have more addons to enable, go back to (2).%0a%0aA: PmWiki has a friendly and reactive community and we may be able to quickly provide fixes.%0a%0a%0a[[#create_function]]%0aQ: My wiki displays warnings "Deprecated: Function create_function() is deprecated".%0a%0aA: PHP version 7.2 deprecated a function which PmWiki used for markup definitions and pattern replacements. It is recommended to [[upgrades|upgrade]] to the latest PmWiki version and update all addons and skins from the [[Cookbook/]]. Addons in the [[https://www.pmwiki.org/wiki/Category/PHP72|PHP 7.2]] category are reported to be compatible with PHP 7.2. If you need a specific addon that has not yet been updated please contact us. To update your own addons, you probably need to update your calls to Markup(), see the pages [[Custom markup]], [[Functions]] and [[(PmWiki:)CustomPagelistSortOrder]].%0a%0aA: The recipe [[(Cookbook:)PccfToPcfOverride]] may provide a temporary solution until you can update all your add-ons.%0a%0aA: Note that PmWiki itself doesn't use that function, but (older) addons can register instructions to be processed at a later point. That's why the warning reports a line in pmwiki.php, even if it was requested by a local configuration or an addon.%0a%0aA: How to track down the addons that cause the warnings, see the [[#track-errors|first section]].%0a%0aQ: [[#deprecated]] [[#preg_replace]] My wiki displays warnings "Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead".%0aA: This is caused by a change in PHP version 5.5 for the [[http://php.net/preg_replace|preg_replace()]] function. PmWiki no longer relies on the deprecated feature since version 2.2.56 (it is recommended to upgrade to the latest version) but many recipes do. %0a%0aA: Note that PmWiki itself doesn't use that function, but (older) addons can register instructions to be processed at a later point. That's why the warning reports a line in pmwiki.php, even if it was requested by a local configuration or an addon.%0a%0aA: Recipes and Skins are currently being updated for [[https://www.pmwiki.org/wiki/Category/PHP55|PHP 5.5]]. Check if there are more recent versions published by their maintainers on the [[(Cookbook:)Cookbook]]. If you update your PmWiki and recipes, and still see the warnings, here is how to find out which recipes cause them:%0a%0aA: For PmWiki version 2.2.71 or newer, in config.php, enable diagnostic tools: \\%0a@@$EnableDiag = 1;@@\\%0aThen visit your wiki with the action 'ruleset', for example http://www.pmwiki.org/wiki/PmWiki/PmWiki?action=ruleset or follow a link like [@[[HomePage?action=ruleset]]@]. This page will list all markup rules; those potentially incompatible with PHP 5.5 will be flagged with filenames, line numbers and search patterns triggering the warning.%0a%0aA: If the ?action=ruleset page shows no flagged rules, it is possible that either your recipes call the preg_replace() function directly, or they define various search-replace patterns in incompatible ways. In these cases, your warning should display the file name and line number causing problems. Otherwise, to track down the addons that cause the warnings, see the [[#track-errors|first section]].%0a%0aA: Note that many hosting providers allow you to run different versions of PHP. See the documentation of your hosting plan to learn how to enable a PHP version earlier than 5.5.%0a%0aA: Finally, it is possible to suppress these warnings in PHP 5.5, by setting this line at the beginning of config.php: \\%0a@@error_reporting(E_ALL & ~E_NOTICE & ~E_DEPRECATED);@@\\%0aThis should be a temporary solution, left only until your recipes are fixed.%0a%0aA: See categories [[https://www.pmwiki.org/wiki/Category/PHP55|PHP 5.5]], [[https://www.pmwiki.org/wiki/Category/PHP72|PHP 7.2]], [[https://www.pmwiki.org/wiki/Category/PHP74|PHP 7.4]].%0a%0a[[#crypt]]%0aQ: My wiki displays warnings "PHP Deprecated: crypt(): Supplied salt is not valid for DES. Possible bug in provided salt format".%0aA: You probably have configuration settings that worked on older PHP versions. Here is how to hunt and try to fix this.%0a%0aA: In your (farm)config.php or other local or cookbook files, any call to @@crypt@@ can be replaced with @@pmcrypt@@, eg \\%0a@@$DefaultPasswords['edit'] = crypt("my_password");@@ # %25red%25DEPRECATED%25%25\\%0a@@$DefaultPasswords['edit'] = '''pmcrypt'''("my_password");@@ # %25green%25OK%25%25\\%0a@@$DefaultPasswords['edit'] = array('''pmcrypt'''("pass1"), '''pmcrypt'''("pass2"));@@ # %25green%25OK%25%25%0a%0aA: Additionally, if there are locked passwords with a star @@*@@, you should replace those with [@@lock@]: \\%0a@@$DefaultPasswords['edit'] = '*';@@ # %25red%25DEPRECATED%25%25\\%0a@@$DefaultPasswords['edit'] = '@lock';@@ # %25green%25OK%25%25 (and no pmcrypt)%0a%0aA: The $DefaultPasswords variables usually have keys like 'edit', 'attr', 'read', 'upload', 'publish'.%0a%0aA: Some of your page files may still have the old star @@*@@ locking. Files that in the past shipped with the star lock were Site.GroupAttributes, SiteAdmin.GroupAttributes, Site.AuthUser and/or PmWiki.GroupAttributes in the directories wikilib.d and/or wiki.d. You need to edit them in a text editor and replace any line among these:\\%0a@@passwdedit=*@@\\%0a@@passwdattr=*@@\\%0a@@passwdread=*@@\\%0a@@passwdpublish=*@@\\%0a@@passwdupload=*@@%0a%0aA:Edit the file and replace the star @@*@@ with the word [@@lock@] on every existing line. ''Do not add these lines if they are not already in the file, and do not change the lines if there is something other than a single star after the = equals sign''. Save the file, upload it back to your wiki and the warnings should disappear. (If you run a wiki farm, you may have such files in several @@wiki.d@@ directories.)%0a%0a[[#blank_sections]]%0aQ: After a PHP upgrade, some of the pages on my wiki are completely blank, empty, some have blank or missing sections, but the sidebar and the action links are visible.%0a%0aA: Sometimes this may be caused by insufficient [[file permissions]] on the server. The PHP process needs "read/write (rw)" access to all files in the directories "wiki.d" and "uploads"; "read (r)" access to those in the "wikilib.d" directory; "list/search (x)" for the directories themselves. Search the documentation of your hosting provider for more information.%0a%0aA: Alternatively, this may be caused by a change in PHP 5.4 which affects the function @@htmlspecialchars()@@.%0a%0aA: The easiest temporary fix would be in your @@php.ini@@, or in @@.user.ini@@ to change the @@default_charset@@ directive to an 8-bit charset, for example cp1252:%0a%0a default_charset = "Windows-1252"%0a%0aA: Or, this may sometimes work in @@local/config.php@@:%0a%0a ini_set("default_charset", "Windows-1252");%0a%0aA: A more permanent fix would be to [[Upgrades|upgrade]] your installation to a more recent PmWiki version, your recipes, and in your own recipes or modules replace all calls to @@htmlspecialchars()@@ with @@PHSC()@@, a PmWiki helper function for such cases.%0a%0aA: The "blank" pages come from the fact that in PHP 5.4 the default encoding switched from an 8-bit encoding to variable-bit validated UTF-8, and that an incorrect UTF-8 string will be rejected. If your wiki uses an 8-bit encoding, it is virtually certain that it is not valid UTF-8. Worse, even if you do use UTF-8 some browsers may submit invalid bits. So the [[Functions#PHSC|PHSC() function]] always pretends that it converts an 8-bit encoding where all bits are allowed.%0a%0aQ: Why am I seeing strange errors after [[Upgrades|upgrading]]?%0aA: Make sure all of the files were updated, in particular @@pmwiki.php@@ and all files in the @@scripts/@@ directory.%0a%0aA: This question sometimes arises when an administrator hasn't%0afollowed the advice, which used to be less prominent, on the%0a[[PmWiki.installation#notes|installation]] and%0a[[PmWiki.initial setup tasks#dontmodify|initial setup tasks]] pages and has renamed%0a''pmwiki.php'' instead of creating an ''index.php'' wrapper script.%0aIf you have renamed ''pmwiki.php'' to ''index.php'', then the upgrade procedure%0awon't have updated your ''index.php'' file. Delete the old version and%0acreate a wrapper script so it won't happen again.%0a%0aA: Sometimes an FTP or other copy program will fail to transfer all of the%0afiles properly. One way to check for this is by comparing file sizes.%0a%0aA: Be sure all of the files in the ''wikilib.d/'' directory%0awere also upgraded. Sometimes it's a good idea to simply delete the ''wikilib.d/''%0adirectory before upgrading. (Local copies of pages are stored in ''wiki.d/'' and not ''wikilib.d/''.)%0a%0aA: Make sure that the [[(PmWiki.)file permissions]] are correct. The official files have a restricted set of permissions that might not match your site's needs.%0a%0aA: If you use a custom pattern for $GroupPattern make sure that it includes Site ($SiteGroup) and since PMWiki 2.2 also SiteAdmin ($SiteAdminGroup).%0aOtherwise migration may fail (e.g. missing SiteAdmin for PMWiki 2.2 and later) and/or login does not work.\\%0aAdditionally Main ($DefaultGroup) should be included too.%0a%0a[[#flock]]%0aQ: I'm suddenly getting messages like "@@Warning: fopen(wiki.d/.flock): failed to open stream: Permission denied...@@" and "@@Cannot acquire lockfile@@"... what's wrong?%0a%0aA: Something (or someone) has changed the [[PmWiki/FilePermissions | permissions]] on the ''wiki.d/.flock'' file or the ''wiki.d/'' directory such that the webserver is no longer able to write the lockfile. The normal solution is to simply delete the ''.flock'' file from the ''wiki.d/'' directory -- PmWiki will then create a new one. Also be sure to check the permissions on the ''wiki.d/'' directory itself. (One can easily check and modify permissions of the ''wiki.d/'' directory in %25newwin%25[[http://filezilla-project.org/ | FileZilla]] (open-source FTP app) by right-clicking on the file > File attributes)%0a%0a[[#sidebar]]%0aQ: My links in the sidebar seem to be pointing to non-existent pages, even though I know I created the pages. Where are the pages?%0a%0aA: Links in the sidebar normally need to be qualified by a [[WikiGroup]] in order to work properly (use [=[[Group/Page]] instead of [[Page]]=]).\\%0aAlso: Make sure you type Side'''B'''ar with a capital B.%0a%0a[[#headers]]%0aQ: Why am I seeing "@@PHP Warning: Cannot modify header information - headers already sent by ...@@" messages at the top of my page.%0a%0aA: If this is the first or only error message you're seeing, it's usually an indication that there are blank lines, spaces, or other characters before the [@%3c?php@] or after the [@?>@] in a [[local customization(s)]] files such as @@config.php@@. Double-check the file and make sure there is nothing before the initial [@%3c?php@]. It's often easiest and safest to eliminate any closing [@?>@] altogether. %0a%0aA: When you save the file, the encoding/charset should be either cp1252/Windows1252 or UTF-8 without Byte Order Mark. [[https://notepad-plus-plus.org/ | NotePad++]] is an editor that can do this.%0a%0aA: When you transfer the files, tell your FTP manager to use text mode transfer, or, if that doesn't help, binary mode transfer.%0a%0a%0aA: If the warning is appearing after some other warning or error message, then resolve the other error and this warning may go away.%0a%0a[[#session_write_close_error]]%0aQ: How do I make a PHP Warning about @@function.session-write-close@@ go away?%0a%0aA: If you are seeing an error similar to this%0a%0a->[@%0aWarning: session_write_close() [function.session-write-close]:%0aopen(/some/filesystem/path/to/a/directory/sess_[...]) failed: No such file%0aor directory (2) in /your/filesystem/path/to/pmwiki.php on line NNN%0a@]%0a%0aPmWiki sometimes does session-tracking using PHP's%0a[[http://php.net/session | session-handling functions ]].%0aFor session-tracking to work, some information needs to be written%0ain a directory on the server. That directory needs to exist and%0abe writable by the webserver software. For this example, the%0awebserver software is configured to write sessions in this%0adirectory%0a%0a->[@/some/filesystem/path/to/a/directory/@]%0a%0abut the directory doesn't exist. The solution is to do at least one%0aof these:%0a* '''Create the directory''' and make sure it's writable by the webserver software%0a* Provide a session_save_path value that points to a directory that is writable by the server, e.g. in config.php:%0a%0a->[@session_save_path('/home/someuser/tmp/sessions');@] # unix-type OS%0a->[@session_save_path('C:/server/tmp/sessions');@] # Windows%0a%0a[[#multiplepwprompts]]%0aQ: Why is PmWiki prompting me multiple times for a password I've already entered?%0a%0aA: This could happen like out of nowhere if your hosting provider upgrades to PHP version 5.3, and you run an older PmWiki release. Recent PmWiki releases fix this problem.%0a%0aA: Alternatively, this may be an indication that the browser isn't accepting cookies, or that PHP's session handling functions on the server aren't properly configured. If the browser is accepting cookies, then try setting $EnableDiag=1; in ''local/config.php'', run PmWiki using [@?action=phpinfo@], and verify that sessions are enabled and that the session.save_path has a reasonable value. Note that several versions of PHP under Windows require that a session_save_path be explicitly set (this can be done in the ''local/config.php'' file). You might also try setting session.auto_start to 1 in your php.ini.%0a%0aA: See also the question [[#configphp-order|I have to log in twice]] below.%0a%0aQ: I edited ''config.php'', but when I look at my wiki pages, all I see is "@@Parse error: parse error, unexpected T_VARIABLE in ''somefile'' on line ''number''.@@"%0a%0aA: You've made a mistake in writing the PHP that goes into the ''config.php'' file. The most common mistake that causes the T_VARIABLE error is forgetting the semi-colon (;) at the end of a line that you added. The line number and file named are where you should look for the mistake.%0a%0a%0aQ: Searches and pagelists stopped working after I upgraded -- no errors are reported, but links to other pages do not appear (or do not appear as they should) -- what gives?%0a%0aA: Be sure all of the files in the ''wikilib.d/'' directory%0awere also upgraded. In particular, it sounds as if the Site.PageListTemplates page is either missing (if no links are displayed) or is an old version (if the links do not appear as they should). Also make sure that read-permissions (attr) are set for the pages Site.PageListTemplates and Site.Search.%0a%0a[[#mod_security]]%0aQ: Some of my posts are coming back with "403 Forbidden" or "406 Not Acceptable" errors, or "Internal Server Error". This happens with some posts but not others.%0a%0aA: Your webserver probably has [[http://modsecurity.org | mod_security]] enabled. The mod_security "feature" scans all incoming posts for forbidden words or phrases that might indicate someone is trying to hack the system, and if any of them are present then Apache returns the 403 Forbidden or 406 Not Acceptable error. Common phrases that tend to trigger mod_security include "curl ", "wget", "file(", and "system(", although there are many others (depending on the configuration, percent signs, html tags, international characters).%0a%0aSince mod_security intercepts the requests and sends the "forbidden"%0amessage before PmWiki ever gets a chance to run, it's not a bug in PmWiki, and%0athere's little that PmWiki can do about it. Instead, one has to alter the%0awebserver configuration to disable mod_security or reconfigure it to allow%0awhatever word it is forbidding. Some sites may be able to disable mod_security%0aby placing [@SecFilterEngine off@] in a ''.htaccess'' file.%0a%0aQ: I get the following message when attempting to upload an image, what do I do?%0a[-@@'''Warning''': move_uploaded_file(): SAFE MODE Restriction in effect. The script whose uid is 1929 is not allowed to access /home/onscolre/public_html/pmwikiuploads/Photos owned by uid 33 in '''/home/onscolre/public_html/pmwiki/scripts/upload.php''' on line '''198'''@@-]%0a%0a@@'''PmWiki can't process your request'''@@%0a%0a[-@@?cannot move uploaded file to /home/onscolre/public_html/pmwikiuploads/Photos/FoundationPupilsIn1958.jpeg@@-]%0a%0a[-@@We are sorry for any inconvenience.@@-]%0a%0aA: Your server is configured with PHP [[http://php.net/manual/en/features.safe-mode.php|Safe Mode]] enabled. Configure your wiki to use a [[PmWiki/UploadsAdmin#sitewideprefix|site-wide uploads prefix]], then create the ''uploads/'' directory manually and set 777 permissions on it (rather than letting PmWiki create the directory).%0a%0a[[#TableRowIndexMax]] [[#divisionbyzero]]%0aQ: I'm starting to see "Division by zero error in pmwiki.php..." on my site. What's wrong?%0a%0aA: It's a bug in PmWiki that occurs only with the [[tables]] markup and only for versions of PHP >= 4.4.6 or >= 5.2.0. Often it seems to occur "out of nowhere" because the server administrator has upgraded PHP. Try [[upgrad(es)]]ing to a later version of PmWiki to remove the error, or try setting the following in ''local/config.php'':%0a%0a $TableRowIndexMax = 1;%0a%0a[[#configphp-order]]%0aQ: I have to log in twice [-(two times) (2 times)-]. -or- My password is not being required even though it should. -or- I changed the password but the old password is still active. -or- My config.php password is not over-riding my farmconfig.php password.%0aA: It could happen if (farm)config.php, or an included recipe, directly calls the functions CondAuth(), or RetrieveAuthPage(), PageTextVar(), PageVar() and possibly others, before defining all passwords and before including AuthUser (if required). %0a%0aThe [[PmWiki/LocalCustomizations#configphp-order|order of config.php]] is very significant.%0a%0a[[#CrashWhenEditing]]%0aQ: When editing an existing page, The "Save" causes a no-response of your server (not a blank page, no response at all, an endless connexion try). To get back the hand, it is necessary to request for another page (by clicking on its link in the menu for instance). And horror!, the ...?action=edit is then inhibited, it becomes impossible to edit any page.%0aA: When the editing of a page is initiated a file names [@.flock@] is created in the [@wiki.d@] repository. As long as this file exists it is impossible to edit any page. This file denotes an edition in progress and is automatically destroyed when leaving successfully an edit action by "Save". In case of a crash of the editing, this file is not destroyed. The remedy is, with an FTP client parameterized to show hidden files, to remove the [@.flock@] file. And all get back OK. This behavior is typically caused by a bug which provokes (directly or indirectly), an endless loop in a recipe concerned by the edited page.%0a%0aQ: I get the error "Data Mismatch - Locking FAILED!"%0aA: This is probably not a PmWiki error. PmWiki cannot create a lock file due to an underlying file system problem.%0aFor example the disk quota has been exceeded (e.g. by an error log file or file uploads), or there are problems with file system permissions.%0a -time=1591250673 +rev=170 +targets=PmWiki.HowToGetAssistance,PmWiki.MailingLists,PmWiki.Questions,PITS.PITS,PmWiki.CustomMarkup,PmWiki.Functions,PmWiki.Upgrades,Cookbook.Cookbook,PmWiki.CustomPagelistSortOrder,Cookbook.PccfToPcfOverride,PmWiki.PmWiki,PmWiki.DebugVariables,PmWiki.SecurityVariables,PmWiki.BasicVariables,PmWiki.LinkVariables,PmWiki.EditVariables,PmWiki.FilePermissions,PmWiki.Installation,PmWiki.InitialSetupTasks,PmWiki.WikiGroup,PmWiki.LocalCustomizations,PmWiki.UploadsAdmin,PmWiki.Tables,PmWiki.LayoutVariables +text=(:Summary:Advice for troubleshooting an installation, keywords: deprecated, preg_replace, crypt, blank pages, headers, .flock, upgrade, create_function:)%0a(:Audience: administrators :)%0a%0aPmWiki is pretty robust and can automatically adapt to a very wide variety of environments. %0aHowever, sometimes things don't go as we expect, so we're cataloging common errors and their fixes here.%0a%0a!! Troubleshooting Frequently Asked Questions%0a%0a->%25note%25 Note: This page on pmwiki.org is probably not the best place to post questions. Consider [[PmWiki:HowToGetAssistance | seeking assistance]] from the pmwiki-users [[mailing list(s)]], or post your question on the [[PmWiki:Questions]] page.%0a%0a>>faq%3c%3c [[#faq]]%0a%0a[[#track-errors]]%0aQ: How to track errors and know if they come from the PmWiki core or from a local configuration or addon/recipe?%0a%0aA: The PHP programming language has recently deprecated or removed a number of functions that were heavily used in the past by PmWiki and many addons/recipes/skins. The PmWiki core no longer relies on these functions but some addons still do -- here is how to track these.%0a%0aA: The PmWiki architecture allows addons (recipes, skins) and local configuration to register actions to be performed by PmWiki at a later point of the process. That's why the PHP warning may indicate a line in @@pmwiki.php@@, even if this was caused by a recipe. %0a%0aA: It is recommended to get the latest versions of PmWiki and of all your addons -- known bugs would have been fixed. This assumes the errors are fixed in the latest versions.%0a%0aA: (1) First disable or comment out all addons and local configuration (@@config.php@@, @@farmconfig.php@@, @@Group.php@@) and test your wiki. If the warning persists, please notify us ASAP with some information on how to reproduce the bug and on your installation (PHP version). If the error doesn't appear, go to (2).%0a%0aA: (2) Enable one local configuration or one addon and test your wiki to see if the error appears.%0a%0aA: (3) If the error doesn't appear, the problem is likely elsewhere. If you have more addons to enable, go back to (2).%0a%0aA: (4) If the error appears, it was likely caused by the last configuration or addon that you enabled. Search the documentation and the cookbook for more recent versions, or contact the addon maintainer, or leave a message on the talk page. If that doesn't work, contact us at [[PITS:PITS|our issue tracking system]]. Developers can find documentation on how to update old addons at [[CustomMarkup]] and [[Functions]].%0a%0aA: (5) Disable again the faulty addon and if you have more addons to enable, go back to (2).%0a%0aA: PmWiki has a friendly and reactive community and we may be able to quickly provide fixes.%0a%0a[[#obsolete]]%0aQ: After a PHP upgrade, some of my markup rules have been disabled, and a tooltip title says (in English) "Markup rule ... is obsolete and has been disabled. See pmwiki.org/Troubleshooting".%0a%0aA: The obsolete markup rule should appear on the tooltip title and should make it easy to identify which custom configuration or addon/recipe caused it. If it is not obvious, follow the steps in the [[#track-errors|first section]]. Developers can find documentation on how to update old addons at [[CustomMarkup]] and [[Functions]].%0a%0a[[#create_function]]%0aQ: My wiki displays warnings "@@Deprecated: Function create_function() is deprecated@@".%0a%0aA: PHP version 7.2 deprecated a function which PmWiki used for markup definitions and pattern replacements. It is recommended to [[upgrades|upgrade]] to the latest PmWiki version and update all addons and skins from the [[Cookbook/]]. Addons in the [[https://www.pmwiki.org/wiki/Category/PHP72|PHP 7.2]] category are reported to be compatible with PHP 7.2. If you need a specific addon that has not yet been updated please contact us. To update your own addons, you probably need to update your calls to Markup(), see the pages [[Custom markup]], [[Functions]] and [[PmWiki:CustomPagelistSortOrder]].%0a%0aA: The recipe [[Cookbook:PccfToPcfOverride]] may provide a temporary solution until you can update all your add-ons.%0a%0aA: Note that PmWiki itself doesn't use that function, but (older) addons can register instructions to be processed at a later point. That's why the warning reports a line in @@pmwiki.php@@, even if it was requested by a local configuration or an addon.%0a%0aA: How to track down the addons that cause the warnings, see the [[#track-errors|first section]].%0a%0aQ: [[#deprecated]] [[#preg_replace]] My wiki displays warnings "@@Deprecated: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead@@".%0aA: This is caused by a change in PHP version 5.5 for the [[https://www.php.net/preg_replace | preg_replace()]] function. PmWiki no longer relies on the deprecated feature since version 2.2.56 (it is recommended to upgrade to the latest version) but many recipes do. %0a%0aA: Note that PmWiki itself doesn't use that function, but (older) addons can register instructions to be processed at a later point. That's why the warning reports a line in @@pmwiki.php@@, even if it was requested by a local configuration or an addon.%0a%0aA: Recipes and Skins are currently being updated for [[https://www.pmwiki.org/wiki/Category/PHP55|PHP 5.5]]. Check if there are more recent versions published by their maintainers on the [[(Cookbook:)Cookbook]]. If you update your PmWiki and recipes, and still see the warnings, here is how to find out which recipes cause them:%0a%0aA: For PmWiki version 2.2.71 or newer, in @@config.php@@, enable diagnostic tools: \\%0a%25hlt php%25@@$EnableDiag = 1;@@\\%0aThen visit your wiki with the action 'ruleset', for example %25newwin%25[[PmWiki:PmWiki?action=ruleset]]%25%25 or follow a link like %25pmhlt%25[@[[HomePage?action=ruleset]]@]. This page will list all markup rules; those potentially incompatible with PHP 5.5 will be flagged with filenames, line numbers and search patterns triggering the warning.%0a%0aA: If the @@?action=ruleset@@ page shows no flagged rules, it is possible that either your recipes call the %25hlt php%25@@preg_replace()@@ function directly, or they define various search-replace patterns in incompatible ways. In these cases, your warning should display the file name and line number causing problems. Otherwise, to track down the addons that cause the warnings, see the [[#track-errors|first section]].%0a%0aA: Note that many hosting providers allow you to run different versions of PHP. See the documentation of your hosting plan to learn how to enable a PHP version earlier than 5.5.%0a%0aA: Finally, it is possible to suppress these warnings in PHP 5.5, by setting this line at the beginning of @@config.php@@: \\%0a%25hlt php%25@@error_reporting(E_ALL & ~E_NOTICE & ~E_DEPRECATED);@@\\%0aThis should be a temporary solution, left only until your recipes are fixed.%0a%0aA: See categories: (:pagelist group=category name=php*,-php,-php5,-php54 fmt=#csvlist:).%0a%0a[[#crypt]]%0aQ: My wiki displays warnings "@@PHP Deprecated: crypt(): Supplied salt is not valid for DES. Possible bug in provided salt format@@" or "@@Uncaught ArgumentCountError: crypt() expects exactly 2 arguments, 1 given@@".%0aA: You probably have configuration settings that worked on older PHP versions. Here is how to hunt and try to fix this.%0a%0aA: In your (farm)@@config.php@@ or other local or cookbook files, any call to %25hlt php%25@@crypt()@@ can be replaced with @@pmcrypt()@@, eg \\%0a%25hlt php%25@@$DefaultPasswords['edit'] = crypt("my_password");@@ # %25red%25DEPRECATED%25%25\\%0a%25hlt php%25@@$DefaultPasswords['edit'] = '''pmcrypt'''("my_password");@@ # %25green%25OK%25%25\\%0a%25hlt php%25@@$DefaultPasswords['edit'] = array('''pmcrypt'''("pass1"), '''pmcrypt'''("pass2"));@@ # %25green%25OK%25%25%0a%0aA: Additionally, if there are locked passwords with a star @@*@@, you should replace those with [@@lock@]: \\%0a%25hlt php%25@@$DefaultPasswords['edit'] = '*';@@ # %25red%25DEPRECATED%25%25\\%0a%25hlt php%25@@$DefaultPasswords['edit'] = '@lock';@@ # %25green%25OK%25%25 (and no pmcrypt)%0a%0aA: The $DefaultPasswords variables usually have keys like 'edit', 'attr', 'read', 'upload', 'publish'.%0a%0aA: Some of your page files may still have the old star @@*@@ locking. Files that in the past shipped with the star lock were @@Site.GroupAttributes@@, @@SiteAdmin.GroupAttributes@@, @@Site.AuthUser@@ and/or @@PmWiki.GroupAttributes@@ in the directories @@wikilib.d@@ and/or @@wiki.d@@. You need to edit them in a text editor and replace any line among these:\\%0a%25hlt php%25@@passwdedit=*@@\\%0a%25hlt php%25@@passwdattr=*@@\\%0a%25hlt php%25@@passwdread=*@@\\%0a%25hlt php%25@@passwdpublish=*@@\\%0a%25hlt php%25@@passwdupload=*@@%0a%0aA:Edit the file and replace the star @@*@@ with the word [@@lock@] on every existing line. ''Do not add these lines if they are not already in the file, and do not change the lines if there is something other than a single star after the = equals sign''. Save the file, upload it back to your wiki and the warnings should disappear. (If you run a wiki farm, you may have such files in several @@wiki.d@@ directories.)%0a%0aQ: [[#invrange]] My wiki displays warnings "@@Compilation failed: invalid range in character class@@".%0a%0aA: A character class range in a regular expression is something in brackets like @@[A-Z]@@. An invalid character class may look like @@[Z-A]@@, where the "Z" character should not be before but after the "A" character. It may not be that obvious, but it would be in brackets with a dash between the wrong characters.%0a%0aA: If you want to match an actual dash (minus) rather than identify a character range, you need to place it first or last thing, like:\\%0a [@[-AZ] or [AZ-]@]%0a%0aA: To track the error, see [[#track-errors|the first question on this page]], and check the variables $GroupPattern, $NamePattern, $MakePageNamePatterns, $ROSPatterns and other locally configured core variables that contain "Pattern" or "Patterns" in the name.%0a%0a[[#blank_sections]]%0aQ: After a PHP upgrade, some of the pages on my wiki are completely blank, empty, some have blank or missing sections, but the sidebar and the action links are visible.%0a%0aA: Sometimes this may be caused by insufficient [[file permissions]] on the server. The PHP process needs "read/write (rw)" access to all files in the directories "@@wiki.d@@" and "@@uploads@@"; "read (r)" access to those in the "@@wikilib.d@@" directory; "list/search (x)" for the directories themselves. Search the documentation of your hosting provider for more information.%0a%0aA: Alternatively, this may be caused by a change in PHP 5.4 which affects the function %25hlt php%25@@htmlspecialchars()@@.%0a%0aA: The easiest temporary fix would be in your @@php.ini@@, or in @@.user.ini@@ to change the @@default_charset@@ directive to an 8-bit charset, for example cp1252:\\%0a%25hlt php%25[@default_charset = "Windows-1252";@]%0a%0aA: Or, this may sometimes work in @@local/config.php@@:\\%0a%25hlt php%25[@ini_set("default_charset", "Windows-1252");@]%0a%0aA: A more permanent fix would be to [[Upgrades|upgrade]] your installation to a more recent PmWiki version, your recipes, and in your own recipes or modules replace all calls to %25hlt php%25@@htmlspecialchars()@@ with @@PHSC()@@, a PmWiki helper function for such cases.%0a%0aA: The "blank" pages come from the fact that in PHP 5.4 the default encoding switched from an 8-bit encoding to variable-bit validated UTF-8, and that an incorrect UTF-8 string will be rejected. If your wiki uses an 8-bit encoding, it is virtually certain that it is not valid UTF-8. Worse, even if you do use UTF-8 some browsers may submit invalid bits. So the [[Functions#PHSC|%25hlt php%25@@PHSC()@@ function]] always pretends that it converts an 8-bit encoding where all bits are allowed.%0a%0a%0aQ: [[#backtrack_limit]] Very long pages with thousands of lines may appear blank after adding a few additional lines. This may be preformatted text, table, or text inside conditional markup, or text in a custom markup directive.%0aA: This may be caused by the PHP limits on how far to look forward, and loop back, when searching for matches of regular expressions. You may want to split the very long page into several pages, or the very long markup into separate sections/blocks, or you can increase the PHP limits by adding this to @@local/config.php@@:\\%0a%25hlt php%25[@@ini_set('pcre.backtrack_limit', 10000000);@]%0a%0aQ: Why am I seeing strange errors after [[Upgrades|upgrading]]?%0aA: Make sure all of the files were updated, in particular @@pmwiki.php@@ and all files in the @@scripts/@@ directory.%0a%0aA: This question sometimes arises when an administrator hasn't%0afollowed the advice, which used to be less prominent, on the%0a[[PmWiki.installation#notes|installation]] and%0a[[PmWiki.initial setup tasks#dontmodify|initial setup tasks]] pages and has renamed%0a''@@pmwiki.php@@'' instead of creating an ''@@index.php@@'' wrapper script.%0aIf you have renamed ''@@pmwiki.php@@'' to ''@@index.php@@'', then the upgrade procedure%0awon't have updated your ''@@index.php@@'' file. Delete the old version and%0acreate a wrapper script so it won't happen again.%0a%0aA: Sometimes an FTP or other copy program will fail to transfer all of the%0afiles properly. One way to check for this is by comparing file sizes.%0a%0aA: Be sure all of the files in the ''@@wikilib.d/@@'' directory%0awere also upgraded. Sometimes it's a good idea to simply delete the ''@@wikilib.d/@@''%0adirectory before upgrading. (Local copies of pages are stored in ''@@wiki.d/@@'' and not ''@@wikilib.d/@@''.)%0a%0aA: Make sure that the [[(PmWiki.)file permissions]] are correct. The official files have a restricted set of permissions that might not match your site's needs.%0a%0aA: If you use a custom pattern for @@$GroupPattern@@ make sure that it includes Site ($SiteGroup) and since PMWiki 2.2 also @@SiteAdmin@@ (@@$SiteAdminGroup@@).%0aOtherwise migration may fail (e.g. missing @@SiteAdmin@@ for PMWiki 2.2 and later) and/or login does not work.\\%0aAdditionally @@Main@@ (@@$DefaultGroup@@) should be included too.%0a%0a[[#flock]]%0aQ: I'm suddenly getting messages like "@@Warning: fopen(wiki.d/.flock): failed to open stream: Permission denied...@@" and "@@Cannot acquire lockfile@@"... what's wrong?%0a%0aA: Something (or someone) has changed the [[PmWiki/FilePermissions | permissions]] on the ''@@wiki.d/.flock@@'' file or the ''@@wiki.d/@@'' directory such that the webserver is no longer able to write the lockfile. The normal solution is to simply delete the ''@@.flock@@'' file from the ''@@wiki.d/@@'' directory -- PmWiki will then create a new one. Also be sure to check the permissions on the ''@@wiki.d/@@'' directory itself. (One can easily check and modify permissions of the ''@@wiki.d/@@'' directory in %25newwin%25[[https://filezilla-project.org/ | FileZilla]] (open-source FTP app) by right-clicking on the file > File attributes)%0a%0a[[#sidebar]]%0aQ: My links in the sidebar seem to be pointing to non-existent pages, even though I know I created the pages. Where are the pages?%0a%0aA: Links in the SideBar normally need to be qualified by a [[WikiGroup]] in order to work properly (use %25pmhlt%25[@[[Group/Page]]@] instead of [@[[Page]]@]).\\%0aAlso: Make sure you type Side'''B'''ar with a capital B.%0a%0a[[#headers]]%0aQ: Why am I seeing "@@PHP Warning: Cannot modify header information - headers already sent by ...@@" messages at the top of my page.%0a%0aA: If this is the first or only error message you're seeing, it's usually an indication that there are blank lines, spaces, or other characters before the %25hlt php%25[@%3c?php@] or after the [@?>@] in a [[local customization(s)]] files such as @@config.php@@. Double-check the file and make sure there is nothing before the initial [@%3c?php@]. It's often easiest and safest to eliminate any closing [@?>@] altogether. %0a%0aA: When you save the file, the encoding/charset should be either @@cp1252/Windows1252@@ or @@UTF-8@@ without Byte Order Mark. [[https://notepad-plus-plus.org/ | NotePad++]] is an editor that can do this.%0a%0aA: When you transfer the files, tell your FTP manager to use text mode transfer, or, if that doesn't help, binary mode transfer.%0a%0a%0aA: If the warning is appearing after some other warning or error message, then resolve the other error and this warning may go away.%0a%0a[[#session_write_close_error]]%0aQ: How do I make a PHP Warning about @@function.session-write-close@@ go away?%0a%0aA: If you are seeing an error similar to this%0a%0a->[@%0aWarning: session_write_close() [function.session-write-close]:%0aopen(/some/filesystem/path/to/a/directory/sess_[...]) failed: No such file%0aor directory (2) in /your/filesystem/path/to/pmwiki.php on line NNN%0a@]%0a%0aPmWiki sometimes does session-tracking using PHP's%0a[[https://www.php.net/manual/en/features.sessions.php | session-handling functions ]].%0aFor session-tracking to work, some information needs to be written%0ain a directory on the server. That directory needs to exist and%0abe writable by the webserver software. For this example, the%0awebserver software is configured to write sessions in this%0adirectory%0a%0a->[@/some/filesystem/path/to/a/directory/@]%0a%0abut the directory doesn't exist. The solution is to do at least one%0aof these:%0a* '''Create the directory''' and make sure it's writable by the webserver software%0a* Provide a session_save_path value that points to a directory that is writable by the server, e.g. in @@config.php@@:%0a%0a->%25hlt php%25[@session_save_path('/home/someuser/tmp/sessions');@] # unix-type OS%0a->%25hlt php%25[@session_save_path('C:/server/tmp/sessions');@] # Windows%0a%0a[[#multiplepwprompts]]%0aQ: Why is PmWiki prompting me multiple times for a password I've already entered?%0a%0aA: This could happen like out of nowhere if your hosting provider upgrades to PHP version 5.3, and you run an older PmWiki release. Recent PmWiki releases fix this problem.%0a%0aA: Alternatively, this may be an indication that the browser isn't accepting cookies, or that PHP's session handling functions on the server aren't properly configured. If the browser is accepting cookies, then try setting %25hlt php%25@@$EnableDiag=1;@@ in ''@@local/config.php@@'', run PmWiki using [@?action=phpinfo@], and verify that sessions are enabled and that the session.save_path has a reasonable value. Note that several versions of PHP under Windows require that a session_save_path be explicitly set (this can be done in the ''@@local/config.php@@'' file). You might also try setting session.auto_start to 1 in your @@php.ini@@.%0a%0aA: See also the question [[#configphp-order|I have to log in twice]] below.%0a%0aQ: I edited ''@@config.php@@'', but when I look at my wiki pages, all I see is "@@Parse error: parse error, unexpected T_VARIABLE in ''somefile'' on line ''number''.@@"%0a%0aA: You've made a mistake in writing the PHP that goes into the ''@@config.php@@'' file. The most common mistake that causes the T_VARIABLE error is forgetting the semi-colon (;) at the end of a line that you added. The line number and file named are where you should look for the mistake.%0a%0a%0aQ: Searches and pagelists stopped working after I upgraded -- no errors are reported, but links to other pages do not appear (or do not appear as they should) -- what gives?%0a%0aA: Be sure all of the files in the ''@@wikilib.d/@@'' directory%0awere also upgraded. In particular, it sounds as if the @@Site.PageListTemplates@@ page is either missing (if no links are displayed) or is an old version (if the links do not appear as they should). Also make sure that read-permissions (attr) are set for the pages @@Site.PageListTemplates@@ and @@Site.Search@@.%0a%0a[[#mod_security]]%0aQ: Some of my posts are coming back with "403 Forbidden" or "406 Not Acceptable" errors, or "Internal Server Error". This happens with some posts but not others.%0a%0aA: Your webserver probably has [[https://github.com/SpiderLabs/ModSecurity | mod_security]] enabled. The mod_security "feature" scans all incoming posts for forbidden words or phrases that might indicate someone is trying to hack the system, and if any of them are present then Apache returns the 403 Forbidden or 406 Not Acceptable error. Common phrases that tend to trigger mod_security include "curl ", "wget", "file(", and "system(", although there are many others (depending on the configuration, percent signs, html tags, international characters).%0a%0aSince mod_security intercepts the requests and sends the "forbidden"%0amessage before PmWiki ever gets a chance to run, it's not a bug in PmWiki, and%0athere's little that PmWiki can do about it. Instead, one has to alter the%0awebserver configuration to disable mod_security or reconfigure it to allow%0awhatever word it is forbidding. Some sites may be able to disable mod_security%0aby placing [@SecFilterEngine off@] in a ''@@.htaccess@@'' file.%0a%0aQ: I get the following message when attempting to upload an image, what do I do?%0a[-@@'''Warning''': move_uploaded_file(): SAFE MODE Restriction in effect. The script whose uid is 1929 is not allowed to access /home/onscolre/public_html/pmwikiuploads/Photos owned by uid 33 in '''/home/onscolre/public_html/pmwiki/scripts/upload.php''' on line '''198'''@@-]%0a%0a@@'''PmWiki can't process your request'''@@%0a%0a[-@@?cannot move uploaded file to /home/onscolre/public_html/pmwikiuploads/Photos/FoundationPupilsIn1958.jpeg@@-]%0a%0a[-@@We are sorry for any inconvenience.@@-]%0a%0aA: Your server is configured with PHP [[https://web.archive.org/web/20201014032613/https://www.php.net/manual/en/features.safe-mode.php|Safe Mode]] enabled (removed as of PHP 5.4.0). Configure your wiki to use a [[PmWiki/UploadsAdmin#sitewideprefix|site-wide uploads prefix]], then create the ''uploads/'' directory manually and set 777 permissions on it (rather than letting PmWiki create the directory).%0a%0a[[#TableRowIndexMax]] [[#divisionbyzero]]%0aQ: I'm starting to see "@@Division by zero error in pmwiki.php...@@" on my site. What's wrong?%0a%0aA: It's a bug in PmWiki that occurs only with the [[tables]] markup and only for versions of PHP >= 4.4.6 or >= 5.2.0. Often it seems to occur "out of nowhere" because the server administrator has upgraded PHP. Try [[upgrad(es)]]ing to a later version of PmWiki to remove the error, or try setting the following in ''@@local/config.php@@'':%0a%0a $TableRowIndexMax = 1;%0a%0a[[#configphp-order]]%0aQ: I have to log in twice [-(two times) (2 times)-]. -or- My password is not being required even though it should. -or- I changed the password but the old password is still active. -or- My @@config.php@@ password is not over-riding my @@farmconfig.php@@ password.%0aA: It could happen if (farm)@@config.php@@, or an included recipe, directly calls the functions %25hlt php%25@@CondAuth()@@, or @@RetrieveAuthPage()@@, @@PageTextVar()@@, @@PageVar()@@ and possibly others, before defining all passwords and before including AuthUser (if required). %0a%0aThe [[PmWiki/LocalCustomizations#configphp-order|order of @@config.php@@]] is very significant.%0a%0a[[#CrashWhenEditing]]%0aQ: When editing an existing page, The "Save" causes a no-response of your server (not a blank page, no response at all, an endless connexion try). To get back the hand, it is necessary to request for another page (by clicking on its link in the menu for instance). And horror!, the ...?action=edit is then inhibited, it becomes impossible to edit any page.%0aA: When the editing of a page is initiated a file names [@.flock@] is created in the [@wiki.d@] repository. As long as this file exists it is impossible to edit any page. This file denotes an edition in progress and is automatically destroyed when leaving successfully an edit action by "Save". In case of a crash of the editing, this file is not destroyed. The remedy is, with an FTP client parameterized to show hidden files, to remove the [@.flock@] file. And all get back OK. This behavior is typically caused by a bug which provokes (directly or indirectly), an endless loop in a recipe concerned by the edited page.%0a%0aQ: I get the error "@@Data Mismatch - Locking FAILED!@@"%0aA: This is probably not a PmWiki error. PmWiki cannot create a lock file due to an underlying file system problem.%0aFor example the disk quota has been exceeded (e.g. by an error log file or file uploads), or there are problems with file system permissions.%0a +time=1667029358 blob - 99e00f5126f769504b2182319034deda79b65a53 blob + 9899775783f368314948f022d1065aa470063e3f --- wikilib.d/PmWiki.UTF-8 +++ wikilib.d/PmWiki.UTF-8 @@ -1,9 +1,9 @@ -version=pmwiki-2.2.122 ordered=1 urlencoded=1 -author=bttr +version=pmwiki-2.3.18 ordered=1 urlencoded=1 +author=Petko charset=UTF-8 -csum=Fix case +csum=pmhlt (+7) name=PmWiki.UTF-8 -rev=34 -targets=PmWiki.Internationalizations,PmWiki.Upgrades,PmWiki.I18nVariables,PmWiki.LayoutVariables,Skins.Amber,PmWiki.LocalCustomizations,Cookbook.UTF-8 -text=Summary: Enabling UTF-8 Unicode language encoding in your wiki. %0a%0aUTF-8 supports all languages and alphabets, including Asian languages and their character depth. It is a widely supported and flexible character encoding. %0a%0aIt's fairly simple to enable UTF-8 on your wiki pages. Current PmWiki versions have the UTF-8 file which is enabled by default in the sample-config.php.%0a%0a!! Enabling UTF-8 on a new wiki%0a%0aIf you start a new wiki in any language with the latest PmWiki version, it is highly recommended to enable UTF-8. In the future, PmWiki will change to use the UTF-8 encoding by default, so if you already use it, you will not need a complex "migration" to UTF-8 later.%0a%0aTo enable UTF-8 for a new wiki, add this line near the beginning of config.php (the docs/sample-config.php file has this line already):%0a%0a include_once("scripts/xlpage-utf-8.php");%0a%0aThis line should come ''before'' a call to the XLPage() function in [[internationalizations|international wikis]].%0a%0aSave your config.php file encoded as UTF-8 (NO BOM). That allows entry of UTF-8 encoded characters in it. Make sure your editor does support this, and test by adding some non-ANSI UTF-8 characters, to see them in the text editor '^[[#notes|1]]^'.%0a%0aWith UTF-8 thus enabled you also got use of classes ''rtl'' and ''ltr'', which offer setting of the text direction to right-to-left, or left-to-right. This is useful for inclusion of right-to-left scripts like Arabic, Farsi (Persian), Hebrew, Urdu and others. %0a%0a!! Enabling UTF-8 on existing wikis%0a%0aCurrently, this is possible ''only if your group and page ''names'', as well as upload names, don't contain international characters''. The names of wiki pages are used as file names, and we don't have yet an easy way to rename the disk files.%0a%0aIf your wiki doesn't have international page/file names, first [[upgrade(s)]] to the latest PmWiki version. To enable UTF-8, add these lines near the beginning of config.php:%0a%0a include_once("scripts/xlpage-utf-8.php");%0a [=$DefaultPageCharset=] = array(''=>'ISO-8859-1'); # see below%0a%0aThese lines should come ''before'' a call to the XLPage() function in [[internationalizations|international wikis]].%0a%0aThe $DefaultPageCharset line is there to fix and correctly handle some pages with missing or wrong attributes, created by older PmWiki versions.%0a%0a* Most wikis in European languages are likely to be in the ISO-8859-1 encoding and should use:\\%0a @@$DefaultPageCharset = array(''=>'ISO-8859-1');@@%0a* Wikis in Czech and Hungarian language are likely to be in the ISO-8859-2 encoding, they should use this line instead:\\%0a @@ $DefaultPageCharset = array(''=>'ISO-8859-2', 'ISO-8859-1'=>'ISO-8859-2'); @@%0a* Wikis in Turkish language are likely to be in the ISO-8859-9 encoding, they should use this line instead:\\%0a @@ $DefaultPageCharset = array(''=>'ISO-8859-9', 'ISO-8859-1'=>'ISO-8859-9'); @@%0a%0a%0aYou should also delete the file @@ wiki.d/.pageindex@@. This file contains a cache of links and words from your pages and is used for searches and pagelists. PmWiki will rebuild it automatically with the new encoding.%0a%0a!!Support for RTL right-to-left languages%0aLanguages like Arabic, Hebrew, Farsi (Persian), Urdu and others are written in script flowing from right to left. Classes ''rtl'' and ''ltr'' can be used to specify direction of text independently of the general text direction within a page, for example: %0a(:markup:)%0a>>rtl%3c%3c%0aيتدفق هذا النص من اليمين إلى اليسار%0a>>ltr%3c%3c%0aThis text flows left to right.%0a>>%3c%3c%0a(:markupend:)%0a%0aTo set text direction for a wiki generally to RTL, you could add to config.php a line like:%0a%0a $HTMLStylesFmt['rtl'] = " body { direction:rtl; }"%0a%0abut the skin you use may need other modifications, for instance to swap the search box and the page actions to the other side etc. %0a%0aSome skins have full support for RTL, see for instance [[Skins:Amber|Amber]]. %0a%0a[[#notes]]%0a!! Notes%0a* You need to save your config.php file in the UTF-8 encoding, and "Without Byte Order Mark (BOM)". See [[LocalCustomizations#encoding|Character encoding of config.php]].%0a%0a* This page concerns the most recent versions of PmWiki. See [[Cookbook:UTF-8]] for tips on older versions.%0a%0a* In the case your PmWiki installation displays wrong encoding, or save an UTF-8 page to an other encoding without explanation, you can double check your custom .htaccess settings at the root of your served pages.%0a %0a -time=1574401061 +rev=46 +targets=PmWiki.Internationalizations,PmWiki.Upgrades,PmWiki.I18nVariables,Skins.Amber,PmWiki.UploadVariables,Cookbook.ISO8859MakePageNamePatterns,PmWiki.LocalCustomizations,Cookbook.UTF-8 +text=(:Summary: Enabling UTF-8 Unicode language encoding in your wiki.:)%0a%0a[[Wikipedia:UTF-8|UTF-8]] supports all languages and alphabets, including Asian languages and their character depth. It is a widely supported and flexible character encoding. %0a%0aIt's fairly simple to enable UTF-8 on your wiki pages. Current PmWiki versions have the UTF-8 file which is enabled by default in the @@sample-config.php@@.%0a%0a!! Enabling UTF-8 on a new wiki%0a%0aIf you start a new wiki in any language with the latest PmWiki version, it is highly recommended to enable UTF-8. In the future, PmWiki will change to use the UTF-8 encoding by default, so if you already use it, you will not need a complex "migration" to UTF-8 later.%0a%0aTo enable UTF-8 for a new wiki, add this line near the beginning of @@config.php@@ (the @@docs/sample-config.php@@ file has this line already):%0a%0a%25hlt php%25[@%0a include_once("scripts/xlpage-utf-8.php");%0a@]%0a%0aThis line should come ''before'' a call to the %25hlt php%25@@XLPage()@@ function in [[internationalizations|international wikis]].%0a%0aSave your @@config.php@@ file encoded as UTF-8 (NO BOM). That allows entry of UTF-8 encoded characters in it. Make sure your editor does support this, and test by adding some non-ANSI UTF-8 characters, to see them in the text editor '^[[#notes|1]]^'.%0a%0aWith UTF-8 thus enabled you also got use of classes ''rtl'' and ''ltr'', which offer setting of the text direction to right-to-left, or left-to-right. This is useful for inclusion of right-to-left scripts like Arabic, Farsi (Persian), Hebrew, Urdu and others. %0a%0a!! Enabling UTF-8 on existing wikis%0a%0aCurrently, this is possible ''only if your group and page ''names'', as well as upload names, don't contain international characters''. The names of wiki pages are used as file names, and we don't have yet an easy way to rename the disk files.%0a%0aIf your wiki doesn't have international page/file names, first [[upgrade(s)]] to the latest PmWiki version. %0a%0aTo enable UTF-8:%0a# Delete the file @@ wiki.d/.pageindex@@. This file contains a cache of links and words from your pages and is used for searches and pagelists. PmWiki will rebuild it automatically with the new encoding.%0a# Add these lines near the beginning of @@config.php@@:%0a%0a%25hlt php%25[@%0a include_once("scripts/xlpage-utf-8.php");%0a $DefaultPageCharset = array(''=>'ISO-8859-1'); # see below%0a@]%0a%0aThese lines should come ''before'' a call to the %25hlt php%25@@XLPage()@@ function in [[internationalizations|international wikis]].%0a%0aThe $DefaultPageCharset line is there to fix and correctly handle some pages with missing or wrong attributes, created by older PmWiki versions.%0a%0a* Most wikis in European languages are likely to be in the ISO-8859-1 encoding and should use:\\%0a %25hlt php%25@@$DefaultPageCharset = array(''=>'ISO-8859-1');@@%0a* Wikis in Czech and Hungarian language are likely to be in the ISO-8859-2 encoding, they should use this line instead:\\%0a %25hlt php%25@@ $DefaultPageCharset = array(''=>'ISO-8859-2', 'ISO-8859-1'=>'ISO-8859-2'); @@%0a* Wikis in Turkish language are likely to be in the ISO-8859-9 encoding, they should use this line instead:\\%0a %25hlt php%25@@ $DefaultPageCharset = array(''=>'ISO-8859-9', 'ISO-8859-1'=>'ISO-8859-9'); @@%0a%0a%0a!!Support for RTL right-to-left languages%0aLanguages like Arabic, Hebrew, Farsi (Persian), Urdu and others are written in script flowing from right to left. Classes ''rtl'' and ''ltr'' can be used to specify direction of text independently of the general text direction within a page, for example: %0a(:markup:)%0a>>rtl%3c%3c%0aيتدفق هذا النص من اليمين إلى اليسار%0a>>ltr%3c%3c%0aThis text flows left to right.%0a>>%3c%3c%0a(:markupend:)%0a%0aTo set text direction for a wiki generally to RTL, you could add to @@config.php@@ a line like:%0a-> %25hlt php%25[@$HTMLStylesFmt['rtl'] = " body { direction:rtl; }"@]%0a%0abut the skin you use may need other modifications, for instance to swap the search box and the page actions to the other side etc. %0a%0aSome skins have full support for RTL, see for instance [[Skins:Amber|Amber]]. %0a%0a!!Using UTF-8 in page names and URLs%0aEnabling UTF-8 allows to use international characters in page names (for file names, see $UploadNameChars).%0a%0aThere are good reasons to use UTF-8 in page names. Easier configuration, works out of the box. Easier management of page titles (no need to add a %25pmhlt%25[@(:title ...:)@] directive). The possibility to have distinct pages for differently accented words, for example in a dictionary or vocabulary wiki. Better SEO if your URLs match certain search terms.%0a%0aAlso while the URLs may have URL-encoded international characters when you copy them, modern browsers display the actual characters in the URL bar, and major search engines understand the international URLs and show them decoded in the search results.%0a%0aOn the other hand, some people may prefer to restrict page names and file names to plain ASCII characters, especially if the language mostly uses the Latin alphabet.%0a%0aOne of the reasons may be to have plain URLs like %25hlt%25[@your-wiki.org/Francais/Champs-Elysees@] instead of [@your-wiki.org/Fran%25C3%25A7ais/Champs-%25C3%2589lys%25C3%25A9es@] (for a page name %25pmhlt%25[@[[Français.Champs-Élysées]]@]). See also [[Cookbook/ISO8859MakePageNamePatterns]].%0a%0aToday there shouldn't be many problems in using international characters in page and file names in UTF-8. But if some day you change servers or operating systems, plain Latin letters are more portable and there is less risk that something breaks.%0a%0aPmWiki automatically converts page text and metadata between encodings, but at the moment cannot automatically rename page files and attachments.%0a%0aIf you already have international characters in file names (page names, uploads), after enabling UTF-8, review your wiki pages and links - you may need to rename some of the files on the server.%0a%0a[[#notes]]%0a!! Notes%0a* You need to save your @@config.php@@ file in the UTF-8 encoding, and "Without Byte Order Mark (BOM)". See [[LocalCustomizations#encoding|Character encoding of config.php]].%0a%0a* This page concerns the most recent versions of PmWiki. See [[Cookbook:UTF-8]] for tips on older versions.%0a%0a* In the case your PmWiki installation displays wrong encoding, or save an UTF-8 page to an other encoding without explanation, you can double check your custom @@.htaccess@@ settings at the root of your served pages.%0a %0a +time=1676059487 blob - 1d65449c1afba9a933233b9c88b5c7eccc52688c blob + 10360f73328655d6d0797e5757afc30c09b95e27 --- wikilib.d/PmWiki.Upgrades +++ wikilib.d/PmWiki.Upgrades @@ -1,10 +1,10 @@ -version=pmwiki-2.2.118 ordered=1 urlencoded=1 +version=pmwiki-2.3.15 ordered=1 urlencoded=1 author=Petko charset=UTF-8 -csum=rm manual TOC, mv !!FAQ above the [[#faq]] line which is included in PmWiki/FAQ +csum=2.3.15 GUI Edit Buttons change (+455) name=PmWiki.Upgrades post= Save -rev=96 -targets=PmWiki.PmWiki,PmWiki.UpgradingFromPmWiki1,PmWiki.ReleaseNotes,PmWiki.BackupAndRestore,PmWiki.Download,PmWiki.SiteAnalyzer,PmWiki.LocalCustomizations,PmWiki.Troubleshooting,Site.Site,SiteAdmin.SiteAdmin,PmWiki.BasicVariables,PmWiki.WikiWords,PmWiki.EditVariables,PmWiki.Links,PmWiki.PageLists,PmWiki.SkinTemplates,PmWiki.AuthUser,PmWiki.Upgrades,PmWiki.ChangeLog,PmWiki.PageVariables,Site.PageActions,Site.EditForm,Site.PageNotFound,PmWiki.LayoutVariables,PmWiki.Version -text=(:Summary:How to upgrade an existing PmWiki installation:)%0a[[PmWiki]] is designed to make it easy to upgrade the PmWiki software without affecting your existing data files or installation. For most upgrades, you simply copy the files in the new release over your existing installation.%0a%0a%25block bgcolor=#f7f7f7 color=black border='1px solid black' padding=5px%25 '''Note for PmWiki 1.0 sites:''' Upgrading from 1.0.x to 2.0 requires more than simply copying the 2.0 software over the 1.0 installation. See [[(PmWiki:)Upgrading From PmWiki 1]] for more details.%0a%0a[[#gen]]%0a!! Generic instructions %0a%0a!!! 1. Read the release notes%0aPlease read carefully the [[(PmWiki:)ReleaseNotes]] before performing an upgrade, about the changes between your previous version and the new one. See if there are any significant changes or preparation tasks that must be handled before performing the upgrade.%0a%0a!!! 2. Backup%0aIt's ''always'' a good idea to have a [[(PmWiki:)backup( and Restore)]] copy of your existing PmWiki installation before starting. You can copy the entire directory containing your existing installation, or you can just make copies of the ''wiki.d/'' directory and any other local customization files you may have created (e.g., ''config.php'', ''localmap.txt'', etc.).%0a%0a!!! 3. Download and extract%0aDownload the version of PmWiki that you want from the [[(PmWiki:)download]] page.%0a%0aExtract the tar image using @@tar -xvzf ''tgzfile''@@, where ''tgzfile'' is the tar file you downloaded above. This will create a @@pmwiki-x.y.z@@ directory with the new version of the software.%0a%0a!!! 4. Copy%0aCopy the files in @@pmwiki-x.y.z@@ over the files of your existing PmWiki installation. For example, if your existing PmWiki installation is in a directory called ''pmwiki'', then one way to copy the new files over the existing ones is to enter the command:%0a%0a->@@cp -a pmwiki-x.y.z/. pmwiki@@%0a%0aNote that BSD systems will not have the -a option as a command-line argument for ''cp'', but that's okay, since it's just shorthand for ''cp -dpR'', so use that instead of ''-a''.%0a%0aSome environments have an alias established for ''cp'' that enable interactive prompts before overwriting a file. To work around this specify the absolute path to ''cp'', such as ''/bin/cp''.%0a%0aOn (some) [=FreeBSD=] servers and Mac OS X systems you need to use %0a%0a->@@cp -Rpv pmwiki-x.y.z/. pmwiki@@%0a%0a!!! 5. Update customisations and recipes%0aThat's it! Your base PmWiki installation is complete.%0a%0aNow use the [[PmWiki:Site Analyzer]] to determine which recipes could be updated to the most recent version.%0a%0aUnless you have made customizations to the ''pmwiki.php'' script or to the files in ''scripts/'', your PmWiki installation should continue to run correctly! (Changes to these files are {+not+} recommended).%0a%0a([[Local customizations]] should go in ''local/config.php'', ''pub/css'', and ''pub/skins/''yourskinname)%0a%0a'''Note''': Additional tips can be found on the [[PmWiki:Troubleshooting]] page.%0a%0a%0a[[#v21v22]]%0a!! Upgrading from version 2.1.27 to 2.2.0%0a%0aBetween the stable versions 2.1.27 and 2.2.0 there are a number of additions. Some of them may need changes to local config files or to wiki pages, and they are outlined here. For the full list of changes see [[ReleaseNotes#v220|the release notes]].%0a%0aIf you are upgrading from a 2.2.beta version, your wiki may already include these features.%0a%0a* Some pages that were formerly in the [[Site]].* group are now in a separate read-protected [[SiteAdmin]].* group: Site.AuthUser, Site.AuthList, Site.NotifyList, Site.Blocklist, and Site.ApprovedUrls. If upgrading from an earlier version, PmWiki will prompt to automatically copy these pages to their new location if needed. If a site wishes to continue using the old Site.* group for these pages, simply set to config.php @@$SiteAdminGroup = $SiteGroup;@@%0a%0a* To authorize reading or editing in protected areas, the former password @@"nopass"@@ should now be written as @@"@nopass"@@.%0a%0a* [[WikiWords]] are now disabled by default. To re-enable them, set either $LinkWikiWords or $EnableWikiWords to 1.%0a%0a* The $ROSPatterns variable has changed -- replacement strings are no longer passed through FmtPageName() i.e., it must now be done explicitly.%0a%0a* [[Links|Page links]] inside included pages, sidebars, headers or footers are now treated as relative to the page where they are written, instead of the page where they appear. For example, in Site.SideBar, always set the group in a wikilink like [@[[Main/HomePage]]@] or with a page variable [@[[{*$Group}/HomePage]]@], because a link [@[[HomePage]]@] will point to a page Site.HomePage.%0a%0a* [[PageLists]]%0a** Spaces no longer separate wildcard patterns -- use commas. %0a** [@{$PageCount}, {$GroupCount}, {$GroupPageCount}@] variables used in pagelist templates are now [@{$$PageCount}, {$$GroupCount}, {$$GroupPageCount}@].%0a** The directive no longer accepts parameters from urls by default. In order to have it accept such parameters (which was the default in 2.1 and earlier), add a [@request=1@] option to the [@(:pagelist:)@] directive.%0a%0a* [[Skin templates]] are now required to have %3c!--HTMLHeader--> and %3c!--HTMLFooter--> directives. %0a%0a* Authentication using Active Directory is now simplified, see [[PmWiki.AuthUser]].%0a%0a%0a[[#v220]]%0a!! Upgrading from version 2.2.0 to the latest version%0a%25commentout-pmwikiorg%25 ''Note: this page may have a more recent version, see PmWiki:Upgrades.''%0a%0aSome additions since version 2.2.0 may need changes to local config files or to wiki pages, and they are outlined here. For the full list of changes see [[ReleaseNotes|release notes]] and [[change log]].%0a%0a* Version 2.2.10: $EnableRelativePageVars was changed to enabled by default, and it affects [[PageVariables]] from included pages, sidebars, headers and footers.%0a** The form [@{*$var}@] refers to "the currently browsed page" while [@{$var}@] without an asterisk refers to "the physical page where the PageVar is written".%0a** %25red%25 Pages that are designed to work on "the currently browsed page" should switch to using [@{*$FullName}@] instead of [@{$FullName}@]. %25%25 Administrators should especially check any customized versions of [[Site.PageActions]], [[Site.EditForm]], [[Site.PageNotFound]], SideBar pages, $GroupHeaderFmt, $GroupFooterFmt, [[Page lists]] in sidebars, headers, and footers. See [[Page variables#specialreferences|Special references]].%0a** If your wiki heavily relies on the previous behavior, you can revert to it, see $EnableRelativePageVars.%0a%0a* Version 2.2.35: Important change for international wikis: the XLPage() function no longer loads encoding scripts such as xlpage-utf-8.php. When you upgrade, you need to include those scripts from config.php, before the call to XLPage(): [@%0a include_once("scripts/xlpage-utf-8.php"); # if your wiki uses UTF-8%0a XLPage('bg','PmWikiBg.XLPage');%0a@]%0a%0a!! FAQ%0a>>faq%3c%3c [[#faq]]%0a%0aQ: How can I determine what version of PmWiki I'm running now?%0aA: See [[version]] - {Version$:Summary}.%0a%0aQ: How can I test a new version of PmWiki on my wiki without changing the prior version used by visitors?%0aA: The easy way to do this is to install the new version in a separate%0adirectory, and for the new version set (in local/config.php):%0a[@%0a%0a $WikiLibDirs = array(&$WikiDir,%0a new PageStore('/path/to/existing/wiki.d/{$FullName}'),%0a new PageStore('wikilib.d/{$FullName}'));%0a%0a@]%0aThis lets you test the new version using existing page content%0awithout impacting the existing site or risking modification of%0athe pages. (Of course, any recipes or local customizations have to%0abe installed in the new version as well.) %0a%0aThen, once you're comfortable that the new version seems to work%0aas well as the old, it's safe to upgrade the old version (and one%0aknows of any configuration or page changes that need to be made).%0a -time=1567166317 +rev=105 +targets=PmWiki.PmWiki,PmWiki.UpgradingFromPmWiki1,PmWiki.Upgrades,PmWiki.ReleaseNotes,PmWiki.BackupAndRestore,PmWiki.Download,PmWiki.SiteAnalyzer,PmWiki.LocalCustomizations,PmWiki.Troubleshooting,Site.Site,SiteAdmin.SiteAdmin,PmWiki.BasicVariables,PmWiki.WikiWords,PmWiki.EditVariables,PmWiki.Links,PmWiki.PageLists,PmWiki.SkinTemplates,PmWiki.AuthUser,PmWiki.ChangeLog,PmWiki.PageVariables,Site.PageActions,Site.EditForm,Site.PageNotFound,PmWiki.LayoutVariables,Cookbook.PageListMultiTargets,PmWiki.Functions,PmWiki.Version +text=(:Summary:How to upgrade an existing PmWiki installation:)%0a[[PmWiki]] is designed to make it easy to upgrade the PmWiki software without affecting your existing data files or installation. For most upgrades, you simply copy the files in the new release over your existing installation.%0a%0a%25block bgcolor=#f7f7f7 color=black border='1px solid black' padding=5px%25 '''Note for PmWiki 1.0 sites:''' Upgrading from 1.0.x to 2.0 requires more than simply copying the 2.0 software over the 1.0 installation. See [[(PmWiki:)Upgrading From PmWiki 1]] for more details.%0a%0a%25commentout-pmwikiorg%25 ''Note: this page may have a more recent version, see PmWiki:Upgrades.''%0a%0a[[#gen]]%0a!! Generic instructions %0a%0a!!! 1. Read the release notes%0aPlease read carefully the [[(PmWiki:)ReleaseNotes]] before performing an upgrade, about the changes between your previous version and the new one. See if there are any significant changes or preparation tasks that must be handled before performing the upgrade.%0a%0a!!! 2. Backup%0aIt's ''always'' a good idea to have a [[(PmWiki:)backup( and Restore)]] copy of your existing PmWiki installation before starting. You can copy the entire directory containing your existing installation, or you can just make copies of the ''wiki.d/'' directory and any other local customization files you may have created (e.g., ''@@config.php@@'', ''@@localmap.txt@@'', etc.).%0a%0a!!! 3. Download and extract%0aDownload the version of PmWiki that you want from the [[(PmWiki:)download]] page.%0a%0aExtract the tar image using @@tar -xvzf ''tgzfile''@@, where ''tgzfile'' is the tar file you downloaded above. This will create a @@pmwiki-x.y.z@@ directory with the new version of the software.%0a%0a!!! 4. Copy%0aCopy the files in @@pmwiki-x.y.z@@ over the files of your existing PmWiki installation. For example, if your existing PmWiki installation is in a directory called ''pmwiki'', then one way to copy the new files over the existing ones is to enter the command:%0a%0a->@@cp -a pmwiki-x.y.z/. pmwiki@@%0a%0aNote that BSD systems will not have the -a option as a command-line argument for ''cp'', but that's okay, since it's just shorthand for ''cp -dpR'', so use that instead of ''-a''.%0a%0aSome environments have an alias established for ''cp'' that enable interactive prompts before overwriting a file. To work around this specify the absolute path to ''cp'', such as ''/bin/cp''.%0a%0aOn (some) [=FreeBSD=] servers and Mac OS X systems you need to use %0a%0a->@@cp -Rpv pmwiki-x.y.z/. pmwiki@@%0a%0a!!! 5. Update customisations and recipes%0aThat's it! Your base PmWiki installation is complete.%0a%0aNow use the [[PmWiki:Site Analyzer]] to determine which recipes could be updated to the most recent version.%0a%0aUnless you have made customizations to the ''@@pmwiki.php@@'' script or to the files in ''@@scripts/@@'', your PmWiki installation should continue to run correctly! (Changes to these files are {+not+} recommended).%0a%0a([[Local customizations]] should go in ''@@local/config.php@@'', ''@@pub/css@@'', and ''@@pub/skins/@@''@@yourskinname@@)%0a%0a'''Note''': Additional tips can be found on the [[PmWiki:Troubleshooting]] page.%0a%0a%0a[[#v21v22]]%0a!! Upgrading from version 2.1.27 to 2.2.0%0a%0aBetween the stable versions 2.1.27 and 2.2.0 there are a number of additions. Some of them may need changes to local config files or to wiki pages, and they are outlined here. For the full list of changes see [[ReleaseNotes#v220|the release notes]].%0a%0aIf you are upgrading from a 2.2.beta version, your wiki may already include these features.%0a%0a* Some pages that were formerly in the [[Site]].* group are now in a separate read-protected [[SiteAdmin]].* group: @@Site.AuthUser@@, @@Site.AuthList@@, @@Site.NotifyList@@, @@Site.Blocklist@@, and @@Site.ApprovedUrls@@. If upgrading from an earlier version, PmWiki will prompt to automatically copy these pages to their new location if needed. If a site wishes to continue using the old @@Site.*@@ group for these pages, simply set to @@config.php@@ %25hlt php%25@@$SiteAdminGroup = $SiteGroup;@@%0a%0a* To authorize reading or editing in protected areas, the former password @@"nopass"@@ should now be written as @@"@nopass"@@.%0a%0a* [[WikiWords]] are now disabled by default. To re-enable them, set either $LinkWikiWords or $EnableWikiWords to 1.%0a%0a* The $ROSPatterns variable has changed -- replacement strings are no longer passed through %25hlt php%25@@FmtPageName()@@ i.e., it must now be done explicitly.%0a%0a* [[Links|Page links]] inside included pages, sidebars, headers or footers are now treated as relative to the page where they are written, instead of the page where they appear. For example, in @@Site.SideBar@@, always set the group in a wikilink like %25pmhlt%25[@[[Main/HomePage]]@] or with a page variable [@[[{*$Group}/HomePage]]@], because a link [@[[HomePage]]@] will point to a page @@Site.HomePage@@.%0a%0a* [[PageLists]]%0a** Spaces no longer separate wildcard patterns -- use commas. %0a** %25pmhlt%25[@{$PageCount}, {$GroupCount}, {$GroupPageCount}@] variables used in pagelist templates are now [@{$$PageCount}, {$$GroupCount}, {$$GroupPageCount}@].%0a** The directive no longer accepts parameters from urls by default. In order to have it accept such parameters (which was the default in 2.1 and earlier), add a %25pmhlt%25[@request=1@] option to the [@(:pagelist:)@] directive.%0a%0a* [[Skin templates]] are now required to have %25hlt html%25@@%3c!--HTMLHeader-->@@ and @@%3c!--HTMLFooter-->@@ directives. %0a%0a* Authentication using Active Directory is now simplified, see [[PmWiki.AuthUser]].%0a%0a%0a[[#v220]]%0a!! Upgrading from version 2.2.0 to 2.2.145%0a%25commentout-pmwikiorg%25 ''Note: this page may have a more recent version, see PmWiki:Upgrades.''%0a%0aSome additions since version 2.2.0 may need changes to local config files or to wiki pages, and they are outlined here. For the full list of changes see [[ReleaseNotes|release notes]] and [[change log]].%0a%0a* Version 2.2.10: $EnableRelativePageVars was changed to enabled by default, and it affects [[PageVariables]] from included pages, sidebars, headers and footers.%0a** The form %25pmhlt%25[@{*$var}@] refers to "the currently browsed page" while [@{$var}@] without an asterisk refers to "the physical page where the PageVar is written".%0a** %25red%25 Pages that are designed to work on "the currently browsed page" should switch to using %25pmhlt%25[@{*$FullName}@] instead of [@{$FullName}@]. %25%25 Administrators should especially check any customized versions of [[Site.PageActions]], [[Site.EditForm]], [[Site.PageNotFound]], @@SideBar@@ pages, $GroupHeaderFmt, $GroupFooterFmt, [[Page lists]] in sidebars, headers, and footers. See [[Page variables#specialreferences|Special references]].%0a** If your wiki heavily relies on the previous behavior, you can revert to it, see $EnableRelativePageVars.%0a%0a* Version 2.2.35: Important change for international wikis: the %25hlt php%25@@XLPage()@@ function no longer loads encoding scripts such as @@xlpage-utf-8.php@@. When you upgrade, you need to include those scripts from @@config.php@@, before the call to %25hlt php%25@@XLPage()@@: [@%0a include_once("scripts/xlpage-utf-8.php"); # if your wiki uses UTF-8%0a XLPage('bg','PmWikiBg.XLPage');%0a@]%0a%0a%0a[[#v22v23]]%0a!! Upgrading from version 2.2.145 to 2.3.0%0a%25commentout-pmwikiorg%25 ''Note: this page may have a more recent version, see PmWiki:Upgrades.''%0a%0a[[ReleaseNotes#v230|Version 2.3.0]] requires PHP 5.3 or more recent. The new version includes a number of new features, some of which were previously provided by recipes. %0a%0aHere are the things to review when upgrading:%0a%0a* If you previously used Cookbook:PageListMultiTargets, please disable it when you upgrade. The same functionality is now available in the core.%0a* For PHP 8.1, the function %25hlt php%25@@strftime()@@ has been deprecated. PmWiki 2.3.0 provides a replacement function @@PSFT()@@, see PmWiki:Functions#PSFT.%0a* The @@RecentChanges@@ pages now store in the page source the time stamp in a slightly different, and portable international format (easily parsable). When the page is displayed, the new format is automatically converted to the current one ($TimeFmt), so the @@RecentChanges@@ pages will look exactly like before, but the source code will be slightly different. \\%0aIf you have custom $RecentChangesFmt settings, they will be preserved. If you have no custom settings but still prefer the old format, to revert to the old format, add this to @@config.php@@: %25hlt php%25[@%0a# revert to pre-2.3.0 RecentChanges%0a$RecentChangesFmt = array(%0a '$SiteGroup.AllRecentChanges' => %0a '* [[{$Group}.{$Name}]] . . . $CurrentTime $[by] $AuthorLink: [=$ChangeSummary=]',%0a '$Group.RecentChanges' =>%0a '* [[{$Group}/{$Name}]] . . . $CurrentTime $[by] $AuthorLink: [=$ChangeSummary=]');%0a@]%0a* The variable $EnableNotSavedWarning is now enabled by default. Add to @@config.php@@ $EnableNotSavedWarning = 0; to disable it. %0a* The core table of contents function ($PmTOC) has had its styles updated, in order to properly indent long sub-headings. Notably, the TOC links now have a @@display:block@@ setting and there are no line breaks between them. If you have previously added custom styles for PmTOC, please review these in case they need updating.%0a%0aSee also [[Release Notes]] for any changes between your previous version and the new one.%0a%0aIf you have any questions or difficulties, please let us know.%0a%0a%0a[[#v22v23]]%0a!! Upgrading from version 2.3.0 to more recent versions%0a%0a!!! [[ReleaseNotes#v2315|2.3.15]] GUI Edit Buttons change%0aPart of these functions were rewritten to avoid 'unsafe inline' JavaScript. While default and most custom buttons should work without change, you should no longer need to url-encode some characters like %25 or add backslashes. If you have such buttons, you may need to update their declarations to strip the extra backslashes. %0a%0a%0a!! FAQ%0a>>faq%3c%3c [[#faq]]%0a%0aQ: How can I determine what version of PmWiki I'm running now?%0aA: See [[version]] - {Version$:Summary}.%0a%0aQ: How can I test a new version of PmWiki on my wiki without changing the prior version used by visitors?%0aA: The easy way to do this is to install the new version in a separate%0adirectory, and for the new version set (in @@local/config.php@@):%0a%25hlt php%25[@%0a $WikiLibDirs = array(&$WikiDir,%0a new PageStore('/path/to/existing/wiki.d/{$FullName}'),%0a new PageStore('wikilib.d/{$FullName}'));%0a%0a@]%0aThis lets you test the new version using existing page content%0awithout impacting the existing site or risking modification of%0athe pages. (Of course, any recipes or local customizations have to%0abe installed in the new version as well.) %0a%0aThen, once you're comfortable that the new version seems to work%0aas well as the old, it's safe to upgrade the old version (and one%0aknows of any configuration or page changes that need to be made).%0a +time=1669057681 blob - 0c2366122f3cb6ed97860a2cd385092c41339b55 blob + c9a620c2941e227fd1dfea43214f013f0b8539c5 --- wikilib.d/PmWiki.UploadVariables +++ wikilib.d/PmWiki.UploadVariables @@ -1,9 +1,9 @@ -version=pmwiki-2.2.117 ordered=1 urlencoded=1 +version=pmwiki-2.3.17 ordered=1 urlencoded=1 author=Petko charset=UTF-8 -csum=It is only possible to enable characters that exist in the code page (charater set) of the wiki. +csum=reveal link to $IMapLinkFmt, format $UploadPrefixFmt (+8) name=PmWiki.UploadVariables -rev=86 +rev=89 targets=PmWiki.Uploads,PmWiki.UploadsAdmin,PmWiki.UploadVariables,Cookbook.Attachtable,PmWiki.PathVariables,PmWiki.LinkVariables,PmWiki.AvailableActions,PmWiki.BasicVariables -text=(:Summary:Variables used for uploads/attachments:)%0a%0aSee also: [[Uploads]], [[Uploads admin]].%0a%0a:$EnableUpload:The upload.php script is automatically included from stdconfig.php if the $EnableUpload variable is true in config.php. Note that one may still need to set an upload password before users can upload (see [[UploadsAdmin]]).%0a%0a:$UploadBlacklist:This array contains forbidden strings for an uploaded file (case insensitive). Some installations with the Apache server will try to execute a file which name contains ".php", ".pl" or ".cgi" even if it is not the last part of the filename. For example, a file named "test.php.txt" may be executed. To disallow such files to be uploaded, add to config.php such a line:%0a: : [@ $UploadBlacklist = array('.php', '.pl', '.cgi', '.py'); # disallow common script files@]%0a%0a:$UploadPermAdd:This variable sets additional unix permissions applied to newly uploaded files, and should be 0 (recommended as of 2013). If uploaded files cannot be downloaded and displayed on the website, for example with the error 403 Forbidden, set this value to 0444 (core setting, default since 2004).%0a: : [@$UploadPermAdd = 0; # recommended@]%0a%0a:$UploadPermSet:This variable sets unix permissions unconditionally applied to newly uploaded files, for example @@0604@@. %25note%25 '''Danger!''' Do not use this variable unless you know what you're doing! %25%25 If you make a mistake, uploaded files may be impossible to edit or delete via the FTP/SSH account (in that case, Cookbook:Attachtable may be used) or to be downloaded and displayed on the website. Note that file permissions may differ on different systems - if you copy or move your PmWiki installation, you may have to change it.%0a%0a:$UploadDir:The directory where uploads are to be stored. Defaults to ''uploads/'' in the pmwiki directory, but can be set to any location on the server. This directory must be writable by the webserver process if uploading is to occur.%0a%0a:$UploadUrlFmt:The url of the directory given by $UploadDir. By default, $UploadUrlFmt is derived from $PubDirUrl and $UploadDir.%0a%0a[[#IMapLinkFmtAttach]]%0a:$IMapLinkFmt[=['Attach:']=]: The format of the upload link displayed when an attachment exists. Can be changed with such a line in config.php:[@%0a$IMapLinkFmt['Attach:'] = "%3ca class='attachlink' href='\$LinkUrl'>\$LinkText%3c/a>";@]%0a %0a:$LinkUploadCreateFmt: The format of the upload link displayed when an attachment not present. Can be changed with such a line in config.php:[@%0a$LinkUploadCreateFmt = "%3ca class='createlinktext' href='\$LinkUpload'>\$LinkText%3c/a>%0a%3ca class='createlink' href='\$LinkUpload'> Δ%3c/a>";@]%0a%0a:$UploadPrefixFmt:Sets the prefix for uploaded files to allow attachments to be organized other than by groups. Defaults to [@'/$Group'@] (uploads are organized per-group), but can be set to other values for sitewide or per-page attachments.%0a $UploadPrefixFmt = '/$Group/$Name'; # per-page attachments%0a $UploadPrefixFmt = ''; # sitewide attachments%0a%0a: : It is recommended to have the $UploadPrefixFmt variable defined in config.php, the same for all pages in the wiki, and not in group/page local configuration files. Otherwise you ''will'' be unable to link to attachments in other wikigroups.%25%25%0a%0a:$EnableDirectDownload:When set to 1 (the default), links to attachments bypass PmWiki and come directly from the webserver. Setting $EnableDirectDownload=0; causes requests for attachments to be obtained via [[PmWiki/AvailableActions#download|[@?action=download@]]]. This allows PmWiki to protect attachments using a page's read permissions, but also increases the load on the server. Don't forget to protect your directory /uploads/ with a .htaccess file (Order Deny,Allow / Deny from all).%0a%0a:$EnableUploadGroupAuth:Set @@$EnableUploadGroupAuth = 1;@@ to authenticate downloads with the group password. This could be used together with @@$EnableDirectDownload = 0;@@. %25note%25 Note: $EnableUploadGroupAuth should not be enabled if your wiki uses per-page attachments.%25%25%0a%0a:$EnableUploadVersions:When set to 1 (default is 0), uploading a file to a location where a file of the same name already exists causes the old version to be renamed to @@file.ext,timestamp@@ (instead of being overwritten). @@timestamp@@ is a Unix-style timestamp.%0a%0a:$EnableUploadOverwrite:When set to 1 (the default), determines if overwriting previously uploaded files is allowed.%0a%0a:$UploadNameChars:The set of characters allowed in upload names. Defaults to [@"-\w. "@], which means alphanumerics, hyphens, underscores, dots, and spaces can be used in upload names, and everything else will be stripped. It is only possible to enable characters that exist in the code page (charater set) of the wiki, see [[Wikipedia:Code page]].%0a: :$UploadNameChars = "-\\w."; # allow dash, letters, digits, underscore, and dots (no spaces)%0a: :$UploadNameChars = "-\\w. \\x80-\\xff"; # allow Unicode%0a: : Note: Not all characters can be used in file names, because of various limitations in protocols or operating systems, file systems and server software, or conflict with PmWiki markup:%0a** [@ +?:@#%25!=/ @] have special meanings in URL addresses, %0a** [@ |\^`[]?:@#%25/ @] may be impossible to save on some systems,%0a** [@ %3c>"|\^`(){}[]#%25 @] may conflict with PmWiki markups,%0a: : so it is strongly recommended to only enable those if you know what you're doing.%0a%0a:$MakeUploadNamePatterns: An array of regular expression replacements that is used to normalize the filename of an attached file. First, everything but $UploadNameChars will be stripped, then the file extension will be converted to lowercase. Administrators can override these replacements with a custom definition (the full array needs to be defined). Currently the default sequence is: [@%0a $MakeUploadNamePatterns = array(%0a "/[^$UploadNameChars]/" => '', # strip all not-allowed characters%0a '/\\.[^.]*$/' => 'cb_tolower', # convert extension to lowercase (callback function)%0a '/^[^[:alnum:]_]+/' => '', # strip initial spaces, dashes, dots%0a '/[^[:alnum:]_]+$/' => '')) # strip trailing spaces, dashes, dots%0a@]%0a%0a:$UploadDirQuota:Overall size limit for all uploads.%0a%0a->[@%0a $UploadDirQuota = 100*1024; # limit uploads to 100KiB%0a $UploadDirQuota = 1000*1024; # limit uploads to 1000KiB%0a $UploadDirQuota = 1024*1024; # limit uploads to 1MiB%0a $UploadDirQuota = 25*1024*1024; # limit uploads to 25MiB%0a $UploadDirQuota = 2*1024*1024*1024; # limit uploads to 2GiB%0a@]%0a%0a:$UploadPrefixQuota:Overall size limit for one directory containing uploads. This directory is usually @@uploads/GroupName@@ (one for every WikiGroup), or @@uploads/Group/PageName@@ (one for every page), depending on the variable $UploadPrefixFmt.%0a%0a:$UploadMaxSize:Maximum size for uploading files, 50000 octets (bytes) by default.%0a%0a:$UploadExtSize:Maximum size per extension, overriding the default in $UploadMaxSize.%0a%0a->[@%0a $UploadExtSize['zip'] = 2*1024*1024; # allow up to 2MiB for zip files%0a@]%0a%0a:$UploadRedirectFunction:The function to be called after a file was posted. By default the "Redirect" function is called with arguments $pagename and the URL of the ?action=upload page (with additional information if the upload was successful or why it wasn't, and if the file was renamed). An add-on may define its own function, for example an AJAX upload may only return some variable back to the browser.%0a -time=1564393703 +text=(:Summary:Variables used for uploads/attachments:)%0a%0aSee also: [[Uploads]], [[Uploads admin]].%0a%0a:$EnableUpload:The upload.php script is automatically included from stdconfig.php if the $EnableUpload variable is true in config.php. Note that one may still need to set an upload password before users can upload (see [[UploadsAdmin]]).%0a%0a:$UploadBlacklist:This array contains forbidden strings for an uploaded file (case insensitive). Some installations with the Apache server will try to execute a file which name contains ".php", ".pl" or ".cgi" even if it is not the last part of the filename. For example, a file named "test.php.txt" may be executed. To disallow such files to be uploaded, add to config.php such a line:%0a: : %25hlt php%25[@ $UploadBlacklist = array('.php', '.pl', '.cgi', '.py'); # disallow common script files@]%0a%0a:$UploadPermAdd:This variable sets additional unix permissions applied to newly uploaded files, and should be 0 (recommended as of 2013). If uploaded files cannot be downloaded and displayed on the website, for example with the error 403 Forbidden, set this value to 0444 (core setting, default since 2004).%0a: : %25hlt php%25[@$UploadPermAdd = 0; # recommended@]%0a%0a:$UploadPermSet:This variable sets unix permissions unconditionally applied to newly uploaded files, for example @@0604@@. %25note%25 '''Danger!''' Do not use this variable unless you know what you're doing! %25%25 If you make a mistake, uploaded files may be impossible to edit or delete via the FTP/SSH account (in that case, Cookbook:Attachtable may be used) or to be downloaded and displayed on the website. Note that file permissions may differ on different systems - if you copy or move your PmWiki installation, you may have to change it.%0a%0a:$UploadDir:The directory where uploads are to be stored. Defaults to ''uploads/'' in the pmwiki directory, but can be set to any location on the server. This directory must be writable by the webserver process if uploading is to occur.%0a%0a:$UploadUrlFmt:The url of the directory given by $UploadDir. By default, $UploadUrlFmt is derived from $PubDirUrl and $UploadDir.%0a%0a[[#IMapLinkFmtAttach]]%0a:%25hlt php%25@@$IMapLinkFmt[=['Attach:']=]@@: The format of the upload link displayed when an attachment exists. Can be changed with such a line in @@config.php@@:%25hlt php%25[@%0a$IMapLinkFmt['Attach:'] = "%3ca class='attachlink' href='\$LinkUrl'>\$LinkText%3c/a>";@]%0a %0a:$LinkUploadCreateFmt: The format of the upload link displayed when an attachment not present. Can be changed with such a line in @@config.php@@:%25hlt php%25[@%0a$LinkUploadCreateFmt = "%3ca class='createlinktext' href='\$LinkUpload'>\$LinkText%3c/a>%0a%3ca class='createlink' href='\$LinkUpload'> Δ%3c/a>";@]%0a%0a:$UploadPrefixFmt:Sets the prefix for uploaded files to allow attachments to be organized other than by groups. Defaults to [@'/$Group'@] (uploads are organized per-group), but can be set to other values for sitewide or per-page attachments.\\%0a %25hlt php%25@@$UploadPrefixFmt = '/$Group/$Name'; # per-page attachments@@\\%0a %25hlt php%25@@$UploadPrefixFmt = ''; # sitewide attachments@@%0a%0a: : It is recommended to have the $UploadPrefixFmt variable defined in @@config.php@@, the same for all pages in the wiki, and not in group/page local configuration files. Otherwise you ''will'' be unable to link to attachments in other wikigroups.%25%25%0a%0a:$EnableDirectDownload:When set to 1 (the default), links to attachments bypass PmWiki and come directly from the webserver. Setting $EnableDirectDownload=0; causes requests for attachments to be obtained via [[PmWiki/AvailableActions#download|[@?action=download@]]]. This allows PmWiki to protect attachments using a page's read permissions, but also increases the load on the server. Don't forget to protect your directory /uploads/ with a @@.htaccess@@ file (Order Deny,Allow / Deny from all).%0a%0a:$EnableUploadGroupAuth:Set @@$EnableUploadGroupAuth = 1;@@ to authenticate downloads with the group password. This could be used together with @@$EnableDirectDownload = 0;@@. %25note%25 Note: $EnableUploadGroupAuth should not be enabled if your wiki uses per-page attachments.%25%25%0a%0a:$EnableUploadVersions:When set to 1 (default is 0), uploading a file to a location where a file of the same name already exists causes the old version to be renamed to @@file.ext,timestamp@@ (instead of being overwritten). @@timestamp@@ is a Unix-style timestamp.%0a%0a:$EnableUploadOverwrite:When set to 1 (the default), determines if overwriting previously uploaded files is allowed.%0a%0a:$UploadNameChars:The set of characters allowed in upload names. Defaults to [@"-\w. "@], which means alphanumerics, hyphens, underscores, dots, and spaces can be used in upload names, and everything else will be stripped. It is only possible to enable characters that exist in the code page (charater set) of the wiki, see [[Wikipedia:Code page]].%0a: :%25hlt php%25@@$UploadNameChars = "-\\w."; # default: allow dash, letters, digits, underscore, and dots (no spaces)@@%0a: :%25hlt php%25@@$UploadNameChars = "-\\w. \\x80-\\xff"; # allow Unicode@@%0a: : Note: Not all characters can be used in file names, because of various limitations in protocols or operating systems, file systems and server software, or conflict with PmWiki markup:%0a** [@ +?:@#%25!=/ @] have special meanings in URL addresses, %0a** [@ |\^`[]?:@#%25/ @] may be impossible to save on some systems,%0a** [@ %3c>"|\^`(){}[]#%25 @] may conflict with PmWiki markups,%0a: : so it is strongly recommended to only enable those if you know what you're doing.%0a%0a:$MakeUploadNamePatterns: An array of regular expression replacements that is used to normalize the filename of an attached file. First, everything but $UploadNameChars will be stripped, then the file extension will be converted to lowercase. Administrators can override these replacements with a custom definition (the full array needs to be defined). Currently the default sequence is: %25hlt php%25[@%0a $MakeUploadNamePatterns = array(%0a "/[^$UploadNameChars]/" => '', # strip all not-allowed characters%0a '/\\.[^.]*$/' => 'cb_tolower', # convert extension to lowercase (callback function)%0a '/^[^[:alnum:]_]+/' => '', # strip initial spaces, dashes, dots%0a '/[^[:alnum:]_]+$/' => '')) # strip trailing spaces, dashes, dots%0a@]%0a%0a:$UploadDirQuota:Overall size limit for all uploads.%0a%0a->%25hlt php%25[@%0a $UploadDirQuota = 100*1024; # limit uploads to 100KiB%0a $UploadDirQuota = 1000*1024; # limit uploads to 1000KiB%0a $UploadDirQuota = 1024*1024; # limit uploads to 1MiB%0a $UploadDirQuota = 25*1024*1024; # limit uploads to 25MiB%0a $UploadDirQuota = 2*1024*1024*1024; # limit uploads to 2GiB%0a@]%0a%0a:$UploadPrefixQuota:Overall size limit for one directory containing uploads. This directory is usually @@uploads/GroupName@@ (one for every WikiGroup), or @@uploads/Group/PageName@@ (one for every page), depending on the variable $UploadPrefixFmt.%0a%0a:$UploadMaxSize:Maximum size for uploading files, 50000 octets (bytes) by default.%0a%0a:$UploadExtSize:Maximum size per extension, overriding the default in $UploadMaxSize.%0a%0a->%25hlt php%25[@%0a $UploadExtSize['zip'] = 2*1024*1024; # allow up to 2MiB for zip files%0a@]%0a%0a:$UploadRedirectFunction:The function to be called after a file was posted. By default the "Redirect" function is called with arguments $pagename and the URL of the ?action=upload page (with additional information if the upload was successful or why it wasn't, and if the file was renamed). An add-on may define its own function, for example an AJAX upload may only return some variable back to the browser.%0a +time=1672218130 blob - 29570da53217148a412c70304d909fc3589a744a blob + 6e5260b2f667c5300a90f22637fa90c346ca4e4c --- wikilib.d/PmWiki.Uploads +++ wikilib.d/PmWiki.Uploads @@ -1,9 +1,9 @@ -version=pmwiki-2.2.129 ordered=1 urlencoded=1 -author=simon +version=pmwiki-2.3.18 ordered=1 urlencoded=1 +author=Petko charset=UTF-8 -csum=See [[PmWiki/Images]] for the files PmWiki automatically displays as images. (+82) +csum=despam (+8246) name=PmWiki.Uploads -rev=136 -targets=PmWiki.PmWiki,PmWiki.Images,PmWiki.UploadsAdmin,PmWiki.WikiGroup,PmWiki.UploadVariables,PmWiki.PageDirectives,PmWiki.WikiAdministrator,PmWiki.Passwords,PmWiki.PasswordsAdmin,Cookbook.Attachtable,Cookbook.AttachLinks,Site.PageActions,PmWiki.AvailableActions,Cookbook.UploadTypes,Cookbook.PreventHotlinking,Cookbook.LinkIcons -text=(:Summary:Allow authors to upload files, also known as page attachments:)%0a(:Audience: authors (intermediate) :)%0a[[PmWiki]] can be configured to allow authors to upload and store files and [[images]] (known as attaching them).%0aThese attachments may then be referenced from any page. %0a%0a-> ''Note'': ''[[PmWiki]] is distributed with uploads disabled by default. See [[Uploads Admin]] for information about how to enable and configure the upload feature.''%0a%0a-> ''Note2'': ''Uploads can be configured site-wide, by-group, or by-page; see [[Uploads Admin]] for details. This determines whether all uploads go in one directory for the site, an individual directory for each group, or an individual directory for each page. The default is to organize uploads by [[WikiGroup | group]].''%0a%0a!! [@Attach:@] syntax%0aTo add or link to an attachment, an author edits a page to include the markup "@@Attach:@@" followed by a name of an attachment (e.g., "@@[=Attach:resume.pdf=]@@"). When the page is displayed, the @@Attach:@@ markup becomes one of the following:%0a%0a* A link to the named attachment (if uploaded, ie already in the upload directory)%0a* A link to a form whereby the author can specify a file to be uploaded and used as the new attachment (if not yet uploaded, ie not in the upload directory)%0a* If the attachment is an [[image(s)]] file with an extension such as .gif, .jpeg, or .png, it is displayed as an [[image(s)]].%0a%0aThe behaviour of links can be modified to%0a* prevent an image attachment from displaying as an image, place it in double brackets (e.g., [@[[Attach:image.jpg]]@]).%0a* have a link to an attachment appear without the "[@Attach:@]" at the beginning of the link, use [@[[(Attach:)file.ext]]@].%0a* display a tool tip on mouse over (e.g., [@[[Attach:image.jpg"mouse over tool tip"]]@]).%0a%0a!! Attachments on other pages and groups%0aTo link to an uploaded attachment (image or file) from another group, you simply refer the group itself (make sure "Groupname" has the dot in it).%0a->[@Attach:Groupname./file_name.ext@] (note the dot after the groupname)%0aIf PmWiki is configured with an individual directory per page use%0a->[@Attach:Pagename/file_name.ext@] (Pagename is in the same WikiGroup)%0a->[@Attach:Groupname.Pagename/file_name.ext@]%0a%0a!! Names with spaces%0aTo link to a filename with spaces in it use the bracket link notation, eg%0a->[@[[Attach:a filename with spaces.txt]]@]%0a%0a"Embedding in the page" an image with spaces is not supported: just upload the images with names without spaces, and use the markup [@Attach:image.jpg@].%0a%0aThe following workaround is possible, but is unsupported and not recommended:%0a->[@[[#blank | Attach:image space.jpeg]]@]%0a%0a!! International characters in file names%0aSee [[UploadsAdmin]] and $UploadNameChars.%0a%0a!! Listing uploaded files on a page%0aTo list files that have been uploaded, use the markup:%0a[[PmWiki/PageDirectives#attachlist | [@(:attachlist:)@] ]]%0a%0aThis will list attachments to the current group or page, depending whether attachments are organised per group or per page; each instance includes a link to the attachment for viewing or downloading. A list of attachments is also shown as part of the uploads page form.%0a%0a!! Upload form / upload replacement%0aOne can go directly to the upload form by appending "?action=upload" to the URI for any page that has file uploads enabled by the [[Wiki Administrator]]. Replace a file by simply uploading a new version of the file with the same name. %0a* Be sure to clear your browser cache after replacing an upload. Otherwise, it may appear that the original upload is still on the server. %0aIf you put @@$EnableUploadVersions=1;@@ in your @@local/config.php@@, the old versions of the same files are renamed and not removed.%0a%0a[[#filetype]]%0a!! Type and size restrictions%0aFor security reasons, the upload feature is disabled when PmWiki is first installed.%0aWhen enabled uploads are restricted as to the types and sizes of files that may be uploaded to the server (see [[Uploads Admin]]). PmWiki's default configuration limits file sizes to 50 kilobytes and file extensions to common types such as ".gif", ".jpeg", ".doc", ".txt", and ".pdf". %0a%0aIn addition, the administrator can configure the system to require an @@upload@@ password--see [[Passwords]] and [[Passwords Admin]].%0a%0aBy default the upload allows the following extensions. Note that by default, it is possible to upload files with no extensions.%0a[[#imagetypes]] %0a gif, jpg, jpeg, png, bmp, ico, wbmp, svg, svgz, xcf, webp # image files%0aSee [[PmWiki/Images]] for the files PmWiki automatically displays as images.%0a[[#imagetypesend]]%0a mp3, au, wav, ogg, flac, opus, # audio%0a ogv, mp4, webm, mpg, mpeg, wmf, mov, qt, avi, mkv, # video%0a zip, 7z, gz, tgz, rpm, hqx, sit, # archives%0a odt, ods, odp, odg, doc, docx, ppt, pptx, xls, mdb, rtf, # Office%0a exe, # executables%0a pdf, psd, ps, ai, eps, # Adobe%0a htm, html, css, fla, swf, # web stuff%0a txt, tex, dvi, # text files%0a epub, kml, kmz, (files with no extension) # misc%0a%0a!!Removal%0aAt present uploaded files can only be deleted from the server by the [[wiki administrator]]. Any uploads-authorized user may over-write an existing file by uploading another of the same name and extension to the same location.%0a%0aThe administrator may remove an uploaded file by accessing the server via ftp (or via a control panel, if the host offers such a feature). The recipe Cookbook:Attachtable allows the deletion of the files from the wiki.%0a%0a!! FAQ%0a>>faq%3c%3c [[#faq]]%0a%0aQ: When I upload a file, how do I make the link look like "file.doc" instead of "Attach:file.doc"?%0aA: Use parentheses, as in [@[[(Attach:)file.doc]]@]. There is also a configuration change that can eliminate the [@Attach:@] -- see [[Cookbook:AttachLinks]].%0a%0aQ: Why can't I upload files of size more than 50kB to my newly installed PmWiki?%0aA: Out of the box PmWiki limits the size of files to be uploaded to 50kB. Add%0a->@@$UploadMaxSize = 1000000; # limit upload file size to 1 megabyte@@%0a->to your ''config.php'' to increase limit to 1MB (for example). See [[UploadsAdmin]] for how to further customize limits. Note that both PHP and webservers also place their own limits on the size of uploaded files.%0a%0aQ: Why does my upload exit unexpectedly with "Incomplete file received"?%0aA: You may be running out of space in a 'scratch' area, used either by PmWiki or by PHP. On *nix, check that you have sufficient free space in /tmp and /var/tmp.%0a%0aQ: How do I make it so that the upload link still allows one to make another upload (if someone wants to replace the old version of a file with a newer version, for example). Currently you only get the upload link when there is no file in the upload directory.%0aA: Use the Attach [[Site/page action(s)]], and click on the delta symbol %25blue%25(Δ)%25%25 shown against each of files listed. If you can't see the attach action either uploads are not enabled, you are not authorized to upload, or the attach action has been commented out or is missing. See also [[PmWiki/available actions]].%0a%0aQ: How do I hide the "[=Attach:=]" for all attachments%0aA: See Cookbook:AttachLinks, note that this does not currently work for [@ [[Attach:my file.ext]] @].%0a%0aQ: How can I link a file that have a 4-letter file extension such like 'abc.pptx'?%0aA: See [[Cookbook:Upload Types]]%0a%0aQ: How can I prevent others from using the url's of my images on their site%0aA: See [[Cookbook:Prevent Hotlinking]] {Cookbook.PreventHotlinking$:Summary}%0a%0aQ: How can I display a file that lacks a correct extension? [-(e.g. you are using Cookbook:LinkIcons)-]%0aA: A file can be displayed by addition of a "false" extension to the URL. For example, if the url is @@http://example.com/dox/mydoc@@, add a fake query string on the end with the desired extension (e.g., @@http://example.com/dox/mydoc?format=.docx@@). If query strings are unsuitable, a fragment identifier should work, e.g. @@http://example.com/dox/mydoc#.docx@@.%0a%0a -time=1590308334 +rev=153 +targets=PmWiki.PmWiki,PmWiki.Images,PmWiki.UploadsAdmin,PmWiki.WikiGroup,PmWiki.Links,PmWiki.UploadVariables,PmWiki.PageDirectives,PmWiki.WikiAdministrator,PmWiki.Passwords,PmWiki.PasswordsAdmin,Cookbook.Attachtable,Cookbook.AttachLinks,Site.PageActions,PmWiki.AvailableActions,Cookbook.UploadTypes,Cookbook.PreventHotlinking,Cookbook.LinkIcons +text=(:Summary:Allow authors to upload files, also known as page attachments:)%0a(:Audience: authors (intermediate) :)%0a[[PmWiki]] can be configured to allow authors to upload and store files and [[images]] (known as attaching them).%0aThese attachments may then be referenced from any page. %0a%0a-> ''Note'': ''[[PmWiki]] is distributed with uploads disabled by default. See [[Uploads Admin]] for information about how to enable and configure the upload feature.''%0a%0a-> ''Note2'': ''Uploads can be configured site-wide, by-group, or by-page; see [[Uploads Admin]] for details. This determines whether all uploads go in one directory for the site, an individual directory for each group, or an individual directory for each page. The default is to organize uploads by [[WikiGroup | group]].''%0a%0a!! %25pmhlt%25[@Attach:@] syntax%0aTo add or link to an attachment, an author edits a page to include the markup "%25pmhlt%25[@Attach:@]" followed by a name of an attachment (e.g., "[@Attach:resume.pdf@]"). When the page is displayed, the [@Attach:@] markup becomes one of the following:%0a%0a* A link to the named attachment (if uploaded, ie already in the upload directory)%0a* A link to a form whereby the author can specify a file to be uploaded and used as the new attachment (if not yet uploaded, ie not in the upload directory)%0a* If the attachment is an [[image(s)]] file with an extension such as .gif, .jpeg, or .png, it is displayed as an [[image(s)]].%0a%0aThe behavior of links can be modified to%0a* prevent an image attachment from displaying as an image, place it in double brackets (e.g., %25pmhlt%25[@[[Attach:image.jpg]]@]).%0a* have a link to an attachment appear without the "%25pmhlt%25[@Attach:@]" at the beginning of the link, use [@[[(Attach:)file.ext]]@].%0a* display a tool tip on mouse over (e.g., %25pmhlt%25[@Attach:image.jpg"mouse over tool tip"@]).%0a* display a tool tip and a caption (e.g., %25pmhlt%25[@Attach:image.jpg"mouse over tool" | Caption text@]).%0a%0a!! Attachments on other pages and groups%0aTo link to an uploaded attachment (image or file) from another group, you simply refer the group itself (make sure "Groupname" has the dot in it).%0a->%25pmhlt%25[@Attach:Groupname./file_name.ext@] (note the dot after the groupname)%0aIf PmWiki is configured with an individual directory per page use%0a->%25pmhlt%25[@Attach:Pagename/file_name.ext@] (Pagename is in the same WikiGroup)%0a->%25pmhlt%25[@Attach:Groupname.Pagename/file_name.ext@]%0a%0a!! Names with spaces and special characters%0aTo link to a filename with spaces in it use the bracket link notation, eg%0a->%25pmhlt%25[@[[Attach:a filename with spaces.txt]]@]%0a%0aTo embed an image with spaces or special characters [[Links#escaped | escape them]] with the markup %25pmhlt%25[@Attach:[=image name.jpg=]@].%0a%0a!! International characters in file names%0aSee [[UploadsAdmin]] and $UploadNameChars.%0a%0a!! Listing uploaded files on a page%0aTo list files that have been uploaded, use the directive %25pmhlt%25[@(:attachlist:)@] -- see [[PmWiki/PageDirectives#attachlist]] for more options.%0a%0aThis will list attachments to the current group or page, depending whether attachments are organized per group (default) or per page; each instance includes a link to the attachment for viewing or downloading. A list of attachments is also shown as part of the upload file form.%0a%0a!! Upload form / upload replacement%0aOne can go directly to the upload form by appending "?action=upload" to the URI for any page that has file uploads enabled by the [[Wiki Administrator]]. Replace a file by simply uploading a new version of the file with the same name. %0a* Be sure to clear your browser cache after replacing an upload. Otherwise, it may appear that the original upload is still on the server. %0aIf you put @@$EnableUploadVersions=1;@@ in your @@local/config.php@@, the old versions of the same files are renamed and not removed.%0a%0a[[#filetype]]%0a!! Type and size restrictions%0aFor security reasons, the upload feature is disabled when PmWiki is first installed.%0aWhen enabled uploads are restricted as to the types and sizes of files that may be uploaded to the server (see [[Uploads Admin]]). PmWiki's default configuration limits file sizes to 50 kilobytes and file extensions to common types such as ".gif", ".jpeg", ".doc", ".txt", and ".pdf". %0a%0aIn addition, the administrator can configure the system to require an @@upload@@ password--see [[Passwords]] and [[Passwords Admin]].%0a%0aBy default the upload allows the following extensions. Note that by default, it is possible to upload files with no extensions.%0a[[#imagetypes]] %0a gif, jpg, jpeg, png, bmp, ico, wbmp, svg, svgz, xcf, webp # image files%0aSee [[PmWiki/Images]] for the files PmWiki automatically displays as images.%0a[[#imagetypesend]]%0a mp3, au, wav, ogg, flac, opus, # audio%0a ogv, mp4, webm, mpg, mpeg, wmf, mov, qt, avi, mkv, # video%0a zip, 7z, gz, tgz, rpm, hqx, sit, # archives%0a odt, ods, odp, odg, doc, docx, ppt, pptx, xls, mdb, rtf, # Office%0a exe, # executables%0a pdf, psd, ps, ai, eps, # Adobe%0a htm, html, css, fla, swf, # web stuff%0a txt, tex, dvi, # text files%0a epub, kml, kmz, (files with no extension) # misc%0a%0a!!Removal%0aAt present uploaded files can only be deleted from the server by the [[wiki administrator]]. Any uploads-authorized user may over-write an existing file by uploading another of the same name and extension to the same location.%0a%0aThe administrator may remove an uploaded file by accessing the server via ftp (or via a control panel, if the host offers such a feature). The recipe Cookbook:Attachtable allows the deletion of the files from the wiki.%0a%0a!! FAQ%0a>>faq%3c%3c [[#faq]]%0a%0aQ: When I upload a file, how do I make the link look like "file.doc" instead of "Attach:file.doc"?%0aA: Use parentheses, as in %25pmhlt%25[@[[(Attach:)file.doc]]@]. There is also a configuration change that can eliminate the [@Attach:@] -- see [[Cookbook:AttachLinks]].%0a%0aQ: Why can't I upload files of size more than 50kB to my newly installed PmWiki?%0aA: Out of the box PmWiki limits the size of files to be uploaded to 50kB. Add%0a->@@$UploadMaxSize = 1000000; # limit upload file size to 1 megabyte@@%0a->to your ''config.php'' to increase limit to 1MB (for example). See [[UploadsAdmin]] for how to further customize limits. Note that both PHP and webservers also place their own limits on the size of uploaded files.%0a%0aQ: Why does my upload exit unexpectedly with "Incomplete file received"?%0aA: You may be running out of space in a 'scratch' area, used either by PmWiki or by PHP. On *nix, check that you have sufficient free space in /tmp and /var/tmp.%0a%0aQ: How do I make it so that the upload link still allows one to make another upload (if someone wants to replace the old version of a file with a newer version, for example). Currently you only get the upload link when there is no file in the upload directory.%0aA: Use the Attach [[Site/page action(s)]], and click on the delta symbol %25blue%25(Δ)%25%25 shown against each of files listed. If you can't see the attach action either uploads are not enabled, you are not authorized to upload, or the attach action has been commented out or is missing. See also [[PmWiki/available actions]].%0a%0aQ: How do I hide the "[=Attach:=]" for all attachments%0aA: See Cookbook:AttachLinks, note that this does not currently work for %25pmhlt%25[@ [[Attach:my file.ext]] @].%0a%0aQ: How can I link a file that have a 4-letter file extension such like 'abc.pptx'?%0aA: See [[Cookbook:Upload Types]]%0a%0aQ: How can I prevent others from using the url's of my images on their site%0aA: See [[Cookbook:Prevent Hotlinking]] {Cookbook.PreventHotlinking$:Summary}%0a%0aQ: How can I display a file that lacks a correct extension? [-(e.g. you are using Cookbook:LinkIcons)-]%0aA: A file can be displayed by addition of a "false" extension to the URL. For example, if the url is @@https://example.com/dox/mydoc@@, add a fake query string on the end with the desired extension (e.g., @@https://example.com/dox/mydoc?format=.docx@@). If query strings are unsuitable, a fragment identifier should work, e.g. @@https://example.com/dox/mydoc#.docx@@.%0a%0a%0a +time=1674015043 blob - 55962e4334ebf21c0f51251f641cd2ef9c3ee77b blob + 9c0b7e337d6ab35520f125b18175ef68e5206b1f --- wikilib.d/PmWiki.UploadsAdmin +++ wikilib.d/PmWiki.UploadsAdmin @@ -1,10 +1,10 @@ -version=pmwiki-2.2.127 ordered=1 urlencoded=1 -author=Petko +version=pmwiki-2.2.145 ordered=1 urlencoded=1 +author=simon charset=UTF-8 -csum=move customization to talk page (-819) +csum=http+s, update links (+3) name=PmWiki.UploadsAdmin -rev=174 +rev=175 targets=PmWiki.PmWiki,PmWiki.Uploads,PmWiki.Security,PmWiki.WikiAdministrator,PmWiki.PasswordsAdmin,PmWiki.UploadVariables,PmWiki.SecurityVariables,PmWiki.Passwords,Cookbook.UploadGroups,PmWiki.GroupCustomizations,PmWiki.LocalCustomizations,Cookbook.UploadTypes,Cookbook.SecureAttachments,PmWiki.DebugVariables,PmWiki.WikiGroup,PmWiki.PageDirectives -text=(:title Uploads Administration:)%0a(:Summary:Administration of PmWiki [[uploads]]:)%0a[[PmWiki]] includes a script called ''upload.php'' that allows users to [[upload(s)]] files to the wiki server using a web browser. Uploaded files (also called ''attachments'') can then be easily accessed using markup within wiki pages. This page describes how to install and configure the upload feature.%0a%0a%0a!! Some notes about [[security]] [[#security]]%0a%0aPmWiki takes a somewhat, but justifiable, paranoid stance%0awhen it comes to the uploads feature. Thus, the default settings for%0auploads tend to try to restrict the feature as much as possible:%0a%0a* The upload function is disabled by default%0a* Even if you enable it, the function is password locked by default%0a* Even if you remove the password, you're restricted to uploading files with certain names, extensions, and sizes%0a* The characters that may appear in upload filenames are (default) alphanumerics, hyphen, underscore, dot, and space ([[#restrictinguploadedfiles|see also here]]).%0a* The maximum upload size is small (50K by default)%0a%0aThis way the potential damage is limited until/unless the wiki%0aadministrator explicitly relaxes the restrictions.%0a%0aKeep in mind that letting users (anonymously!) upload files to your web server does entail some amount of risk. The ''upload.php'' script has been designed to reduce the hazards, but [[wiki administrator]]s should be aware that the potential for vulnerabilities exist, and that misconfiguration of the upload utility could lead to unwanted consequences.%0a%0aBy default, authorized users are able to overwrite files that have already been uploaded, without the possibility of restoring the previous version of the file. If you want to disallow users from being able to overwrite files that have already been uploaded, add the following line to ''config.php'':%0a%0a->%25hlt php%25[@$EnableUploadOverwrite = 0;@]%0a%0aAlternatively, an administrator can [[#upload_versions|keep older versions]] of uploads.%0a%0aAn administrator can also [[#direct_download|configure]] PmWiki so the password mechanism controls access to uploaded files.%0a%0a%0a!! Basic installation%0a%0aThe ''upload.php'' script is automatically included from ''stdconfig.php'' if the $EnableUpload variable is true in ''config.php''. In addition, ''config.php'' can set the $UploadDir and $UploadUrlFmt variables to specify the local directory where uploaded files should be stored, and the URL that can be used to access that directory. By default, $UploadDir and $UploadUrlFmt assume that uploads will be stored in a directory called ''uploads/'' within the current directory (usually the one containing ''pmwiki.php''). In addition, ''config.php'' should also set a default upload password (see [[PasswordsAdmin]]).%0a%0aThus, a basic ''config.php'' for uploads might look like:%0a%0a->%25hlt php%25[@%0a%3c?php if (!defined('PmWiki')) exit();%0a## Enable uploads and set a site-wide default upload password.%0a$EnableUpload = 1;%0a$UploadPermAdd = 0;%0a$DefaultPasswords['upload'] = pmcrypt('secret');%0a@]%0a%0aIf you have edit passwords and wish to allow all users with edit rights to upload, instead of $DefaultPasswords['upload'], you can set @@$HandleAuth['upload'] = 'edit';@@ in config.php.%0a%0a'''Important''': do NOT create the uploads directory yet! See the next paragraph.%0a%0aYou may also need to explicitly set which filesystem directory will hold uploads and provide a URL that corresponds to that directory like:%0a%0a->%25hlt php%25[@%0a$UploadDir = "/home/foobar/public_html/uploads";%0a$UploadUrlFmt = "http://example.com/~foobar/uploads";%0a@]%0a%0a%25red%25 Note: In most installations, you don't need to define or change these variables, usually PmWiki can detect them (and if you do, uploads may simply not work).%0a%0a[[#uploaddirectoryconfiguration]]%0a!!! Upload directory configuration [[#dirconf]]%0aUploads can be configured ''site-wide'', ''by-group'' (default), or ''by-page'' by changing $UploadPrefixFmt in @@config.php@@. %0aThis determines whether all uploads go in one directory for the site, an individual directory for each group, or an individual directory for each page. The default is to organize upload by group. %0a%0a''It is recommended that the $UploadPrefixFmt variable defined in config.php is the same for all pages in the wiki, and not different in group or page local configuration files. Otherwise you '''will''' be unable to link to attachments in other wikigroups.''%0a%0a!!!! Single upload directory [[#sitewideprefix]]%0aFor site-wide uploads, use%0a%0a->%25hlt php%25[@$UploadPrefixFmt = '';@]%0a%0a!!!! Per page upload directories [[#pageprefix]]%0aTo organize uploads by page, use:%0a%0a->%25hlt php%25[@$UploadPrefixFmt = '/$Group/$Name';@]%0a%0aYou may prefer uploads attached per-page rather than per-group or per-site if you plan to have many files attached to individual pages. This setting simplifies the management of picture galleries for example. (In a page, you can always link to attachments to other pages.)%0a%0a!!! The upload directory [[#uploaddir]]%0a%0aFor the upload feature to work properly, the directory given by [=$UploadDir=] must be writable by the web server process, and it usually must be in a location that is accessible to the web somewhere (e.g., in a subdirectory of ''public_html''). Executing PmWiki with uploads enabled will prompt you with the set of steps required to create the uploads directory on your server (it differs from one server to the next). ''Note that in that case you may be required to explicitly create writable group- or page-specific subdirectories as well!''%0a%0a%0a!!! Uploading a file [[#uploadfile]]%0a%0aOnce the upload feature is enabled, users can access the upload form by adding "@@?action=upload@@" to the end of a normal PmWiki URL. The user will be prompted for an upload password similar to the way other pages ask for passwords (see [[Passwords]] and [[PasswordsAdmin]] for information about setting passwords on pages, groups, and the entire site).%0a%0aAnother way to access the upload form is to insert the markup "[@Attach:filename.ext@]" into an existing page, where @@filename.ext@@ is the name of a new file to be uploaded. When the page is displayed, a '?-link' will be added to the end of the markup to take the author to the upload page. (See [[Uploads]] for syntax variations.)%0a%0aBy default, PmWiki will organize the uploaded files into separate subdirectories for each group. This can be changed by modifying the $UploadPrefixFmt variable. See [[Cookbook:UploadGroups]] for details.%0a%0a%0a!! [[#upload_versions]] Versioning Uploaded Files%0a%0aPmWiki does not manage versioning of uploaded files by default. However, by setting @@$EnableUploadVersions=1;@@ an administrator can have older versions of uploads preserved in the uploads directory along with the most recent version.%0a%0a!! Upload restrictions%0a!!! Restricting uploaded files for groups and pages%0a%0aUploads can be enabled only for specific groups or pages by using a [[group customization(s)]]. Simply set @@$EnableUpload=1;@@ for those groups or pages where uploading is to be enabled; alternately, set @@$EnableUpload=1;@@ in the config.php file and then set @@$EnableUpload=0;@@ in the per-group or per-page customization files where uploads are to be disabled.%0a%0a!!! Restricting total upload size for a group or the whole wiki%0a%0aUploads can be restricted to an overall size limit for groups. In the group configuration file (i.e., local/Group.php), add the line%0a%0a->%25hlt php%25@@$UploadPrefixQuota = 1000000; # limit group uploads to 1000KB (1MB)@@%25%25%0a%0aThis will limit the total size of uploads for that group to 1000KB --any upload that pushes the total over the limit will be rejected with an error message. This value defaults to zero (unlimited).%0a%0aUploads can also be restricted to an overall size limit for all uploads. Add the line%0a%0a->%25hlt php%25@@$UploadDirQuota = 10000000; # limit total uploads to 10000KB (10MB)@@%25%25%0a%0aThis will limit the total size of uploads for the whole wiki to 10000KB --any upload that pushes the total over the limit will be rejected with an error message. This value defaults to zero (unlimited).%0a%0a%0a[[#restrictinguploadedfiles]]%0a!!!Restricting uploaded files type and size%0a%0aThe upload script performs a number of verifications on an uploaded file before storing it in the upload directory. The basic verifications are described below.%0a:'''filenames''': the name for the uploaded file can contain only letters, digits, underscores, hyphens, spaces, and periods, and the name must begin and end with a letter or digit. %0a:'''file extension''': only files with approved extensions such as "@@.gif@@", "@@.jpeg@@", "@@.doc@@", etc. are allowed to be uploaded to the web server. This is vitally important for server security, since the web server might attempt to execute or specially process files with extensions like "@@.php@@", "@@.cgi@@", etc. %0a:'''file size''': By default all uploads are limited to 50K bytes, as specified by the $UploadMaxSize variable. Thus, to limit all uploads to 100KB, simply specify a new value for $UploadMaxSize in ''config.php'':%0a%0a->%25hlt php%25[@$UploadMaxSize = 100000;@]%0a%0aHowever, the default maximum file size can also be specified for each type of file uploaded. Thus, an administrator can restrict "@@.gif@@" and "@@.jpeg@@" files to 20K, "@@.doc@@" files to 200K, and all others to the size given by $UploadMaxSize. The $UploadExtSize array is used to determine which file extensions are valid and the maximum upload size (in bytes) for each file type. For example:%0a%0a->%25hlt php%25[@$UploadExtSize['gif'] = 20000; # limit .gif files to 20KB@]%0a%0a[[#disallow_ext]]%0a!!! Disabling file upload by file type%0aSetting an entry to zero disables file uploads of that type altogether:%0a%0a->%25hlt php%25[@$UploadExtSize['zip'] = 0; # disallow .zip files%0a$UploadExtSize[''] = 0; # disallow files with no extension@]%0a%0aYou can limit which types of files are uploadable by disabling all defaults and specifying only desired types.%0aSetting the variable $UploadMaxSize to zero will disable all default file types. Individual file types may then be enabled by setting their maximum size with the variable $UploadExtSize.%0a%0a-> %25hlt php%25[@# turns off all upload extensions%0a$UploadMaxSize = 0;%0a%0a# enable only these file types for uploading%0a$aSize=100000; // 100 KB file size limitation%0a$UploadExtSize['jpg' ] = $aSize;%0a$UploadExtSize['gif' ] = $aSize;%0a$UploadExtSize['png' ] = $aSize;%0a@]%0a%0a!!! Note: Files with multiple extensions%0a%0aSome installations with the Apache server will try to execute a file which name contains ".php", ".pl" or ".cgi" even if it isn't the last part of the filename. For example, a file named "test.php.txt" may be executed. To disallow such files to be uploaded, add to config.php such a line:%0a%0a-> %25hlt php%25@@$UploadBlacklist = array('.php', '.pl', '.cgi');@@%25%25%0a%0a[[#newuploadfiletypes]]%0a!! Adding new file types to permitted uploads%0a%0aTo add a new extension to the list of allowed upload types, add a line like the following to a [[local customization(s)]] file:%0a%0a->%25hlt php%25[@$UploadExts['ext'] = 'content-type';@]%0a%0awhere ''ext'' is the extension to be added, and ''content-type'' is the "[[(Wikipedia:)MIME type]]", or content-type (which you may find %25newwin%25[[http://www.iana.org/assignments/media-types/ | here]] or on the lower part of %25newwin%25[[http://www.w3schools.com/media/media_mimeref.asp | this page]]) to be used for files with that extension. For example, to add the '[@dxf@]' extension with a Content-Type of '[@image/x-dxf@]', place the line%0a%0a->%25hlt php%25[@$UploadExts['dxf'] = 'image/x-dxf';@]%0a%0aEach entry in $UploadExts needs to be the extension and the%0amime-type associated with that extension, thus:%0a%0a->%25hlt php%25[@%0a$UploadExts = array(%0a 'gif' => 'image/gif',%0a 'jpeg' => 'image/jpeg',%0a 'jpg' => 'image/jpeg',%0a 'png' => 'image/png',%0a 'xxx' => 'yyyy/zzz'%0a);%0a@]%0a%0aFor the types that PmWiki already knows about it's not necessary to repeat them here (the ''upload.php'' script adds PmWiki's defaults to whatever the administrator supplies).%0a[[#newuploadfiletypesend]]%0aSee also Cookbook:UploadTypes for additional types.%0a%0a[[#otherfilesizelimits]]%0a!!Other file size limits%0a%0aThere are other factors involved that affect upload file sizes. In Apache 2.0, there is a [[http://httpd.apache.org/docs/2.2/mod/core.html#limitrequestbody|LimitRequestBody]] directive that controls the maximum size of anything that is posted (including file uploads). Apache has this defaulted to unlimited size. However, some Linux distributions (e.g., Red Hat Linux) limit postings to 512K so this may need to be changed or increased. (Normally these settings are in an ''httpd.conf'' configuration file or in a file in ''/etc/httpd/conf.d''.)%0a%0aProblem noted on Red Hat 8.0/9.0 with Apache 2.0.x, the error "Requested content-length of 670955 is larger than the configured limit of 524288" was occurring under Apache and a "Page not found" would appear in the browser. Trying the above settings made no change with PHP, but on Red Hat 8.0/9.0 there is an additional PHP config file, /etc/httpd/conf.d/php.conf, and increasing the number on the line "`LimitRequestBody 524288" solves the issue.%0a%0aPHP itself has two limits on file uploads (usually located in @@/etc/php.ini@@). The first is the @@upload_max_filesize@@ parameter, which is set to 2MB by default. The second is @@post_max_size@@, which is set to 6MB by default.%0a%0aWith the variables in place--PmWiki's maximum file size, Apache's request-size limits, and the PHP file size parameters, the maximum uploaded file size will be the smallest of the three variables.%0a%0a!!! [[#direct_download]] Password protecting uploaded files%0aSetting a read password for pages (and groups) will prevent an attached file from being seen or accessed through the page, but to prevent direct access to the file location (the uploads/ directory) one can do the following:%0a %0a* In local/config.php set @@$EnableDirectDownload=0@@;%0a* If you use per-group upload directories (PmWiki default, see $UploadPrefixFmt), add to config.php @@$EnableUploadGroupAuth = 1;@@%0a* Deny public access to the uploads/ directory through moving it out of the html/ or public_html/ directory tree, or through a .htaccess file.%0a%0a%0aSee [[Cookbook:Secure attachments]] {Cookbook.SecureAttachments$:Summary}%0a%0a%0a!! Other notes%0a%0a* If uploads doesn't seem to work, make sure that your PHP installation allows uploads. The ''php.ini'' file (usually ''/etc/php.ini'' or ''/usr/local/lib/php.ini'') should have %0a%0a->[@file_uploads = On@]%0a%0a* Another source of error in the ''php.ini'' file is a not defined ''upload_tmp_dir''. Just set this variable to your temp directory, e.g.%0a%0a->[@upload_tmp_dir = /tmp@]%0a%0a%0aNote that if you change this values, httpd must generally be restarted. Another way to check if uploads are allowed by the server is to set $EnableDiag to 1 in ''config.php'', and set ?action=phpinfo on a URL. The "@@file_uploads@@" variable must have a value of 1 (if it says "@@no value@@", that means it's off).%0a%0a%0a!! FAQ [[#FAQ]]%0a>>faq%3c%3c [[#faq]]%0a%0aQ: How do I disable uploading of a certain type of file?%0aA: Here's an example of what to add to your ''local/config.php'' file to disable uploading of .zip files, or of files with no extension:%0a%0a%25hlt php%25[@%0a$UploadExtSize['zip'] = 0; # Disallow uploading .zip files%0a$UploadExtSize[''] = 0; # Disallow files with no extension@]%0a%0aQ: How do I attach uploads to individual pages or the entire site, instead of organizing them by [[wiki group]]?%0aA: Use the $UploadPrefixFmt variable (see also the Cookbook:UploadGroups recipe).%0a%0a%25hlt php%25[@%0a$UploadPrefixFmt = '/$FullName'; # per-page, in Group.Name directories%0a$UploadPrefixFmt = '/$Group/$Name'; # per-page, in Group directories with Name subdirectories%0a$UploadPrefixFmt = ''; # site-wide@]%0a%0aQ:For $UploadDirQuota - can you provide some units and numbers? Is the specification in bytes or bits? What is the number for 100K? 1 Meg? 1 Gig? 1 Terabyte?%0aA: Units are in bytes. %0a%0a%25hlt php%25[@%0a $UploadDirQuota = 100*1024; # limit uploads to 100KiB%0a $UploadDirQuota = 1000*1024; # limit uploads to 1000KiB%0a $UploadDirQuota = 1024*1024; # limit uploads to 1MiB%0a $UploadDirQuota = 25*1024*1024; # limit uploads to 25MiB%0a $UploadDirQuota = 2*1024*1024*1024; # limit uploads to 2GiB@]%0a%0aQ: Is there a way to allow file names with Unicode or additional characters? %0aA: Yes, see $UploadNameChars%0a%0aQ:Where is the list of attachments stored?%0aA: It is generated on the fly by the [[PageDirectives#attachlist|(:attachlist:)]] markup.%0a -time=1586370368 +text=(:title Uploads Administration:)%0a(:Summary:Administration of PmWiki [[uploads]]:)%0a[[PmWiki]] includes a script called ''upload.php'' that allows users to [[upload(s)]] files to the wiki server using a web browser. Uploaded files (also called ''attachments'') can then be easily accessed using markup within wiki pages. This page describes how to install and configure the upload feature.%0a%0a%0a!! Some notes about [[security]] [[#security]]%0a%0aPmWiki takes a somewhat, but justifiable, paranoid stance%0awhen it comes to the uploads feature. Thus, the default settings for%0auploads tend to try to restrict the feature as much as possible:%0a%0a* The upload function is disabled by default%0a* Even if you enable it, the function is password locked by default%0a* Even if you remove the password, you're restricted to uploading files with certain names, extensions, and sizes%0a* The characters that may appear in upload filenames are (default) alphanumerics, hyphen, underscore, dot, and space ([[#restrictinguploadedfiles|see also here]]).%0a* The maximum upload size is small (50K by default)%0a%0aThis way the potential damage is limited until/unless the wiki%0aadministrator explicitly relaxes the restrictions.%0a%0aKeep in mind that letting users (anonymously!) upload files to your web server does entail some amount of risk. The ''upload.php'' script has been designed to reduce the hazards, but [[wiki administrator]]s should be aware that the potential for vulnerabilities exist, and that misconfiguration of the upload utility could lead to unwanted consequences.%0a%0aBy default, authorized users are able to overwrite files that have already been uploaded, without the possibility of restoring the previous version of the file. If you want to disallow users from being able to overwrite files that have already been uploaded, add the following line to ''config.php'':%0a%0a->%25hlt php%25[@$EnableUploadOverwrite = 0;@]%0a%0aAlternatively, an administrator can [[#upload_versions|keep older versions]] of uploads.%0a%0aAn administrator can also [[#direct_download|configure]] PmWiki so the password mechanism controls access to uploaded files.%0a%0a%0a!! Basic installation%0a%0aThe ''upload.php'' script is automatically included from ''stdconfig.php'' if the $EnableUpload variable is true in ''config.php''. In addition, ''config.php'' can set the $UploadDir and $UploadUrlFmt variables to specify the local directory where uploaded files should be stored, and the URL that can be used to access that directory. By default, $UploadDir and $UploadUrlFmt assume that uploads will be stored in a directory called ''uploads/'' within the current directory (usually the one containing ''pmwiki.php''). In addition, ''config.php'' should also set a default upload password (see [[PasswordsAdmin]]).%0a%0aThus, a basic ''config.php'' for uploads might look like:%0a%0a->%25hlt php%25[@%0a%3c?php if (!defined('PmWiki')) exit();%0a## Enable uploads and set a site-wide default upload password.%0a$EnableUpload = 1;%0a$UploadPermAdd = 0;%0a$DefaultPasswords['upload'] = pmcrypt('secret');%0a@]%0a%0aIf you have edit passwords and wish to allow all users with edit rights to upload, instead of $DefaultPasswords['upload'], you can set @@$HandleAuth['upload'] = 'edit';@@ in config.php.%0a%0a'''Important''': do NOT create the uploads directory yet! See the next paragraph.%0a%0aYou may also need to explicitly set which filesystem directory will hold uploads and provide a URL that corresponds to that directory like:%0a%0a->%25hlt php%25[@%0a$UploadDir = "/home/foobar/public_html/uploads";%0a$UploadUrlFmt = "https://example.com/~foobar/uploads";%0a@]%0a%0a%25red%25 Note: In most installations, you don't need to define or change these variables, usually PmWiki can detect them (and if you do, uploads may simply not work).%0a%0a[[#uploaddirectoryconfiguration]]%0a!!! Upload directory configuration [[#dirconf]]%0aUploads can be configured ''site-wide'', ''by-group'' (default), or ''by-page'' by changing $UploadPrefixFmt in @@config.php@@. %0aThis determines whether all uploads go in one directory for the site, an individual directory for each group, or an individual directory for each page. The default is to organize upload by group. %0a%0a''It is recommended that the $UploadPrefixFmt variable defined in config.php is the same for all pages in the wiki, and not different in group or page local configuration files. Otherwise you '''will''' be unable to link to attachments in other wikigroups.''%0a%0a!!!! Single upload directory [[#sitewideprefix]]%0aFor site-wide uploads, use%0a%0a->%25hlt php%25[@$UploadPrefixFmt = '';@]%0a%0a!!!! Per page upload directories [[#pageprefix]]%0aTo organize uploads by page, use:%0a%0a->%25hlt php%25[@$UploadPrefixFmt = '/$Group/$Name';@]%0a%0aYou may prefer uploads attached per-page rather than per-group or per-site if you plan to have many files attached to individual pages. This setting simplifies the management of picture galleries for example. (In a page, you can always link to attachments to other pages.)%0a%0a!!! The upload directory [[#uploaddir]]%0a%0aFor the upload feature to work properly, the directory given by [=$UploadDir=] must be writable by the web server process, and it usually must be in a location that is accessible to the web somewhere (e.g., in a subdirectory of ''public_html''). Executing PmWiki with uploads enabled will prompt you with the set of steps required to create the uploads directory on your server (it differs from one server to the next). ''Note that in that case you may be required to explicitly create writable group- or page-specific subdirectories as well!''%0a%0a%0a!!! Uploading a file [[#uploadfile]]%0a%0aOnce the upload feature is enabled, users can access the upload form by adding "@@?action=upload@@" to the end of a normal PmWiki URL. The user will be prompted for an upload password similar to the way other pages ask for passwords (see [[Passwords]] and [[PasswordsAdmin]] for information about setting passwords on pages, groups, and the entire site).%0a%0aAnother way to access the upload form is to insert the markup "[@Attach:filename.ext@]" into an existing page, where @@filename.ext@@ is the name of a new file to be uploaded. When the page is displayed, a '?-link' will be added to the end of the markup to take the author to the upload page. (See [[Uploads]] for syntax variations.)%0a%0aBy default, PmWiki will organize the uploaded files into separate subdirectories for each group. This can be changed by modifying the $UploadPrefixFmt variable. See [[Cookbook:UploadGroups]] for details.%0a%0a%0a!! [[#upload_versions]] Versioning Uploaded Files%0a%0aPmWiki does not manage versioning of uploaded files by default. However, by setting @@$EnableUploadVersions=1;@@ an administrator can have older versions of uploads preserved in the uploads directory along with the most recent version.%0a%0a!! Upload restrictions%0a!!! Restricting uploaded files for groups and pages%0a%0aUploads can be enabled only for specific groups or pages by using a [[group customization(s)]]. Simply set @@$EnableUpload=1;@@ for those groups or pages where uploading is to be enabled; alternately, set @@$EnableUpload=1;@@ in the config.php file and then set @@$EnableUpload=0;@@ in the per-group or per-page customization files where uploads are to be disabled.%0a%0a!!! Restricting total upload size for a group or the whole wiki%0a%0aUploads can be restricted to an overall size limit for groups. In the group configuration file (i.e., local/Group.php), add the line%0a%0a->%25hlt php%25@@$UploadPrefixQuota = 1000000; # limit group uploads to 1000KB (1MB)@@%25%25%0a%0aThis will limit the total size of uploads for that group to 1000KB --any upload that pushes the total over the limit will be rejected with an error message. This value defaults to zero (unlimited).%0a%0aUploads can also be restricted to an overall size limit for all uploads. Add the line%0a%0a->%25hlt php%25@@$UploadDirQuota = 10000000; # limit total uploads to 10000KB (10MB)@@%25%25%0a%0aThis will limit the total size of uploads for the whole wiki to 10000KB --any upload that pushes the total over the limit will be rejected with an error message. This value defaults to zero (unlimited).%0a%0a%0a[[#restrictinguploadedfiles]]%0a!!!Restricting uploaded files type and size%0a%0aThe upload script performs a number of verifications on an uploaded file before storing it in the upload directory. The basic verifications are described below.%0a:'''filenames''': the name for the uploaded file can contain only letters, digits, underscores, hyphens, spaces, and periods, and the name must begin and end with a letter or digit. %0a:'''file extension''': only files with approved extensions such as "@@.gif@@", "@@.jpeg@@", "@@.doc@@", etc. are allowed to be uploaded to the web server. This is vitally important for server security, since the web server might attempt to execute or specially process files with extensions like "@@.php@@", "@@.cgi@@", etc. %0a:'''file size''': By default all uploads are limited to 50K bytes, as specified by the $UploadMaxSize variable. Thus, to limit all uploads to 100KB, simply specify a new value for $UploadMaxSize in ''config.php'':%0a%0a->%25hlt php%25[@$UploadMaxSize = 100000;@]%0a%0aHowever, the default maximum file size can also be specified for each type of file uploaded. Thus, an administrator can restrict "@@.gif@@" and "@@.jpeg@@" files to 20K, "@@.doc@@" files to 200K, and all others to the size given by $UploadMaxSize. The $UploadExtSize array is used to determine which file extensions are valid and the maximum upload size (in bytes) for each file type. For example:%0a%0a->%25hlt php%25[@$UploadExtSize['gif'] = 20000; # limit .gif files to 20KB@]%0a%0a[[#disallow_ext]]%0a!!! Disabling file upload by file type%0aSetting an entry to zero disables file uploads of that type altogether:%0a%0a->%25hlt php%25[@$UploadExtSize['zip'] = 0; # disallow .zip files%0a$UploadExtSize[''] = 0; # disallow files with no extension@]%0a%0aYou can limit which types of files are uploadable by disabling all defaults and specifying only desired types.%0aSetting the variable $UploadMaxSize to zero will disable all default file types. Individual file types may then be enabled by setting their maximum size with the variable $UploadExtSize.%0a%0a-> %25hlt php%25[@# turns off all upload extensions%0a$UploadMaxSize = 0;%0a%0a# enable only these file types for uploading%0a$aSize=100000; // 100 KB file size limitation%0a$UploadExtSize['jpg' ] = $aSize;%0a$UploadExtSize['gif' ] = $aSize;%0a$UploadExtSize['png' ] = $aSize;%0a@]%0a%0a!!! Note: Files with multiple extensions%0a%0aSome installations with the Apache server will try to execute a file which name contains ".php", ".pl" or ".cgi" even if it isn't the last part of the filename. For example, a file named "test.php.txt" may be executed. To disallow such files to be uploaded, add to config.php such a line:%0a%0a-> %25hlt php%25@@$UploadBlacklist = array('.php', '.pl', '.cgi');@@%25%25%0a%0a[[#newuploadfiletypes]]%0a!! Adding new file types to permitted uploads%0a%0aTo add a new extension to the list of allowed upload types, add a line like the following to a [[local customization(s)]] file:%0a%0a->%25hlt php%25[@$UploadExts['ext'] = 'content-type';@]%0a%0awhere ''ext'' is the extension to be added, and ''content-type'' is the "[[(Wikipedia:)MIME type]]", or content-type (which you may find at %25newwin%25[[https://www.iana.org/assignments/media-types/ | IANA]] or the %25newwin%25[[https://www.htmlquick.com/reference/mime-types.html | internet media types]]) to be used for files with that extension. For example, to add the '[@dxf@]' extension with a Content-Type of '[@image/x-dxf@]', place the line%0a%0a->%25hlt php%25[@$UploadExts['dxf'] = 'image/x-dxf';@]%0a%0aEach entry in $UploadExts needs to be the extension and the%0amime-type associated with that extension, thus:%0a%0a->%25hlt php%25[@%0a$UploadExts = array(%0a 'gif' => 'image/gif',%0a 'jpeg' => 'image/jpeg',%0a 'jpg' => 'image/jpeg',%0a 'png' => 'image/png',%0a 'xxx' => 'yyyy/zzz'%0a);%0a@]%0a%0aFor the types that PmWiki already knows about it's not necessary to repeat them here (the ''upload.php'' script adds PmWiki's defaults to whatever the administrator supplies).%0a[[#newuploadfiletypesend]]%0aSee also Cookbook:UploadTypes for additional types.%0a%0a[[#otherfilesizelimits]]%0a!!Other file size limits%0a%0aThere are other factors involved that affect upload file sizes. In Apache 2.4, there is a [[https://httpd.apache.org/docs/2.4/mod/core.html#limitrequestbody|LimitRequestBody]] directive that controls the maximum size of anything that is posted (including file uploads). Apache has this defaulted to unlimited size. However, some Linux distributions (e.g., Red Hat Linux) limit postings to 512K so this may need to be changed or increased. (Normally these settings are in an ''httpd.conf'' configuration file or in a file in ''/etc/httpd/conf.d''.)%0a%0aProblem noted on Red Hat 8.0/9.0 with Apache 2.0.x, the error "Requested content-length of 670955 is larger than the configured limit of 524288" was occurring under Apache and a "Page not found" would appear in the browser. Trying the above settings made no change with PHP, but on Red Hat 8.0/9.0 there is an additional PHP config file, /etc/httpd/conf.d/php.conf, and increasing the number on the line "`LimitRequestBody 524288" solves the issue.%0a%0aPHP itself has two limits on file uploads (usually located in @@/etc/php.ini@@). The first is the @@upload_max_filesize@@ parameter, which is set to 2MB by default. The second is @@post_max_size@@, which is set to 6MB by default.%0a%0aWith the variables in place--PmWiki's maximum file size, Apache's request-size limits, and the PHP file size parameters, the maximum uploaded file size will be the smallest of the three variables.%0a%0a!!! [[#direct_download]] Password protecting uploaded files%0aSetting a read password for pages (and groups) will prevent an attached file from being seen or accessed through the page, but to prevent direct access to the file location (the uploads/ directory) one can do the following:%0a %0a* In local/config.php set @@$EnableDirectDownload=0@@;%0a* If you use per-group upload directories (PmWiki default, see $UploadPrefixFmt), add to config.php @@$EnableUploadGroupAuth = 1;@@%0a* Deny public access to the uploads/ directory through moving it out of the html/ or public_html/ directory tree, or through a .htaccess file.%0a%0a%0aSee [[Cookbook:Secure attachments]] {Cookbook.SecureAttachments$:Summary}%0a%0a%0a!! Other notes%0a%0a* If uploads doesn't seem to work, make sure that your PHP installation allows uploads. The ''php.ini'' file (usually ''/etc/php.ini'' or ''/usr/local/lib/php.ini'') should have %0a%0a->[@file_uploads = On@]%0a%0a* Another source of error in the ''php.ini'' file is a not defined ''upload_tmp_dir''. Just set this variable to your temp directory, e.g.%0a%0a->[@upload_tmp_dir = /tmp@]%0a%0a%0aNote that if you change this values, httpd must generally be restarted. Another way to check if uploads are allowed by the server is to set $EnableDiag to 1 in ''config.php'', and set ?action=phpinfo on a URL. The "@@file_uploads@@" variable must have a value of 1 (if it says "@@no value@@", that means it's off).%0a%0a%0a!! FAQ [[#FAQ]]%0a>>faq%3c%3c [[#faq]]%0a%0aQ: How do I disable uploading of a certain type of file?%0aA: Here's an example of what to add to your ''local/config.php'' file to disable uploading of .zip files, or of files with no extension:%0a%0a%25hlt php%25[@%0a$UploadExtSize['zip'] = 0; # Disallow uploading .zip files%0a$UploadExtSize[''] = 0; # Disallow files with no extension@]%0a%0aQ: How do I attach uploads to individual pages or the entire site, instead of organizing them by [[wiki group]]?%0aA: Use the $UploadPrefixFmt variable (see also the Cookbook:UploadGroups recipe).%0a%0a%25hlt php%25[@%0a$UploadPrefixFmt = '/$FullName'; # per-page, in Group.Name directories%0a$UploadPrefixFmt = '/$Group/$Name'; # per-page, in Group directories with Name subdirectories%0a$UploadPrefixFmt = ''; # site-wide@]%0a%0aQ:For $UploadDirQuota - can you provide some units and numbers? Is the specification in bytes or bits? What is the number for 100K? 1 Meg? 1 Gig? 1 Terabyte?%0aA: Units are in bytes. %0a%0a%25hlt php%25[@%0a $UploadDirQuota = 100*1024; # limit uploads to 100KiB%0a $UploadDirQuota = 1000*1024; # limit uploads to 1000KiB%0a $UploadDirQuota = 1024*1024; # limit uploads to 1MiB%0a $UploadDirQuota = 25*1024*1024; # limit uploads to 25MiB%0a $UploadDirQuota = 2*1024*1024*1024; # limit uploads to 2GiB@]%0a%0aQ: Is there a way to allow file names with Unicode or additional characters? %0aA: Yes, see $UploadNameChars%0a%0aQ:Where is the list of attachments stored?%0aA: It is generated on the fly by the [[PageDirectives#attachlist|(:attachlist:)]] markup.%0a +time=1642193162 title=Uploads Administration blob - 91ff3f5f68229dafb9c05d2e3243755a7ae5d830 blob + 9c0236b660cc0a07f203255e86a546ea3ca0e676 --- wikilib.d/PmWiki.UrlApprovals +++ wikilib.d/PmWiki.UrlApprovals @@ -1,9 +1,9 @@ -version=pmwiki-2.2.102 ordered=1 urlencoded=1 -author=p1 +version=pmwiki-2.3.5 ordered=1 urlencoded=1 +author=simon charset=UTF-8 -csum=Sidebars, headers, footers, included pages +csum=hlt php, http+s (+139) name=PmWiki.UrlApprovals -rev=76 -targets=Category.Spam,SiteAdmin.ApprovedUrls,PmWiki.IncludeOtherPages,Site.AllRecentChanges,PmWiki.LinkVariables,PmWiki.Blocklist,PmWiki.Security -text=(:Summary:Require approval of Url links:)%0aThis page explains how to discourage "link spamming" on your wiki site using PmWiki's ''urlapprove.php'' script. This script is already included in PmWiki files, but not activated by default.%0a%0a%0a!! Using ''urlapprove.php''%0aOccasionally [[!spam]]mers may try to add large number of (sometimes hidden) `URLs to pages because they think it will improve their search engine rankings -- which it [[#nofollow |probably won't]]. The ''urlapprove.php'' script works against these spammers' purpose by%0a%0a* requiring approval of links to Internet sites before a link to them are created in the wiki, and%0a* allowing you to limit the number of unapproved links that may be added to a page.%0a%0aTo enable ''urlapprove.php'', add the following line to a configuration file:%0a%0a->[@include_once("$FarmD/scripts/urlapprove.php");@]%0a%0aBy default, unapproved links display what ever should be displayed normally (the URL or a text), but not linked and next to it a link [-%25blue%25(approve links)%25%25-].%0aA click on the link will approve all unapproved `URLs on the page, %25green%25but ''only'' if you are authorized to edit the ''SiteAdmin.ApprovedUrls'' page%25%25. You may also pre-approve sites by by adding them directly to the [[SiteAdmin.ApprovedUrls]] page.%0a%0a%0a!!! Limiting unapproved urls per page%0aYou can limit the number of unapproved links per page. If the limit is exceeded, the page cannot be saved. This is useful because spammers like to write long link lists, which is rare for normal authors.%0a%0aExample: To set the limit to 5 unapproved links, add the following line to a configuration file:%0a%0a->[@$UnapprovedLinkCountMax = 5;@]%0a->[@include_once('scripts/urlapprove.php');@]%0a%0aNote that $UnapprovedLinkCountMax must be set ''before'' including the ''urlapprove.php'' script.%0a%0a%0a!!! Handling of Unapproved Links%0aYou can also change the disapproval message defined in the $UnapprovedLinkFmt variable, for example:%0a%0a-> [@%0ainclude_once('scripts/urlapprove.php');%0a$UnapprovedLinkFmt =%0a "[$[Link requires approval]]%3ca class='apprlink'%0a href='\$PageUrl?action=approvesites'>$[(approve)]%3c/a>";%0a@]%0a%0a"Link requires approval" is whatever you want to see in place of the unapproved link and "(approve)" is the blue text. Using this feature may prove usefull if you want to always hide the unapproved link.%0a%0aIf you wish to totally forbid unapproved links you can use%0a%0a->[@$UnapprovedLinkFmt = "%3cb>external link not allowed%3c/b>";@]%0a%0a%0a!!! Sidebars, headers, footers, included pages or sections [[#sidebar]] [[#included]]%0aPlease note that in general you need to go to the sidebar, header, footer pages in order to approve links in them. If pages or sections with unapproved links are [[IncludeOtherPages|included]] in other pages, or transcluded via a pagelist or a page text variable, you need to approve the links in the original pages. The reason for this is that the approve mechanism only approves links on the ''current'' page.%0a%0a%0a!!! Initial setup%0aAfter initial setup all existing links become unapproved. You need to visit your pages and approve all links, where needed. See [[Site/AllRecentChanges]] for a list of all pages that were created on your wiki.%0a%0a!! Password approval of URLs%0aTo approve external links, an author needs permissions to edit the page [[SiteAdmin.ApprovedUrls]].%0a%0a!! Technical tips%0a[[#whiteurls]]%0a!!! URL Whitelist%0aUrls can also be approved by adding them to a "white list", %0adefined in the variable @@$WhiteUrlPatterns@@, %0awhich is set in the ''local/config.php'' file.\\%0aTo add multiples urls, use the separator @@|@@ (vertical bar). For example:%0a%0a-> [@%0a$WhiteUrlPatterns =%0a "(http://example.com|http://example.net|http://example.org)";%0a@]%0a%0aTo add all urls from, say New Zealand and Australia, use:%0a%0a-> [@%0a$WhiteUrlPatterns[] = 'http://[^/]+\\.nz';%0a$WhiteUrlPatterns[] = 'http://[^/]+\\.au';%0a@]%0a%0a%0a!!! Change Approved URLs page name%0aIf you want to change the default name of ''SiteAdmin.ApprovedUrls'', set the following in ''local/config.php'':%0a%0a->[@$ApprovedUrlPagesFmt = array('OtherGroup.OtherName');@]%0a%0a!!! Previewing the unapproved URL%0aTo see what link is to be approved without editing the page a tool tip can be displayed when the cursor hovers over the [-%25blue%25(approve links)%25%25-] link that displays the URL. e.g. [[http://uuu.example.com|Example]].%0a%0aAdd the following setting in your ''local/config.php'':%0a%0a-> [@%0a$UnapprovedLinkFmt =%0a "\$LinkText%3ca class='apprlink' href='\$PageUrl?action=approvesites'%0a title='\$LinkUrl'>$[(approve links)]%3c/a>";%0a@]%0a%0a->Some browsers show only the link and not the tooltip title. In this case, you can use the following code to see the unapproved link at the end of the tooltip :%0a-> [@$UnapprovedLinkFmt =%0a "\$LinkText%3ca class='apprlink' href='\$PageUrl?action=approvesites&XES_url=\$LinkUrl'%0a title='\$LinkUrl'>$[(approve sites)]%3c/a>";%0a@]%0a%0a%0a!! About rel='nofollow' [[#nofollow]]%0aBy default, PmWiki creates external links that are not followed by search engines. %0aHere are release notes from pmwiki-2.0.beta20 (30-Jan-2005):%0a%0a->''First, the $UrlLinkFmt variable has been modified so that links to external urls automatically have a rel='nofollow' attribute added to them, to help combat wiki spam as described in [[http://googleblog.blogspot.com/2005/01/preventing-comment-spam.html]]. Site administrators can customize $UrlLinkFmt and $UnapprovedLinkFmt to supply or omit rel='nofollow' as appropriate.''%0a%0a!! See Also%0a%0a* [[PmWiki/Blocklist]] - Blocking postings based on content or IP address%0a* [[PmWiki/Security]] - Securing your PmWIki%0a -time=1504506256 +rev=78 +targets=Category.Spam,!Spam,SiteAdmin.ApprovedUrls,PmWiki.IncludeOtherPages,Site.AllRecentChanges,PmWiki.LinkVariables,PmWiki.Blocklist,PmWiki.Security +text=(:Summary:Require approval of Url links:)%0aThis page explains how to discourage "link spamming" on your wiki site using PmWiki's ''urlapprove.php'' script. This script is already included in PmWiki files, but not activated by default.%0a%0a!! Using ''urlapprove.php''%0aOccasionally [[!spam]]mers may try to add large number of (sometimes hidden) `URLs to pages because they think it will improve their search engine rankings -- which it [[#nofollow |probably won't]]. The ''@@urlapprove.php@@'' script works against these spammers' purpose by%0a* requiring approval of links to Internet sites before a link to them are created in the wiki, and%0a* allowing you to limit the number of unapproved links that may be added to a page.%0a%0aTo enable ''@@urlapprove.php@@'', add the following line to a configuration file:%0a->%25hlt php%25[@include_once("$FarmD/scripts/urlapprove.php");@]%0a%0aBy default, unapproved links display what ever should be displayed normally (the URL or a text), but not linked and next to it a link [-%25blue%25(approve links)%25%25-].%0aA click on the link will approve all unapproved `URLs on the page, %25green%25but ''only'' if you are authorized to edit the ''SiteAdmin.ApprovedUrls'' page%25%25. You may also pre-approve sites by by adding them directly to the [[SiteAdmin.ApprovedUrls]] page.%0a%0a%0a!!! Limiting unapproved urls per page%0aYou can limit the number of unapproved links per page. If the limit is exceeded, the page cannot be saved. This is useful because spammers like to write long link lists, which is rare for normal authors.%0a%0aExample: To set the limit to 5 unapproved links, add the following line to a configuration file:%0a->%25hlt php%25[@$UnapprovedLinkCountMax = 5;@]%0a->%25hlt php%25[@include_once('scripts/urlapprove.php');@]%0a%0aNote that variable @@$UnapprovedLinkCountMax@@ must be set ''before'' including the ''@@urlapprove.php@@'' script.%0a%0a%0a!!! Handling of Unapproved Links%0aYou can also change the disapproval message defined in the @@$UnapprovedLinkFmt@@ variable, for example:%0a-> %25hlt php%25[@%0ainclude_once('scripts/urlapprove.php');%0a$UnapprovedLinkFmt =%0a "[$[Link requires approval]]%3ca class='apprlink'%0a href='\$PageUrl?action=approvesites'>$[(approve)]%3c/a>";%0a@]%0a%0a"Link requires approval" is whatever you want to see in place of the unapproved link and "(approve)" is the blue text. Using this feature may prove useful if you want to always hide the unapproved link.%0a%0aIf you wish to totally forbid unapproved links you can use%0a->%25hlt php%25[@$UnapprovedLinkFmt = "%3cb>external link not allowed%3c/b>";@]%0a%0a%0a!!! Sidebars, headers, footers, included pages or sections [[#sidebar]] [[#included]]%0aPlease note that in general you need to go to the sidebar, header, footer pages in order to approve links in them. If pages or sections with unapproved links are [[IncludeOtherPages|included]] in other pages, or transcluded via a pagelist or a page text variable, you need to approve the links in the original pages. The reason for this is that the approve mechanism only approves links on the ''current'' page.%0a%0a%0a!!! Initial setup%0aAfter initial setup all existing links become unapproved. You need to visit your pages and approve all links, where needed. See [[Site/AllRecentChanges]] for a list of all pages that were created on your wiki.%0a%0a!! Password approval of URLs%0aTo approve external links, an author needs permissions to edit the page [[SiteAdmin.ApprovedUrls]].%0a%0a!! Technical tips%0a[[#whiteurls]]%0a!!! URL Whitelist%0aURLs can also be approved by adding them to a "white list", %0adefined in the variable @@$WhiteUrlPatterns@@, %0awhich is set in the ''@@local/config.php@@'' file.\\%0aTo add multiples URLs, use the separator @@|@@ (vertical bar). For example:%0a-> %25hlt php%25[@%0a$WhiteUrlPatterns =%0a "(https://example.com|https://example.net|https://example.org)";%0a@]%0a%0aTo add all URLs from, say New Zealand and Australia, use:%0a-> %25hlt php%25[@%0a$WhiteUrlPatterns[] = 'https://[^/]+\\.nz';%0a$WhiteUrlPatterns[] = 'https://[^/]+\\.au';%0a@]%0a%0a%0a!!! Change Approved URLs page name%0aIf you want to change the default name of ''SiteAdmin.ApprovedUrls'', set the following in ''@@local/config.php@@'':%0a->%25hlt php%25[@$ApprovedUrlPagesFmt = array('OtherGroup.OtherName');@]%0a%0a!!! Previewing the unapproved URL%0aTo see what link is to be approved without editing the page a tool tip can be displayed when the cursor hovers over the [-%25blue%25(approve links)%25%25-] link that displays the URL. e.g. [[https://uuu.example.com|Example]].%0a%0aAdd the following setting in your ''@@local/config.php@@'':%0a-> %25hlt php%25[@%0a$UnapprovedLinkFmt =%0a "\$LinkText%3ca class='apprlink' href='\$PageUrl?action=approvesites'%0a title='\$LinkUrl'>$[(approve links)]%3c/a>";%0a@]%0a%0a->Some browsers show only the link and not the tooltip title. In this case, you can use the following code to see the unapproved link at the end of the tooltip :%0a-> %25hlt php%25[@$UnapprovedLinkFmt =%0a "\$LinkText%3ca class='apprlink' href='\$PageUrl?action=approvesites&XES_url=\$LinkUrl'%0a title='\$LinkUrl'>$[(approve sites)]%3c/a>";%0a@]%0a%0a%0a!! About rel='nofollow' [[#nofollow]]%0aBy default, PmWiki creates external links that are not followed by search engines. %0aHere are release notes from pmwiki-2.0.beta20 (30-Jan-2005):%0a%0a->''First, the @@$UrlLinkFmt@@ variable has been modified so that links to external urls automatically have a rel='nofollow' attribute added to them, to help combat wiki spam as described in [[https://googleblog.blogspot.com/2005/01/preventing-comment-spam.html]]. Site administrators can customize @@$UrlLinkFmt@@ and @@$UnapprovedLinkFmt@@ to supply or omit rel='nofollow' as appropriate.''%0a%0a!! See Also%0a%0a* [[PmWiki/Blocklist]] - Blocking postings based on content or IP address%0a* [[PmWiki/Security]] - Securing your PmWIki%0a +time=1653632924 blob - 1610e4c17d02d5ea0502bee12afd6b46d910a43c blob + 7db38831c65d9cee57914ca0ebaeae9fef41a142 --- wikilib.d/PmWiki.Variables +++ wikilib.d/PmWiki.Variables @@ -1,9 +1,9 @@ -version=pmwiki-2.2.127 ordered=1 urlencoded=1 -author=simon +version=pmwiki-2.3.15 ordered=1 urlencoded=1 +author=Petko charset=UTF-8 -csum=add link (+55) +csum=rframe font-size=smaller clear=right (+12) name=PmWiki.Variables -rev=90 -targets=PmWiki.LocalCustomizations,PmWiki.BasicVariables,PmWiki.DebugVariables,PmWiki.EditVariables,PmWiki.I18nVariables,PmWiki.LayoutVariables,PmWiki.LinkVariables,PmWiki.OtherVariables,PmWiki.PagelistVariables,PmWiki.PageLists,PmWiki.PathVariables,PmWiki.SecurityVariables,PmWiki.UploadVariables,PmWiki.Blocklist,PmWiki.Notify,PmWiki.PageVariables,PmWiki.PageTextVariables,PmWiki.Functions,PmWiki.MarkupExpressions,Category.PmWikiDeveloper -text=(:Summary:Variables available for local customisation:)%0a(:Audience: administrators (basic) :)%0a[[%3c%3c]]%0a>>rframe font-size:smaller%3c%3c%0a[[#index]]%0a!! List of documented PHP variables%0a(:varindex:)%0a[[#indexend]]%0a>>%3c%3c%0a%0aThis page documents the PHP variables available in PmWiki for [[local customizations]]. Much of this documentation is still incomplete but people are working on it now. Feel free to add placeholders for variables you want to have documented if you don't know what the variable does.%0a%0aThe variables documentation is divided into several pages:%0a%0a* [[Basic Variables]] - {BasicVariables$:Summary}%0a* [[Debug Variables]] - {DebugVariables$:Summary}%0a* [[Edit Variables]] - {EditVariables$:Summary}%0a* [[I18n Variables]] - {I18nVariables$:Summary}%0a* [[Layout Variables]] - {LayoutVariables$:Summary}%0a* [[Link Variables]] - {LinkVariables$:Summary}%0a* [[Other Variables]] - {OtherVariables$:Summary}%0a* [[Pagelist Variables]] - {PagelistVariables$:Summary}%0a* [[Path Variables]] - {PathVariables$:Summary}%0a* [[Security Variables]] - {SecurityVariables$:Summary}%0a* [[Upload Variables]] - {UploadVariables$:Summary}%0a%0aThe following functions are also controlled by several variables:%0a* [[Blocklist(#variables)]] - {Blocklist$:Summary}%0a* [[Notify(#variables)]] - {Notify$:Summary}%0a* [[Basic Variables]] %25item comment%25 to provide circular trail%0a%0aThe following variables are used in page markup.%0a* [[Page Variables]] - {PageVariables$:Summary}%0a* [[Page TextVariables]] - {PageTextVariables$:Summary}%0a%0a%0aAn complete index of documented PHP variables is given below.%0a%0aIn general, variables with names ending in 'Fmt' (such as $PageLayoutFmt) have their values processed for $-variable substitutions prior to being output. Thus strings such as [@{$Name}@] and [@{$PageUrl}@] are replaced with the name and URL of the page when the string is printed.%0a%0aNote: The automatic variable index and link generation is done by scripts/vardoc.php using $VarPagesFmt to find the pages containing trails of pages with the variable documentation.%0a%0aThere is a slight discrepancy between index generation and link generation: The index generation finds lines starting with a colon followed by "$" and an uppercase word. In contrast, the automatic link generation works only with WikiWords ($WikiWordPattern) preceded with "$". Therefore all "non WikiWord" variables are shown as link only in the list below, but not elsewhere in PmWiki, as $XL. 'Author', 'Skin', 'pagename' and 'Version' (preceded with a $-sign) are handled correctly.%0a%0a!!See Also%0a%0a* %25%25 [[PmWiki/Functions]] - {Functions$:Summary} (:comment why? Could be removed IMO --OliverBetz:)%0a* [[Markup Expressions]] -{MarkupExpressions$:Summary}%0a%0aCategories: [[!PmWiki Developer]] -time=1587889074 +rev=98 +targets=PmWiki.LocalCustomizations,PmWiki.BasicVariables,PmWiki.DebugVariables,PmWiki.EditVariables,PmWiki.I18nVariables,PmWiki.LayoutVariables,PmWiki.LinkVariables,PmWiki.OtherVariables,PmWiki.PagelistVariables,PmWiki.PageLists,PmWiki.PathVariables,PmWiki.SecurityVariables,PmWiki.UploadVariables,PmWiki.Blocklist,PmWiki.Notify,PmWiki.PageVariables,PmWiki.PageTextVariables,PmWiki.Functions,PmWiki.MarkupExpressions,Category.PmWikiDeveloper,!PmWikiDeveloper +text=(:Summary:Variables available for local customisation:)%0a(:Audience: administrators (basic) :)%0a[[%3c%3c]]%0a>>rframe font-size=smaller clear=right%3c%3c%0a[[#index]]%0a!! List of documented PHP variables%0a(:varindex:)%0a[[#indexend]]%0a>>%3c%3c%0a%0aThis page documents the PHP variables available in PmWiki for [[local customizations]]. Much of this documentation is still incomplete but people are working on it now. Feel free to add placeholders for variables you want to have documented if you don't know what the variable does.%0a%0aThe variables documentation is divided into several pages:%0a%0a* [[Basic Variables]] - {BasicVariables$:Summary}%0a* [[Debug Variables]] - {DebugVariables$:Summary}%0a* [[Edit Variables]] - {EditVariables$:Summary}%0a* [[I18n Variables]] - {I18nVariables$:Summary}%0a* [[Layout Variables]] - {LayoutVariables$:Summary}%0a* [[Link Variables]] - {LinkVariables$:Summary}%0a* [[Other Variables]] - {OtherVariables$:Summary}%0a* [[Pagelist Variables]] - {PagelistVariables$:Summary}%0a* [[Path Variables]] - {PathVariables$:Summary}%0a* [[Security Variables]] - {SecurityVariables$:Summary}%0a* [[Upload Variables]] - {UploadVariables$:Summary}%0a%0aThe following functions are also controlled by several variables:%0a* [[Blocklist(#variables)]] - {Blocklist$:Summary}%0a* [[Notify(#variables)]] - {Notify$:Summary}%0a* [[Basic Variables]] %25item comment%25 to provide circular trail%0a%0aThe following variables are used in page markup.%0a* [[Page Variables]] - {PageVariables$:Summary}%0a* [[Page TextVariables]] - {PageTextVariables$:Summary}%0a%0a%0aAn complete index of documented PHP variables is given below.%0a%0aIn general, variables with names ending in '@@Fmt@@' (such as @@$PageLayoutFmt@@) have their values processed for @@$-variable@@ substitutions prior to being output. Thus strings such as %25pmhlt%25[@{$Name}@] and [@{$PageUrl}@] are replaced with the name and URL of the page when the string is printed.%0a%0aNote: The automatic variable index and link generation is done by @@scripts/vardoc.php@@ using @@$VarPagesFmt@@ to find the pages containing trails of pages with the variable documentation.%0a%0aThere is a slight discrepancy between index generation and link generation: The index generation finds lines starting with a colon followed by "@@$@@" and an uppercase word. In contrast, the automatic link generation works only with WikiWords (@@$WikiWordPattern@@) preceded with "$". Therefore all "non WikiWord" variables are shown as link only in the list below, but not elsewhere in PmWiki, as @@$XL@@. 'Author', 'Skin', 'pagename' and 'Version' (preceded with a $-sign) are handled correctly.%0a%0a!!See Also%0a%0a* %25%25 [[PmWiki/Functions]] - {Functions$:Summary} (:comment why? Could be removed IMO --OliverBetz:)%0a* [[Markup Expressions]] -{MarkupExpressions$:Summary}%0a%0aCategories: [[!PmWiki Developer]] +time=1669297541 blob - 25c9e535f991b75daec2f8b627b8506baa100002 blob + 4a0ec5b4f9ab647709bf2134b610292cb8e21d42 --- wikilib.d/PmWiki.Version +++ wikilib.d/PmWiki.Version @@ -1,10 +1,10 @@ -version=pmwiki-2.2.115 ordered=1 urlencoded=1 -author=Petko +version=pmwiki-2.3.2 ordered=1 urlencoded=1 +author=simon charset=UTF-8 -csum=intermap on a link to a page not in the distribution +csum=pm hlt, add extra links (+201) ctime=1176363304 name=PmWiki.Version -rev=15 -targets=PmWiki.PageVariables,SiteAdmin.Status,PmWiki.BasicVariables,PmWiki.SiteAnalyzer,Cookbook.ModuleGuidelines,Cookbook.RecipeCheck -text=(:Summary: Determining and displaying the current version of PmWiki ({$Version}):)%0a%0a'''This wiki installation is running version %25red%25{$Version}%25%25, version number %25red%25{$VersionNum}%25%25.'''%0a%0a!! Obtaining the PmWiki version%0aUse the [@{$Version}@] [[page variable(s)]] to display the current version of PmWiki.%0a%0aSee the [[SiteAdmin.Status]] page for the current version and version number.%0a%0aFor example%0a(:markup:)%0aThis wiki installation is running PmWiki {$Version}, version number {$VersionNum}.%0a-%3cThe default group is {$DefaultGroup}.%0a-%3cThe default name is {$DefaultName}.%0a-%3cThe site group is {$SiteGroup}%0a(:markupend:)%0a%0aSee also [[basic variables]].%0a%0aThe script @@version.php@@ contains the declaration of the version number. The file is located on scripts/version.php, relative to PmWiki installation path.%0a%0a!! Obtaining recipe versions%0aThe [[(PmWiki:)Site Analyzer]] can be used to display the current version of %0a[[Cookbook(:/)]] recipes. If you are the administrator, [[Cookbook:ModuleGuidelines|cookbook recipe guidelines]] recommends that the first couple of lines of a recipe file should contain the recipe version:%0a[@%0a $RecipeInfo['RecipeName']['Version'] = '2017-06-02'; # dates YYYY-MM-DD prefered%0a@] %0a%0aSee also [[Cookbook:RecipeCheck]]%0a%0a%0a -time=1558728064 +rev=17 +targets=PmWiki.PageVariables,SiteAdmin.Status,PmWiki.SiteAnalyzer,Cookbook.ModuleGuidelines,Cookbook.RecipeCheck,Cookbook.Cookbook +text=(:Summary: Determining and displaying the current version of PmWiki ({$Version}):)%0a%0a'''This wiki installation is running version %25red%25{$Version}%25%25, version number %25red%25{$VersionNum}%25%25.'''%0a%0a!! Obtaining the PmWiki version%0aUse the %25pmhlt%25[@{$Version}@] [[page variable(s)]] to display the current version of PmWiki.%0a%0aSee the [[SiteAdmin.Status]] page for the current version and version number.%0a%0aFor example%0a(:markup:)%0aThis wiki installation is running PmWiki {$Version}, version number {$VersionNum}.%0a-%3cThe default group is {$DefaultGroup}.%0a-%3cThe default name is {$DefaultName}.%0a-%3cThe site group is {$SiteGroup}%0a(:markupend:)%0a%0aThe script @@version.php@@ contains the declaration of the version number. The file is located on scripts/version.php, relative to PmWiki installation path.%0a%0a[[#recipeinfo]]%0a!! Obtaining recipe versions%0aThe [[(PmWiki:)Site Analyzer]] can be used to display the current version of %0a[[Cookbook(:/)]] recipes. If you are the administrator, [[Cookbook:ModuleGuidelines|cookbook recipe guidelines]] recommends that the first couple of lines of a recipe file should contain the recipe version:%0a[@%0a $RecipeInfo['RecipeName']['Version'] = '2017-06-02'; # dates YYYY-MM-DD prefered%0a@] %0a%0a!! See also %0a(:pagelist group=pmwiki name=basicvariables,releasenotes,changelog,upgrades,siteanalyzer fmt=#titlesummary:)%0a* [[Cookbook:RecipeCheck]] [-{Cookbook.RecipeCheck$:Summary}-]%0a* [[Cookbook:ModuleGuidelines]] [-{Cookbook.ModuleGuidelines$:Summary}-]%0a%0a%0a +time=1647462869 blob - 203a9f8fef92d70339960b33e8dd5e28627bbc61 blob + 559a59d5cc39f7107e1a1675627ce7a17f5887f6 --- wikilib.d/PmWiki.WebFeeds +++ wikilib.d/PmWiki.WebFeeds @@ -1,9 +1,9 @@ -version=pmwiki-2.2.118 ordered=1 urlencoded=1 -author=Petko +version=pmwiki-2.3.2 ordered=1 urlencoded=1 +author=MFWolff charset=UTF-8 -csum= +csum=hlt php (+27) name=PmWiki.WebFeeds -rev=86 -targets=PmWiki.WikiTrails,Site.AllRecentChanges,Cookbook.Backlinks,PmWiki.WikiGroup,PmWiki.Categories,PmWiki.PageLists,Cookbook.RssFeedDisplay,PmWiki.LocalCustomizations,Cookbook.FeedLinks,PmWiki.BasicVariables,PmWiki.OtherVariables,PmWiki.PagelistVariables,Cookbook.PageFeed,Cookbook.CustomRecentChanges,PmWiki.LayoutVariables,PITS.01161 -text=(:Summary:Web feed notification of changes:)%0a(:Audience: visitors (intermediate) :)%0aWeb feeds are a convenient mechanism to let visitors be notified of changes to a site. Instead of repeatedly checking [=RecentChanges=] every day to see what is new, a visitor can use a [[news aggregator -> Wikipedia:Aggregator]] to quickly see what pages of interest have changed on a site. Web feeds are commonly recognized by terms such as [[(Wikipedia:)RSS]], [[(Wikipedia:)Atom(_%2528standard%2529)]], and ''[[Wikipedia:web_syndication | web syndication]]''. They are also the foundation for podcasting.%0a%0a!! Based on WikiTrails%0aIn its simplest form, web feeds in PmWiki are built on [[WikiTrails]]. Using a feed action such as [@?action=rss@] or [@?action=atom@] on a trail generates a web feed (often called a "channel") where each page on the trail is an item in the feed. Since the RecentChanges and [[{$SiteGroup}.AllRecentChanges]] pages are effectively trails, one can easily get an RSS feed for a group or site by simply adding [@?action=rss@] to the url for a RecentChanges page. For example, to get the site feed for pmwiki.org, one would use%0a%0a->http://pmwiki.org/wiki/Site/AllRecentChanges?action=rss%0a%0aAuthors can also create custom feeds by simply creating a wiki trail of the pages they want included in the feed. Feeds can also be generated from [[groups -> WikiGroup]], [[categories]], and %25newwin%25[[Cookbook:Backlinks|backlinks]], and the order and number of items in the feed can be changed using options in the feed url. Thus, one can obtain a feed for the ''Skins'' category (sorted with most recent items first) by using%0a%0a->http://pmwiki.org/wiki/Category/Skins?action=rss&order=-time%0a%0aPmWiki is able to generate feeds in many formats, including RSS 2.0 ([@?action=rss@]), Atom 1.0 ([@?action=atom@]), and RSS 1.0 ([@?action=rdf@]). In addition, although it is not normally considered a web feed, PmWiki can generate metadata information using the Dublin Core Metadata extensions ([@?action=dc@]).%0a%0a!!How to read a PmWiki syndicated feed%0a%0a# You'll need a [[news aggregator -> Wikipedia:List_of_feed_aggregators]], which is a piece of software designed to read news feeds. Many different news aggregators are available. Some run on your own computer, either on their own or as plugins for email clients, web browsers, or newsreaders. Others are web applications that you can use from any Internet-connected computer. Some are in between (technically web applications, but ones designed to run on your computer, not some remote server). Get one that you like.%0a# Subscribe to the [[WikiTrail(s)]] you desire by supplying the feed url to the aggregator. The feed url will be the name of a trail page with [@?action=rss@] or [@?action=atom@] added to the end of the url.%0a%0a!!Feed options%0a%0aAdd any of the following options to the end of a PmWiki web feed url to change its output (basically any [[pagelist->PageLists]] option is available for web feeds):%0a%0a:?count=''n'': Limit feed to ''n'' items (default 10)%0a:?order=-time : Display most recently changed items first (default: the order of the trail, or by name; in RecentChanges pages the trail is already ordered by -time)%0a:?trail=''page'': Obtain items from trail on ''page'' (default: the trail on the current page)%0a:?group=''group'': Limit feed to pages in ''group''%0a:?name=''name'': Limit feed to pages with specific ''name''%0a:?link=''page'': Create feed from pages linked to ''page''%0a:?list=normal: Exclude things like RecentChanges, AllRecentChanges, etc.%0a%0a%25audience%25 authors (intermediate)%0a!!Configure PmWiki for feeds%0a%0aThis section describes how to syndicate portions of a wiki to appear in a web feed. It does not describe how to display a web feed within a wiki page -- for that, see Cookbook:RssFeedDisplay.%0a%0aTo enable web feed generation for a site, add one or more of the following to a [[local customization(s)]] file:%0a%0a->[@%0aif ($action == 'rss') include_once("$FarmD/scripts/feeds.php");%0aif ($action == 'atom') include_once("$FarmD/scripts/feeds.php");%0aif ($action == 'rdf') include_once("$FarmD/scripts/feeds.php");%0aif ($action == 'dc') include_once("$FarmD/scripts/feeds.php");%0a@]%0a%0aor you can combine multiple feeds into a single expression using "||" to separate each feed type. For example, if you want to enable RSS and Atom feeds you would use%0a%0a->[@%0aif ($action == 'rss' ||%0a $action == 'atom' ||%0a $action == 'rdf' ||%0a $action == 'dc') include_once("$FarmD/scripts/feeds.php");%0a@]%0a%0a!!Configure feed content%0aWeb feeds are highly configurable, new elements can be easily added to feeds via the $FeedFmt array. Elements in $FeedFmt look like%0a%0a[@$FeedFmt['atom']['feed']['rights'] = 'All Rights Reserved';@]%0a%0awhere the first index corresponds to the action (?action=atom), the second index indicates a per-feed or per-item element, and%0athe third index is the name of the element being generated. The above setting would therefore generate a "%3crights>All Rights Reserved%3c/rights>" in the feed for ?action=atom.%0a%0a[[#pitfall1]]%0aIf the value of an entry begins with a '%3c', then feeds.php doesn't automatically add the tag around it. Elements can also be callable functions which are called to generate the appropriate output. See [[http://blogs.law.harvard.edu/tech/rss | RSS specification]] or other feed specifications for what feed content you can use.%0a%0aYou can also change an existing element rather than add a new one. You can use the following lines to ensure that changes made to the wiki will be picked up by some RSS readers that wouldn't otherwise "notice" a page has been changed:%0a%0a->[@%0a# Change the link URL when an item is edited.%0a$FeedFmt['rss']['item']['link'] = '{$PageUrl}?when=$ItemISOTime';%0a$FeedFmt['atom']['item']['link'] =%0a "%3clink rel=\"alternate\" href=\"{\$PageUrl}?when=\$ItemISOTime\" />\n";%0a@]%0a%0a%0a!!See Also%0a%0a* [[Cookbook:FeedLinks]] - Add HTML %3chead> links for auto-discovery of your feeds.%0a* [[WikiTrails]]%0a* Wikipedia:Web_feed, Wikipedia:Web_syndication, Wikipedia:RSS, Wikipedia:Atom_%2528standard%2529%0a%0a!! FAQ%0a>>faq%3c%3c [[#faq]]%0a%0aQ: How do I include text from the page (whole page, or first X characters) in the feed body? (note: markup NOT digested)%0a%0a function MarkupExcerpt($pagename) {%0a $page = RetrieveAuthPage($pagename, 'read', false);%0a return substr(@$page['text'], 0, 200);%0a }%0a%0a $FmtPV['$MarkupExcerpt'] = 'MarkupExcerpt($pn)';%0a $FeedFmt['rss']['item']['description'] = '$MarkupExcerpt';%0a%0a%25green%25 Does this mean if I want to include the time in the rss title and "summary" to rss body I call [@$FeedFmt@] twice like so:%0a->%25block green%25[@$FeedFmt['rss']['item']['description'] = '$LastSummary'; %0a$FeedFmt['rss']['item']['title'] = '{$Group} / {$Title} @ $ItemISOTime';@] %0a%0a--->%25black%25 From mailing list Feb 13,2007, a response by Pm: Yes%0a%0aQ: How can I use the RSS %3cenclosure> tag for podcasting?%0a%0aA: For podcasting of mp3 files, simply attach an mp3 file to the page%0awith the same name as the page (i.e., for a page named Podcast.Episode4,%0aone would attach to that page a file named "Episode4.mp3"). The%0afile is automatically picked up by ?action=rss and used as an%0aenclosure.%0a%0aThe set of potential enclosures is given by the $RSSEnclosureFmt%0aarray, thus%0a%0a->[@$RSSEnclosureFmt = array('{$Name}.mp3', '{$Name}.wma', '{$Name}.ogg');@]%0a%0aallows podcasting in mp3, wma, and ogg formats.%0a%0a%0aQ: [[#AddSummary]] How to add "summary" to the title in a rss feed (ie. with [@?action=rss@])?%0a%0aA: Add this line in you [@local/config.php@]%0a%0a->[@$FeedFmt['rss']['item']['title'] = '{$Group} / {$Title} : $LastModifiedSummary';@]%0a%0a%0aQ: [[#AddDescriptionSummary]] How to add "description" to the title in an rss feed, and summary to the body?%0a%0aA: Add these lines to your [@local/config.php@]%0a%0a->[@$FeedFmt['rss']['item']['title'] = '{$Group} / {$Title} : {$Description}';@]%0a->[@$FeedFmt['rss']['item']['description'] = '$LastModifiedSummary';@]%0a%0a%0a'''NOTES:'''%0a* you need to replicate these lines for each type (atom, rdf, dc) of feed you provide.%0a* the RSS '''[@description@]'''-tag is not equivalent to the pmWiki ''[@$Description@]'' variable, despite the confusing similarity.%0a%0aQ: Some of my password-protected pages aren't appearing in the feed... how do I work around this?%0a%0aA: From a similar question on the newsgroup, Pm's reply:%0a%0aThe last time I checked, RSS and other syndication protocols didn't%0areally have a well-established interface or mechanism for performing%0aaccess control (i.e., authentication). As far as I know this is%0astill the case.%0a%0aPmWiki's WebFeeds capability is built on top of pagelists, so it%0acould simply be that the $EnablePageListProtect option is preventing%0athe updated pages from appearing in the feed. You might try%0asetting $EnablePageListProtect=0; and see if the password-protected%0apages start appearing in the RSS feed.%0a%0aThe "downside" to setting $EnablePageListProtect to zero is that%0aanyone doing a search on your site will see the existence of the%0apages in the locked section. They won't be able to read any of%0athem, but they'll know they are there!%0a%0aYou could also set $EnablePageListProtect to zero only if ?action=rss:%0a%0a if ($action == 'rss') $EnablePageListProtect = 0;%0a%0aThis limits the ability to see the protected pages to RSS feeds;%0anormal pagelists and searches wouldn't see them.%0a%0aLastly, it's also possible to configure the webfeeds to obtain%0athe authentication information from the url directly, as in:%0a%0a .../Site/AllRecentChanges?action=rss&authpw=secret%0a%0aThe big downside to this is that the cleartext password will%0aend up traveling across the net with every RSS request, and%0amay end up being recorded in Apache's access logs.%0a%0aQ: How to add feed image?%0a%0aA: Add the following to ''local/config.php'' (this example is for [@?action=rss@]):%0a%0a->[@%0a$FeedFmt['rss']['feed']['image'] =%0a" %3ctitle>Logo title%3c/title>%0a %3clink>http://example.com/%3c/link>%0a %3curl>http://example.com/images/logo.gif%3c/url>%0a %3cwidth>120%3c/width>%0a %3cheight>60%3c/height>";%0a@]%0a%0a-> %25red%25Do not forget NOT to start with a '%3c' as there would be no %3cimage> tag around this... See [[#pitfall1|here]].%0a%0aQ: How do I insert RSS news feeds into PmWiki pages?%0a%0aA: See [[Cookbook:RssFeedDisplay]].%0a%0aQ: How can I specify default feed options in a configuration file instead of always placing them in the url?%0aA: For example, if you want [@?action=rss@] to default to [@?action=rss&group=News&order=-time&count=10@], try the following in a [[local customization(s)]] file:%0a%0a->[@%0a if ($action == 'rss')%0a SDVA($_REQUEST, array(%0a 'group' => 'News',%0a 'order' => '-time',%0a 'count' => 10));%0a@]%0a%0aQ: Are there ways to let people easily subscribe to a feed?%0a%0aA: On some browsers (Mozilla Firefox), the visitor can see an orange RSS icon in the address bar, and subscribe to the feed by clicking on it. To enable the RSS icon, add this to config.php :%0a[@%0a$HTMLHeaderFmt['feedlinks'] = '%3clink rel="alternate" type="application/rss+xml" %0a title="$WikiTitle" href="$ScriptUrl?n=Site.AllRecentChanges&action=rss" />%0a%3clink rel="alternate" type="application/atom+xml" title="$WikiTitle"%0a href="$ScriptUrl?n=Site.AllRecentChanges&action=atom" />';@]%0a%0aYou can also add such a link, for example in your SideBar, @@[=[[Site.AllRecentChanges?action=atom | Subscribe to feed]]=]@@. %0a%0aQ: Can I create an RSS feed for individual page histories?%0aA: See Cookbook:PageFeed.%0a%0a%0aQ: How do I create a custom FeedPage similar to RecentChanges or AllRecentChanges, but with only certain groups or pages recorded?%0aA: See Cookbook:CustomRecentChanges. In a nutshell, you'll declare a $RecentChangesFmt variable with your dedicated FeedPage, and then wrap it in a condition of your choice. For example:%0a[@%0a if (PageVar($pagename, '$Group')!='ForbiddenGroup') {%0a $RecentChangesFmt['Site.MyFeedPage'] =%0a '* [[{$FullName}]] . . . $CurrentTime $[by] $AuthorLink: [=$ChangeSummary=]';%0a }%0a@]%0a%0aQ: How can I update my RSS feed to show every edit for pages on that feed, not just new pages added to the feed?%0aA: Add unique guid links for each edit to your to config.php file (see PITS [[PITS:01161|entry]]):%0a[@%0a $FeedFmt['rss']['item']['guid'] = '{$PageUrl}?guid=$ItemISOTime';%0a@]%0a%0aA: Alternatively, you can create the option for edit monitoring by adding a qualifier for RSS links. This allows the user to choose between default ''new pages'' RSS feeds and ''new edits'' RSS feeds (pmwiki.org has this option enabled).%0a[@%0a ## For new pages updates: http://example.com/wiki/HomePage?action=rss%0a ## For edits updates: http://example.com/wiki/HomePage?action=rss&edits=1%0a if(@$_REQUEST['edits'] && $action == 'rss')%0a $FeedFmt['rss']['item']['guid'] = '{$PageUrl}?guid=$ItemISOTime';%0a@] -time=1567167739 +rev=89 +targets=PmWiki.WikiTrails,Site.AllRecentChanges,Cookbook.Backlinks,PmWiki.WikiGroup,PmWiki.Categories,PmWiki.PageLists,Cookbook.RssFeedDisplay,PmWiki.LocalCustomizations,Cookbook.FeedLinks,PmWiki.PagelistVariables,Cookbook.PageFeed,Cookbook.CustomRecentChanges,PmWiki.LayoutVariables,PITS.01161 +text=(:Summary:Web feed notification of changes:)%0a(:Audience: visitors (intermediate) :)%0aWeb feeds are a convenient mechanism to let visitors be notified of changes to a site. Instead of repeatedly checking [=RecentChanges=] every day to see what is new, a visitor can use a [[news aggregator -> Wikipedia:Aggregator]] to quickly see what pages of interest have changed on a site. Web feeds are commonly recognized by terms such as [[(Wikipedia:)RSS]], [[(Wikipedia:)Atom(_%2528standard%2529)]], and ''[[Wikipedia:web_syndication | web syndication]]''. They are also the foundation for podcasting.%0a%0a!! Based on WikiTrails%0aIn its simplest form, web feeds in PmWiki are built on [[WikiTrails]]. Using a feed action such as [@?action=rss@] or [@?action=atom@] on a trail generates a web feed (often called a "channel") where each page on the trail is an item in the feed. Since the RecentChanges and [[{$SiteGroup}.AllRecentChanges]] pages are effectively trails, one can easily get an RSS feed for a group or site by simply adding [@?action=rss@] to the url for a RecentChanges page. For example, to get the site feed for pmwiki.org, one would use%0a%0a->https://pmwiki.org/wiki/Site/AllRecentChanges?action=rss%0a%0aAuthors can also create custom feeds by simply creating a wiki trail of the pages they want included in the feed. Feeds can also be generated from [[groups -> WikiGroup]], [[categories]], and %25newwin%25[[Cookbook:Backlinks|backlinks]], and the order and number of items in the feed can be changed using options in the feed url. Thus, one can obtain a feed for the ''Skins'' category (sorted with most recent items first) by using%0a%0a->https://pmwiki.org/wiki/Category/Skins?action=rss&order=-time%0a%0aPmWiki is able to generate feeds in many formats, including RSS 2.0 ([@?action=rss@]), Atom 1.0 ([@?action=atom@]), and RSS 1.0 ([@?action=rdf@]). In addition, although it is not normally considered a web feed, PmWiki can generate metadata information using the Dublin Core Metadata extensions ([@?action=dc@]).%0a%0a!!How to read a PmWiki syndicated feed%0a%0a# You'll need a [[news aggregator -> Wikipedia:List_of_feed_aggregators]], which is a piece of software designed to read news feeds. Many different news aggregators are available. Some run on your own computer, either on their own or as plugins for email clients, web browsers, or newsreaders. Others are web applications that you can use from any Internet-connected computer. Some are in between (technically web applications, but ones designed to run on your computer, not some remote server). Get one that you like.%0a# Subscribe to the [[WikiTrail(s)]] you desire by supplying the feed url to the aggregator. The feed url will be the name of a trail page with [@?action=rss@] or [@?action=atom@] added to the end of the url.%0a%0a!!Feed options%0a%0aAdd any of the following options to the end of a PmWiki web feed url to change its output (basically any [[pagelist->PageLists]] option is available for web feeds):%0a%0a:?count=''n'': Limit feed to ''n'' items (default 10)%0a:?order=-time : Display most recently changed items first (default: the order of the trail, or by name; in RecentChanges pages the trail is already ordered by -time)%0a:?trail=''page'': Obtain items from trail on ''page'' (default: the trail on the current page)%0a:?group=''group'': Limit feed to pages in ''group''%0a:?name=''name'': Limit feed to pages with specific ''name''%0a:?link=''page'': Create feed from pages linked to ''page''%0a:?list=normal: Exclude things like RecentChanges, AllRecentChanges, etc.%0a%0a%25audience%25 authors (intermediate)%0a!!Configure PmWiki for feeds%0a%0aThis section describes how to syndicate portions of a wiki to appear in a web feed. It does not describe how to display a web feed within a wiki page -- for that, see Cookbook:RssFeedDisplay.%0a%0aTo enable web feed generation for a site, add one or more of the following to a [[local customization(s)]] file:%0a%0a->%25hlt php%25[@%0aif ($action == 'rss') include_once("$FarmD/scripts/feeds.php");%0aif ($action == 'atom') include_once("$FarmD/scripts/feeds.php");%0aif ($action == 'rdf') include_once("$FarmD/scripts/feeds.php");%0aif ($action == 'dc') include_once("$FarmD/scripts/feeds.php");%0a@]%0a%0aor you can combine multiple feeds into a single expression using "||" to separate each feed type. For example, if you want to enable RSS and Atom feeds you would use%0a%0a->%25hlt php%25[@%0aif ($action == 'rss' ||%0a $action == 'atom' ||%0a $action == 'rdf' ||%0a $action == 'dc') include_once("$FarmD/scripts/feeds.php");%0a@]%0a%0a!!Configure feed content%0aWeb feeds are highly configurable, new elements can be easily added to feeds via the $FeedFmt array. Elements in $FeedFmt look like%0a%0a->%25hlt php%25[@$FeedFmt['atom']['feed']['rights'] = 'All Rights Reserved';@]%0a%0awhere the first index corresponds to the action (?action=atom), the second index indicates a per-feed or per-item element, and%0athe third index is the name of the element being generated. The above setting would therefore generate a "%3crights>All Rights Reserved%3c/rights>" in the feed for ?action=atom.%0a%0a[[#pitfall1]]%0aIf the value of an entry begins with a '%3c', then @@feeds.php@@ doesn't automatically add the tag around it. Elements can also be callable functions which are called to generate the appropriate output. See [[https://blogs.law.harvard.edu/tech/rss | RSS specification]] or other feed specifications for what feed content you can use.%0a%0aYou can also change an existing element rather than add a new one. You can use the following lines to ensure that changes made to the wiki will be picked up by some RSS readers that wouldn't otherwise "notice" a page has been changed:%0a%0a->%25hlt php%25[@%0a# Change the link URL when an item is edited.%0a$FeedFmt['rss']['item']['link'] = '{$PageUrl}?when=$ItemISOTime';%0a$FeedFmt['atom']['item']['link'] =%0a "%3clink rel=\"alternate\" href=\"{\$PageUrl}?when=\$ItemISOTime\" />\n";%0a@]%0a%0a%0a!!See Also%0a%0a* [[Cookbook:FeedLinks]] - Add HTML %3chead> links for auto-discovery of your feeds.%0a* [[WikiTrails]]%0a* Wikipedia:Web_feed, Wikipedia:Web_syndication, Wikipedia:RSS, Wikipedia:Atom_%2528standard%2529%0a%0a!! FAQ%0a>>faq%3c%3c [[#faq]]%0a%0aQ: How do I include text from the page (whole page, or first X characters) in the feed body? (note: markup NOT digested)%0a%0a->%25hlt php%25[@function MarkupExcerpt($pagename) {%0a $page = RetrieveAuthPage($pagename, 'read', false);%0a return substr(@$page['text'], 0, 200);%0a}%0a%0a$FmtPV['$MarkupExcerpt'] = 'MarkupExcerpt($pn)';%0a$FeedFmt['rss']['item']['description'] = '$MarkupExcerpt';@]%0a%0a%25green%25 Does this mean if I want to include the time in the rss title and "summary" to rss body I call [@$FeedFmt@] twice like so:%0a->%25hlt php%25[@$FeedFmt['rss']['item']['description'] = '$LastSummary'; %0a$FeedFmt['rss']['item']['title'] = '{$Group} / {$Title} @ $ItemISOTime';@] %0a%0a-->From mailing list Feb 13,2007, a response by Pm: Yes%0a%0aQ: How can I use the RSS %3cenclosure> tag for podcasting?%0a%0aA: For podcasting of mp3 files, simply attach an mp3 file to the page%0awith the same name as the page (i.e., for a page named Podcast.Episode4,%0aone would attach to that page a file named "Episode4.mp3"). The%0afile is automatically picked up by ?action=rss and used as an%0aenclosure.%0a%0aThe set of potential enclosures is given by the $RSSEnclosureFmt%0aarray, thus%0a%0a->%25hlt php%25[@$RSSEnclosureFmt = array('{$Name}.mp3', '{$Name}.wma', '{$Name}.ogg');@]%0a%0aallows podcasting in mp3, wma, and ogg formats.%0a%0a%0aQ: [[#AddSummary]] How to add "summary" to the title in a rss feed (ie. with [@?action=rss@])?%0a%0aA: Add this line in your [@local/config.php@]%0a%0a->%25hlt php%25[@$FeedFmt['rss']['item']['title'] = '{$Group} / {$Title} : $LastModifiedSummary';@]%0a%0a%0aQ: [[#AddDescriptionSummary]] How to add "description" to the title in an rss feed, and summary to the body?%0a%0aA: Add these lines to your [@local/config.php@]%0a%0a->%25hlt php%25[@$FeedFmt['rss']['item']['title'] = '{$Group} / {$Title} : {$Description}';@]%0a->%25hlt php%25[@$FeedFmt['rss']['item']['description'] = '$LastModifiedSummary';@]%0a%0a%0a'''NOTES:'''%0a* you need to replicate these lines for each type (atom, rdf, dc) of feed you provide.%0a* the RSS '''[@description@]'''-tag is not equivalent to the pmWiki ''[@$Description@]'' variable, despite the confusing similarity.%0a%0aQ: Some of my password-protected pages aren't appearing in the feed... how do I work around this?%0a%0aA: From a similar question on the newsgroup, Pm's reply:%0a%0aThe last time I checked, RSS and other syndication protocols didn't%0areally have a well-established interface or mechanism for performing%0aaccess control (i.e., authentication). As far as I know this is%0astill the case.%0a%0aPmWiki's WebFeeds capability is built on top of pagelists, so it%0acould simply be that the $EnablePageListProtect option is preventing%0athe updated pages from appearing in the feed. You might try%0asetting $EnablePageListProtect=0; and see if the password-protected%0apages start appearing in the RSS feed.%0a%0aThe "downside" to setting $EnablePageListProtect to zero is that%0aanyone doing a search on your site will see the existence of the%0apages in the locked section. They won't be able to read any of%0athem, but they'll know they are there!%0a%0aYou could also set $EnablePageListProtect to zero only if ?action=rss:%0a%0a->%25hlt php%25[@if ($action == 'rss') $EnablePageListProtect = 0;@]%0a%0aThis limits the ability to see the protected pages to RSS feeds;%0anormal pagelists and searches wouldn't see them.%0a%0aLastly, it's also possible to configure the webfeeds to obtain%0athe authentication information from the url directly, as in:%0a%0a .../Site/AllRecentChanges?action=rss&authpw=secret%0a%0aThe big downside to this is that the cleartext password will%0aend up traveling across the net with every RSS request, and%0amay end up being recorded in Apache's access logs.%0a%0aQ: How to add feed image?%0a%0aA: Add the following to ''local/config.php'' (this example is for [@?action=rss@]):%0a%0a->%25hlt php%25[@%0a$FeedFmt['rss']['feed']['image'] =%0a" %3ctitle>Logo title%3c/title>%0a %3clink>https://example.com/%3c/link>%0a %3curl>https://example.com/images/logo.gif%3c/url>%0a %3cwidth>120%3c/width>%0a %3cheight>60%3c/height>";%0a@]%0a%0a-> %25red%25Do not forget NOT to start with a '%3c' as there would be no %3cimage> tag around this... See [[#pitfall1|here]].%0a%0aQ: How do I insert RSS news feeds into PmWiki pages?%0a%0aA: See [[Cookbook:RssFeedDisplay]].%0a%0aQ: How can I specify default feed options in a configuration file instead of always placing them in the url?%0aA: For example, if you want [@?action=rss@] to default to [@?action=rss&group=News&order=-time&count=10@], try the following in a [[local customization(s)]] file:%0a%0a->%25hlt php%25[@%0a if ($action == 'rss')%0a SDVA($_REQUEST, array(%0a 'group' => 'News',%0a 'order' => '-time',%0a 'count' => 10));%0a@]%0a%0aQ: Are there ways to let people easily subscribe to a feed?%0a%0aA: On some browsers (Mozilla Firefox), the visitor can see an orange RSS icon in the address bar, and subscribe to the feed by clicking on it. To enable the RSS icon, add this to config.php :%0a%25hlt php%25[@%0a$HTMLHeaderFmt['feedlinks'] = '%3clink rel="alternate" type="application/rss+xml" %0a title="$WikiTitle" href="$ScriptUrl?n=Site.AllRecentChanges&action=rss" />%0a%3clink rel="alternate" type="application/atom+xml" title="$WikiTitle"%0a href="$ScriptUrl?n=Site.AllRecentChanges&action=atom" />';@]%0a%0aYou can also add such a link, for example in your SideBar, @@[=[[Site.AllRecentChanges?action=atom | Subscribe to feed]]=]@@. %0a%0aQ: Can I create an RSS feed for individual page histories?%0aA: See Cookbook:PageFeed.%0a%0a%0aQ: How do I create a custom FeedPage similar to RecentChanges or AllRecentChanges, but with only certain groups or pages recorded?%0aA: See Cookbook:CustomRecentChanges. In a nutshell, you'll declare a $RecentChangesFmt variable with your dedicated FeedPage, and then wrap it in a condition of your choice. For example:%0a%25hlt php%25[@%0a if (PageVar($pagename, '$Group')!='ForbiddenGroup') {%0a $RecentChangesFmt['Site.MyFeedPage'] =%0a '* [[{$FullName}]] . . . $CurrentTime $[by] $AuthorLink: [=$ChangeSummary=]';%0a }%0a@]%0a%0aQ: How can I update my RSS feed to show every edit for pages on that feed, not just new pages added to the feed?%0aA: Add unique guid links for each edit to your to config.php file (see PITS [[PITS:01161|entry]]):%0a%25hlt php%25[@%0a $FeedFmt['rss']['item']['guid'] = '{$PageUrl}?guid=$ItemISOTime';%0a@]%0a%0aA: Alternatively, you can create the option for edit monitoring by adding a qualifier for RSS links. This allows the user to choose between default ''new pages'' RSS feeds and ''new edits'' RSS feeds (pmwiki.org has this option enabled).%0a%25hlt php%25[@%0a ## For new pages updates: https://example.com/wiki/HomePage?action=rss%0a ## For edits updates: https://example.com/wiki/HomePage?action=rss&edits=1%0a if(@$_REQUEST['edits'] && $action == 'rss')%0a $FeedFmt['rss']['item']['guid'] = '{$PageUrl}?guid=$ItemISOTime';%0a@] +time=1646120102 blob - 6d0e9eed38dda9e539281db52fbae10ca249770d blob + 6bbf3bc99ce16bd0f733adab8d2ad12544f253b7 --- wikilib.d/PmWiki.WikiFarms +++ wikilib.d/PmWiki.WikiFarms @@ -1,10 +1,10 @@ -version=pmwiki-2.2.76 ordered=1 urlencoded=1 -author=Peter Bowers +version=pmwiki-2.3.7 ordered=1 urlencoded=1 +author=simon charset=UTF-8 -csum=markup typo (again) +csum=hlt php (+7) ctime=1142482306 name=PmWiki.WikiFarms -rev=99 -targets=Cookbook.FarmSetupByExample,Cookbook.WikiFarmAlternative,PmWiki.WikiFarms,PmWiki.WikiGroup,PmWiki.Installation,Cookbook.CookbookBasics,PmWiki.LocalCustomizations,PmWiki.WikiFarmTerminology,PmWiki.WikiFarmsAdvanced -text=(:Audience: administrators (intermediate) :)%0a(:Summary:Running multiple wikis from a single installation:)%0aAlso see: [[Cookbook:Farm Setup By Example]], [[Cookbook:Wiki Farm Alternative]]%0a%0aA [[WikiFarm(s)]] is a collection of two or more wikis running on the same web server and sharing a set of common components. The term is based on the computing phrase "server farm".%0a%0aThis page provides some background information about [[WikiFarms]] and describes how to turn a "normal" configuration into a farm by adding a wiki. (Click [[#config|here]] to go directly to instructions on configuring a farm.) There are many ways to configure wiki farms; this page describes only one, in an effort to make it as simple as possible for the administrator who is creating a farm for the first time.%0a%0aThis page will discuss 3 ways to organize content:%0a# Use [[(PmWiki:)WikiGroup]]s%0a# Use independent wiki sites with a shared code base (a "farm")%0a# Use independent wiki sites with a complete PmWiki [[installation]] per site%0a%0a!! Choosing between separate wiki-sites and [[(PmWiki:)WikiGroup|WikiGroups]]%0a!!! Why use [[(PmWiki:)WikiGroup|WikiGroups]]?%0aWhen you divide content between independently installed wikis (i.e., with their own separate URL), it is difficult (but not impossible) to provide services that require access to more than one wiki. For example, the PmWiki search function can only search within one wiki. Using a farm as a way of subdividing related content is generally a bad idea. A much better way to subdivide content is to use [[(PmWiki:)WikiGroup | WikiGroups]].%0a%0a!!! Why use separate wiki-sites?%0aWhen content is largely unrelated and there will be little or no need for sharing the data between the sites, it makes sense to divide the wikis into independently installed sites.%0a%0a(:comment (not sure if this statement is general enough) As a general rule, if you will regularly reference one site from the other (and particularly if you want to view [[PageLists]] of information on one site and view it on the other site) then you probably want to use [[WikiGroup | WikiGroups]] rather than independent sites.:)%0a%0a!! Choosing between separate, independent installations of PmWiki and a [[WikiFarm(s)]]%0aOnce you have decided that you need a separate wiki (with its own URL), you have two basic choices:%0a# Do a complete [[installation]] of PmWiki in a new directory. This gives you two totally independent wikis that are completely self-contained. This is '''not''' a wiki farm.%0a# Create a wiki farm using an existing wiki as the "home wiki" where most of the shared PmWiki components will live.%0a%0a'''The primary motivation for using a wiki farm is to reduce the amount of administrative work involved in managing several wikis.''' In a farm, most of the PmWiki code is stored in one place and is shared by all the wikis. An administrator can (for example) upgrade to a new version of PmWiki on every wiki in the farm by simply updating the shared components in a single location.%0a%0aFrom a reader's point of view, there is no difference between separate, self-contained installations of PmWiki and separate wikis within a WikiFarm: each wiki in a farm is completely independent, and appears as a separate web site. Each wiki in a farm:%0a* has its own URL, and the URLs can be in different domains%0a* can have its own look and feel by using different skins%0a* can have its own add-ons or "recipes" from the [[(Cookbook:)Cookbook(Basics)]]%0a* can have its own administrator responsible for local configuration%0a%0a!!! Why to use independent, self-contained installations of PmWiki%0a* it is not a wiki farm, and requires no additional administrative knowledge - it's just two installations%0a* if you decide to move one of the wikis to another server, you can simply copy the wiki directory structure to the second server, and it will work (assuming there is a web server and PHP in place).%0a* you can run different versions of PmWiki on each wiki (good for testing new versions)%0a* no matter how badly you mess up one installation, it doesn't affect the other%0a%0a!!! Why to use a [[WikiFarm(s)]]%0a* you can upgrade all wikis in your farm by simply upgrading your home wiki%0a* recipes can be shared across all wikis%0a* portions of your configuration can be shared across wikis%0a* most code is stored in one location and shared by all wikis in the farm%0a%0a!!! I still can't decide if I need a farm ...%0aThe good news is that you don't have to decide in advance. In fact, the recommended procedure is to first do a "normal" or single [[installation]] of PmWiki. Use it for a while. Create pages and edit them. Get to know how to add recipes. Be sure to try out [[WikiGroup | WikiGroups]] (they may be all you need).%0a%0aIf you choose to create a wiki farm, then read on ...%0a%0a[[#config]]%0a!! Creating/Configuring a [[WikiFarm(s)]]%0a!!! Prerequisites%0aBefore you create a farm, make sure that:%0a* you have a working installation of PmWiki ready to become the home wiki for your farm%0a* all of the wikis in your farm will be on the same web server%0a* each wiki will have a unique URL, such as http://www.example.com/wiki1/, http://www.example.com/wiki2/, http://another.example.com/wiki1/ and so on.%0a%0a!!! Creating the home wiki%0aYou do have a working installation of PmWiki at this point, don't you? That's good, because your existing wiki is about to become the home wiki of your farm.%0a%0aIn the directory that contains your existing wiki, create the file ''local/farmconfig.php''. This file is used to hold any [[local customizations]] that apply across the whole farm. For example, you could assign an admin password in ''farmconfig.php'' that will be used by all of the wikis in your farm.%0a%0aIf the URL used to access your existing wiki is http://www.example.com/pmwiki/ then a minimal ''farmconfig.php'' file would look like this:%0a%0a-> [@%3c?php if (!defined('PmWiki')) exit();%0a$FarmPubDirUrl = 'http://www.example.com/pmwiki/pub';@]%0a%0aThis loads the variable $FarmPubDirUrl with the URL location of your home wiki's ''pub/'' directory. All of the wikis in your farm share this ''pub/'' directory. The ''pub/'' directory holds skin definitions and GUI-edit buttons to be shared by all the wikis in the farm.%0a%0aAmazing as it may sound, this completes all of the changes you need to make in order to turn your existing wiki into the home wiki of your farm.%0a%0a!!! Creating an additional wiki in your farm%0a-%3c 1. Create a directory to hold the new wiki. This directory must be web-accessible, just like the directory that holds your home wiki.%0a%0a-%3c 2. Create a file called ''index.php'' in the directory with the following contents:%0a%0a--> [@ %3c?php include_once('path/to/pmwiki.php'); @]%0a%0a-> This allows your new wiki to share the PmWiki code stored in your home wiki. The ''[@path/to/pmwiki.php@]'' is the file path to ''pmwiki.php'' in your home wiki. Use an absolute file path ([@/home/username/pmwiki/pmwiki.php@]) or a relative file path ([@../pmwiki/pmwiki.php@]). Do not use a url path - there should not be an '[@http://@]' in it anywhere. For a web server running under Windows, you need to use a complete file path as in [@C:/Apache Group/Apache2 /www/mynewwiki/@].%0a%0a-%3c 3. Open a web browser and browse the URL of the new wiki. This will be a web address starting with '[@http://@]'. PmWiki will attempt to automatically create a writable ''wiki.d/'' directory where the wiki's pages will be stored. If you see an error message, follow the instructions. If you choose the option for a "slightly more secure installation" be sure to execute both commands.%0a%0aYour new wiki is now set up, and your farm now contains 2 wikis. To add more wikis, just repeat these 3 steps.%0a%0a%0a!!! Customization%0aEach wiki in a farm inherits the settings stored in ''farmconfig.php''. Do any customization that you want to apply farm-wide (to all the wikis) in ''farmconfig.php''.%0a%0aCreate a ''local/'' directory within each wiki's directory to hold [[local customizations]] that apply only to that wiki. You should at least create the local/config.php file with a new title, like so : %0a%0a->[@%0a%3c?php if (!defined('PmWiki')) exit();%0a ## Title of your farmed wiki%0a $WikiTitle = 'New Wiki';%0a@]%0a%0aFarm-wide customizations are processed before the individual wiki local customizations.%0a%0aThe PmWiki variable ''$FarmD'' points to the directory in which pmwiki.php is installed, and your home wiki, and it is used as a prefix to allow the other wikis to share PmWiki components. For example:%0a* ''$FarmD/scripts/'' points to the shared ''scripts/'' directory%0a* ''$FarmD/pub/'' points to the shared ''pub/'' directory%0a* ''$FarmD/cookbook/'' points to the shared ''cookbook/'' directory%0a%0aAny [[Cookbook(:.)]] scripts you include in farmconfig.php must be included with a line such as:%0a-> @@include_once("$FarmD/cookbook/scriptfile.php");@@\\%0aNote the double quotes - single quotes may work for per farm inclusions, but they will not work for $FarmD.%0a%0a!!! Password use/authorization on farm wikis:%0a%0a''' How come when I switch to another wiki within a farm, I keep my same authorization?'''%0a%0aPmWiki uses PHP sessions to keep track of authentication/authorization information, and by default PHP sets things up such that all interactions with the same server are considered part of the same session.%0a%0aAn easy way to fix this is to make sure each wiki is using a different cookie name for its session identifier. Near the top of one of the wiki's local/config.php files, before calling authuser or any other recipes, add a line like:%0a%0a-> @@ session_name('XYZSESSID'); @@%0a%0aYou can pick any alphanumeric name for XYZSESSID; for example, for the cs559-1 wiki you might choose%0a%0a-> @@ session_name('CS559SESSID'); @@%0a%0aThis will keep the two wikis' sessions independent of each other.%0a%0a!! Notes%0a* The terminology used to describe wiki farms is not used consistently. See [[WikiFarmTerminology]] for more info.%0a* It is important to remember that not all of the recipes in the Cookbook have been written for or tested with farms. Be sure to look for instructions on how to use a recipe on a farm.%0a* There are many, many more things you can do with farms. Some are described on [[PmWiki:WikiFarmsAdvanced]] which also contains links to step-by-step examples of setting up a farm.%0a%0aCategories: [[(http://www.pmwiki.org/wiki/Category/)WikiFarms]] -time=1433320784 +rev=101 +targets=Cookbook.FarmSetupByExample,Cookbook.WikiFarmAlternative,PmWiki.WikiFarms,PmWiki.WikiGroup,PmWiki.Installation,Cookbook.CookbookBasics,PmWiki.LocalCustomizations,PmWiki.PathVariables,PmWiki.WikiFarmTerminology,PmWiki.WikiFarmsAdvanced,Category.WikiFarms,!WikiFarms +text=(:Audience: administrators (intermediate) :)%0a(:Summary:Running multiple wikis from a single installation:)%0aAlso see: [[Cookbook:Farm Setup By Example]], [[Cookbook:Wiki Farm Alternative]]%0a%0aA [[WikiFarm(s)]] is a collection of two or more wikis running on the same web server and sharing a set of common components. The term is based on the computing phrase "server farm".%0a%0aThis page provides some background information about [[WikiFarms]] and describes how to turn a "normal" configuration into a farm by adding a wiki. (Click [[#config|here]] to go directly to instructions on configuring a farm.) There are many ways to configure wiki farms; this page describes only one, in an effort to make it as simple as possible for the administrator who is creating a farm for the first time.%0a%0aThis page will discuss 3 ways to organize content:%0a# Use [[(PmWiki:)WikiGroup]]s%0a# Use independent wiki sites with a shared code base (a "farm")%0a# Use independent wiki sites with a complete PmWiki [[installation]] per site%0a%0a!! Choosing between separate wiki-sites and [[(PmWiki:)WikiGroup|WikiGroups]]%0a!!! Why use [[(PmWiki:)WikiGroup|WikiGroups]]?%0aWhen you divide content between independently installed wikis (i.e., with their own separate URL), it is difficult (but not impossible) to provide services that require access to more than one wiki. For example, the PmWiki search function can only search within one wiki. Using a farm as a way of subdividing related content is generally a bad idea. A much better way to subdivide content is to use [[(PmWiki:)WikiGroup | WikiGroups]].%0a%0a!!! Why use separate wiki-sites?%0aWhen content is largely unrelated and there will be little or no need for sharing the data between the sites, it makes sense to divide the wikis into independently installed sites.%0a%0a(:comment (not sure if this statement is general enough) As a general rule, if you will regularly reference one site from the other (and particularly if you want to view [[PageLists]] of information on one site and view it on the other site) then you probably want to use [[WikiGroup | WikiGroups]] rather than independent sites.:)%0a%0a!! Choosing between separate, independent installations of PmWiki and a [[WikiFarm(s)]]%0aOnce you have decided that you need a separate wiki (with its own URL), you have two basic choices:%0a# Do a complete [[installation]] of PmWiki in a new directory. This gives you two totally independent wikis that are completely self-contained. This is '''not''' a wiki farm.%0a# Create a wiki farm using an existing wiki as the "home wiki" where most of the shared PmWiki components will live.%0a%0a'''The primary motivation for using a wiki farm is to reduce the amount of administrative work involved in managing several wikis.''' In a farm, most of the PmWiki code is stored in one place and is shared by all the wikis. An administrator can (for example) upgrade to a new version of PmWiki on every wiki in the farm by simply updating the shared components in a single location.%0a%0aFrom a reader's point of view, there is no difference between separate, self-contained installations of PmWiki and separate wikis within a WikiFarm: each wiki in a farm is completely independent, and appears as a separate web site. Each wiki in a farm:%0a* has its own URL, and the URLs can be in different domains%0a* can have its own look and feel by using different skins%0a* can have its own add-ons or "recipes" from the [[(Cookbook:)Cookbook(Basics)]]%0a* can have its own administrator responsible for local configuration%0a%0a!!! Why to use independent, self-contained installations of PmWiki%0a* it is not a wiki farm, and requires no additional administrative knowledge - it's just two installations%0a* if you decide to move one of the wikis to another server, you can simply copy the wiki directory structure to the second server, and it will work (assuming there is a web server and PHP in place).%0a* you can run different versions of PmWiki on each wiki (good for testing new versions)%0a* no matter how badly you mess up one installation, it doesn't affect the other%0a%0a!!! Why to use a [[WikiFarm(s)]]%0a* you can upgrade all wikis in your farm by simply upgrading your home wiki%0a* recipes can be shared across all wikis%0a* portions of your configuration can be shared across wikis%0a* most code is stored in one location and shared by all wikis in the farm%0a%0a!!! I still can't decide if I need a farm ...%0aThe good news is that you don't have to decide in advance. In fact, the recommended procedure is to first do a "normal" or single [[installation]] of PmWiki. Use it for a while. Create pages and edit them. Get to know how to add recipes. Be sure to try out [[WikiGroup | WikiGroups]] (they may be all you need).%0a%0aIf you choose to create a wiki farm, then read on ...%0a%0a[[#config]]%0a!! Creating/Configuring a [[WikiFarm(s)]]%0a!!! Prerequisites%0aBefore you create a farm, make sure that:%0a* you have a working installation of PmWiki ready to become the home wiki for your farm%0a* all of the wikis in your farm will be on the same web server%0a* each wiki will have a unique URL, such as https://www.example.com/wiki1/, https://www.example.com/wiki2/, https://another.example.com/wiki1/ and so on.%0a%0a!!! Creating the home wiki%0aYou do have a working installation of PmWiki at this point, don't you? That's good, because your existing wiki is about to become the home wiki of your farm.%0a%0aIn the directory that contains your existing wiki, create the file ''local/farmconfig.php''. This file is used to hold any [[local customizations]] that apply across the whole farm. For example, you could assign an admin password in ''farmconfig.php'' that will be used by all of the wikis in your farm.%0a%0aIf the URL used to access your existing wiki is https://www.example.com/pmwiki/ then a minimal ''farmconfig.php'' file would look like this:%0a%0a-> %25hlt php%25[@%3c?php if (!defined('PmWiki')) exit();%0a$FarmPubDirUrl = 'https://www.example.com/pmwiki/pub';@]%0a%0aThis loads the variable $FarmPubDirUrl with the URL location of your home wiki's ''pub/'' directory. All of the wikis in your farm share this ''pub/'' directory. The ''pub/'' directory holds skin definitions and GUI-edit buttons to be shared by all the wikis in the farm.%0a%0aAmazing as it may sound, this completes all of the changes you need to make in order to turn your existing wiki into the home wiki of your farm.%0a%0a!!! Creating an additional wiki in your farm%0a-%3c 1. Create a directory to hold the new wiki. This directory must be web-accessible, just like the directory that holds your home wiki.%0a%0a-%3c 2. Create a file called ''index.php'' in the directory with the following contents:%0a%0a--> %25hlt php%25[@ %3c?php include_once('path/to/pmwiki.php'); @]%0a%0a-> This allows your new wiki to share the PmWiki code stored in your home wiki. The ''[@path/to/pmwiki.php@]'' is the file path to ''pmwiki.php'' in your home wiki. Use an absolute file path ([@/home/username/pmwiki/pmwiki.php@]) or a relative file path ([@../pmwiki/pmwiki.php@]). Do not use a url path - there should not be an '[@https://@]' in it anywhere. For a web server running under Windows, you need to use a complete file path as in [@C:/Apache Group/Apache2 /www/mynewwiki/@].%0a%0a-%3c 3. Open a web browser and browse the URL of the new wiki. This will be a web address starting with '[@https://@]'. PmWiki will attempt to automatically create a writable ''wiki.d/'' directory where the wiki's pages will be stored. If you see an error message, follow the instructions. If you choose the option for a "slightly more secure installation" be sure to execute both commands.%0a%0aYour new wiki is now set up, and your farm now contains 2 wikis. To add more wikis, just repeat these 3 steps.%0a%0a%0a!!! Customization%0aEach wiki in a farm inherits the settings stored in ''farmconfig.php''. Do any customization that you want to apply farm-wide (to all the wikis) in ''farmconfig.php''.%0a%0aCreate a ''local/'' directory within each wiki's directory to hold [[local customizations]] that apply only to that wiki. You should at least create the local/config.php file with a new title, like so : %0a%0a->%25hlt php%25[@%0a%3c?php if (!defined('PmWiki')) exit();%0a ## Title of your farmed wiki%0a $WikiTitle = 'New Wiki';%0a@]%0a%0aFarm-wide customizations are processed before the individual wiki local customizations.%0a%0aThe PmWiki variable ''$FarmD'' points to the directory in which pmwiki.php is installed, and your home wiki, and it is used as a prefix to allow the other wikis to share PmWiki components. For example:%0a* ''$FarmD/scripts/'' points to the shared ''scripts/'' directory%0a* ''$FarmD/pub/'' points to the shared ''pub/'' directory%0a* ''$FarmD/cookbook/'' points to the shared ''cookbook/'' directory%0a%0aAny [[Cookbook(:.)]] scripts you include in farmconfig.php must be included with a line such as:%0a-> @@include_once("$FarmD/cookbook/scriptfile.php");@@\\%0aNote the double quotes - single quotes may work for per farm inclusions, but they will not work for $FarmD.%0a%0a!!! Password use/authorization on farm wikis:%0a%0a''' How come when I switch to another wiki within a farm, I keep my same authorization?'''%0a%0aPmWiki uses PHP sessions to keep track of authentication/authorization information, and by default PHP sets things up such that all interactions with the same server are considered part of the same session.%0a%0aAn easy way to fix this is to make sure each wiki is using a different cookie name for its session identifier. Near the top of one of the wiki's local/config.php files, before calling authuser or any other recipes, add a line like:%0a%0a-> %25hlt php%25@@ session_name('XYZSESSID'); @@%0a%0aYou can pick any alphanumeric name for XYZSESSID; for example, for the cs559-1 wiki you might choose%0a%0a-> %25hlt php%25@@ session_name('CS559SESSID'); @@%0a%0aThis will keep the two wikis' sessions independent of each other.%0a%0a!! Notes%0a* The terminology used to describe wiki farms is not used consistently. See [[WikiFarmTerminology]] for more info.%0a* It is important to remember that not all of the recipes in the Cookbook have been written for or tested with farms. Be sure to look for instructions on how to use a recipe on a farm.%0a* There are many, many more things you can do with farms. Some are described on [[PmWiki:WikiFarmsAdvanced]] which also contains links to step-by-step examples of setting up a farm.%0a%0aCategories: [[!WikiFarms]] +time=1656810056 blob - d28eb34711e64caf8593144f71763f68a0525976 blob + bdbe2caf9928c6bc1871c5772dffa0afe90006e0 --- wikilib.d/PmWiki.WikiGroup +++ wikilib.d/PmWiki.WikiGroup @@ -1,10 +1,10 @@ -version=pmwiki-2.2.118 ordered=1 urlencoded=1 -author=Petko +version=pmwiki-2.3.8 ordered=1 urlencoded=1 +author=simon charset=UTF-8 -csum= +csum=http+s, hlt php, pmhlt (+153) keywords=trailing dot, trailing slash, default group name=PmWiki.WikiGroup -rev=112 +rev=115 targets=Main.WikiSandbox,Main.HomePage,PmWiki.MailingLists,PmWiki.Links,PmWiki.CreatingNewPages,PmWiki.PmWiki,Site.Site,SiteAdmin.SiteAdmin,PmWiki.Search,PmWiki.WikiGroup,PmWiki.SpecialPages,PmWiki.RecentChanges,Site.AllRecentChanges,PmWiki.GroupHeaders,PmWiki.Passwords,PmWiki.WikiAdministrator,PmWiki.LocalCustomizations,PmWiki.GroupCustomizations,PmWiki.BasicVariables,PmWiki.HierarchicalGroups,Cookbook.SubgroupMarkup,Cookbook.IncludeWithEdit,Cookbook.LimitWikiGroups,Cookbook.NewGroupWarning,Cookbook.GetRidOfMain,Cookbook.RecentChangesDeletion -text=(:Audience: authors (basic) :)%0a(:Summary: Organising pages into related groups:)%0a(:keywords trailing dot, trailing slash, default group:)%0aPmWiki pages are organized into groups of related pages. This feature was added to PmWiki to allow authors to create their own ''wiki spaces'' of specialized content on their own, without having to become, or rely on, wiki administrators. See [[http://pmichaud.com/|Pm]]'s [[http://pmichaud.com/pipermail/pmwiki-users/2006-March/024838.html|post]] to the pmwiki-users [[mailing list(s)]].%0a%0a!! In-group and cross-group linking%0aBy default, page [[links]] are between pages of the same group; to create a link to a page in another group, add the name of the other group and a dot or slash to the page name. For example, links to [=Main/WikiSandbox=] could be written as:%0a%0a(:markup class=horiz:)%0a* [[Main.WikiSandbox]]%0a* [[Main/WikiSandbox]]%0a* [[(Main.Wiki)Sandbox]]%0a* [[Main.WikiSandbox | link text]]%0a* [[Main.WikiSandbox | +]]%0a(:markupend:)%0a%0aTo link to the [[#groupdefaultpage | default home page]] of a group, the name of the page can be omitted, like this:%0a%0a(:markup class=horiz:)%0a* [[Main.]]%0a* [[Main/]]%0a(:markupend:)%0a%0a!! Creating groups%0aCreating a new group is as easy as [[creating new pages]]; simply edit an existing page to include a [[link(s)]] to the new group's default home page (or any page in the new group) then click on the '?' to edit the page. As a rule, group names must start with a letter (but this can be changed by the wiki administrator by adding %0a-> @@[@$GroupPattern = '[[:upper:]\\d][\\w]*(?:-\\w+)*';@]@@%0ain config.php).%0a%0aFor example, to make a default page in the group Foo, create a link to [=[[Foo/]]=] (or [=[[Foo.]]=]). %0aTo make a page called Bar in the group Foo, create a link to [=[[Foo/Bar]]=] and follow the link to edit that page.%0a%0a!! Groups in a standard PmWiki distribution%0a* [[Main]]: The default group. On many wikis, it contains most of the author-contributed content. Main.HomePage and Main.WikiSandbox come pre-installed.%0a* [[PmWiki]]: An edit-protected group that contains PmWiki documentation and help pages.%0a* [[Site]]: Holds a variety of utility and configuration pages used by PmWiki, including [[%3c%3c]][=SideBar=], Search, Preferences, Templates, and [=AllRecentChanges=].%0a* [[SiteAdmin/]]: Holds a number of password protected administration and configuration pages used by PmWiki, including [[%3c%3c]] [=ApprovedUrls=], and Blocklist%0a%0a* To list all the groups in a site, try [[PmWiki/Search | searching]] for "[[{$FullName}?action=search&q=fmt%253Dgroup|fmt=group]]".%0a* To list all the pages in a group, try [[PmWiki/Search | searching]] for "[[{$FullName}?action=search&q={$Group}%252F|GroupName/]]".%0a%0a[[#specialpages]]%0a!! [[(PmWiki:)Special Pages]] in a Group%0aBy default, the ''[[Recent Changes]]'' page of each group shows only the pages that have changed within that group; the ''[[Site.All Recent Changes]]'' page shows all pages that have changed in all groups.%0a%0aEach group can also have ''[[Group Header(s)]]'' or ''Group Footer'' pages that contain text to be automatically prepended or appended to every page in the group. A group can also have a ''Group Attributes ''page that defines attributes (read and edit passwords) shared by all pages within the group. %0a%0aEach page can also have its own individual read/edit password that overrides the group passwords (see [[Passwords]]).%0a%0aFinally, [[wiki administrator]]s can set [[local customizations]] on a per-group basis--see [[Group Customizations]].%0a%0a[[#groupdefaultpage]]%0a!! Group's default page%0a%0aThe default "start page" for a group is a page whose name can be: %0a# the same as the group (Foo/Foo)%0a# HomePage (Foo/HomePage)%0a# a name that the administrator has assigned to the [={$DefaultName}=] variable in the configuration ([farm]config.php) file. %0a%0aNote, on this site, the value of [={$DefaultName}=] is ''{$DefaultName}'' and, thus, the default home page would be Foo/{$DefaultName}. %0a%0aYou can usefully change the default ''search'' order for an entered page name by setting the variable @@$PagePathFmt @@ in @@config.php@@, eg%0a-> @@ $PagePathFmt = array('$Group.$1', '$1.$DefaultName', '$1.$1', '$DefaultGroup.$1', 'Profiles.$1'); @@%0awhere "$1" is the name of the page entered. %0a%0aIf you are setting $DefaultName in order to make a start page for your groups, you will need to also define $PagePathFmt (see above) to get consistent use of this functionality. The simplest setting would be this:%0a-> @@ $PagePathFmt = array('$Group.$1', '$1.$DefaultName'); @@%0aNote that the order of the definitions of these variables ($DefaultName and $PagePathFmt) is important - it must occur before any call to ResolvePageName() and it (therefore) it cannot occur in a per-page or per-group customization script.%0a%0aAs noted above, when linking to the default home page, authors can omit the page name and simply identify the group followed by a forward slash ([=[[Foo/]]=]).%0a%0aNote the forward slash is required to ensure that the link unambiguously points to the identified group. %0aIf the slash is omitted, the link can end up being interpreted as pointing to an existing (or new) page in the current group (if the group, or its default home page, do not exist). %0a%0a!! Subgroups? Subpages?%0aNo, PmWiki does not have subpages. Pm's reasons for not having subgroups are described at [[PmWiki:Hierarchical Groups]], but it comes down to not having a good page linking syntax. If you create a link or pagename like [@[[A.B.C]]@] PmWiki doesn't think of "B.C" as being in group "A", it instead thinks of "C" as being in group "AB", which is a separate group from "A". Wiki administrators can look at [[Cookbook:Subgroup Markup]] and [[Cookbook:Include With Edit]] for recipes that may be of some help with developing subgroups or subpages.%0a%0a!! Restricting the creation of new groups%0aYou can set PmWiki's $GroupPattern variable to only accept the group names you want to define. For example, to limit pages to the "PmWiki", "Main", "Profiles", and "Example" groups, add the following to local/config.php:%0a%0a-> $GroupPattern = '(?:Site|SiteAdmin|PmWiki|Main|Profiles|Example)';%0a%0aWith this setting, only the listed groups will be considered valid WikiGroups. You can add more groups to the list by placing additional group names separated by pipes (|).%0a%0aSee other solutions to this at [[Cookbook:Limit Wiki Groups]] and [[Cookbook:New Group Warning]].%0a%0a!! FAQ%0a>>faq%3c%3c [[#faq]]%0aQ: How can I get rid of the 'Main' group in urls for pages pointing to Main?%0a%0aA: See [[Cookbook:Get Rid Of Main]].%0a%0aQ: How can I limit the creation of new groups?%0a%0aA: See [[Cookbook:Limit Wiki Groups]].%0a%0aQ: Why doesn't [=[[St. Giles and St. James]]=] work as a link? (It doesn't display anything.)%0a%0aA: Because it contains periods, and destroys PmWiki's file structure, which saves pages as [=Group.PageName=]. Adding those periods disrupts this format. Links may only contain words. If you need a link precisely as shown, the page must be named eg StGilesAndStJames then you can use the [=(:title:)=] directive to have the page's title appear with periods [=(:title St. Giles and St. James:)=]. (Although in US grammar the period is often omitted and in UK grammar the period [[http://en.wikipedia.org/wiki/Abbreviation|must be]] omitted for contractions like St).%0a%0aQ: How can I delete a wiki group?%0a%0aA: Normally you can't, as this requires an admin with server-side access to delete the file that makes up the group's RecentChanges page. But there is an option method of making it possible to delete RecentChanges pages from within the wiki if the admin enables the code found on [[Cookbook:RecentChanges Deletion]].%0a%0aQ: How can I delete a wiki group's Group.RecentChanges page?%0a%0aA: Normally you can't, as this requires an admin with server-side access to delete a file. But there is an optional method of making it possible to delete RecentChanges pages from within the wiki if the admin enables the code found on [[Cookbook:RecentChanges Deletion]].%0a%0aQ: Can I delete a wiki group inside wiki.d folder on the server to eliminate the group?%0aA: Yes, if you delete all files named YourGroup.*, the pages from that group will be removed from the wiki. Note that the documentation (group PmWiki) and the site configuration (groups Site and SiteAdmin) that exist in the default installation, are located in wikilib.d and not in wiki.d, and some recipes provide files located in a wikilib.d subdirectory in the cookbook directory. (You shouldn't delete the groups Site and SiteAdmin, required for normal function.)%0a%0aQ: How can I list all pages in a WikiGroup?%0aA: In a wiki page use [@(:pagelist group=GroupName list=all:)@] or in a search box type @@GroupName/ list=all@@. -time=1567165843 +text=(:Audience: authors (basic) :)%0a(:Summary: Organising pages into related groups:)%0a(:keywords trailing dot, trailing slash, default group:)%0aPmWiki pages are organized into groups of related pages. This feature was added to PmWiki to allow authors to create their own ''wiki spaces'' of specialized content on their own, without having to become, or rely on, wiki administrators. See [[https://pmichaud.com/|Pm]]'s [[https://pmichaud.com/pipermail/pmwiki-users/2006-March/024838.html|post]] to the pmwiki-users [[mailing list(s)]].%0a%0a!! In-group and cross-group linking [[#linking]]%0aBy default, page [[links]] are between pages of the same group; to create a link to a page in another group, add the name of the other group and a dot or slash to the page name. For example, links to [=Main/WikiSandbox=] could be written as:%0a%0a(:markup class=horiz:)%0a* [[Main.WikiSandbox]]%0a* [[Main/WikiSandbox]]%0a* [[(Main.Wiki)Sandbox]]%0a* [[Main.WikiSandbox | link text]]%0a* [[Main.WikiSandbox | +]]%0a(:markupend:)%0a%0aTo link to the [[#groupdefaultpage | default home page]] of a group, the name of the page can be omitted, like this:%0a%0a(:markup class=horiz:)%0a* [[Main.]]%0a* [[Main/]]%0a(:markupend:)%0a%0a!! Creating groups [[#creategroups]]%0aCreating a new group is as easy as [[creating new pages]]; simply edit an existing page to include a [[link(s)]] to the new group's default home page (or any page in the new group) then click on the '?' to edit the page. As a rule, group names must start with a letter (but this can be changed by the wiki administrator by adding %0a-> %25hlt php%25@@[@$GroupPattern = '[[:upper:]\\d][\\w]*(?:-\\w+)*';@]@@%0ain @@config.php@@).%0a%0aFor example, to make a default page in the group Foo, create a link to [=[[Foo/]]=] (or [=[[Foo.]]=]). %0aTo make a page called Bar in the group Foo, create a link to [=[[Foo/Bar]]=] and follow the link to edit that page.%0a%0a!! Groups in a standard PmWiki distribution [[#stdgroups]]%0a* [[Main]]: The default group. On many wikis, it contains most of the author-contributed content. @@Main.HomePage@@ and @@Main.WikiSandbox@@ come pre-installed.%0a* [[PmWiki]]: An edit-protected group that contains PmWiki documentation and help pages.%0a* [[Site]]: Holds a variety of utility and configuration pages used by PmWiki, including [[%3c%3c]][=SideBar=], Search, Preferences, Templates, and [=AllRecentChanges=].%0a* [[SiteAdmin/]]: Holds a number of password protected administration and configuration pages used by PmWiki, including [[%3c%3c]] [=ApprovedUrls=], and Blocklist%0a%0a* To list all the groups in a site, try [[PmWiki/Search | searching]] for "[[{$FullName}?action=search&q=fmt%253Dgroup|fmt=group]]".%0a* To list all the pages in a group, try [[PmWiki/Search | searching]] for "[[{$FullName}?action=search&q={$Group}%252F|GroupName/]]".%0a%0a[[#specialpages]]%0a!! [[(PmWiki:)Special Pages]] in a Group [[#specialpages]]%0aBy default, the ''[[Recent Changes]]'' page of each group shows only the pages that have changed within that group; the ''[[Site.All Recent Changes]]'' page shows all pages that have changed in all groups.%0a%0aEach group can also have ''[[Group Header(s)]]'' or ''Group Footer'' pages that contain text to be automatically prepended or appended to every page in the group. A group can also have a ''Group Attributes ''page that defines attributes (read and edit passwords) shared by all pages within the group. %0a%0aEach page can also have its own individual read/edit password that overrides the group passwords (see [[Passwords]]).%0a%0aFinally, [[wiki administrator]]s can set [[local customizations]] on a per-group basis--see [[Group Customizations]].%0a%0a[[#groupdefaultpage]]%0a!! Group's default page [[#defaultpage]]%0a%0aThe default "start page" for a group is a page whose name can be: %0a# the same as the group (@@Foo/Foo@@)%0a# @@HomePage@@ (@@Foo/HomePage@@)%0a# a name that the administrator has assigned to the [={$DefaultName}=] variable in the configuration (@@[farm]config.php@@) file. %0a%0aNote, on this site, the value of [={$DefaultName}=] is ''{$DefaultName}'' and, thus, the default home page would be @@Foo/{$DefaultName}@@. %0a%0aYou can usefully change the default ''search'' order for an entered page name by setting the variable @@$PagePathFmt @@ in @@config.php@@, eg%0a-> %25hlt php%25@@ $PagePathFmt = array('$Group.$1', '$1.$DefaultName', '$1.$1', '$DefaultGroup.$1', 'Profiles.$1'); @@%0awhere "$1" is the name of the page entered. %0a%0aIf you are setting $DefaultName in order to make a start page for your groups, you will need to also define $PagePathFmt (see above) to get consistent use of this functionality. The simplest setting would be this:%0a-> %25hlt php%25@@ $PagePathFmt = array('$Group.$1', '$1.$DefaultName'); @@%0aNote that the order of the definitions of these variables ($DefaultName and $PagePathFmt) is important - it must occur before any call to ResolvePageName() and it (therefore) it cannot occur in a per-page or per-group customization script.%0a%0aAs noted above, when linking to the default home page, authors can omit the page name and simply identify the group followed by a forward slash ([=[[Foo/]]=]).%0a%0aNote the forward slash is required to ensure that the link unambiguously points to the identified group. %0aIf the slash is omitted, the link can end up being interpreted as pointing to an existing (or new) page in the current group (if the group, or its default home page, do not exist). %0a%0a!! Subgroups? Subpages? [[#subgroups]]%0aNo, PmWiki does not have subpages. Pm's reasons for not having subgroups are described at [[PmWiki:Hierarchical Groups]], but it comes down to not having a good page linking syntax. If you create a link or pagename like [@[[A.B.C]]@] PmWiki doesn't think of "B.C" as being in group "A", it instead thinks of "C" as being in group "AB", which is a separate group from "A". Wiki administrators can look at [[Cookbook:Subgroup Markup]] and [[Cookbook:Include With Edit]] for recipes that may be of some help with developing subgroups or subpages.%0a%0a!! Restricting the creation of new groups [[#restrictcreation]]%0aYou can set PmWiki's $GroupPattern variable to only accept the group names you want to define. For example, to limit pages to the "PmWiki", "Main", "Profiles", and "Example" groups, add the following to local/config.php:%0a%0a-> %25hlt php%25@@$GroupPattern = '(?:Site|SiteAdmin|PmWiki|Main|Profiles|Example)';@@%0a%0aWith this setting, only the listed groups will be considered valid WikiGroups. You can add more groups to the list by placing additional group names separated by pipes (|).%0a%0aSee other solutions to this at [[Cookbook:Limit Wiki Groups]] and [[Cookbook:New Group Warning]].%0a%0a!! FAQ [[#faq]]%0a>>faq%3c%3c%0aQ: How can I get rid of the 'Main' group in urls for pages pointing to Main?%0a%0aA: See [[Cookbook:Get Rid Of Main]].%0a%0aQ: How can I limit the creation of new groups?%0a%0aA: See [[Cookbook:Limit Wiki Groups]].%0a%0aQ: Why doesn't [=[[St. Giles and St. James]]=] work as a link? (It doesn't display anything.)%0a%0aA: Because it contains periods, and destroys PmWiki's file structure, which saves pages as [=Group.PageName=]. Adding those periods disrupts this format. Links may only contain words. If you need a link precisely as shown, the page must be named eg StGilesAndStJames then you can use the %25pmhlt%25[@(:title:)@] directive to have the page's title appear with periods [@(:title St. Giles and St. James:)@]. (Although in US grammar the period is often omitted and in UK grammar the period [[https://en.wikipedia.org/wiki/Abbreviation|must be]] omitted for contractions like St).%0a%0aQ: How can I delete a wiki group?%0a%0aA: Normally you can't, as this requires an admin with server-side access to delete the file that makes up the group's @@RecentChanges@@ page. But there is an option method of making it possible to delete @@RecentChanges@@ pages from within the wiki if the admin enables the code found on [[Cookbook:RecentChanges Deletion]].%0a%0aQ: How can I delete a wiki group's @@Group.RecentChanges@@ page?%0a%0aA: Normally you can't, as this requires an admin with server-side access to delete a file. But there is an optional method of making it possible to delete @@RecentChanges@@ pages from within the wiki if the admin enables the code found on [[Cookbook:RecentChanges Deletion]].%0a%0aQ: Can I delete a wiki group inside @@wiki.d@@ folder on the server to eliminate the group?%0aA: Yes, if you delete all files named @@YourGroup.*@@, the pages from that group will be removed from the wiki. Note that the documentation (group @@PmWiki@@) and the site configuration (groups @@Site@@ and @@SiteAdmin@@) that exist in the default installation, are located in @@wikilib.d@@ and not in @@wiki.d@@, and some recipes provide files located in a @@wikilib.d@@ subdirectory in the cookbook directory. (You shouldn't delete the groups @@Site@@ and @@SiteAdmin@@, they are required for normal function.)%0a%0aQ: How can I list all pages in a WikiGroup?%0aA: In a wiki page use %25pmhlt%25[@(:pagelist group=GroupName list=all:)@] or in a search box type @@GroupName/ list=all@@. +time=1659950011 blob - 6b14c3a5d91e4cc5d23df7501a21e2f9ee1baae7 blob + f17c736feced0a0ea3be5ac791ee0d91250cc789 --- wikilib.d/PmWiki.WikiStructure +++ wikilib.d/PmWiki.WikiStructure @@ -1,11 +1,10 @@ -version=pmwiki-2.2.30 ordered=1 urlencoded=1 -agent=Mozilla/5.0 (X11; Linux x86_64; rv:5.0) Gecko/20100101 Firefox/5.0 -author=Petko +version=pmwiki-2.3.8 ordered=1 urlencoded=1 +author=simon charset=UTF-8 -csum=refactored +csum=pm hlt, update (-236) name=PmWiki.WikiStructure post= Save -rev=39 +rev=41 targets=PmWiki.WikiPage,PmWiki.WikiWord,PmWiki.Links,PmWiki.WikiGroup,PmWiki.WikiTrails,PmWiki.Categories,PmWiki.PageTextVariables,PmWiki.PageLists,Site.PageListTemplates,PmWiki.IncludeOtherPages,PmWiki.Search -text=(:Summary: PmWiki structural support for page organization:)%0aAuthors have a range of options to choose from when organizing a collection of [[wiki page]]s. %0aUsed in combination, these give a lot of flexibility.%0aAn effective wiki will use all of these to optimize%0a* content%0a* navigation%0aThese are the two most important aspects of a website.%0a%0a:[[Wiki Word]]: The most powerful organizing principle is the author's choice of page names. When a search returns a list of pages, their names need to be clear enough to guide a visitor to the right place.%0a: : Providing a network of [[PmWiki/links]] to other points in the wiki, with or without wiki words, is the primary means of navigating a wiki.%0a%0a:[[Wiki Page]]: A page with text (and images), where the text can contain for instance [[WikiWord]]s that automatically becomes a link to another WikiPage.%0a%0a:[[Wiki Group]]: PmWiki requires every page to be a member of a group. A group is like a wiki within a wiki; it can have its own presentation look, security controls and navigation aids. With default configuration, [[WikiWord]]s are only searched inside the current group, and you use either [@OtherGroup/MyWikiWord@] or [@OtherGroup.MyWikiWord@] to refer to pages in other groups (see [[Links]]).%0a%0a:[[Wiki Trails]]: A collection of pages, either in the same group or across multiple groups, can be designated as a trail. A visitor can move from stop to stop by clicking on ''next'' and ''previous'' links.%0a%0a:[[Categories]]: Individual wiki pages can also be grouped by having tags and links to a common "category" page; we say that any pages that link to a common page are in a "category" defined by that page. PmWiki uses the [@[[!category]]@] markup as a shorthand to place a page into a category with other pages containing the same markup.%0a: : The shortcoming of categories is that categories do not distinguish between the declaration of a category ([=[[!structure]]=]) and the link to a category ([=[[Category/Structure]]=]).%0a%0a:[[Page text variables]]: A newer and more powerful concept than [[Categories]], pages can use one of more [[page text variables]] to store page attributes. These can the be used in [[page lists]].%0a%0a:[[Page lists]]: Page lists provide a powerful means of presenting lists of relevant pages, or selection of data from within a page. Lists are [[Site/PageListTemplates|template]] based and are highly customizable.%0a%0a:[[Include other pages]]: The capability to include parts of other pages also provides a flexible means of sharing content between pages.%0a%0a:[[Search]]: Being able to search is a fundamental requirement of a website. In PmWiki search, like pagelists is both powerful and highly customizable.%0a -time=1315670897 +text=(:Summary: PmWiki structural support for page organization:)%0aAuthors have a range of options to choose from when organizing a collection of [[wiki page]]s. %0aUsed in combination, these give a lot of flexibility.%0aAn effective wiki will use all of these to optimize%0a* content%0a* navigation%0aThese are the two most important aspects of a website.%0a%0a:[[Wiki Word]]: The most powerful organizing principle is the author's choice of page names. When a search returns a list of pages, their names need to be clear enough to guide a visitor to the right place.%0a: : Providing a network of [[PmWiki/links]] to other points in the wiki, with or without wiki words, is the primary means of navigating a wiki.%0a%0a:[[Wiki Page]]: A page with text (and images), where the text can contain for instance [[WikiWord]]s that automatically becomes a link to another WikiPage.%0a%0a:[[Wiki Group]]: PmWiki requires every page to be a member of a group. A group is like a wiki within a wiki; it can have its own presentation look, security controls and navigation aids. With default configuration, [[WikiWord]]s are only searched inside the current group, and you use either [@OtherGroup/MyWikiWord@] or [@OtherGroup.MyWikiWord@] to refer to pages in other groups (see [[Links]]).%0a%0a:[[Wiki Trails]]: A collection of pages, either in the same group or across multiple groups, can be designated as a trail. A visitor can move from stop to stop by clicking on ''next'' and ''previous'' links.%0a%0a:[[Categories]]: Individual wiki pages can also be grouped by having tags and links to a common "category" page; we say that any pages that link to a common page are in a "category" defined by that page. PmWiki uses the %25pmhlt%25[@[[!category]]@] markup as a shorthand to place a page into a category with other pages containing the same markup.%0a%0a:[[Page text variables]]: Pages can use one or more [[page text variables]] to store page attributes. These can then be used in [[page lists]].%0a%0a:[[Page lists]]: Page lists provide a powerful means of presenting lists of relevant pages, or selection of data from within a page. Lists are [[Site/PageListTemplates|template]] based and are highly customizable.%0a%0a:[[Include other pages]]: The capability to include parts of other pages also provides a flexible means of sharing content between pages.%0a%0a:[[Search]]: Being able to search is a fundamental requirement of a website. In PmWiki search, like pagelists is both powerful and highly customizable.%0a +time=1659950155 blob - fa9c4936b346b5dc6de1cb4214130c730a556f39 blob + 3b6658fb6210b7591d72f11b4b6d17eff6dd2827 --- wikilib.d/PmWiki.WikiStyles +++ wikilib.d/PmWiki.WikiStyles @@ -1,10 +1,10 @@ -version=pmwiki-2.2.129 ordered=1 urlencoded=1 +version=pmwiki-2.3.15 ordered=1 urlencoded=1 author=Petko charset=UTF-8 -csum=upd. highlight.js version (+0) +csum=+overflow (+10) name=PmWiki.WikiStyles post= Save -rev=239 -targets=PmWiki.WikiWord,PmWiki.WikiStyleColors,PmWiki.BlockMarkup,PmWiki.Tables,PmWiki.TableDirectives,PmWiki.GroupHeaders,PmWiki.WikiAdministrator,PmWiki.LocalCustomizations,PmWiki.CustomWikiStyles,Cookbook.OutlineLists,PmWiki.BasicEditing,PmWiki.LayoutVariables,PmWiki.WikiStyleExamples,PmWiki.TextFormattingRules,PmWiki.ListStyles,Cookbook.WikiStylesPlus -text=(:Summary: Modifying the style of page contents:)%0a(:Audience: authors (basic, advanced) :)%0a%0aWikiStyles allow authors to modify the color and other styling attributes of the contents of a page. %0aA WikiStyle is written using percent-signs, as in %25red%25[@%25red%25@]%25%25 or %25bgcolor=lightblue%25[@%25bgcolor=lightblue%25@]%25%25.%0a%0a[[#Attributes]]%0a!! WikiStyle attributes%0a%0aThe style attributes recognized within a WikiStyle specification are:%0a(:table:)%0a(:cellnr colspan=2:)%25center%25------------ CSS -------------%25%25%0a(:cell:)%25center%25--HTML--%25%25%0a(:cellnr:)%0a bgcolor%0a background-color%0a border'^[[#al|1]]^'%0a color%0a display%0a float%0a clear%0a font-size%0a font-family%0a font-weight%0a font-style%0a(:cell:)%0a height[[#fn|*]]%0a list-style%0a margin'^[[#al|1]]^'%0a padding'^[[#al|1]]^'%0a text-align%0a text-decoration%0a white-space%0a width[[#fn|*]] %0a(:cell:)%0a accesskey %0a align%0a class%0a hspace %0a id %0a target %0a rel %0a vspace %0a value%0a reversed%0a(:cellnr rowspan=3:)%0a Special: define, apply%0a(:tableend:)%0a%0aThe attributes in the first two columns correspond to the ''[[cascading style sheet -> http://blooberry.com/indexdot/css/propindex/all.htm]]'' (CSS) properties of the same name. The attributes in the last column apply only to specific items:%0a%0a* '''[@class=@]''' and '''[@id=@]''' assign a CSS class or identifier to an HTML element%0a* '''[@target=name@]''' opens links that follow in a browser window called "name"%0a* '''[@rel=name@]''' in a link identifies the relationship of a target page%0a* '''[@accesskey=x@]''' uses 'x' as a shortcut key for the link that follows%0a* '''[@value=9@]''' sets the number of the current ordered list item%0a%0a** [[#fn]] The width and height attributes have asterisks because they are handled specially for %3cimg .../> tags. If used by themselves (i.e., without anything providing an "apply=" parameter to the WikiStyle), then they set the 'width=' and 'height=' attributes of any %3cimg ... /> tags that follow. Otherwise, they set the 'width:' and 'height:' properties of the element being styled.%0a## [[#al]] margin, padding, and border can be suffixed by -left, -right, -top, and -bottom%0a%0a!! WikiStyles versus CSS styles%0aWikiStyles, as written in the wiki page, are not exactly CSS styles or CSS classes. WikiStyles allow authors to use both pre-defined by the administrator CSS classes, and to define new combinations of styles, without any need to edit/update local CSS files on the server.%0a%0aNote that PmWiki allows advanced authors to use of @@ class= @@ and @@ style= @@ in tables and division blocks, but these are raw HTML attributes, and not WikiStyles; knowledge of CSS is required to use them.%0a%0a!! Text color and font%0aThe most basic use of WikiStyles is to change text attributes such as color, background color, and font. %0aPmWiki defines several WikiStyles for changing the text color to [=%25black%25, %25white%25, %25red%25, %25yellow%25, %25blue%25, %25gray%25 (%25grey%25), %25silver%25, %25maroon%25, %25green%25, %25navy%25, %25fuchsia%25, %25olive%25, %25lime%25, %25teal%25, %25aqua%25, %25orange%25 and %25purple%25=].%0a%0a(:markup class=horiz:)%0aThe basket contains %25red%25 apples, %25blue%25 blueberries, %25purple%25 eggplant, %25green%25 limes, %25%25 and more.%0a(:markupend:)%0a%0aFor colors other than the predefined colors, use the [@%25color=...%25@] WikiStyle. (Note: RGB colors (#rrggbb) should always be specified with lowercase letters to avoid [[WikiWord]] conflicts.)%0a%0a(:markup class=horiz:)%0aI'd like to have some %25color=#ff7f00%25 tangerines%25%25, too!%0a(:markupend:)%0a%0aTo change the background color, use [@%25bgcolor=...%25@] as a WikiStyle:%0a%0a(:markup class=horiz:)%0aThis sentence contains %25bgcolor=green yellow%25 yellow text on a green background.%0a(:markupend:)%0a%0aSee [[(PmWiki:)WikiStyle Colors]] for more color help.%0a%0a!! Text justification%0aWikiStyles are used to control the text justification%0a%0a(:markup class=horiz:)%0a%25center%25 This text is centered. %0a%0a%25right%25 Right justified.%0a(:markupend:)%0a%0aand to create floating text:%0a%0a(:markup class=horiz:)%0a%25rfloat%25 This text floats to the right%0a%0a%25rframe%25 floats to the right with a frame%0a%0aLorem ipsum dolor sit amet, consectetuer sadipscing elitr%0a(:markupend:)%0a%0a%0a[[#Scope]]%0a!! Scope%0a%0aWikiStyles can also specify a ''scope''; with no scope, the style is applied to any text that follows up to the next WikiStyle specification or the end of the paragraph, whichever comes first. The '''apply=''' attribute and its shortcuts allow to change the scope as follows:%0a%0a||class='tabtable' cellpadding=3 cellspacing=0 style="border:1px dotted blue;" rules=rows %0a||!apply attribute ||!shortcut ||!style applies to... ||%0a||[@%25apply=img ...%25@] ||- ||all images that ''follow'' until another style applied||%0a||[@%25apply=p ...%25@] ||[@%25p ...%25@] ||the current paragraph||%0a||[@%25apply=pre ...%25@] ||- ||the current preformatted text||%0a||[@%25apply=list ...%25@] ||[@%25list ...%25@] ||the current list||%0a||[@%25apply=item ...%25@] ||[@%25item ...%25@] ||the current list item||%0a||[@%25apply=div ...%25@] ||- ||the current div||%0a||[@%25apply=block ...%25@] ||[@%25block ...%25@] ||to the current block, whether it's a paragraph, list, list item, heading, or division.||%0a%0aThus, '''[@%25p color=blue%25@]''' is the same as '''[@%25apply=p color=blue%25@]''', and '''[@%25list ROMAN%25@]''' is the same as '''[@%25apply=list list-style=upper-roman%25@]'''.%0a%0aSome [[#predefined|predefined style shortcuts]] also make use of apply, thus '''[@%25right%25@]''' is a shortcut for '''[@%25text-align=right apply=block%25@]'''.%0a%0aExample: Apply a style to a paragraph:%0a(:markup:)%0a%25p bgcolor=#ffeeee%25 The WikiStyle specification at the beginning of this line applies to the entire paragraph, even if there are %25blue%25 other WikiStyle specifications %25%25 in the middle of the paragraph.%0a(:markupend:)%0a%0a%0a'''Caveat''': An applied WikiStyle will only take effect if it's on the%0aline that starts the thing it's supposed to modify. In other%0awords, a WikiStyle in the third markup line of a paragraph%0acan't change the attributes of the paragraph:%0a%0a(:markup class=horiz:) %0aafter the first line of the paragraph,%0awe try to %25apply=p color=blue%25 change color.%0aThis does't work because the style comes after the first line of the paragraph.%0a(:markupend:)%0a%0a(:markup class=horiz:)%0aHowever, this %25apply=p color=red%25 paragraph%0a''will'' be in red because its block style does%0aoccur in the first line of its text.%0a(:markupend:)%0a%0a(:markup class=horiz:) %0a* Here's a list item%0a* %25list red%25 Oops, too late to affect the list!%0a(:markupend:)%0a%0aIf you want to break a list in two, you need to have a line not part of the list between, that is a line that has any content other than space and newlines, otherwise PmWiki considers the vertical space part of the previous list item. You can have an non-breaking space, or the escaped null character:%0a%0a(:markup class=horiz:)%0a* %25list red%25 first item%0a* second item%0a %0a* %25apply=list bgcolor=lightgreen%25 second list - first item%0a* second list - second item%0a[==]%0a* %25list class=mambo%25 third list - first item%0a* third list - second item%0a(:markupend:)%0a%0a%0a[[#blocks]]%0a!! Larger blocks%0a%0aThe '''[@>>WikiStyle%3c%3c@]''' block can be used to apply a WikiStyle to a large block of items. %0aThe style is applied until the next [@>>%3c%3c@] is encountered.%0a%0a(:markup class=horiz:)%0a>>blue font-style:italic bgcolor=#ffffcc%3c%3c%0aEverything after the above line is styled with blue italic text,%0a%0aThis includes%0a preformatted %25red%25text%25%25%0a* lists%0a-> indented items%0a>>%3c%3c%0a(:markupend:)%0a%0aNote, the '''[@(:div style="..." class="...":)@]''' directive does not work the same way as [@>>WikiStyle%3c%3c@], it can only contain the regular HTML style and class attributes.%0a%0a%0a[[#styleclass]]%0a!! HTML "class" and "style" attributes for tables and divisions%0aWikiStyles are only the commands between [@%25...%25@] percent signs.%0a%0a[[PmWiki/Tables]], [[PmWiki/table directives]] and [[PmWiki.BlockMarkup#div|[=(:div:)=]]] division blocks allow advanced authors to incorporate the HTML/CSS attributes @@ class= @@ and @@ style=@@. %25red%25 Note that these attributes are not WikiStyles%25%25, knowledge of CSS is required to use them.%0a%0a(:markup class=horiz:)%0a(:table style="font-style:italic; color:green; border:1px solid blue; background-color:#ffffcc":)%0a(:cellnr:)%0aEverything after the above line is styled with green italic text,%0a%0aThis includes%0a preformatted text%0a* lists%0a-> indented items%0a(:tableend:)%0a(:markupend:)%0a%0aNote, the '''[@(:div style="..." class="...":)@]''' directive does not work the same way as [@>>style%3c%3c@], as mentioned above, it can only contain the HTML style and class attributes.%0a%0a[[#Shortcuts]]%0a!! Custom style shortcuts%0a%0aThe '''[@define=@]''' attribute can be used to assign a shorthand name to any WikiStyle specification.%0aThis shorthand name can then be reused in later WikiStyle specifications.%0a%0a(:markup class=horiz:)%0a%25define=box block bgcolor=#ddddff border="2px dotted blue"%25%0a%0a%25box%25 [@some sort of text@]%0a%0a%25box font-weight=bold color=green%25 [@some sort of text@]%0a(:markupend:)%0a%0a-%3c '''Tip:''' It's often a good idea to put common style definitions into [[Group Header(s)]] pages so that they can be shared among multiple pages in a group. Or, the [[wiki administrator]] can predefine styles site-wide as a [[local customization(s)]] (see [[Custom WikiStyles]]).%0a%0a-%3c '''Tip:''' Use custom style definitions to associate meanings with text instead of just colors. For example, if warnings are to be displayed as green text, set [@%25define=warn green%25@] and then use [@%25warn%25@] instead of [@%25green%25@] in the document. Then, if you later decide that warnings should be styled differently, it's much easier to change the (one) definition than many occurrences of [@%25green%25@] in the text.%0a%0a-%3c '''Tip:''' Any undefined WikiStyle is automatically treated as a request for a class, thus [@%25pre%25@] is the same as saying [@%25class=pre%25@].%0a%0a!![[#predefined]] Predefined style shortcuts%0a%0aPmWiki defines a number of style shortcuts.%0a%0a* Text colors: %25black%25black%25%25, %25white bgcolor=black%25white%25%25, %25red%25red%25%25, %25yellow%25yellow%25%25, %25blue%25blue%25%25, %25gray%25gray (grey)%25%25, %25silver%25silver%25%25, %25maroon%25maroon%25%25, %25green%25green%25%25, %25navy%25navy%25%25, %25purple%25purple%25%25, %25fuchsia%25fuchsia%25%25, %25olive%25olive%25%25, %25lime%25lime%25%25, %25teal%25teal%25%25, %25aqua%25aqua%25%25, %25orange%25orange%25%25 (shortcut for [@%25color=...%25@])%0a* Justification: [@%25center%25@] and [@%25right%25@]%0a* Images and boxes%0a** Floating left or right: [@%25rfloat%25@] and [@%25lfloat%25@]%0a** Framed items: [@%25frame%25@], [@%25rframe%25@], and [@%25lframe%25@]%0a** Thumbnail sizing: [@%25thumb%25@]%0a* Open link in new window: [@%25newwin%25@] (shortcut for [@%25target=_blank%25@])%0a* Comments: [@%25comment%25@] (shortcut for [@%25display=none%25@]). %25red%25 This is not meant to hide secrets,%25%25 as the hidden content is still printed into the HTML source of the page -- readable to bots (and may appear in web searches) or via "View: Source" and "View: Page Style: None" in the browser.%0a* Ordered lists: [@%25decimal%25@], [@%25roman%25@], [@%25ROMAN%25@], [@%25alpha%25@], [@%25ALPHA%25@], [@%25reversed%25@] (see also Cookbook:OutlineLists)%0a%0a!! Enabling the "Syntax Highlight" code beautifier library %25block id=highlight%25%0a%0aSince version 2.2.119, PmWiki makes it relatively easy to enable syntax highlighting for preformatted text blocks. Note, a block is considered a "code block" for highlighting if it is rendered as a preformatted element. see [[BasicEditing#preformatted]] for 3 ways to do this.%0a%0aTo enable syntax highlighting, add to config.php:%0a%0a(:hlt_cdn_prefix:[=https:=]//cdn.jsdelivr.net/gh/highlightjs/cdn-release@latest/build:)%0a>>hlt php%3c%3c%0a $EnableHighlight = 1;%0a $HTMLHeaderFmt['Highlight'] = '%0a %3clink rel="stylesheet" href="{$:hlt_cdn_prefix}/styles/default.min.css" />%0a %3cscript src="{$:hlt_cdn_prefix}/highlight.min.js">%3c/script>';%0a>>%3c%3c%0a''This loads the [[https://highlightjs.org/ | Highlight.js library]] from a global CDN, but you can copy these 2 files to your @@pub@@ directory and link to them instead.''%0a%0aThen, in a wiki page, you can use the [@%25highlight%25@] or [@%25hlt%25@] wikistyles, and the language to mark your code blocks.%0a%0aEither immediately before the code block:%0a(:markup:)%0a%25hlt php%25[@%0a function SDVA(&$var,$val)%0a { foreach($val as $k=>$v) if (!isset($var[$k])) $var[$k]=$v; }%0a function IsEnabled(&$var,$f=0)%0a { return (isset($var)) ? $var : $f; }%0a@]%0a(:markupend:)%0a%0aOr in a wrapping division block:%0a(:markup:)%0a>>highlight css%3c%3c%0a /* These adjust the size and spacing of heading elements */%0a h1, h2, h3, h4, h5, h6 { margin:1.0em 0 .6em 0; }%0a h1, h2, h3, h6 { font-weight:normal; }%0a h4, h5 { font-weight:bold; }%0a>>%3c%3c%0a(:markupend:)%0a''If you have the feature correctly enabled you will see the syntax highlighting of the above code.''%0a%0a[[#Styles]]%0a!! Enabling Styles%0aStyles not listed above can be enabled by a PmWiki Administrator by modifying the local/config.php file. %0aFor instance to enable the "line-height" style attribute add the following line to the local/config.php file:%0a%0a->[@$WikiStyleCSS[] = 'line-height';@]%0a%0a%0a[[#WikiStyleApply]]%0a!! Defining scope for other HTML elements%0aYou can add additional HTML elements to [@$WikiStyleApply@] to apply WikiStyles to other HTML elements. For example to allow styling on anchor tags:%0a%0a $WikiStyleApply['link'] = 'a';%0a%0a%0a[[#Examples]]%0a!! Examples%0a%0a[[WikiStyle Examples]] contains a number of examples of ways to use WikiStyles in pages.%0a%0a[[#KnownIssues]]%0a!! Known Issues%0a* Percents in style definitions (like: [@%25block width=50%25 %25@]) require the use of "pct" instead of "%25". PmWiki will convert the "pct" into "%25" so that it becomes valid CSS.%0a* If you specify multiple values for an attribute, like @@border="2px solid blue"@@ make sure you place the values in quotes.%0a* Be sure to use lowercase letters for red-green-blue hex colors, [@%25color=#aa3333%25@] will work, [@%25color=#AA3333%25@] may not.%0a[[#SeeAlso]]%0a!!See Also%0a* [[PmWiki/Custom WikiStyles]] {PmWiki/CustomWikiStyles$:Summary}%0a* [[PmWiki:List Styles]] {PmWiki/ListStyles$:Summary}%0a* [[Cookbook:WikiStylesPlus | WikiStylesPlus]] {Cookbook.WikiStylesPlus$:Summary} -time=1592380927 +rev=255 +targets=PmWiki.WikiWord,PmWiki.WikiStyleColors,PmWiki.BlockMarkup,PmWiki.Tables,PmWiki.TableDirectives,PmWiki.GroupHeaders,PmWiki.WikiAdministrator,PmWiki.LocalCustomizations,PmWiki.CustomWikiStyles,Cookbook.OutlineLists,PmWiki.LayoutVariables,PmWiki.WikiStyleExamples,PmWiki.TextFormattingRules,PmWiki.ListStyles,Cookbook.WikiStylesPlus +text=(:Summary: Modifying the style of page contents:)%0a(:Audience: authors (basic, advanced) :)%0a%0aWikiStyles allow authors to modify the color and other styling attributes of the contents of a page. %0aA WikiStyle is written using percent-signs, as in %25red%25[@%25red%25@]%25%25 or %25bgcolor=lightblue%25[@%25bgcolor=lightblue%25@]%25%25.%0a%0a[[#Attributes]]%0a!! WikiStyle attributes%0a%0aThe style attributes recognized within a WikiStyle specification are:%0a(:table:)%0a(:cellnr colspan=2:)%25center%25------------ CSS -------------%25%25%0a(:cell:)%25center%25--HTML--%25%25%0a(:cellnr:)%0a bgcolor%0a background-color%0a border'^[[#al|1]]^'%0a color%0a display%0a float%0a clear%0a overflow%0a font-size%0a font-family%0a font-weight%0a font-style%0a(:cell:)%0a height[[#fn|*]]%0a list-style%0a margin'^[[#al|1]]^'%0a padding'^[[#al|1]]^'%0a text-align%0a text-decoration%0a white-space%0a width[[#fn|*]] %0a(:cell:)%0a accesskey %0a align%0a class%0a hspace %0a id %0a target %0a rel %0a vspace %0a value%0a reversed%0a(:cellnr rowspan=3:)%0a Special: define, apply%0a(:tableend:)%0a%0aThe attributes in the first two columns correspond to the ''[[cascading style sheet -> http://blooberry.com/indexdot/css/propindex/all.htm]]'' (CSS) properties of the same name. The attributes in the last column apply only to specific items:%0a%0a* '''[@class=@]''' and '''[@id=@]''' assign a CSS class or identifier to an HTML element%0a* '''[@target=name@]''' opens links that follow in a browser window called "name"%0a* '''[@rel=name@]''' in a link identifies the relationship of a target page%0a* '''[@accesskey=x@]''' uses 'x' as a shortcut key for the link that follows%0a* '''[@value=9@]''' sets the number of the current ordered list item%0a%0a** [[#fn]] The width and height attributes have asterisks because they are handled specially for %25hlt html%25[@%3cimg .../>@] tags. If used by themselves (i.e., without anything providing an "apply=" parameter to the WikiStyle), then they set the 'width=' and 'height=' attributes of any [@%3cimg ... />@] tags that follow. Otherwise, they set the 'width:' and 'height:' properties of the element being styled.%0a## [[#al]] margin, padding, and border can be suffixed by -left, -right, -top, and -bottom%0a%0a!! WikiStyles versus CSS styles%0aWikiStyles, as written in the wiki page, are not exactly CSS styles or CSS classes. WikiStyles allow authors to use both pre-defined by the administrator CSS classes, and to define new combinations of styles, without any need to edit/update local CSS files on the server.%0a%0aNote that PmWiki allows advanced authors to use of @@ class= @@ and @@ style= @@ in tables and division blocks, but these are raw HTML attributes, and not WikiStyles; knowledge of CSS is required to use them.%0a%0a!! Text color and font%0aThe most basic use of WikiStyles is to change text attributes such as color, background color, and font. %0aPmWiki defines several WikiStyles for changing the text color to %25pmhlt%25@@[=%25black%25, %25white%25, %25red%25, %25yellow%25, %25blue%25, %25gray%25 (%25grey%25), %25silver%25, %25maroon%25, %25green%25, %25navy%25, %25fuchsia%25, %25olive%25, %25lime%25, %25teal%25, %25aqua%25, %25orange%25 and %25purple%25=]@@.%0a%0a(:markup class=horiz:)%0aThe basket contains %25red%25 apples, %25blue%25 blueberries, %25purple%25 eggplant, %25green%25 limes, %25%25 and more.%0a(:markupend:)%0a%0aFor colors other than the predefined colors, use the %25pmhlt%25[@%25color=...%25@] WikiStyle. (Note: RGB colors (#rrggbb) should always be specified with lowercase letters to avoid [[WikiWord]] conflicts.)%0a%0a(:markup class=horiz:)%0aI'd like to have some %25color=#ff7f00%25 tangerines%25%25, too!%0a(:markupend:)%0a%0aTo change the background color, use %25pmhlt%25[@%25bgcolor=...%25@] as a WikiStyle:%0a%0a(:markup class=horiz:)%0aThis sentence contains %25bgcolor=green yellow%25 yellow text on a green background.%0a(:markupend:)%0a%0aSee [[(PmWiki:)WikiStyle Colors]] for more color help.%0a%0a!! Text justification%0aWikiStyles are used to control the text justification%0a%0a(:markup class=horiz:)%0a%25center%25 This text is centered. %0a%0a%25right%25 Right justified.%0a(:markupend:)%0a%0aand to create floating text:%0a%0a(:markup class=horiz:)%0a%25rfloat%25 This text floats to the right%0a%0a%25rframe%25 floats to the right with a frame%0a%0aLorem ipsum dolor sit amet, consectetuer sadipscing elitr%0a(:markupend:)%0a%0a%0a[[#Scope]]%0a!! Scope%0a%0aWikiStyles can also specify a ''scope''; with no scope, the style is applied to any text that follows up to the next WikiStyle specification or the end of the paragraph, whichever comes first. The '''apply=''' attribute and its shortcuts allow to change the scope as follows:%0a%0a||class='tabtable' cellpadding=3 cellspacing=0 style="border:1px dotted blue;" rules=rows %0a||!apply attribute ||!shortcut ||!style applies to... ||%0a||%25pmhlt%25[@%25apply=img ...%25@] ||- ||all images that ''follow'' until another style applied||%0a||%25pmhlt%25[@%25apply=p ...%25@] ||%25pmhlt%25[@%25p ...%25@] ||the current paragraph||%0a||%25pmhlt%25[@%25apply=pre ...%25@] ||- ||the current preformatted text||%0a||%25pmhlt%25[@%25apply=list ...%25@] ||%25pmhlt%25[@%25list ...%25@] ||the current list||%0a||%25pmhlt%25[@%25apply=item ...%25@] ||%25pmhlt%25[@%25item ...%25@] ||the current list item||%0a||%25pmhlt%25[@%25apply=div ...%25@] ||- ||the current div||%0a||%25pmhlt%25[@%25apply=block ...%25@] ||%25pmhlt%25[@%25block ...%25@] ||to the current block, whether it's a paragraph, list, list item, heading, or division.||%0a%0aThus, %25pmhlt%25[@%25p color=blue%25@] is the same as [@%25apply=p color=blue%25@], and [@%25list ROMAN%25@] is the same as [@%25apply=list list-style=upper-roman%25@].%0a%0aSome [[#predefined|predefined style shortcuts]] also make use of apply, thus %25pmhlt%25[@%25right%25@] is a shortcut for [@%25text-align=right apply=block%25@].%0a%0aExample: Apply a style to a paragraph:%0a(:markup:)%0a%25p bgcolor=#ffeeee%25 The WikiStyle specification at the beginning of this line applies to the entire paragraph, even if there are %25blue%25 other WikiStyle specifications %25%25 in the middle of the paragraph.%0a(:markupend:)%0a%0a%0a'''Caveat''': An applied WikiStyle will only take effect if it's on the%0aline that starts the thing it's supposed to modify. In other%0awords, a WikiStyle in the third markup line of a paragraph%0acan't change the attributes of the paragraph:%0a%0a(:markup class=horiz:) %0aafter the first line of the paragraph,%0awe try to %25apply=p color=blue%25 change color.%0aThis doesn't work because the style comes after the first line of the paragraph.%0a(:markupend:)%0a%0a(:markup class=horiz:)%0aHowever, this %25apply=p color=red%25 paragraph%0a''will'' be in red because its block style does%0aoccur in the first line of its text.%0a(:markupend:)%0a%0a(:markup class=horiz:) %0a* Here's a list item%0a* %25list red%25 Oops, too late to affect the list!%0a(:markupend:)%0a%0aIf you want to break a list in two, you need to have a line not part of the list between, that is a line that has any content other than space and newlines, otherwise PmWiki considers the vertical space part of the previous list item. You can have an non-breaking space, or the escaped null character:%0a%0a(:markup class=horiz:)%0a* %25list red%25 first item%0a* second item%0a %0a* %25apply=list bgcolor=lightgreen%25 second list - first item%0a* second list - second item%0a[==]%0a* %25list class=mambo%25 third list - first item%0a* third list - second item%0a(:markupend:)%0a%0a%0a[[#blocks]]%0a!! Larger blocks%0a%0aThe %25pmhlt%25[@>>WikiStyle%3c%3c@] block can be used to apply a WikiStyle to a large block of items. %0aThe style is applied until the next %25pmhlt%25[@>>%3c%3c@] is encountered.%0a%0a(:markup class=horiz:)%0a>>blue font-style:italic bgcolor=#ffffcc%3c%3c%0aEverything after the above line is styled with blue italic text,%0a%0aThis includes%0a preformatted %25red%25text%25%25%0a* lists%0a-> indented items%0a>>%3c%3c%0a(:markupend:)%0a%0aNote, the %25pmhlt%25[@(:div style="..." class="...":)@] directive does not work the same way as [@>>WikiStyle%3c%3c@], it can only contain the regular HTML style and class attributes.%0a%0a%0a[[#styleclass]]%0a!! HTML "class" and "style" attributes for tables and divisions%0aWikiStyles are only the commands between %25pmhlt%25[@%25...%25@] percent signs.%0a%0a[[PmWiki/Tables]], [[PmWiki/table directives]] and [[PmWiki.BlockMarkup#div|%25pmhlt%25[@(:div:)@]]] division blocks allow advanced authors to incorporate the HTML/CSS attributes @@ class= @@ and @@ style=@@. %25red%25 Note that these attributes are not WikiStyles%25%25, knowledge of CSS is required to use them.%0a%0a(:markup class=horiz:)%0a(:table style="font-style:italic; color:green; border:1px solid blue; background-color:#ffffcc":)%0a(:cellnr:)%0aEverything after the above line is styled with green italic text,%0a%0aThis includes%0a preformatted text%0a* lists%0a-> indented items%0a(:tableend:)%0a(:markupend:)%0a%0aNote, the %25pmhlt%25[@(:div style="..." class="...":)@] directive does not work the same way as [@>>style%3c%3c@], as mentioned above, it can only contain the HTML style and class attributes.%0a%0a[[#Shortcuts]]%0a!! Custom style shortcuts%0a%0aThe '''[@define=@]''' attribute can be used to assign a shorthand name to any WikiStyle specification.%0aThis shorthand name can then be reused in later WikiStyle specifications.%0a%0a(:markup class=horiz:)%0a%25define=box block bgcolor=#ddddff border="2px dotted blue"%25%0a%0a%25box%25 [@some sort of text@]%0a%0a%25box font-weight=bold color=green%25 [@some sort of text@]%0a(:markupend:)%0a%0a-%3c '''Tip:''' It's often a good idea to put common style definitions into [[Group Header(s)]] pages so that they can be shared among multiple pages in a group. Or, the [[wiki administrator]] can predefine styles site-wide as a [[local customization(s)]] (see [[Custom WikiStyles]]).%0a%0a-%3c '''Tip:''' Use custom style definitions to associate meanings with text instead of just colors. For example, if warnings are to be displayed as green text, set %25pmhlt%25[@%25define=warn green%25@] and then use [@%25warn%25@] instead of [@%25green%25@] in the document. Then, if you later decide that warnings should be styled differently, it's much easier to change the (one) definition than many occurrences of [@%25green%25@] in the text.%0a%0a-%3c '''Tip:''' Any undefined WikiStyle is automatically treated as a request for a class, thus %25pmhlt%25[@%25pre%25@] is the same as saying [@%25class=pre%25@].%0a%0a!![[#predefined]] Predefined style shortcuts%0a%0aPmWiki defines a number of style shortcuts.%0a%0a* Text colors: %25black%25black%25%25, %25white bgcolor=black%25white%25%25, %25red%25red%25%25, %25yellow%25yellow%25%25, %25blue%25blue%25%25, %25gray%25gray (grey)%25%25, %25silver%25silver%25%25, %25maroon%25maroon%25%25, %25green%25green%25%25, %25navy%25navy%25%25, %25purple%25purple%25%25, %25fuchsia%25fuchsia%25%25, %25olive%25olive%25%25, %25lime%25lime%25%25, %25teal%25teal%25%25, %25aqua%25aqua%25%25, %25orange%25orange%25%25 (shortcut for %25pmhlt%25[@%25color=...%25@])%0a* Justification: %25pmhlt%25[@%25center%25@] and [@%25right%25@]%0a* Images and boxes%0a** Floating left or right: %25pmhlt%25[@%25rfloat%25@] and [@%25lfloat%25@]%0a** Framed items: %25pmhlt%25[@%25frame%25@], [@%25rframe%25@], and [@%25lframe%25@]%0a** Thumbnail sizing: %25pmhlt%25[@%25thumb%25@]%0a* Open link in new window: %25pmhlt%25[@%25newwin%25@] (shortcut for [@%25target=_blank%25@])%0a* Comments: %25pmhlt%25[@%25comment%25@] (shortcut for [@%25display=none%25@]). %25red%25 This is not meant to hide secrets,%25%25 as the hidden content is still printed into the HTML source of the page -- readable to bots (and may appear in web searches) or via "View: Source" and "View: Page Style: None" in the browser.%0a* Ordered lists: %25pmhlt%25[@%25decimal%25@], [@%25roman%25@], [@%25ROMAN%25@], [@%25alpha%25@], [@%25ALPHA%25@], [@%25reversed%25@] (see also Cookbook:OutlineLists)%0a%0a!! Enabling the "Syntax Highlight" code beautifier library %25block id=highlight%25%0a%0a''This section is about highlighting code in various programming languages using an external library. Instead, or in addition, to enable highlighting of the PmWiki's own markup language syntax in the documentation and/or the edit form, see $EnablePmSyntax.''%0a%0aSince version 2.2.119, PmWiki makes it relatively easy to enable syntax highlighting for preformatted text blocks, wrapped in %25pmhlt%25@@[=[@escaped@]=]@@ markup blocks.''%0a%0aTo enable syntax highlighting, add to @@config.php@@:%0a%0a%25hlt php%25 [@%0a $EnableHighlight = 1;%0a $HTMLHeaderFmt['Highlight'] = '%0a %3clink rel="stylesheet" href="https://cdn.jsdelivr.net/gh/highlightjs/cdn-release@latest/build/styles/default.min.css" />%0a %3cscript src="https://cdn.jsdelivr.net/gh/highlightjs/cdn-release@latest/build/highlight.min.js">%3c/script>';%0a@]%0a''This loads the [[https://highlightjs.org/ | Highlight.js library]] from a global CDN, but you can copy these 2 files to your @@pub@@ directory and link to them instead.''%0a%0aThen, in a wiki page, you can use the %25pmhlt%25[@%25highlight%25@] or [@%25hlt%25@] wikistyles, and the language to mark your code blocks.%0a%0aEither immediately before the code block:%0a(:markup:)%0a%25hlt php%25[@%0a function SDVA(&$var,$val)%0a { foreach($val as $k=>$v) if (!isset($var[$k])) $var[$k]=$v; }%0a function IsEnabled(&$var,$f=0)%0a { return (isset($var)) ? $var : $f; }%0a@]%0a(:markupend:)%0a%0aOr in a wrapping division block:%0a(:markup:)%0a>>highlight css%3c%3c%0a[@%0a /* These adjust the size and spacing of heading elements */%0a h1, h2, h3, h4, h5, h6 { margin:1.0em 0 .6em 0; }%0a h1, h2, h3, h6 { font-weight:normal; }%0a h4, h5 { font-weight:bold; }%0a@]%0a>>%3c%3c%0a(:markupend:)%0a''If you have the feature correctly enabled you will see the syntax highlighting of the above code.''%0a%0a[[#Styles]]%0a!! Enabling Styles%0aStyles not listed above can be enabled by a PmWiki Administrator by modifying the @@local/config.php@@ file. %0aFor instance to enable the "line-height" style attribute add the following line to the @@local/config.php@@ file:%0a%0a->%25hlt php%25[@$WikiStyleCSS[] = 'line-height';@]%0a%0a%0a[[#WikiStyleApply]]%0a!! Defining scope for other HTML elements%0aYou can add additional HTML elements to %25pmhlt%25[@$WikiStyleApply@] to apply WikiStyles to other HTML elements. For example to allow styling on anchor tags:%0a%0a->%25hlt php%25[@$WikiStyleApply['link'] = 'a';@]%0a%0a%0a[[#Examples]]%0a!! Examples%0a%0a[[WikiStyle Examples]] contains a number of examples of ways to use WikiStyles in pages.%0a%0a[[#KnownIssues]]%0a!! Known Issues%0a* Percents in style definitions (like: %25pmhlt%25[@%25block width=50%25 %25@]) require the use of "pct" instead of "%25". PmWiki will convert the "pct" into "%25" so that it becomes valid CSS.%0a* If you specify multiple values for an attribute, like @@border="2px solid blue"@@ make sure you place the values in quotes.%0a* Be sure to use lowercase letters for red-green-blue hex colors, %25pmhlt%25[@%25color=#aa3333%25@] will work, [@%25color=#AA3333%25@] may not.%0a[[#SeeAlso]]%0a!!See Also%0a* [[PmWiki/Custom WikiStyles]] {PmWiki/CustomWikiStyles$:Summary}%0a* [[PmWiki:List Styles]] {PmWiki/ListStyles$:Summary}%0a* [[Cookbook:WikiStylesPlus | WikiStylesPlus]] {Cookbook.WikiStylesPlus$:Summary} +time=1669285358 blob - b7363f84abc6c2c9bc31ac815a1e740c790ad1a5 blob + 4dc73050df88c32ab78a9605129084d2f8bae209 --- wikilib.d/PmWiki.WikiTrails +++ wikilib.d/PmWiki.WikiTrails @@ -1,9 +1,9 @@ -version=pmwiki-2.2.118 ordered=1 urlencoded=1 -author=Petko +version=pmwiki-2.3.4 ordered=1 urlencoded=1 +author=MFWolff charset=UTF-8 -csum=rm manual TOC, add !!FAQ +csum=path trail (+89) name=PmWiki.WikiTrails -rev=168 +rev=172 targets=PmWiki.PageLists,PmWiki.GroupHeader,PmWiki.Links,PmWiki.ListStyles,Cookbook.CSSInWikiPages,PmWiki.Installation,PmWiki.LocalCustomizations,PmWiki.PmWiki,PmWiki.PmWikiPhilosophy,PmWiki.WikiStyles,PmWiki.Uploads,PmWiki.InterMap,Cookbook.Cookbook,PmWiki.TextFormattingRules,PmWiki.DesignNotes,PmWiki.Security,PmWiki.Troubleshooting,PmWiki.GroupHeaders,PmWiki.ConditionalMarkup,PmWiki.FullName,PmWiki.WebFeeds -text=(:Summary: Trails from lists items from a single page:)%0a(:Audience: authors (basic) :)%0aThe WikiTrails feature allows wiki authors to create "trails" through sequences of pages in the wiki. You simply specify pages and their order on a "trail index", and then place the navigation markup on the pages that you will be navigating. %0a%0a(Don't confuse the [[PmWiki/PageLists|pagelist]] directive with WikiTrails - they are different animals as explained in the [[#faq|Q and A]] below.)%0a%0a[[#types]]%0a!! Trail types%0aPmWiki defines 2 trail markups, specifying a trail index link:%0a%0a* '''[@%3c%3c|[[Trail Index Page]]|>>@]''' displays as "[=%3c%3c PreviousPage | Trail Index Page | NextPage >>=]".%0a%0a* '''[@%3c|[[Trail Index Page]]|>@]''' displays as "[=%3c PreviousPage | Trail Index Page | NextPage >=]", except the appropriate arrow is omitted at the beginning and end of the trail.%0a%0aand for a [[#pathtrail| trail path]]:%0a* '''[@^|[[TrailIndexPage]]|^@]'''%0a%0aMarkup is most often added to a [[group header]] or group footer.%0a%0a[[#linksyntax]]%0a!! Trail index page link markup%0aThe trail index page link has the same markup as a standard [[link(s)]], %0athis means for example you can specify:%0a* [@%3c|[[TrailIndexPage | +]]|>@]%0a* [@%3c%3c|[[TrailIndexPage | A description]]|>>@]%0a%0aTrail index page links can be restricted by [[links#anchors|anchors]] (links to a specific location within a page),%0athis means you can have more than one trail on a page, or start a trail from a specific location in a page.%0a* [@%3c|[[Trail Index Page(#trailstart#trailend)]]|>@]%0a%0a[[#creating]]%0a!! Creating a trail%0a%0aBefore you can use a trail through a set of pages, you have to create a "trail index" on a separate page, which we will call the "trail index page". %0aOn that trail index page, you simply create a numbered, bulleted, or definition [[PmWiki:ListStyles|list]] of links. (So every numbered or bulleted list of links implicitly creates a trail.) %0a%0aIt is important that each page name ([[Links|link]]) be the first item following each bullet; any text or formatting in front of the page name link will exclude it from the trail.\\%0aIf you want to format your trail (list), you can [[Cookbook:CSSInWikiPages|include a CSS]].%0a%0aAn example trail index page might contain the list:%0a[[#trailstart]]%0a* [[Installation]] how to install%0a* [[The customisation page->LocalCustomizations]]%0a* [[PmWiki]] some other text [[PmWiki Philosophy]] [-(The latter won't be in the trail because it is preceded by text)-]%0a* Yet some other text. [[PmWiki.WikiStyles]] [-(This won't be in the trail because it follows text)-]%0a* %25center%25[[PmWiki/Uploads]] [-(This won't be in the trail because it is preceded by the [=%25center%25=] style.)-]%0a%0a* Some text [-(This won't be in the trail because it is not a link)-]%0a* [[PmWiki/PageLists]] {PmWiki/PageLists$:Summary}%0a* [[http://pmwiki.org]] [-(This won't be in the trail because it is not a page link)-]%0a** [[PmWiki:InterMap]] [-(This won't be in the trail because it is an [[InterMap]] link)-]%0a* [[Cookbook:Cookbook]] [-(This won't be in the trail because it is an [[InterMap]] link)-] %0a: [[PmWiki philosophy]] : [[Design notes]] [-(The first link in this definition list will, and the second link won't, be in the trail defined by ([[TextFormattingRules#DefinitionLists | definition list]]))-]%0a* [[#security]][[Security]] [-(This won't be in the trail because its preceded by a (hidden) [[Links#anchors | anchor]])-]%0a* %25newwin%25[[Links]] [-(This won't be in the trail because its preceded by a (hidden) [=%25newwin%25=] style)-]%0a* ''[[PmWiki/Troubleshooting]]'' [-(This won't be in the trail because its preceded by (hidden) ''italic'' style markup)-]%0a[[#trailend]]%0a%0aThe list above creates the following "wikitrail", displayed using a [[PageLists|pagelist]]:%0a(:markup:)%0a(:pagelist trail={$FullName}#trailstart#trailend fmt={$FullName}#traillist:)%0a(:markupend:)%0a%0a[[#observations]]%0a!!! Observations%0a%0a# In general, indentation levels in the page list don't matter -- trails are a linear sequence of pages.%0a# A page is part of the trail only if the page link immediately follows the list markup.%0a# The list itself can be [[#linksyntax|delineated]] by the use of [[#list#anchors|anchors]], allowing for multiple lists on a page, or for some list items to be excluded.%0a%0a[[#using]]%0a!! Using the trail%0a%0aWhat makes a trail "work" is adding ''trail markup'' on the pages in the trail (i.e. the pages that are listed in the bullet/numbered list on the trail index page).%0a%0aTo build a trail, add ''trail markup'' like [@%3c%3c|[[TrailIndexPage]]|>>@] to a page, where `TrailIndexPage is the page, described above, containing the bulleted list of pages in the trail. PmWiki will display the trail markup with links to any previous and next pages in the trail. %0a%0aThe trail markup can be placed anywhere in a group header or footer, or on a page. A page can contain multiple trail markups. If you are adding a trail to every page in a group, consider setting the trail markup in the [[Group Headers | Group Header]] or Group Footer pages instead of on every individual page in your group.%0a%0a[[#pathtrail]]%0a!!! Path trail[[#path-trail]]%0a%0a[@^|[[TrailIndexPage]]|^@] treats the list levels as a hierarchy and displays the "path" to reach the current page (i.e., a "breadcrumb" trail). In the example trail above, the markup [@^|TrailIndexPage|^@] on [@TrailPage4@] would display as "[=TrailIndexPage | TrailPage2 | TrailPage4=]".%0aand for a [[#pathtrail| trail path]]%0a%0aWiki administrators can change the trail separator of the "path" trail ( [@^|[[TrailIndexPage]]|^@] ) from the default | by setting the variable @@$TrailPathSep@@ in the ''config.php'' file. For instance @@$TrailPathSep = ' > ';@@ will output "[=TrailIndexPage > TrailPage2 > TrailPage4=]".%0a%0a[[#circular-trails]]%0a!! Circular trails%0a%0aTypically, a trail is a linear list with a first and a last page. However, the trail can be made "circular" by repeating the first page as the last item in the trail index:%0a%0a->[@%0a * [[TrailPage1]]%0a * [[TrailPage2]]%0a ...%0a * [[TrailPageN]]%0a * [[TrailPage1]]%0a@]%0a%0aIf the trail index page is intended to be read by others, the last item can be made invisible inside an [@(:if false:)@] block:%0a%0a->[@%0a * [[TrailPage1]]%0a * [[TrailPage2]]%0a ...%0a * [[TrailPageN]]%0a (:if false:)%0a * [[TrailPage1]]%0a (:ifend:)%0a@]%0a%0a[[#crossgroup]]%0a!! Cross Group Trails%0aBefore version 2.2.1, if your trail contains pages in different groups, it should use full [=[[Group.Name]]=] links instead of just [=[[Name]]=].%0a%0a!! Other notes%0a* There is no space between @@[=%3c|=]@@ and @@[=[[link]]=]@@ and @@[=|>=]@@; same for the other trail markups.%0a* Note that non-existing pages will appear in the WikiTrail as links.%0a* [[Conditional markup]] supports the [[ConditionalMarkup#ontrail | ontrail]] query.%0a* [[Page lists]] provides the [[PageLists#pagelisttrail | trail=]] parameter.%0a%0a[[#trailstyle]]%0a!!! Trail style%0aPmWiki encapsulates the trail with a @@''wikitrail''@@ css class. %0aThis allows the wiki trail to be [[LocalCustomizations | customised]] by defining CSS for the ''wikitrail'' in the @@''local.css''@@ file.%0a%0a%0a[[#trailpagelists]]%0a!!! Trail in [[page lists]]%0aTrails from a single page can only be displayed using the pagelist [[PmWiki/PageLists#pagelisttrail|trail]] parameter. For example%0a(:markup class="horiz":)%0a(:pagelist trail=PmWiki/WikiTrails#trailstart fmt=PmWiki.WikiTrails#traillist order=random,$Name count=3:)%0a(:markupend:)%0a%0a!!!A simple example of a WikiTrail%0a%0a1) On the TrailIndexPage:%0a%0a[@%0a* [[MyTrailPage1]]%0a* [[MyTrailPage2]]%0a* [[MyTrailPage3]]%0a@]%0a%0a2) On the pages MyTrailPage1, 2, and 3:%0a%0a[@%0a%3c%3c|[[TrailIndexPage]]|>>%0a@]%0a%0a>>comment%3c%3c%0a[[#traillist]]%0a%25font-size:small green%25> [[{=$FullName}|{=$Groupspaced}.{=$Namespaced}]] %3c%0a[[#traillistend]]%0a>>%3c%3c%0a%0a!! FAQ%0a[[#faq]]%0a>>faq%3c%3c%0aQ: What's the difference between a [[[[PmWiki/PageLists|PageList]] and a WikiTrail?%0aA: The pagelist directive dynamically generates a list of pages. There are many ways to generate the list, including using a WikiTrail as the source. The pagelist directive then displays the pages that match the criteria using an optional template - for example displaying each page name on a separate line as a link or including the entire content. The pagelist directive currently does not have built-in navigation markup that you can put on the pages in the list. By contrast, WikiTrails are simply specified via links on an "index" page and you ''can'' put previous-next navigation markup on each page. The two serve very different purposes. WikiTrails are useful for specifying the pages in [[PmWiki/WebFeeds|web feeds]], for creating a "tour" through a predefined set of pages, and many other things. -time=1567165912 +text=(:Summary: Trails from lists items from a single page:)%0a(:Audience: authors (basic) :)%0aThe WikiTrails feature allows wiki authors to create "trails" through sequences of pages in the wiki. You simply specify pages and their order on a "trail index", and then place the navigation markup on the pages that you will be navigating. %0a%0a(Don't confuse the [[PmWiki/PageLists|pagelist]] directive with WikiTrails - they are different animals as explained in the [[#faq|Q and A]] below.)%0a%0a[[#types]]%0a!! Trail types%0aPmWiki defines 2 trail markups, specifying a trail index link:%0a%0a* %25pmhlt%25[@%3c%3c|[[Trail Index Page]]|>>@] displays as "[=%3c%3c PreviousPage | Trail Index Page | NextPage >>=]".%0a%0a* %25pmhlt%25[@%3c|[[Trail Index Page]]|>@] displays as "[=%3c PreviousPage | Trail Index Page | NextPage >=]", except the appropriate arrow is omitted at the beginning and end of the trail.%0a%0aand for a [[#pathtrail| trail path]]:%0a* %25pmhlt%25[@^|[[TrailIndexPage]]|^@]%0a%0aMarkup is most often added to a [[group header]] or group footer.%0a%0a[[#linksyntax]]%0a!! Trail index page link markup%0aThe trail index page link has the same markup as a standard [[link(s)]], %0athis means for example you can specify:%0a* %25pmhlt%25[@%3c|[[TrailIndexPage | +]]|>@]%0a* %25pmhlt%25[@%3c%3c|[[TrailIndexPage | A description]]|>>@]%0a%0aTrail index page links can be restricted by [[links#anchors|anchors]] (links to a specific location within a page),%0athis means you can have more than one trail on a page, or start a trail from a specific location in a page.%0a* %25pmhlt%25[@%3c|[[Trail Index Page(#trailstart#trailend)]]|>@]%0a%0a[[#creating]]%0a!! Creating a trail index%0a%0aBefore you can use a trail through a set of pages, you have to create a "trail index" on a separate page, which we will call the "trail index page". %0aOn that trail index page, you simply create a numbered, bulleted, or definition [[PmWiki:ListStyles|list]] of links. (So every numbered or bulleted list of links implicitly creates a trail.) %0a%0aIt is important that each page name ([[Links|link]]) be the first item following each bullet; any text or formatting in front of the page name link will exclude it from the trail.\\%0aIf you want to style your trail index, you can [[Cookbook:CSSInWikiPages|include a CSS]].%0a%0aAn example trail index page might be the following list:%0a[[#trailstart]]%0a* [[Installation]] how to install%0a* [[The customisation page->LocalCustomizations]]%0a* [[PmWiki]] some other text [[PmWiki Philosophy]] [-(The latter won't be in the trail because it is preceded by text)-]%0a* Yet some other text. [[PmWiki.WikiStyles]] [-(This won't be in the trail because it follows text)-]%0a* %25center%25[[PmWiki/Uploads]] [-(This won't be in the trail because it is preceded by the [=%25center%25=] style.)-]%0a%0a* Some text [-(This won't be in the trail because it is not a link)-]%0a* [[PmWiki/PageLists]] {PmWiki/PageLists$:Summary}%0a* [[https://pmwiki.org]] [-(This won't be in the trail because it is not a page link)-]%0a** [[PmWiki:InterMap]] [-(This won't be in the trail because it is an [[InterMap]] link)-]%0a* [[Cookbook:Cookbook]] [-(This won't be in the trail because it is an [[InterMap]] link)-] %0a: [[PmWiki philosophy]] : [[Design notes]] [-(The first link in this definition list will, and the second link won't, be in the trail defined by ([[TextFormattingRules#DefinitionLists | definition list]]))-]%0a* [[#security]][[Security]] [-(This won't be in the trail because its preceded by a (hidden) [[Links#anchors | anchor]])-]%0a* %25newwin%25[[Links]] [-(This won't be in the trail because its preceded by a (hidden) [=%25newwin%25=] style)-]%0a* ''[[PmWiki/Troubleshooting]]'' [-(This won't be in the trail because its preceded by (hidden) ''italic'' style markup)-]%0a[[#trailend]]%0a%0aThe list above creates the following "wikitrail", displayed using a [[PageLists|pagelist]]:%0a(:markup:)%0a(:pagelist trail={$FullName}#trailstart#trailend fmt={$FullName}#traillist:)%0a(:markupend:)%0a%0a[[#observations]]%0a!!! Observations%0a%0a# In general, indentation levels in the page list don't matter -- trails are a linear sequence of pages.%0a# A page is part of the trail only if the page link immediately follows the list markup.%0a# The list itself can be [[#linksyntax|delineated]] by the use of [[#list#anchors|anchors]], allowing for multiple lists on a page, or for some list items to be excluded.%0a%0a[[#using]]%0a!! Using the trail%0a%0aWhat makes a trail "work" is adding ''trail markup'' on the pages in the trail (i.e. the pages that are listed in the bullet/numbered list on the trail index page).%0a%0aTo build a trail, add ''trail markup'' like %25pmhlt%25[@%3c%3c|[[TrailIndexPage]]|>>@] to a page, where `TrailIndexPage is the page, described above, containing the bulleted list of pages in the trail. PmWiki will display the trail markup with links to any previous and next pages in the trail. %0a%0aThe trail markup can be placed anywhere in a group header or footer, or on a page. A page can contain multiple trail markups. If you are adding a trail to every page in a group, consider setting the trail markup in the [[Group Headers | Group Header]] or Group Footer pages instead of on every individual page in your group.%0a%0a[[#pathtrail]]%0a!!! Path trail[[#path-trail]]%0a%0a%25pmhlt%25[@^|[[TrailIndexPage]]|^@] treats the list levels as a hierarchy and displays the "path" to reach the current page (i.e., a "breadcrumb" trail). %0a%0a* %25color=#0066CC%25TrailPage1 %0a* %25color=#0066CC%25TrailPage2 %0a** %25color=#0066CC%25TrailPage3%0a** %25color=#0066CC%25TrailPage4%0a%0aIn the example trail above, the markup %25pmhlt%25[@^|TrailIndexPage|^@] on [@TrailPage4@] would display "[=TrailIndexPage | TrailPage2 | TrailPage4=]".%0a%0aWiki administrators can change the trail separator of the "path" trail ( %25pmhlt%25[@^|[[TrailIndexPage]]|^@] ) from the default | by setting the variable @@$TrailPathSep@@ in the ''config.php'' file. For instance @@$TrailPathSep = ' > ';@@ will output "[=TrailIndexPage > TrailPage2 > TrailPage4=]".%0a%0a[[#circular-trails]]%0a!! Circular trails%0a%0aTypically, a trail is a linear list with a first and a last page. However, the trail can be made "circular" by repeating the first page as the last item in the trail index:%0a%0a->%25pmhlt%25[@%0a * [[TrailPage1]]%0a * [[TrailPage2]]%0a ...%0a * [[TrailPageN]]%0a * [[TrailPage1]]%0a@]%0a%0aIf the trail index page is intended to be read by others, the last item can be made invisible inside an [@(:if false:)@] block:%0a%0a->%25pmhlt%25[@%0a * [[TrailPage1]]%0a * [[TrailPage2]]%0a ...%0a * [[TrailPageN]]%0a (:if false:)%0a * [[TrailPage1]]%0a (:ifend:)%0a@]%0a%0a[[#crossgroup]]%0a!! Cross Group Trails%0aBefore version 2.2.1, if your trail contains pages in different groups, it should use full [=[[Group.Name]]=] links instead of just [=[[Name]]=].%0a%0a!! Other notes%0a* There is no space between @@[=%3c|=]@@ and @@[=[[link]]=]@@ and @@[=|>=]@@; same for the other trail markups.%0a* Note that non-existing pages will appear in the WikiTrail as links.%0a* [[Conditional markup]] supports the [[ConditionalMarkup#ontrail | ontrail]] query.%0a* [[Page lists]] provides the [[PageLists#pagelisttrail | trail=]] parameter.%0a%0a[[#trailstyle]]%0a!!! Trail style%0aPmWiki encapsulates the trail with a @@''wikitrail''@@ css class. %0aThis allows the wiki trail to be [[LocalCustomizations | customised]] by defining CSS for the ''wikitrail'' in the @@''local.css''@@ file.%0a%0a%0a[[#trailpagelists]]%0a!!! Trail in [[page lists]]%0aTrails from a single page can only be displayed using the pagelist [[PmWiki/PageLists#pagelisttrail|trail]] parameter. For example%0a(:markup:)%0a(:pagelist trail=PmWiki/WikiTrails#trailstart fmt=PmWiki.WikiTrails#traillist order=random,$Name count=3:)%0a(:markupend:)%0a%0a!!!A simple example of a WikiTrail%0a%0a1) On the TrailIndexPage:%0a%0a%25pmhlt%25[@%0a* [[MyTrailPage1]]%0a* [[MyTrailPage2]]%0a* [[MyTrailPage3]]%0a@]%0a%0a2) On the pages MyTrailPage1, 2, and 3:%0a%0a%25pmhlt%25[@%0a%3c%3c|[[TrailIndexPage]]|>>%0a@]%0a%0a>>comment%3c%3c%0a[[#traillist]]%0a%25font-size:small green%25> [[{=$FullName}|{=$Groupspaced}.{=$Namespaced}]] %3c%0a[[#traillistend]]%0a>>%3c%3c%0a%0a!! FAQ%0a[[#faq]]%0a>>faq%3c%3c%0aQ: What's the difference between a [[PmWiki/PageLists|PageList]] and a WikiTrail?%0aA: The pagelist directive dynamically generates a list of pages. There are many ways to generate the list, including using a WikiTrail as the source. \\%0aThe pagelist directive then displays the pages that match the criteria using an optional template - for example displaying each page name on a separate line as a link or including the entire content. \\%0aThe pagelist directive currently does not have built-in navigation markup that you can put on the pages in the list. \\%0aBy contrast, WikiTrails are simply specified via links on an "index" page and you ''can'' put previous-next navigation markup on each page. The two serve very different purposes. WikiTrails are useful for specifying the pages in [[PmWiki/WebFeeds|web feeds]], for creating a "tour" through a predefined set of pages, and many other things. +time=1652170980 blob - fdc73d79045966b974402caecc9da1b03b64b4bb blob + a92c4e4984af601672cad1eb5827ae5998d53ca6 --- wikilib.d/Site.AuthForm +++ wikilib.d/Site.AuthForm @@ -1,9 +1,9 @@ -version=pmwiki-2.2.78 ordered=1 urlencoded=1 +version=pmwiki-2.3.13 ordered=1 urlencoded=1 author=Petko charset=UTF-8 -csum=capital first letter +csum=autofocus=autofocus (+40) name=Site.AuthForm -rev=19 +rev=20 targets= -text=(:Summary:Form displayed when requesting a [[PmWiki/password(s)]] or username/password:)%0a'''By logging in, you agree to release all contributions under [[license/ircnow|the IRCNow license]]. $[Password required]'''%0a(:messages:)%0a(:if enabled InvalidLogin:)* $[Name/password not recognized]%0a(:ifend:)%0a(:input auth_form:)%0a(:if enabled EnableAuthUser:)$[Name]: (:input text name=authid:)\\%0a(:if:)$[Password]: (:input password name=authpw:)%0a(:input submit value='$[OK]':)%0a(:input end:)%0a(:ifend:)%0a -time=1438511767 +text=(:Summary:Form displayed when requesting a [[PmWiki/password(s)]] or username/password:)%0a'''$[Password required]'''%0a(:messages:)%0a(:if enabled InvalidLogin:)* $[Name/password not recognized]%0a(:ifend:)%0a(:input auth_form:)%0a(:if enabled EnableAuthUser:)$[Name]: (:input text name=authid autofocus=autofocus:)\\%0a(:if:)$[Password]: (:input password name=authpw autofocus=autofocus:)%0a(:input submit value='$[OK]':)%0a(:input end:)%0a(:ifend:)%0a +time=1665309211 blob - 233aeb2b2f0835afd78f0c0a07ac33a0ccfaf083 blob + 9002d60bbbc0af88343057746c941328d52d9342 --- wikilib.d/Site.EditQuickReference +++ wikilib.d/Site.EditQuickReference @@ -1,9 +1,9 @@ -version=pmwiki-2.2.67 ordered=1 urlencoded=1 +version=pmwiki-2.3.15 ordered=1 urlencoded=1 author=Petko charset=UTF-8 -csum=add signatures name and date PITS:01350 +csum=avoid style="..." in table, wrap in div with wikistyles (safer) (+1) name=Site.EditQuickReference -rev=45 +rev=49 targets=PmWiki.BasicEditing,PmWiki.TextFormattingRules,PmWiki.DocumentationIndex,PmWiki.Tables,PmWiki.TableDirectives -text=(:nolinebreaks:)(:Summary:quick reference for [[PmWiki/BasicEditing|editing]] pages:)%0a%25define=em font-weight=bold%25%0a(:table width='100%25' cellspacing='0' cellpadding='0' style='font-size:80%25; font-family:Arial; padding:2px; border:1px solid #cccccc;' class='quickref' :) (:comment Use 'quickref' class to override formatting :)%0a(:cellnr:)%0a%25target=_blank%25 [[PmWiki/Basic editing]] - [[PmWiki/Text formatting rules]] - [[PmWiki/Documentation index]]%0a(:cell align=right:)%0a%25em%25Tables%25%25: %25target=_blank%25[[PmWiki/Tables | simple ]] - [[PmWiki/TableDirectives | advanced ]]%0a(:cellnr:)%0a%25em%25Paragraphs%25%25: for a new paragraph, use a blank line;%0a(:cell align=right:)%0a%25em%25Line break%25%25: %0a%25em%25[=\\=]%25%25 or %0a%25em%25[=[[%3c%3c]]=]%25%25%0a(:cellnr:)%0a%25em%25[=->=]%25%25 to indent text, %0a%25em%25[=-%3c=]%25%25 hanging text %0a(:cell align=right:)%0a%25em%25Join line%25%25: %25em%25\%25%25%0a(:cellnr colspan='2':)%0a%25em%25Lists%25%25: %0a%25em%25*%25%25 for bulleted, %0a%25em%25#%25%25 for numbered, %0a%25em%25:%25%25term%25em%25:%25%25definition for definition lists%0a(:cellnr colspan='2':)%0a%25em%25Emphasis%25%25: %0a%25em%25[=''=]%25%25''italics''%25em%25[=''=]%25%25  %0a%25em%25[='''=]%25%25'''bold'''%25em%25[='''=]%25%25  %0a%25em%25[='''''=]%25%25'''''bold italics'''''%25em%25[='''''=]%25%25  %0a%25em%25[=@@=]%25%25@@monospaced@@%25em%25[=@@=]%25%25%0a(:cellnr:)%0a%25em%25References%25%25: %0a%25em%25[=[[=]%25%25another page%25em%25[=]]=]%25%25, %0a%25em%25[=[[=]%25%25[=http://example.com/=]%25em%25[=]]=]%25%25, %0a%25em%25[=[[=]%25%25another page %25em%25[=|=]%25%25 link text%25em%25[=]]=]%25%25, %0a%25em%25[=[[#=]%25%25anchor%25em%25[=]]=]%25%25,%0a%25em%25[=[[#=]%25%25anchor %25em%25[=|=]%25%25 link text%25em%25[=]]=]%25%25%0a(:cell align=right:)%0a%25em%25Signatures:%25%25 name: %25em%25~~[==]~%25%25%0a(:cellnr:)%0a%25em%25Groups%25%25: %0a%25em%25[=[[=]%25%25Group%25em%25[=/=]%25%25Page%25em%25[=]]=]%25%25 [-displays Page,-] %0a%25em%25[=[[=]%25%25Group%25em%25[=.=]%25%25Page%25em%25[=]]=]%25%25 [-displays [=Group.Page=],-] %0a%25em%25[=[[=]%25%25Group%25em%25[=(.=]%25%25Page%25em%25[=)]]=]%25%25 [-displays Group,-]%0a%25em%25[=[[=]%25%25Group%25em%25[=/]]=]%25%25 [-links Group homepage-]%0a(:cell align=right:)%0aname and date: %25em%25~~[==]~~%25%25%0a(:cellnr:)%0a%25em%25Separators%25%25: %0a%25em%25!!%25%25, %0a%25em%25!!!%25%25 for headings, %0a%25em%25[=----=]%25%25 for horizontal line%0a(:cell align=right:)%0a%25em%25Prevent formatting%25%25: %0a%25em%25[=[==]%25%25...%25em%25[==]=]%25%25%0a(:cellnr:)%0a%25em%25Other%25%25: %0a%25em%25[=[+=]%25%25[+big+]%25em%25[=+]=]%25%25  %0a%25em%25[=[++=]%25%25[++bigger++]%25em%25[=++]=]%25%25  %0a%25em%25[=[-=]%25%25[-small-]%25em%25[=-]=]%25%25  %0a%25em%25[=[--=]%25%25[--smaller--]%25em%25[=--]=]%25%25  %0a%25em%25[='^=]%25%25'^superscript^'%25em%25[=^'=]%25%25  %0a%25em%25[='_=]%25%25'_subscript_'%25em%25[=_'=]%25%25  %0a%25em%25[={+=]%25%25{+inserted+}%25em%25[=+}=]%25%25  %0a%25em%25[={-=]%25%25{-deleted-}%25em%25[=-}=]%25%25%0a(:cell align=right:)%0a%25em%25Preformatted%25%25: %0a%25em%25[=[@=]%25%25...%25em%25[=@]=]%25%25 or %0a%25em%25[=>>=]pre%3c%3c%25%25...%25em%25[=>>=]%3c%3c%25%25%0a(:tableend:) -time=1407498170 +text=(:nolinebreaks:)(:Summary:quick reference for [[PmWiki/BasicEditing|editing]] pages:)%0a(:comment Use 'quickref' class to override formatting :)%0a>>font-size:80pct font-family:Arial padding:2px border:'1px solid #cccccc'%3c%3c%0a(:table width='100%25' cellspacing='0' cellpadding='0' class='quickref pmhlt' :)%0a(:cellnr:)%0a%25target=_blank%25 [[PmWiki/Basic editing]] - [[PmWiki/Text formatting rules]] - [[PmWiki/Documentation index]]%0a(:cell align=right:)%0a'''Tables''': %25target=_blank%25[[PmWiki/Tables | simple ]] - [[PmWiki/TableDirectives | advanced ]]%0a(:cellnr:)%0a'''Paragraphs''': for a new paragraph, use a blank line;%0a(:cell align=right:)%0a'''Line break''': %25pmbullet%25[@\\@]%25%25 or %0a[@[[%3c%3c]]@]%0a(:cellnr:)%0a[@->@] to indent text, %0a[@-%3c@] hanging text %0a(:cell align=right:)%0a'''Join line''': %25pmbullet%25[@\@]%25%25%0a(:cellnr colspan='2':)%0a'''Lists''': %0a[@* @]for bulleted, %0a[@# @]for numbered, %0a[@:term:definition@] for definition lists%0a(:cellnr colspan='2':)%0a'''Emphasis''': %0a[@''@]''italics''[@''@]  %0a[@'''@]'''bold'''[@'''@]  %0a[@'''''@]'''''bold italics'''''[@'''''@]  %0a[@@@monospaced@@@]%0a(:cellnr:)%0a'''References''': %0a[@[[another page]]@], [@[[https://example.com/]]@], [@[[link"tool tip"|link text]]@], [@[[link|+]]@], [@[[#anchor]]@], [@[[#anchor|link text]]@]%0a(:cell align=right:)%0a'''Signatures:''' name: @@~~[==]~@@\\%0aname and date: @@~~[==]~~@@%0a(:cellnr:)%0a'''Groups''': %0a[@[[Group/Page]]@] [-displays Page,-] %0a[@[[Group.Page]]@] [-displays [=Group.Page=],-] %0a[@[[Group(.Page)]]@] [-displays Group,-]%0a[@[[Group/]]@] [-links Group homepage-]%0a(:cell align=right:)%0a(:cellnr:)%0a'''Separators''': %0a[@!!@], [@!!!@] for headings, %0a[@----@] for horizontal line%0a(:cell align=right:)%0a'''Prevent formatting''': %0a[@[=...=]@]%0a(:cellnr:)%0a'''Other''': %0a[@[+big+]@]  %0a[@[++bigger++]@]  %0a[@[-small-]@]  %0a[@[--smaller--]@]  %0a[@'^superscript^'@]  %0a[@'_subscript_'@]  %0a[@{+inserted+}@]  %0a[@{-deleted-}@]%0a(:cell align=right:)%0a'''Preformatted''': %0a@@[=[@...@]=]@@ or %0a[@>>pre%3c%3c@]...[@>>%3c%3c@]%0a(:tableend:)%0a>>%3c%3c +time=1669299269 blob - 4c60ebfacdb0e5f0b5b31ad059e8088f3dbb21a9 blob + c521c5d06bacf72b632273e1d8999b96dc614f4c --- wikilib.d/Site.PageActions +++ wikilib.d/Site.PageActions @@ -5,5 +5,5 @@ csum=$PageInDist after link name=Site.PageActions rev=51 targets=Site.PageActions -text=(:Summary:Contains the '[[PmWiki/AvailableActions|action]]' links (like Browse, Edit, History, etc.), placed at the top of the page, see [[PmWiki/site page actions]]:)%0a(:comment This page can be somewhat complex to figure out the first time you see it. Its contents are documented at PmWiki.SitePageActions if you need help. :)%0a* %25item rel=nofollow class=browse accesskey='$[ak_view]'%25 [[{*$FullName} | $[View] ]]%0a* %25item rel=nofollow class=edit accesskey='$[ak_edit]'%25 [[{*$FullName}?action=edit | $[Edit] ]]%0a* %25item rel=nofollow class=diff accesskey='$[ak_history]'%25 [[{*$FullName}?action=diff | $[History] ]]%0a(:if auth upload:)%0a* %25item rel=nofollow class=upload accesskey='$[ak_attach]'%25 [[{*$FullName}?action=upload | $[Attach] ]]%0a(:ifend:)%0a* %25item rel=nofollow class=print accesskey='$[ak_print]'%25 [[{*$FullName}?action=print | $[Print] ]]%0a(:if group Site,SiteAdmin,Cookbook,Profiles,PmWiki*:) (:comment delete if and ifend to enable backlinks:)%0a* %25item rel=nofollow class=backlinks accesskey='$[ak_backlinks]'%25 [[{*$Name}?action=search&q=link={*$FullName} | $[Backlinks] ]]%0a(:ifend:)%0a(:if enabled AuthPw:)%0a* %25item rel=nofollow class=logout accesskey="$[ak_logout]"%25'' [-[[{*$FullName}?action=logout | $[Logout] ]]-]''%0a(:ifend:) +text=(:Summary:Contains the '[[PmWiki/AvailableActions|action]]' links (like Browse, Edit, History, etc.), placed at the top of the page, see [[PmWiki/site page actions]]:)%0a(:comment This page can be somewhat complex to figure out the first time you see it. Its contents are documented at PmWiki.SitePageActions if you need help. :)%0a* %25item rel=nofollow class=browse accesskey='$[ak_view]'%25 [[{*$FullName} | $[View] ]] {*$PageInDist}%0a* %25item rel=nofollow class=edit accesskey='$[ak_edit]'%25 [[{*$FullName}?action=edit | $[Edit] ]]%0a* %25item rel=nofollow class=diff accesskey='$[ak_history]'%25 [[{*$FullName}?action=diff | $[History] ]]%0a(:if auth upload:)%0a* %25item rel=nofollow class=upload accesskey='$[ak_attach]'%25 [[{*$FullName}?action=upload | $[Attach] ]]%0a(:ifend:)%0a* %25item rel=nofollow class=print accesskey='$[ak_print]'%25 [[{*$FullName}?action=print | $[Print] ]]%0a(:if group Site,SiteAdmin,Cookbook,Profiles,PmWiki*:) (:comment delete if and ifend to enable backlinks:)%0a* %25item rel=nofollow class=backlinks accesskey='$[ak_backlinks]'%25 [[{*$Name}?action=search&q=link={*$FullName} | $[Backlinks] ]]%0a(:ifend:)%0a(:if enabled AuthPw:)%0a* %25item rel=nofollow class=logout accesskey="$[ak_logout]"%25'' [-[[{*$FullName}?action=logout | $[Logout] ]]-]''%0a(:ifend:) time=1467280938 blob - c2101a63c28dad4bfac9513b404a6cc2f40b49c1 blob + dc1af1814151e0d357c4a04935e54e53dd5337e2 --- wikilib.d/Site.Preferences +++ wikilib.d/Site.Preferences @@ -1,9 +1,9 @@ -version=pmwiki-2.2.39 ordered=1 urlencoded=1 +version=pmwiki-2.3.17 ordered=1 urlencoded=1 author=simon charset=UTF-8 -csum=summary link +csum=hlt php, remove ref to IE, add links (+44) name=Site.Preferences -rev=34 +rev=36 targets=PmWiki.AccessKeys,Site.Preferences,Cookbook.UserConfigurations -text=(:Summary: Preferences for [[PmWiki/access keys]] and edit form:)%0aPreferences for [[PmWiki/access keys]] and edit form%0a%0aThis page can be used as template for (personal) preferences, or set as default site preference (see below).%0a%0a->[@%0a # Access keys - hold Alt (Windows IE), Shift + Alt (Firefox)%0a # or Control (Mac) and tap the indicated key on your keyboard%0a # to trigger the corresponding action.%0a# 'ak_view' => '' , # view page%0a 'ak_edit' => 'e', # edit page%0a 'ak_history' => 'h', # page history%0a# 'ak_print' => '', # print view of page%0a 'ak_recentchanges' => 'c', # Recent Changes%0a 'ak_save' => 's', # save page%0a 'ak_saveedit' => 'u', # save and keep editing%0a 'ak_savedraft' => 'd', # save as draft%0a 'ak_preview' => 'p', # preview page%0a 'ak_textedit' => ',' # focus to edit textarea (at the end)%0a 'ak_em' => 'i', # emphasized text (italic)%0a 'ak_strong' => 'b', # strong text (bold)%0a%0a# 'ak_attach' => '', # attach a file%0a# 'ak_backlinks' => '', # show backlinks%0a# 'ak_logout' => '', # log out%0a%0a # Editing components%0a 'e_rows' => '20', # rows in edit textarea%0a 'e_cols' => '70', # columns in edit textarea%0a 'Site.EditForm' => 'Site.EditForm' # location of EditForm%0a @]%0a%0aTo create personal user (browser) preferences,%0a* make a copy of [[{$FullName}?action=source | this page]] somewhere, preferably as @@Profiles.''%25green%25insert_your_name_here%25%25''-Preferences@@%0a* edit that page with your new preferred settings,%0a* select [[{$FullName}?setprefs={$FullName} | Set Preferences of this Page]] on the page containing your newly created settings. %0a-> This sets a preference cookie on your browser which tells PmWiki where to find your personal preference settings.%0a%0aTo revert to the PmWiki default preferences%0a* select [[{$Name}?setprefs=| Revert to PmWiki Default Preferences]] to unset the preference cookie%0a%0aSee also [[Cookbook:UserConfigurations]] about how to customise the edit form for personal use.%0a%0a%0aNote that by default, parsing of {$FullName} is disabled. To make it the default site preference, add%0a XLPage('prefs', "Site.Preferences");%0ato a config file (e.g. local/config.php).%0a%0aTo disable user preferences entirely set $EnablePrefs = 0; -time=1342223944 +text=(:Summary: Preferences for [[PmWiki/access keys]] and edit form:)%0aPreferences for [[PmWiki/access keys]] and edit form%0a%0aThis page can be used as template for (personal) preferences, or set as default site preference (see below).%0a%0a->%25hlt php%25[@%0a # Access keys - hold Alt (Windows Edge), Shift + Alt (Firefox)%0a # or Control (Mac) and tap the indicated key on your keyboard%0a # to trigger the corresponding action.%0a# 'ak_view' => '' , # view page%0a 'ak_edit' => 'e', # edit page%0a 'ak_history' => 'h', # page history%0a# 'ak_print' => '', # print view of page%0a 'ak_recentchanges' => 'c', # Recent Changes%0a 'ak_save' => 's', # save page%0a 'ak_saveedit' => 'u', # save and keep editing%0a 'ak_savedraft' => 'd', # save as draft%0a 'ak_preview' => 'p', # preview page%0a 'ak_textedit' => ',' # focus to edit textarea (at the end)%0a 'ak_em' => 'i', # emphasized text (italic)%0a 'ak_strong' => 'b', # strong text (bold)%0a%0a# 'ak_attach' => '', # attach a file%0a# 'ak_backlinks' => '', # show backlinks%0a# 'ak_logout' => '', # log out%0a%0a # Editing components%0a 'e_rows' => '20', # rows in edit textarea%0a 'e_cols' => '70', # columns in edit textarea%0a 'Site.EditForm' => 'Site.EditForm' # location of EditForm%0a @]%0a%0aTo create personal user (browser) preferences,%0a* make a copy of [[{$FullName}?action=source | this page]] somewhere, preferably as @@Profiles.''%25green%25insert_your_name_here%25%25''-Preferences@@%0a* edit that new page with your new preferred settings,%0a* select [[{$FullName}?setprefs={$FullName} | Set Preferences of this Page]] from the new page containing your newly created settings. %0a-> This sets a preference cookie on your browser which tells PmWiki where to find your personal preference settings.%0a%0aTo revert to the PmWiki default preferences%0a* select [[{$Name}?setprefs=| Revert to PmWiki Default Preferences]] to unset the preference cookie%0a%0aSee also [[Cookbook:UserConfigurations]] about how to customise the edit form for personal use.%0a%0a%0aNote that by default, parsing of {$FullName} is disabled. To make it the default site preference, add%0a-> %25hlt php%25 @@ XLPage('prefs', "Site.Preferences");@@%0ato a config file (e.g. @@local/config.php@@).%0a%0aTo disable user preferences entirely set %25hlt php%25 @@$EnablePrefs = 0;@@%0a%0aSee %0a* [[Windows access keys -> https://learn.microsoft.com/en-us/windows/apps/design/input/access-keys]]%0a* [[Keyboard shorts in Edge -> https://support.microsoft.com/en-us/microsoft-edge/keyboard-shortcuts-in-microsoft-edge-50d3edab-30d9-c7e4-21ce-37fe2713cfad]]%0a* [[Firefox accessibility -> https://support.mozilla.org/en-US/kb/accessibility-features-firefox]]%0a* [[Mac keyboard shortcuts -> https://support.apple.com/en-us/HT201236]] +time=1673149736 blob - 1fe49c8afc616ae19e94055350a19e369566be9f blob + ab824d2579136715c36793fbd9219e15621539a1 --- wikilib.d/Site.Site +++ wikilib.d/Site.Site @@ -1,10 +1,10 @@ -version=pmwiki-2.2.125 ordered=1 urlencoded=1 -author=Petko +version=pmwiki-2.3.17 ordered=1 urlencoded=1 +author=simon charset=UTF-8 -csum= (+9) +csum=add skinelements, pageelements, preferences to pagelists (+255) name=Site.Site -rev=39 +rev=40 targets=PmWiki.Skins,Site.Site,SiteAdmin.SiteAdmin,Site.SideBar,PmWiki.PasswordsAdmin,PmWiki.GroupHeaders,PmWiki.Forms -text=(:title Site Configuration:)(:Summary: Site Configuration:)%0aHere you find some links to Site configuration and administration pages. Add links to other pages you may need for your site's configuration here, as necessary. %0aSome links may only apply to certain configurations or [[PmWiki/skins]].%0a%0aThe [[{$SiteGroup}/]] group contains configuration pages, and the [[SiteAdmin/]] group contains administrative pages.%0a%0a!! Note to new administrators%0a* All pages in the 'Site' group (except [[Site.Side Bar]]) are locked for editing as the default. [[{$SiteGroup}.SideBar]] is locked with the site-wide edit password, if one is set. %0a* All pages in the 'SiteAdmin' group are locked for reading and editing as the default.%0a* In order to edit any locked page you need to create in @@local/config.php@@ a site wide '''admin''' password (see [[PmWiki/Passwords Admin]]). Then you can edit pages and change the access protection of individual pages by changing the page attributes with [@?action=attr@].%0a%0a(:table border=0 width=100%25:)%0a(:cellnr:)%0a!! Configuration and Menu Pages%0a(:pagelist group={$SiteGroup} list=all name=All*,PageActions,InterMap,Search,Preferences,PageNotFound*,LocalCSS,*menu*,IncludeFailed,*style*,version fmt=#titlesummary:)%0a%0a!! SideBar, header, and footer pages%0aSidebar, [[PmWiki/GroupHeaders | headers]] and footers are used to display common content across a group or entire website.%0a(:pagelist group={$SiteGroup} list=all name=*bar*,*head*,*foot* fmt=#titlesummary:)%0a%0a!! Form pages%0a[[PmWiki/Forms]] are used for display and entry of information.%0a(:pagelist group={$SiteGroup} list=all name=*form* fmt=#titlesummary:)%0a%0a!! Quick reference pages%0aQuick reference pages are included in other pages to assist in the use of those pages.%0a(:pagelist group={$SiteGroup} list=all name=*quick*,Search fmt=#titlesummary:)%0a%0a!! Template pages%0aTemplates are used by page and form directives to control the output displayed.%0a(:pagelist group={$SiteGroup} list=all name=*template* fmt=#titlesummary:)%0a(:cell:)%0a!! Site Administration%0aHere is the list of the pages in the [[SiteAdmin/]] group. Some links may only apply to certain configurations.%0a(:pagelist group=SiteAdmin list=all fmt=#titlesummary:)%0a(:tableend:)%0a%0a%0a -time=1580197272 +text=(:title Site Configuration:)(:Summary: Site Configuration:)%0aHere you find some links to Site configuration and administration pages. Add links to other pages you may need for your site's configuration here, as necessary. %0aSome links may only apply to certain configurations or [[PmWiki/skins]].%0a%0aThe [[{$SiteGroup}/]] group contains configuration pages, and the [[SiteAdmin/]] group contains administrative pages.%0a%0a!! Note to new administrators%0a* All pages in the 'Site' group (except [[Site.Side Bar]]) are locked for editing as the default. [[{$SiteGroup}.SideBar]] is locked with the site-wide edit password, if one is set. %0a* All pages in the 'SiteAdmin' group are locked for reading and editing as the default.%0a* In order to edit any locked page you need to create in @@local/config.php@@ a site wide '''admin''' password (see [[PmWiki/Passwords Admin]]). Then you can edit pages and change the access protection of individual pages by changing the page attributes with [@?action=attr@].%0a%0a(:table border=0 width=100%25:)%0a(:cellnr:)%0a!! {$SiteGroup} group Configuration and Menu Pages%0a(:pagelist group={$SiteGroup} list=all name=PageActions,InterMap,Search,Preferences,PageNotFound*,LocalCSS,*menu*,IncludeFailed,*style*,version fmt=#titlesummary:)%0a%0a!! Changes%0a(:pagelist group={$SiteGroup} list=all name=All* fmt=#titlesummary:)%0a%0a!! {$SiteGroup} group sidebar, header, and footer pages%0a{$SiteGroup} group sidebar, skin element, [[PmWiki/GroupHeaders | headers]] and footers are used to display common content across a group or entire website.%0a(:pagelist group={$SiteGroup} list=all name=*bar*,*head*,*foot*,skinelements,pageelements fmt=#titlesummary:)%0a%0a!! {$SiteGroup} group Form pages%0a[[PmWiki/Forms]] are used for display and entry of information.%0a(:pagelist group={$SiteGroup} list=all name=*form* fmt=#titlesummary:)%0a%0a!! {$SiteGroup} group Quick reference pages%0aQuick reference pages are included in other pages to assist in the use of those pages.%0a(:pagelist group={$SiteGroup} list=all name=*quick*,Search,*reference*,-preferences fmt=#titlesummary:)%0a%0a!! {$SiteGroup} group Template pages%0aTemplates are used by page and form directives to control the output displayed.%0a(:pagelist group={$SiteGroup} list=all name=*template* fmt=#titlesummary:)%0a(:cell:)%0a!! Site Administration%0aHere is the list of the pages in the [[SiteAdmin/]] group. Some links may only apply to certain configurations.%0a(:pagelist group=SiteAdmin list=all fmt=#titlesummary:)%0a(:tableend:)%0a%0a%0a +time=1673147535 title=Site Configuration