Posted by John Dunlop on 11/18/06 09:55
Jorolat:
> Does it matter if you use _ or %5F in urls?
After percent-encoding normalisation they are equivalent in so far as
the resource identified is the same and can be established to be the
same without accessing the resource. Only in a character-by-character
comparison - a primitive computational comparison - are they unequal.
Consistently providing URLs in normalised form avoids false negatives
even in character-by-character comparisons.
Bearing in mind that URLs are part of the user-interface and can be
presented to the user before normalisation I would say it does matter
whether or not you percent-encode unreserved characters (characters
that are representable as raw data). I would not percent-encode them
since doing so would muddy an otherwise meaningful character not to
mention needlessly lengthen the URL by two and hamper rememberability.
(Underscores in URLs may be unwise because the underscore can be
hidden by the underline that often accompanies URLs - for example in
e-mails and on Usenet.)
--
Jock
Navigation:
[Reply to this message]
|