When user data received by a Web server, it is presented in URL encoding format. If you retrieve this data from $_SERVER['QUERY_STRING'], you need to decode the data using the urldecode() function. If This page allows you to learn and test the urldecode() function to perform URL decoding.
What is URL Encoding?
URL encoding is an Internet standard defined in RFC1738 to protect special characters as part of user data included Web URL strings. URL encoding requires that all non-alphanumeric characters except -_. to be replaced with a percent (%) sign followed by two hex digits and spaces replaced as plus (+) signs. For example,
String: $99.99 and 10% tax URL encoded: %2499.99+and+10%25+tax
How to use and test urldecode() PHP function?
urldecode(string) converts the input string according to the URL decoding rules.
To help you learn and test urldecode() function, FYIcenter.com has designed this online testing page. All you need to do is to enter the testing string in the form below and click the Start button. The converted string will be presented in the result area.
Other On-line Testing Pages by FYIcenter.com
FYIcenter.com has prepared some simple but very interesting on-line testing pages that are useful for your programming and testing tasks:
Each tutorial answers one commonly asked PHP programming question with a short, but precise and clear PHP script.