[OT] absolute vs. relative URI

Grant Edwards invalid at invalid.invalid
Fri Jan 23 16:40:52 CET 2015


On 2015-01-23, Marko Rauhamaa <marko at pacujo.net> wrote:
> Grant Edwards <invalid at invalid.invalid>:
>
>> I'm not an HTLM/HTTP guru, but I've tinkered with web pages for 20+
>> years, and for links within sites, I've always used links either
>> relative to the current location or an absolute _path_ relative to the
>> current server:
>>
>>   <a src='/Whatever'>Whatever</a>
>>
>> I've never had any problems with links like that.  Is there some case
>> where that doesn't work right and I've just been stupidly lucky?
>
> An ancient HTML spec (<URL: https://tools.ietf.org/html/rfc1866>)
> specifies:
[...]
> It refers to the URI spec (<URL: https://tools.ietf.org/html/rfc1630>):
[...]
>
> Bottom line: you are safe.

Thanks, I was pretty sure that was the case. But, I'm still baffled
why the original author(s) went to the extra work to always generate
absolute URIs.  The pages were originally developed by a web
development company we contracted to do the initial design for us. We
were _assuming_ they knew more about that sort of thing than we
old-school EE types.

[I must admit that I have learned a lot from their code about how to
use CSS to avoid putting layout/presentation info directly in the HTML
tags the way we did in days of yore.]

-- 
Grant Edwards               grant.b.edwards        Yow! I have a TINY BOWL in
                                  at               my HEAD
                              gmail.com            



More information about the Python-list mailing list