[pmwiki-users] Spacing Wiki Words
Hans
design5 at softflow.co.uk
Fri Mar 11 04:11:17 CST 2011
I went through some confusion about WikiWords in page titles,
so can you confirm that I got the following right?
1. Bare WikiWords are by default not used as links,
$EnableWikiWords = 1; will turn this feature on,
turning any CamelCase word into a link.
2. $LinkWikiWords = 1; will do the same as $EnableWikiWords = 1;
plus also honour directives (:linkwikiwords:) and (:nolinkwikiwords:)
in the content for the respective content.
3. $SpaceWikiWords = 1; will space any bare WikiWord link enabled by
setting one or the other variables above. It will also honour
(:spacewikiwords:) and (:nospacewikiwords:) directives for
respective content.
4. Since Wikiwords are by default off, the only effect of
$SpaceWikiWords = 1; is for the page variable {$Title}:
If no (:title ...:) is set in a page, $SpaceWikiWords = 1;
will space any WikiWord page name, same as {$Titlespaced}
does by default always.
5. $SpaceWikiWords = 1; will not space WikiWords in links
written as links like [[WikiWord]] or [[Main/WikiWord]].
Instead space the words in the link.
6. If you don't use WikiWords, you may as well use {$Groupspaced} and
{$Titlespaced} in content or header navigation links or page title
or in the skin template, rather than $SpaceWikiWords = 1;
7. I don't know how to set exemptions for some page and group names,
which I don't want to be spaced. $WikiWordCount['PmWiki'] = -1;
has no effect on {$Groupspaced} or {$Titlespaced} or
{$Title} plus setting $SpaceWikiWords = 1;
It only has an effect on bare WikiWords when WikiWords are enabled.
In the documentation PmWiki/BasicVariables does not mention all of
this. $SpaceWikiWords does not mention the effect on {$Title},
but this is the only effect it has in a default install.
Looking through the code of pmwiki.php:
there are two instances of $AsSpacedFunction declared global in a
function, without it being used:
in functions PageVar() and FmtPageName()
Those could probably be deleted.
Is there a solution to point 7?
~Hans
More information about the pmwiki-users
mailing list