html - PHP converting URL string to ASCII characters -
i have string of characters passed in url.
the string happens contain group of characters equivalent ascii code.
when try use string on page using $_get
command, converts part of string equivalent ascii code ascii code instead of passing actual string.
for example url contains string name='%bert%'
. when echo out $_get['name']
'3/4rt%'
instead of '%bert%'
. how can actual text?
you're not escaping data properly.
if want use %bert%
in url, need encode %
%25
, making query string value %25bert%25
.
%
in url means next 2 characters going encoded entity, if want use literally, must encoded way.
you can read more information here: http://www.blooberry.com/indexdot/html/topics/urlencoding.htm
Comments
Post a Comment