Home > Article > Backend Development > How to solve garbled URL in php
php method to solve the garbled URL:
In HTML, transfer the data to the URL
When I click "Submit Reply", the jump page will display:
We get this parameter:
But since the parameters passed are in Chinese, the url will be automatically parsed into binary codes, then the data we receive in the background is parsed:
Then How do we solve it? PHP provides us with a function: urldecode(). We can just parse it in the receiving page:
Output effect:
Related references:php中文网
The above is the detailed content of How to solve garbled URL in php. For more information, please follow other related articles on the PHP Chinese website!