[pmwiki-users] Link Formats and the title attribute.

Waylan Limberg waylan at gmail.com
Wed Nov 2 11:22:57 CST 2005

I am trying to make all the links in my wiki include a title
attribute, but am running into a few problems. So far I have this in
my config.php:

$LinkPageSelfFmt = "<a class='selflink' href='\$LinkUrl'

$LinkPageExistsFmt = "<a class='wikilink' href='\$LinkUrl'

$LinkPageCreateFmt = "<a class='createlinktext'
href='\$PageUrl?action=edit' title='Create the page:

As most of my pages have titles, this works great (and in the few
cases where they don't, the page name is an acceptable alternative).
The problem is with my action links (Edit, History, View). They also
set the title, however, I would prefer to have the title attribute be
something like "Edit :\$Titlespaced" or even "Edit this page" would be
fine. Any idea how I can do that?

In a related thought, I'd like to see some markup to define the title
attribute in a link. Perhaps something like: [[Link | Link Text |
Title Text]]

As an extention of the TitledLinks recipe, one could maybe do
something like: [[Link | Link Text | +]] or even [[Link | + | +]]

Then, have a variable to set what the default title is for a link (ie.
$LinkTitle=$LinkText or $LinkTitle=$TitleSpaced). Then, if a title is
set in the markup (proposed above) that would override the default
behavior. Which would make this possable: [[?action=edit | Edit | Edit
this page]] or how about this: [[?action=edit | Edit | Edit: +]].
These are just thoughts at this point. Not really nesseccary if we can
address the first problem without it.

BTW, yes I know the extra createlink? is removed from the
$LinkPageCreateFmt in my example above. I want it that way.
Waylan Limberg
waylan at gmail.com

More information about the pmwiki-users mailing list