KBD

Keith Devens .com

Tuesday, March 16, 2010 Flag waving
Crying is all right in its way while it lasts. But you have to stop sooner or later, and then... – C.S. Lewis (The Silver Chair, ch 2)
← Saddam's TrialABC News: 'The Simpsons' Exported to Middle East -- Minus Bacon, Beer →

Daily link icon Wednesday, October 19, 2005

Collected BNF for URI

Collected BNF for URI. PHP's urlencode function escapes more than is necessary specifically for the path component of a URL. So things like the colon get escaped when they don't have to be:

http://keithdevens.com/weblog/archive/2005/Oct/19/James-4%3A13-17
http://keithdevens.com/weblog/archive/2005/Oct/19/James-4:13-17

Gonna write my own escaper based on the BNF that just works for paths so that my slugs won't be so ugly when they contain characters that are invalid in certain components of the URL, but not the path.

← Saddam's TrialABC News: 'The Simpsons' Exported to Middle East -- Minus Bacon, Beer →

Comments XML gif


Feel free to post a comment below. Please see my comment policy.

Formatting Rules (No HTML):

  • **bold**, *italic*, _underlined_, --strikeout--
  • "text"="url" creates a link, and URLs are auto-highlighted
  • Blockquote: Like e-mail, begin paragraph with > (greater-than sign)
  • Lists: begin paragraph with *,-, or + (unordered), or # (ordered)
  • Code block: ?!code:language=perl|php|sql|javascript|etc.{\n}...{\n}?!/code

:
(will be your IP address if blank)
: (optional)
(Will not be shown on site)

: (optional)
:

March 2010
SunMonTueWedThuFriSat
 123456
78910111213
14151617181920
21222324252627
28293031 



RSS feed RSS feed for Keith's Weblog
Atom feed Atom feed for Keith's Weblog
Weblog archive
Recent comments
  on 1 posts

Recent comments XML

new⇒Quantum physics and free will

I knew you were going to say that....

Tom Massey: Mar 15, 9:26pm

Generated in about 0.119s.

(Used 8 db queries)