[pmwiki-users] Editlink for each paragraph

Pico pmwiki at ben-amotz.com
Fri Sep 15 17:19:13 CDT 2006


pmwiki Besenreuther <pmwiki <at> besenreuther.de> writes:
> Hi,
> 
> sorry for my uncorrectness.
> As I wrote in my first mail I use following code:
> (:if authid:)%right% [- [[{$Group}.Homepage|{$Group}]] -
[[{$FullName}?action=edit | edit]]-](:if:)
> 
> When I'm in page: thematik/HomePage use the followin code:
> ! Big Section
> !! Chapter 1
> !!! Chaper 1.1
> (:include thematik/paragraph1-1-1:)
> ...
> 
> and thematik/paragraph1-1-1 looks like:
> (:if authid:)%right% [- [[{$Group}.Homepage|{$Group}]] -
[[{$FullName}?action=edit | edit]]-](:if:)
> !!!! Pragraph 1.1.1
> any text ....
> 
> and I open in browser thematik/Homepage and click on the edit link then
doesn't open thematik/paragraph1-1-1,
> as expeted - the page thematik/HomePage opens instead.
> 
[snip]

Ok, so the underlying issue is that you expect the value of the page variable
{$FullName} to always return the name of the page in which that markup was
entered, but that is not how PmWiki is working: the value of {$FullName} returns
the name of the page that is currently being viewed.  

Pm wrote about that confusion is one of the (several) extended threads a week
(or two) ago discussing the proposed {$:var} (and way before that it was
discussed in the content of other page variables, {$Title} or {Description}, I
can't recall).

For an illustration of what is going on here, I setup two test pages on PmWiki:
1. Test/IncludingPage and
2. Test/IncludedPage

Where 
1. Including Page contains (:include Test/IncludedPage:)
and
2. Included Page contains {$FullName}

The returned value of {$FullName} is:
1. "Test.IncludingPage" when viewing Test/IncludingPage and
2. "Test.Included Page" when viewing Test/IncludedPage

Pico


Pico





More information about the pmwiki-users mailing list