Beefy Boxes and Bandwidth Generously Provided by pair Networks
We don't bite newbies here... much
 
PerlMonks  

Warn people who have perlmonks in a URL?

by tilly (Archbishop)
on Nov 08, 2003 at 16:36 UTC ( #305555=monkdiscuss: print w/ replies, xml ) Need Help??

A common and recurring problem is that people who want to link elsewhere on perlmonks write URLS like <a href=http://perlmonks.org/index.pl?node_id=284436>this</a> rather than like [id://284436|this] or even like <a href=/index.pl?node_id=284436>this</a>. The problem, as all long-term users of perlmonks know, is that this site is available under many names, and following a link to a different site name logs you out. (For which reason most long-term PM users change their theme from the default so that they can immediately see when they are logged out.)

If you have never seen this, either this or that should demonstrate the problem for you.

This is annoying. However new users cannot be expected to know better until they are told about it. (They don't even know to test it because the link works perfectly..for them.) Therefore why don't we have Perlmonks itself issue a warning and an explanatory note to anyone who tries to post anything with "perlmonks" in a URL? Let them post anyways (perhaps after hitting some sort of final confirmation), but have the education be done automatically by the software rather than after the fact by annoyed messages from people who got logged out.

Comment on Warn people who have perlmonks in a URL?
Select or Download Code
Re: Warn people who have perlmonks in a URL?
by fokat (Deacon) on Nov 08, 2003 at 17:35 UTC

    Well, I've been here for a couple of years and was not aware of this, so certainly it looks like an excellent idea to me.

    Best regards

    -lem, but some call me fokat

Re: Warn people who have perlmonks in a URL?
by atcroft (Monsignor) on Nov 08, 2003 at 19:09 UTC

    With the .com, .net, and .org, this can be annoying. I did notice that most sections (but not all) had the "standard set" of reminder links to where to post, the approved tags, how to link (which has a link to the linking shortcuts), and display escape characters and code, but that the initial reply form does not (the preview, however, does). Do you think it would be best to do it in the initial preview, or perhaps maybe on submit, sending them instead to the preview if present with the explanation? (Incidentally, most of the times I see this actually seem to occur in the CB, but that appears to be my limited experience, however.)

    And, out of curiousity, are there ever valid times to send them to such a link?

    Actually, I may have found an answer to the last of my questions as I was composing this, since I found it very difficult to link to an anchor (#wheredoipost, #linking, and $code) via id shortcut (id:9953) for a node (Site How To) that comes back with a large number of search results when I tried to use "site how to;#anchor" or "id://9953#anchor".

      What about <a href='/index.pl?node=12345#foo'>my link</a>
        That doesn't always work (like when DNS goes whacky). The safest way is something like <a href="?&node=10277">crazyinsomniac</a> => crazyinsomniac

        MJD says "you can't just make shit up and expect the computer to know what you mean, retardo!"
        I run a Win32 PPM repository for perl 5.6.x and 5.8.x -- I take requests (README).
        ** The third rule of perl club is a statement of fact: pod is sexy.

      It's not just .com, .org and .net, there's also with or without www. (for example http://perlmonks.org and http://www.perlmonks.org/) and finally, monkads. That makes for 7 different domains total all pointing to the same site, the latter not even at the root — and no two of them can use the same cookie.

        If www.perlmonks.org and perlmonks.org cannot share the same cookie, even though one is a CNAME for the other and they are in the same domain, this strikes me as either a browser bug or possibly a design flaw in the cookie specification. Many systems have multiple machine names and yet should be considered the same system. I would understand if they were in different domains (e.g., www.foo.org and cgi.bar.org), but such is not the case.

        However, doesn't Apache have a feature that will fix this, by rewriting the URI to have a certain machine name? (I'm thinking something about canonical names, but my memory is a little hazy on the details.) Or am I confused about that?

        As far as the .com and .net domains... I'd be interested in hearing the reasoning behind why those TLDs don't just do a refresh/redirect to the .org domain. I can sort-of understand the reasoning behind registering perlmonks.com, because of people who get all their ideas about the internet from television (do such people read sites like perlmonks, though?), but I have difficulty believing *anyone* would think perlmonks would belong in the .net TLD, and it seems to me that even given that you want people who type in those domains to get to the right place, a refresh would accomplish that, and still land everyone's URIs in the same TLD, which would have more benefits than just making absolute links work better. What am I missing?


        $;=sub{$/};@;=map{my($a,$b)=($_,$;);$;=sub{$a.$b->()}} split//,".rekcah lreP rehtona tsuJ";$\=$ ;->();print$/
Re: Warn people who have perlmonks in a URL?
by graff (Chancellor) on Nov 09, 2003 at 15:06 UTC
    The first technique I ever learned for linking to other perlmonks nodes from inside a post that I'm writing was to put just the node-id, together with some text to label it, inside square brackets, like this:
    [44715|graff's home node]
    I gather you could also use a string representing a node title in place of the node-id (assuming someone doesn't decide to change the node's title string at some later date).

    I don't recall which of the FAQ/intro/help pages at the Monastery gave me this idea (I got habituated to this a couple years ago). Having looked for it just now, I'm only seeing instructions that involve putting the "id://" prefix on the node-id.

    All the links I've put in my nodes, using just the unadorned node-id, still seem to work. (That's a relief!) But now that I know more about the "id://" prefix, I'll use it. Thanks.

      The idea that the node ID by itself should work was added later. It will work, only so long as nobody creates a title whose name is the same as that node ID. (At least that was the case in the original implementation, that may have changed.)

      Therefore for posts I always use id:// just in case, someday, someone wants to play a bad joke...

        A big difference is that id:// can also fetch the node's title to autolabel the link. IMO this is its main selling point.

        Makeshifts last the longest.

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: monkdiscuss [id://305555]
Approved by valdez
Front-paged by dbwiz
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others lurking in the Monastery: (9)
As of 2014-09-03 05:03 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    My favorite cookbook is:










    Results (35 votes), past polls