Eric E Johnson wrote:
As for why these functions exist, I keep thinking along these lines - imagine you want to encode foreign language characters in a URL. The way to do it is to convert your string into bytes, and then URL encode the bytes as if it were ASCII. Reversing the process, take your URL, decode it into ASCII, treat each character as a byte, and then convert those bytes back via the expected encoding. So you can imagine that the first step would be precisely what these routines do - a conversion of a String into byte encoding XXX, and then back into a String in encoding YYY, where YYY almost certainly is ASCII. Having done that, you can use all your functions that URL encode a String instead of writing an additional function that takes bytes. Unfortunately, if the encoding YYY has any characters outside the 0-255 range, you'd be hosed, and the documentation doesn't say that.
This correct modulo all the phrases with the word "ASCII" in it. It's just about a sequence of bytes and has nothing to to with ASCII (which is 7-bit only by the way).
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
