[pmwiki-users] LinkCSSToolTip recipe

Hans design5 at softflow.co.uk
Wed Apr 9 18:03:27 CDT 2008

Wednesday, April 9, 2008, 8:51:39 PM, Dominique Faure wrote:

> Couldn't we having this kind of effect using a sibling span section
> instead of a child one: <a class='ttlink'>...</a><span
class='ttip'>>...</span> ?
> This way, you could preserve the page structure from anchor being
> embed into other anchor (which may be the case using included markup).

The tooltip content needs to be in  a wrapper (span or div) with
This needs to be inside a wrapper which has position:relative,
otherwise the tooltip pops up in the top left corner, and not next to
the link. I used a span element as a wrapper in the latest update
(just put on http://www.pmwiki.org/wiki/Cookbook/LinkCSSToolTip )

The other restriction lies with the link markup used:
in order to be able to include links (from included pages or sections
perhaps) the markup needs to have a different ending, not simply ]]
perhaps :]] , something like

[[target | link text |: tooltip text :]]

So I changed the markup to use this syntax. Is this acceptable?
It could be [[target | link text | tooltip text :]], but
  : tooltip text : looks more symmetrical like bracketing.

All this seems to work fine now, even with active links inside
tooltips, and all without javascript, even for IE.

> Meanwhile, nothing would prevent you from making yourself the call to
> MarkupToHTML to render the tooltip section (which is more or less what
> is done with Cookbook/DomTT).

Yes, I got this working now I think. Thanks!
The markup runs right at the beginning (is this dangerous, shall it
be processed a little later?), and the function calls MarkupToHTML
and Keep.


More information about the pmwiki-users mailing list