Here I will introduce how to configure Tomcat to solve the problem of garbled Url with Chinese parameters;
First open the Tomcat installation directory, take Tomcat7 as an example, other versions are basically the same;
open conf file
Open server.xml
At about line 70, we add an attribute URIEncoding="UTF-8"
Do it like this. . This is the configuration method when the project is published.
The following describes how to configure when developing:
open eclipse
find server
Click on server.xml
As before, add URIEncoding="UTF-8" to support Url Chinese parameters;
Of course, there are other methods, which are more troublesome. For example, transcoding and filtering by yourself. It will not be introduced here.