1: Make sure your system is UTF coded
[Root@tserver ~]# env|grep LANG
lang=en_us. UTF-8
The default encoding in the 2:nginx configuration file is set to Utf-8
Server
{
listen;
server_name. inginx.com;
Index index.html index.htm index.php;
root/usr/local/nginx/html/inginx.com;
CharSet utf-8;
}
If you are uploading files with SECURECRT, please select the –> appearance –utf-8
If the FTP software also sets the default encoding to TUF-8
3. Convert UTF-8 filename to UTF-8 encoding
The advantage of using Nginx is the ability to use the Chinese URL, but the file name of Windows is GBK by default, and you need to convert it.
The procedure is very simple, the file name is modified to UTF8 code on it! "But Apache doesn't need to be so troublesome."
Install CONVMV, by which he goes to convert the code:
Yum install convmv-y
convmv-f gbk-t utf8-r Target Destination Path
Where-f is the source code,-T is the target encoding,-R is a recursive directory,--notest is not moving, actually renaming the file, target is the destination directory
In the case of Windows operating system, you can disregard this method, general Windows under the use of Nginx forwarding is not the case, the method of the approach is only for Linux under the operation.