stanley1610
Programmer
I customized Tomcat to list files of a folder by editing web.xml
<servlet>
<servlet-name>listing</servlet-name>
<servlet-class>org.apache.catalina.servlets.DefaultServlet</servlet-class>
<init-param>
<param-name>debug</param-name>
<param-value>0</param-value>
</init-param>
<init-param>
<param-name>listings</param-name>
<param-value>true</param-value>
</init-param>
<load-on-startup>1</load-on-startup>
</servlet>
However, if the file name is non English characters such as Chinese and Japanese, it will be shown as strange characters and it prompts an error page if I click the file name.
How can I solve it?
<servlet>
<servlet-name>listing</servlet-name>
<servlet-class>org.apache.catalina.servlets.DefaultServlet</servlet-class>
<init-param>
<param-name>debug</param-name>
<param-value>0</param-value>
</init-param>
<init-param>
<param-name>listings</param-name>
<param-value>true</param-value>
</init-param>
<load-on-startup>1</load-on-startup>
</servlet>
However, if the file name is non English characters such as Chinese and Japanese, it will be shown as strange characters and it prompts an error page if I click the file name.
How can I solve it?