Here are the current link-handling settings:

Setting Value
cpan my $escapedname=$query->escape($nodeloc); my $cpantitle= $title || $nodeloc; return qq[<a href="http://search.cpan.org/search?mode=module&query=$escapedname">$cpantitle</a>];
dict my $escapedname = $query->escape($nodeloc); my $x = $title || $nodeloc; return qq[<a href="http://www.m-w.com/cgi-bin/dictionary?book=Dictionary&va=$escapedname">$x</a>];
doc if ($escapedname =~ /^perl/) {qq[<a href="http://perldoc.perl.org/$escapedname.html">$cpantitle</a>];} else {qq[<a href="http://perldoc.perl.org/functions/$escapedname.html">$cpantitle</a>];}
ftp return $title ? qq[<a href="ftp://$nodeloc">$title</a>] : qq[<a href="ftp://$nodeloc">$nodeloc</a>];
google my $escapedname=$query->escape($nodeloc); my $cpantitle= $title || $nodeloc; return qq[<a href="http://www.google.com/search?q=$escapedname">$cpantitle</a>];
href return qq[<a href="$nodeloc">$cpantitle</a>]
http return $title ? qq[<a href="http://$nodeloc">$title</a>] : qq[<a href="http://$nodeloc">http://$nodeloc</a>];
https return $title ? qq[<a href="https://$nodeloc">$title</a>] : qq[<a href="https://$nodeloc">https://$nodeloc</a>];
id if($nodeloc=~/\D/) {return "[$inner]"} else {return $title ? linkNode($nodeloc, $title) : linkNode($nodeloc)};
isbn $nodeloc =~ tr/0-9Xx//cd; my $cpantitle = $title || "ISBN $nodeloc"; "<a href='http://isbn.nu/$nodeloc'>$cpantitle</a>";
jargon return qq[<a href="http://www.science.uva.nl/cng/search/htsearch.CGI?words=$escapedname&restrict=%2F%7Emes%2Fjargon%2F">$cpantitle</a>];
kobe return qq[<a href="http://cpan.uwinnipeg.ca/search?query=$escapedname&mode=module">$cpantitle</a>];
kobes return qq[<a href="http://cpan.uwinnipeg.ca/search?query=$escapedname&mode=module">$cpantitle</a>];
link return qq[<a href="$nodeloc">$cpantitle</a>]
lj return qq[<a href="http://livejournal.com/users/$nodeloc">$cpantitle</a>];
localtime $nodeloc="" if $nodeloc=~/now/i; return htmlcode('parseTimeInString', '', $nodeloc);
lucky my $escapedname = $query->escape($nodeloc); my $cpantitle= $title || $nodeloc; return qq[<a href="http://www.google.com/search?q=$escapedname&btnI=I">$cpantitle</a>];
node return htmlcode('node_link', '', $inner, $nodeloc, $title, $cpantitle);
pad return htmlcode('scratchpad_link', '', $nodeloc||$AUTHOR->{title}, $title, {});
perldoc return qq[<a href="http://www.perldoc.com/cgi-bin/htsearch?&words=$escapedname">$cpantitle</a>];
pmdev return htmlcode('pmdev_link', '', $inner);

Much of the complexity has been factored out already but there are still a lot of improvements for the infrastructure of link handling that are desired and partially implemented. But even what we have now isn't a simple text substitution. Provide the start of an enhancement to get your customization and it might get into the queue with the other enhancements that have yet to be deployed. Sometimes such a kick-start is exactly what is needed.

If you are missing something, then implementing it will probably rectify that situation. I don't see the obvious right way to do something like what you have asked for that I'd consider flexible to the point of being worth implementing, but I haven't sat down and tried to design it (but it appears you haven't sat down and tried to design it in any detail either so I don't feel particularly lazy in comparison).

- tye        


In reply to Re^5: Personalizing the linkers (happen) by tye
in thread Personalizing the linkers by dragonchild

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.