Welcome to WebmasterWorld Guest from 18.104.22.168 , register , free tools , login , search , pro membership , help , library , announcements , recent posts , open posts Become a Pro Member
escaping get request in php Lisa
I am looking to send some information with the Get request but when I read the variable in PHP it is all encoded. I have been trying to locate the function that uncodes this. Anyone know this off the top of their head?
rawurldecode() and urldecode()
The difference (as far as I can see) is that if spaces have been encoded as +, you will need urldecode().
rawurldecode("foo%20bar") == "foo bar"
urldecode("foo+bar") == "foo bar"
If in doubt, urldecode() is probably the one to use.
To encode URLs, of course, use rawurlencode() or urlencode() as appropriate.