Why is it this way? Because the heart of the code is the very simple: /\D/ ? linkNodeTitle($_) : linkNode($_). That is, it was designed to accept a node ID or a node title. Why was it designed that way? Well, I didn't design it, but that is a clean design, especially considering what is obvious to do with the current code base. The fact that linkNodeTitle() also understands "|" is rather an accident.

To Aristotle: You are in pmdev so Feel Free. It probably wouldn't be very hard to change that code to call the code that handles square bracket links. Of course, ar0n started rewriting that code months ago. Then footpad at least announced that he had started rewriting it a month or two ago. I jumped in a few weeks back and you can (for a while) see what I've got so far at tye . My plan is to support typing "pad://tye" or "cpan://cache" in the simple Search box at the top of any PM page so you get a redirect to whatever that would link to if found in square brackets.

So put your code where your node is. You have access to all of the code. Go look at what I've done, fix the remaining bugs in it. Or just fix the personal nodelet to use the existing code (and to just put out verbatim any items that start with < so all of my <a href=...>...</a> links in my personal nodelet continue to work [at least in my browsers]).

I haven't had time to get back to that (and a lot of other things). And if I did, I'd be working on speeding the site up rather than that anyway.

                - tye

In reply to Re^2: YAPND: Yet Another Personal Nodelet Discussion (why) by tye
in thread YAPND: Yet Another Personal Nodelet Discussion by Aristotle

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.