[pmwiki-users] (:title:) of (:include:) included pages overrides page title

Oliver Betz list_ob at gmx.net
Tue Feb 3 03:23:35 CST 2009


Petko Yotov wrote:

>> I'm somewhat confused by http://pmwiki.org/wiki/PITS/00779
>>
>> Pm wrote 2006-04-29 "This is being fixed for 2.1.6.  In 2.1.6,
>> (:title:) directives in included pages won't have any effect."
>>
>> Seemingly it's not. Maybe I missed something - what's the real status
>> of this issue?
>
>I added in the PITS entry a code to disable title directives from included 
>pages:
>  $QualifyPatterns['/\\(:title\\s(.*?):\\)/i'] = '';

It doesn't help for pages in the pmwiki distribution or pmwiki.org
itself. For example, the German documentation uses title directives on
nearly every page to make the page names matching the English names.
If one of these German pages includes another German page, it gets the
wrong title. I have to admit that I know of only one page being
affected currently. But maybe other languages are also concerned.

>I do use title directives in included pages and I will oppose the pure removal 

So all pages including the other page get the same title?

What if more than one page is included? The we have again the "who
wins" question.

(:title {includedpage$Title}:) would also set the title to the title
of the included page, and it controls _which_ page's title is used.

[...]

>Do you think we should push for some change to the core, or the solution I 
>gave is good enough and we could instead just update the documentation?

I still consider it very confusing that title directives from included
pages have an effect. Why should I use a title directive, if the
include directive overrides it later?

Maybe I simply missed the scenario where it's useful.

Regarding inclusion of other variables (parallel thread Hans started
briefly before my posting), I have no preference. But "title" is a
special case IMO.

Since i don't understand the effect of $QualifyPatterns completely,
and I don't know whether it will work in future revisions, I can't say
whether that's a good solution.

BTW: It would be nice if $QualifyPatterns were documented somewhat
mode extensive.

Oliver




More information about the pmwiki-users mailing list