curl-library
curl_escape() space character bug?
Date: Wed, 19 Jun 2002 12:18:59 -0400
I thought that a URL encoded string should convert
the space character to %20 (hex).
curl_escape() converts the space character to a "+".
Also, curl_unescape() does not return the original string:
original, operation=name=abcd efg&value=5
curl_escape(), operation=name%3Dabcd+efg%26value%3D5
curl_unescape(), operation=name=abcd+efg&value=5
The original space was converted to a plus sign,
but did not convert back to a space.
I think the URL encoded string should be:
operation: name%3Dabcd%20efg%26value%3D5
where space is %20.
I also think that curl_unescape() should return
the original string.
RFC 1738, Uniform Resource Locators (URL), mentions
using %20 in place of the space character.
RFC 2316 is mentioned in escape.c, but this rfc
is about Report of the IAB Security Architecture Workshop.
Any thoughts on this appreciated.
Chris
----------------------------------------------------------------------------
Bringing you mounds of caffeinated joy
>>> http://thinkgeek.com/sf <<<
Received on 2002-06-19