Home  >  Article  >  Backend Development  >  "Problem with PHP parsing URL encoding"

"Problem with PHP parsing URL encoding"

WBOY
WBOYOriginal
2016-08-08 09:30:071352browse

Parse the passed JSON value through $GLOBALS["HTTP_RAW_POST_DATA"] and find that "is escaped to %22 by the browser.

It turns out that the content obtained by $_SERVER['QUERY_STRING'] and $GLOBALS["HTTP_RAW_POST_DATA"] They are all contents without result decoding.

$postStr = str_replace("%22", """, $postStr);

Just replace.

The above introduces the "problem" of PHP parsing URL encoding, including aspects of the content. I hope it will be helpful to friends who are interested in PHP tutorials.

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Previous article:nginx+gunicorn+djangoNext article:nginx+gunicorn+django