1 Reply Latest reply on Feb 27, 2008 1:49 PM by DCwebGuy

    How do I encode these special characters?

    DCwebGuy Level 1
      I am amazed that I cannot find any examples of how to do this (so far). Basically, I need to URL encoded only these special characters, as specified in RFC1738, section 2.2:

      ";","/", "?", ":", "@", "=" and "&" (plus "+" although "+" is not required by section 2.2)

      I find it strange that thers is no URLEncodedFormat param to specify exactly which characters to encode. This seems like an important thing. Many web services, such as the Amazon SimpleDB service I'm working with, have strict requirements when it comes to encoding.

      I am not very good with regular expressions, but that seems like the way to go here. Anybody know how to build a RE to encode the section 2.2 characters, or have you seen any special tags or examples? I just want to pass a string that may have any of those characters, and have it return encoded. Thanks.