[pmwiki-users] Default styling of links to non-existent pages

Waylan Limberg waylan at gmail.com
Fri Jan 27 23:44:10 CST 2006


On 1/27/06, Patrick R. Michaud <pmichaud at pobox.com> wrote:
> Before leaving the 2.1.beta series, I'd like to visit the
> possibility of changing the default styling of links to
> non-existent pages, but could use feedback.
>
> Currently PmWiki automatically styles links to non-existent pages
> by placing a question mark after the link and a dotted underline
> beneath it.  This choice was settled upon after many discussions
> in August of 2004.
>
> Currently the link styling is built-in to the PmWiki core itself;
> i.e., it's the default unless a skin redefines it.  Skin designers
> will tell you that it can be a bit of a pain to override.
>
> I'm curious to know if we should change this, and if so, how.
> I can think of ways where it might be nice to eliminate the
> question mark that appears, and use some other form of styling
> besides the dotted underlining.  I notice that many other
> systems have gone to simply highlighting the link with a different
> color.
>
> Any comments/suggestions on this?
>

My first thought is that each case should have a different class
attribute as a styling hook, which should be easy to customize.

As far as the question mark - in my site, I've removed it (I forget
how). Anyway, perhaps a separate variable should be created to assign
the text displayed for that link (default would currently be '?'). If
the variable is set to '' (empty string) then that link is not
created.

some (bad??) examples:

    $LinkPageCreateClass = 'createpagelink';
    $LinkPageCreateLabel = '?';

which gives us:

    <a class='createpagelink' href='Group.Page?action-edit'>?</a>

Of course, the link which contains the link text would still display,
but needs a proper class attribute as well, which should just as
easily be customized.
--
----
Waylan Limberg
waylan at gmail.com




More information about the pmwiki-users mailing list