Encoding/Decoding working differentlty on different servers. Locally I'm running PHP v5.6. default_charset = UTF-8 according to php_info(). When I pass the value 's
in the URL it displays correctly in an input field as 's
.
Remotely my Godaddy server is running PHP v5.3, default_charset = No value according to php_info() When I pass the value 's in the URL it displays incorrectly in the input field as %27s
.
I have added <meta http-equiv="content-type" content="text/html; charset=utf-8"></meta>
in the header of the html file.
Does anyone know how to resolve this so that 's
displays as 's
on the remote server?
您不是必须用\\'或\\'来代替单引号吗?
'
is not a standard alphanumeric character so it gets URL-encoded with a method similar to this one for compatibility.
'
is %27
hex or 39
decimal ASCII character.
在输入字段中显示值之前,需要通过urldecode()传递值。
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.