[pmwiki-users] trail bookmarks

Patrick R. Michaud pmichaud at pobox.com
Mon Jul 25 15:04:12 CDT 2005


On Mon, Jul 25, 2005 at 03:50:35PM -0400, Martin Fick wrote:
> Could it be encoded in the URL with something like this?
>
> URL&anchor=<anchor>#<anchor>

No, not really.  The way that [[#tgt | link text]] is rendered is as

   <a href='#tgt'>link text</a>

This is by design, so that clicking the link text allows the browser
to jump to the anchor on the current page without having to reload the
page.  Changing this to be

   <a href='http://...url?anchor=tgt#tgt'>link text</a>

means that following the link would cause the browser to reload
the page, which generally isn't what we want.  We could perhaps
say that trailstops for anchors have to be written as

   [[PageName#tgt | link text]]

and have markups of this form render as ?anchor=tgt#tgt extension, but
then people are likely to ask why the anchor is always being repeated,
not to mention that someone accessing the page without the ?anchor=tgt,
or following a [[#tgt | link text]] link is going to see a different
trail marker.

Overall I think it has too much potential for confusion among authors
and readers, and is probably best left as a cookbook recipe for now.

Pm




More information about the pmwiki-users mailing list