CGI Forms   «Prev 

Unsafe-character encoding

According to the URL specification (RFC 1738), any character that is not alphanumeric or one of these special characters:
$-_.+!*'(),

is considered unsafe, and must be encoded unless it's being used for a designated special purpose.
In practice, the only characters that are not commonly encoded are alphanumerics and these characters:
-_.

The encoding scheme used for unsafe characters uses a hexadecimal representation of the encoded character, introduced by a percent sign (%). This, of course, necessitates that a percent sign must be represented by its own value, 25 hex, if it is not being used for this purpose.
Additionally, any spaces in the original string are replaced with the + (plus) sign. What does this look like? Here are a few strings and their encoded equivalents:

String Encoded equivalent
wew@bearnet.com wew%40bearnet.com
Big light in sky Big+light+in+sky
25^3 & 14% of 12. 25%5E3+%26+14%25+of+12.