Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl-Sensitive Sunglasses
 
PerlMonks  

Link to searches is missing domain

by daveola (Novice)
on Dec 26, 2012 at 07:18 UTC ( #1010326=monkdiscuss: print w/ replies, xml ) Need Help??

When you search, the results contain a preload link that looks like this:

Link to preload this search: [href://?node_id=3989;HIT=perl]

The domain is missing.

Comment on Link to searches is missing domain
Download Code
Re: Link to searches is missing domain
by Anonymous Monk on Dec 26, 2012 at 08:17 UTC
      Except a relative URL can't have the "http://" at the front.

      The actual href for the line printed works, but the text URL does not. Try cutting and pasting it into your browser location bar.

        Except a relative URL can't have the "http://" at the front.

        But it doesn't have a "http://" at the front.

        The actual href for the line printed works, but the text URL does not. Try cutting and pasting it into your browser location bar.

        What "text url"? There is no "text url" anywhere.

Re: Link to searches is missing domain
by jdporter (Canon) on Dec 26, 2012 at 16:23 UTC
    The domain is missing.

    You say that as if it's a bad thing.

      I shall rephrase. It's an absolute URL, and it's missing the domain. It either needs the domain or it needs to be a relative link.

      Regardless, if someone is saving that piece of text, it makes sense that in that instance it is *not* relative, since a piece of text is not specifically tied to a page.

      Regardless, the URL it prints simply does not work.

        "Regardless" (as you were of Perl Monks Approved HTML tags and/or Markup in the Monastery) it would be well to know the subject well before correcting those who do. Thus, I suggest that you read What shortcuts can I use for linking to other information?.

        The "(l)ink to preload this search" to which you object works where it's intended to... as a link in a node here at the Monastery.

        It would also reflect better upon you if you demonstrated that you know that <p /> is NOT an element of the pseudo-HTML (HTML subset, mostly) used in the Monastery.

        It's an absolute URL, and it's missing the domain.

        Actually, the semantics of a URL depend entirely on the scheme. I recommend you read up on URI scheme.
        In this case, the scheme is href, which is one we've defined here at PerlMonks; its semantics do not include the specification of a domain.
        It seems that you were assuming that the semantics of href should and must be identical to those of http. That assumption is incorrect.

        ... since a piece of text is not specifically tied to a page.

        I'm having trouble making sense of that statement.

        the URL it prints simply does not work.

        Odd. You're the first and only person to have problems with it.

        Wait -- Did you trying putting it directly in your browser address bar? Of course that won't work. It needs to be interpreted by the PerlMonks rendering engine. To do that, you must insert the link (including the square brackets) in the text of a post or cb message.

        I reckon we are the only monastery ever to have a dungeon stuffed with 16,000 zombies.

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others avoiding work at the Monastery: (11)
As of 2014-07-10 16:54 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    When choosing user names for websites, I prefer to use:








    Results (213 votes), past polls