[pmwiki-users] Bug in Trails?

Petko Yotov 5ko at 5ko.fr
Sun Mar 18 07:10:17 CDT 2012

Ulf Bro writes:
> # Genesis
> ## Adam
> ## Noah
> I see the following when using ^|Indexpage|^ on "Noah":
> Indexpage | Genesis | Noah
> Indexpage is just a name (should have been a link)
> Genesis is a link
> Noah is a link (should have been just a name)

To have a link to the index page, use a link to the index page:


The self-link on the current page is probably an error, but it is not  
technically trivial to remove the link while keeping the link text in  
different cases:

* [[Link]]ed with a suffix
* [[Lini|+]] with a title
* [[Link|with an alternative text]]

In this case, to remove the self links, you have two options:

1. Set in config.php a plain text format for all self links:

  $LinkPageSelfFmt = '$LinkText';

This will remove the links from all self links, not only those in trail paths.

2. You can use CSS to style differently the self link. Add in your file  
pmwiki/pub/css/local.css (if it doesn't exist, create it) one of the  
following lines:

/* for wikitrail selflinks only */
.wikitrail a.selflink {text-decoration: none; color: black;}

/* for all selflinks, use instead of the previous line */
a.selflink {text-decoration: none; color: black;}

This way, you will have a self link which doesn't look like a link but like  
plain text.

Petko P.S. For this type of path wikitrails, some people prefer the ">"  
separator which can be set by adding to config.php such a line:

  $TrailPathSep = ' > ';

More information about the pmwiki-users mailing list