This has been tossed about before... or rather the essence of it has.

How do you link to a particular writeup?

Our sister site (http://perlmonks.org/) has one additional way to link to a node (other than the <a href=...> tag working). To link to a particular writeup they use [id://124|The default node].

In a land where nothing ever gets nuked, this is fine and dandy. However, that is not the case here - things go *poof* from time to time. We all have seen it - a node that gets completely destroyed on the New Writeups so the link goes to "Nothing here". Archiving these links to missing nodes wouldn't work and would just create a nightmare for people trying to clean things up. Picture a node where every link goes to a nuked node - not even a search.

Enter the <a name=....> tag. For the low low price of a fraction of the time it takes to add
<!-- Announcement (if any): -->
<!-- "Keep 'em short"?! I'm a creative person, darn it! You're oppressin' me! -->
<!-- Dammit, *I* am ekw and I say keep 'em short! -->
<!-- I HAVE SILLY INITIALS AND I SAY KEEP 'EM LONG! -->

to the page (well, maybe just a bit more than that) it would be possible to toss in a name anchor. For example:

<a name="Webster 1913"></a>
<table border="0" cellpadding="0" cellspacing="0" width="100%"> <tr> <td> (<A HREF="/index.pl?node_id=281233&lastnode_id=104031">definition</a>) by <strong> <A HREF="/index.pl?node_id=176726&lastnode_id=104031">Webster 1913</a></strong> (<A HREF="/index.pl?displaytype=printable&node_id=281233">print</a>)</td> <td align="center"></td> <td align="right"><small>Wed Dec 22 1999 at 01:14:17 UTC</small> </td> </tr> </table>
...
Alone, this is mildly useful for the outside world. With that anchor, it would be possible to link to Webster's writeup within a node and keep the rest of the node there. Not the biggest gain (we typically link to a particular nodeid from the outside, but the idea is there).

The true power of this comes with the realization that this makes linking to a writeup within a node possible at almost no cost to the E2 engine - all the work is done on the browser side.

Previous ideas for writeup linking have been based around the idea of specifying a node and a name and having the E2 engine identify the writeup node id and put that into the url. This is expensive on the database side. When we look at the links formed by nodes we see that they are without exception names rather than numbers. A link to mistletoe goes to http://everything2.com/index.pl?node=mistletoe.

So, what if we were to add a character (or sequence) that is then parsed out. So (using '##' as a sequence) [mistletoe##Webster 1913|Mistletoe] would then be be linked as http://everything2.com/index.pl?node=mistletoe#Webster+1913 which would then jump to the right spot on the page? The only changes that need (at a first guess) be made are the addition of the <a name=...> tags at the start of each writeup, where the name is the writeup author and a small change to the link generator to stick anything after a '##' to http://....#stuff which is a simple string processing no more difficult than the URL encoding that is already being done.

The largest impact on this would be that the sequence would no longer work as part of a node title and thus would have to be chosen after careful consideration.

Log in or register to write something here or to contact authors.