1.提供下载文件的链接,但是点击后是直接打开,显示乱码
解决办法 在web.xml中配置
<mime-mapping>
<extension>rar</extension>
<mime-type>application/rar</mime-type>
</mime-mapping>
另外rar文件名要是中文?
2.设置weblogic的默认应用
正常的weblogic的应用url为 http://ip:port/applicationname/index.html
在web.xml中配置
<welcome-file-list>
<welcome-file>index.html</welcome-file>
</welcome-file-list>
在web-inf目录下新建weblogic.xml
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE weblogic-web-app PUBLIC "-//BEA Systems, Inc.//DTD Web Application 8.1//EN" "http://www.bea.com/servers/wls810/dtd/weblogic810-web-jar.dtd">
<weblogic-web-app>
<context-root>/</context-root>
</weblogic-web-app>
上面的url简化成http://ip:port
解决办法 在web.xml中配置
<mime-mapping>
<extension>rar</extension>
<mime-type>application/rar</mime-type>
</mime-mapping>
另外rar文件名要是中文?
2.设置weblogic的默认应用
正常的weblogic的应用url为 http://ip:port/applicationname/index.html
在web.xml中配置
<welcome-file-list>
<welcome-file>index.html</welcome-file>
</welcome-file-list>
在web-inf目录下新建weblogic.xml
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE weblogic-web-app PUBLIC "-//BEA Systems, Inc.//DTD Web Application 8.1//EN" "http://www.bea.com/servers/wls810/dtd/weblogic810-web-jar.dtd">
<weblogic-web-app>
<context-root>/</context-root>
</weblogic-web-app>
上面的url简化成http://ip:port