Friday, October 19th, 2007
Relative URLs as //ajaxian.com
I had never thought to use relative URLs that are just relative to the protocol scheme as Ned Batchelder explains in his post on Http-https transitions and relative URLs.
-
-
<img src='//fast.cdn.net/pix/smiley.jpg' />
-
Who knew.












Whew knew? Only those who read documentation.
I use this a lot specifically for this purpose of easily making the same content show on both secure and non-secure sites with mixed domains in the URL. Many lame browsers, like old versions of WebTV weren’t written by developers who read the documentation (like Rick points out) don’t support it. Fortunately, if you can get ahold of the developers and point out the RFC, most are willing to fix it, as happened when I contacted a research search engine with a busted mining bot.
Hey, that’s actually pretty cool. thanks for enlightening me ^^
Who knew? I sure didn’t!!
This is a useful tip–thanks for poiting it out.
Every XSS hacker knows it really wel :P
Well, his site doesn’t work, so how serious could he be?