Salvete! I have discovered that a certain way of url encoding breaks the link. For the record %2f represents the forward slash character: /
Now, consider this:
Original Link: http://dottech.org/95285/this-is-the-pacific-barreleye-a-fish-with-a-transparent-head-amazing-photo-of-the-day
javascript (encodeURIComponent) urlencoded link: http://dottech.org%2f95285%2fthis-is-the-pacific-barreleye-a-fish-with-a-transparent-head-amazing-photo-of-the-day
Now, if you paste the encoded link into your browser’s address bar, it is broken (Firefox, Chrome, IE).
However, if you don’t url-encode the first forward slash, it works perfectly:
‘http://dottech.org/95285%2fthis-is-the-pacific-barreleye-a-fish-with-a-transparent-head-amazing-photo-of-the-day
Why?
The
/is a reserved character. It’s not equivalent to%2f. If you need the slash without its defined meaning, you’d use the encoded form.See RFC 3986: "Reserved Characters":
The reason why the mentionend URL still works if you don’t use the reserved char
/for the second slash: their CMS simply looks for the ID part in the URL. So you can add whatever you want to the URL, e.g. the following should still work:(However, it seems that it still has to be
/or%2fin their case.)If you try it with a Wikipedia article, it redirects to the front page: