`

WEB.XML

阅读更多
上传图片推荐使用png, jpg, gif等类型
MIME-MAPPING
<mime-mapping extension=".html" mime-type="text/html"/>
  <mime-mapping extension=".ai" mime-type="application/postscript"/>
  <mime-mapping extension=".aif" mime-type="audio/x-aiff"/>
  <mime-mapping extension=".aiff" mime-type="audio/x-aiff"/>
  <mime-mapping extension=".aifc" mime-type="audio/x-aiff"/>
  <mime-mapping extension=".au" mime-type="audio/basic"/>
  <mime-mapping extension=".asc" mime-type="text/plain"/>
  <mime-mapping extension=".asf" mime-type="video/x-ms-asf"/>
  <mime-mapping extension=".asx" mime-type="video/x-ms-asf"/>
  <mime-mapping extension=".atom" mime-type="application/atom+xml"/>
  <mime-mapping extension=".avi" mime-type="video/x-msvideo"/>
  <mime-mapping extension=".bin" mime-type="application/octet-stream"/>
  <mime-mapping extension=".bcpio" mime-type="application/x-bcpio"/>
  <mime-mapping extension=".bmp" mime-type="image/bmp"/>
  <mime-mapping extension=".class" mime-type="application/octet-stream"/>
  <mime-mapping extension=".cpt" mime-type="application/mac-compactpro"/>
  <mime-mapping extension=".css" mime-type="text/css"/>
  <mime-mapping extension=".cpio" mime-type="application/x-cpio"/>
  <mime-mapping extension=".csh" mime-type="application/x-csh"/>
  <mime-mapping extension=".cdf" mime-type="application/x-netcdf"/>
  <mime-mapping extension=".dmg" mime-type="application/octet-stream"/>
  <mime-mapping extension=".dms" mime-type="application/octet-stream"/>
  <mime-mapping extension=".doc" mime-type="application/msword"/>
  <mime-mapping extension=".dcr" mime-type="application/x-director"/>
  <mime-mapping extension=".dir" mime-type="application/x-director"/>
  <mime-mapping extension=".dll" mime-type="application/x-msdownload"/>
  <mime-mapping extension=".dxr" mime-type="application/x-director"/>
  <mime-mapping extension=".dvi" mime-type="application/x-dvi"/>
  <mime-mapping extension=".exe" mime-type="application/octet-stream"/>
  <mime-mapping extension=".eps" mime-type="application/postscript"/>
  <mime-mapping extension=".etx" mime-type="text/x-setext"/>
  <mime-mapping extension=".gram" mime-type="application/srgs"/>
  <mime-mapping extension=".grxml" mime-type="application/srgs+xml"/>
  <mime-mapping extension=".gtar" mime-type="application/x-gtar"/>
  <mime-mapping extension=".gif" mime-type="image/gif"/>
  <mime-mapping extension=".gz" mime-type="application/octet-stream"/>
  <mime-mapping extension=".hdml" mime-type="text/x-hdml"/>
  <mime-mapping extension=".hqx" mime-type="application/mac-binhex40"/>
  <mime-mapping extension=".html" mime-type="text/html"/>
  <mime-mapping extension=".htm" mime-type="text/html"/>
  <mime-mapping extension=".hdf" mime-type="application/x-hdf"/>
  <mime-mapping extension=".ief" mime-type="image/ief"/>
  <mime-mapping extension=".ice" mime-type="x-conference/x-cooltalk"/>
  <mime-mapping extension=".jar" mime-type="application/java-archive"/>
  <mime-mapping extension=".jnlp" mime-type="application/x-java-jnlp-file"/>
  <mime-mapping extension=".jpeg" mime-type="image/jpeg"/>
  <mime-mapping extension=".jpg" mime-type="image/jpeg"/>
  <mime-mapping extension=".jpe" mime-type="image/jpeg"/>
  <mime-mapping extension=".js" mime-type="application/x-javascript"/>
  <mime-mapping extension=".kar" mime-type="audio/midi"/>
  <mime-mapping extension=".latex" mime-type="application/x-latex"/>
  <mime-mapping extension=".lha" mime-type="application/octet-stream"/>
  <mime-mapping extension=".lhz" mime-type="application/octet-stream"/>
  <mime-mapping extension=".mathml" mime-type="application/mathml+xml"/>
  <mime-mapping extension=".mid" mime-type="audio/midi"/>
  <mime-mapping extension=".mif" mime-type="application/vnd.mif"/>
  <mime-mapping extension=".mpeg" mime-type="video/mpeg"/>
  <mime-mapping extension=".mpg" mime-type="video/mpeg"/>
  <mime-mapping extension=".mpe" mime-type="video/mpeg"/>
  <mime-mapping extension=".mov" mime-type="video/quicktime"/>
  <mime-mapping extension=".movie" mime-type="video/x-sgi-movie"/>
  <mime-mapping extension=".mpga" mime-type="audio/mpeg"/>
  <mime-mapping extension=".mp2" mime-type="audio/mpeg"/>
  <mime-mapping extension=".mp3" mime-type="audio/mpeg"/>
  <mime-mapping extension=".man" mime-type="application/x-troff-man"/>
  <mime-mapping extension=".me" mime-type="application/x-troff-me"/>
  <mime-mapping extension=".ms" mime-type="application/x-troff-ms"/>
  <mime-mapping extension=".nc" mime-type="application/x-netcdf"/>
  <mime-mapping extension=".oda" mime-type="application/oda"/>
  <mime-mapping extension=".ogg" mime-type="application/ogg"/>
  <mime-mapping extension=".pdf" mime-type="application/pdf"/>
  <mime-mapping extension=".ps" mime-type="application/postscript"/>
  <mime-mapping extension=".ppt" mime-type="application/vnd.ms-powerpoint"/>
  <mime-mapping extension=".png" mime-type="image/png"/>
  <mime-mapping extension=".pgn" mime-type="application/x-chess-pgn"/>
  <mime-mapping extension=".pnm" mime-type="image/x-portable-anymap"/>
  <mime-mapping extension=".pbm" mime-type="image/x-portable-bitmap"/>
  <mime-mapping extension=".pgm" mime-type="image/x-portable-graymap"/>
  <mime-mapping extension=".ppm" mime-type="image/x-portable-pixmap"/>
  <mime-mapping extension=".qt" mime-type="video/quicktime"/>
  <mime-mapping extension=".ra" mime-type="audio/x-realaudio"/>
  <mime-mapping extension=".ram" mime-type="audio/x-pn-realaudio"/>
  <mime-mapping extension=".rdf" mime-type="application/rdf+xml"/>
  <mime-mapping extension=".rm" mime-type="audio/x-pn-realaudio"/>
  <mime-mapping extension=".rpm" mime-type="audio/x-pn-realaudio-plugin"/>
  <mime-mapping extension=".ras" mime-type="image/x-cmu-raster"/>
  <mime-mapping extension=".rgb" mime-type="image/x-rgb"/>
  <mime-mapping extension=".rtf" mime-type="application/rtf"/>
  <mime-mapping extension=".rtx" mime-type="text/richtext"/>
  <mime-mapping extension=".rtf" mime-type="text/rtf"/>
  <mime-mapping extension=".smi" mime-type="application/smil"/>
  <mime-mapping extension=".smil" mime-type="application/smil"/>
  <mime-mapping extension=".sml" mime-type="application/smil"/>
  <mime-mapping extension=".skp" mime-type="application/x-koan"/>
  <mime-mapping extension=".skd" mime-type="application/x-koan"/>
  <mime-mapping extension=".skt" mime-type="application/x-koan"/>
  <mime-mapping extension=".skm" mime-type="application/x-koan"/>
  <mime-mapping extension=".src" mime-type="application/x-wais-source"/>
  <mime-mapping extension=".sh" mime-type="application/x-sh"/>
  <mime-mapping extension=".shar" mime-type="application/x-shar"/>
  <mime-mapping extension=".swf" mime-type="application/x-shockwave-flash"/>
  <mime-mapping extension=".sit" mime-type="application/x-stuffit"/>
  <mime-mapping extension=".so" mime-type="application/octet-stream"/>
  <mime-mapping extension=".spl" mime-type="application/x-futuresplash"/>
  <mime-mapping extension=".sv4cpio" mime-type="application/x-sv4cpio"/>
  <mime-mapping extension=".sv4crc" mime-type="application/x-sv4crc"/>
  <mime-mapping extension=".snd" mime-type="audio/basic"/>
  <mime-mapping extension=".sgml" mime-type="text/sgml"/>
  <mime-mapping extension=".sgm" mime-type="text/sgml"/>

  <mime-mapping extension=".t" mime-type="application/x-troff"/>
  <mime-mapping extension=".tar" mime-type="application/x-tar"/>
  <mime-mapping extension=".tcl" mime-type="application/x-tcl"/>
  <mime-mapping extension=".tex" mime-type="application/x-tex"/>
  <mime-mapping extension=".texi" mime-type="application/x-texinfo"/>
  <mime-mapping extension=".texinfo" mime-type="application/x-texinfo"/>
  <mime-mapping extension=".tgz" mime-type="application/octet-stream"/>
  <mime-mapping extension=".tiff" mime-type="image/tiff"/>
  <mime-mapping extension=".tif" mime-type="image/tiff"/>
  <mime-mapping extension=".torrent" mime-type="application/x-bittorrent"/>
  <mime-mapping extension=".tr" mime-type="application/x-troff"/>
  <mime-mapping extension=".troff" mime-type="application/x-troff"/>
  <mime-mapping extension=".tsv" mime-type="text/tab-separated-values"/>
  <mime-mapping extension=".txt" mime-type="text/plain"/>

  <mime-mapping extension=".ustar" mime-type="application/x-ustar"/>
  <mime-mapping extension=".vcd" mime-type="application/x-cdlink"/>
  <mime-mapping extension=".vrml" mime-type="model/vrml"/>
  <mime-mapping extension=".wav" mime-type="audio/x-wav"/>
  <mime-mapping extension=".wax" mime-type="audio/x-ms-wax"/>
  <mime-mapping extension=".wbmp" mime-type="image/vnd.wap.wbmp"/>
  <mime-mapping extension=".wbxml" mime-type="application/vnd.wap.wbxml"/>
  <mime-mapping extension=".wrl" mime-type="model/vrml"/>
  <mime-mapping extension=".wm" mime-type="audio/x-ms-wm"/>
  <mime-mapping extension=".wma" mime-type="audio/x-ms-wma"/>
  <mime-mapping extension=".wmd" mime-type="application/x-ms-wmd"/>
  <mime-mapping extension=".wmz" mime-type="application/x-ms-wmz"/>
  <mime-mapping extension=".wml" mime-type="text/vnd.wap.wml"/>
  <mime-mapping extension=".wmls" mime-type="text/vnd.wap.wmlscript"/>
  <mime-mapping extension=".wmlc" mime-type="application/vnd.wap.wmlc"/>
  <mime-mapping extension=".wmlsc" mime-type="application/vnd.wap.wmlscript"/>
  <mime-mapping extension=".wmv" mime-type="audio/x-ms-wmv"/>
  <mime-mapping extension=".wvx" mime-type="video/x-ms-wvx"/>
  <mime-mapping extension=".xls" mime-type="application/vnd.ms-excel"/>
  <mime-mapping extension=".xbm" mime-type="image/x-xbitmap"/>
  <mime-mapping extension=".xml" mime-type="text/xml"/>
  <mime-mapping extension=".xpm" mime-type="image/x-xpixmax"/>
  <mime-mapping extension=".xsl" mime-type="text/xml"/>
  <mime-mapping extension=".xwd" mime-type="image/x-xwindowdump"/>
  <mime-mapping extension=".zip" mime-type="application/zip"/>
  <mime-mapping extension=".z" mime-type="application/octet-stream"/>


<web-app>
      <mime-mapping>
        <extension>txt</extension>
        <mime-type>application/octet-stream</mime-type>
      </mime-mapping>
     
      <mime-mapping>
        <extension>dat</extension>
        <mime-type>application/octet-stream</mime-type>
      </mime-mapping>
       
      <mime-mapping>
        <extension>csv</extension>
        <mime-type>application/octet-stream</mime-type>
      </mime-mapping> 
 
      <mime-mapping>
        <extension>rar</extension>
        <mime-type>application/octet-stream</mime-type>
      </mime-mapping>   

      <mime-mapping>
        <extension>rmvb</extension>
        <mime-type>application/octet-stream</mime-type>
      </mime-mapping>   

      <mime-mapping>
        <extension>avi</extension>
        <mime-type>application/octet-stream</mime-type>
      </mime-mapping>   

      <mime-mapping>
        <extension>ppt</extension>
        <mime-type>application/octet-stream</mime-type>
      </mime-mapping>
       
      <mime-mapping>
        <extension>doc</extension>
        <mime-type>application/octet-stream</mime-type>
      </mime-mapping>

      <mime-mapping>
        <extension>xls</extension>
        <mime-type>application/octet-stream</mime-type>
      </mime-mapping> 
     
      <mime-mapping>
        <extension>flv</extension>
        <mime-type>application/octet-stream</mime-type>
      </mime-mapping>
     
    <mime-mapping>
        <extension>docx</extension>
        <mime-type>application/vnd.openxmlformats</mime-type>
      </mime-mapping>
     
      <mime-mapping>
        <extension>xlsx</extension>
        <mime-type>application/vnd.openxmlformats</mime-type>
      </mime-mapping>
     
      <mime-mapping>
        <extension>pptx</extension>
        <mime-type>application/vnd.openxmlformats</mime-type>
      </mime-mapping>


</web-app>
分享到:
评论

相关推荐

    在web.xml中引入其他xml配置文件的步骤

    ### 在web.xml中引入其他XML配置文件的步骤 在Java Web开发中,`web.xml`作为Web应用程序的核心配置文件,负责定义应用级别的配置信息。为了提高代码的可维护性和复用性,有时需要将一部分配置内容提取到独立的XML...

    web.xml配置详解, web.xml web.xml 配置实例

    Web.xml 配置详解 Web.xml 是一个部署描述符文件,用于描述 Web 应用程序的配置信息。该文件是基于 XML 语法的,所有的元素都是大小写敏感的。下面是 web.xml 配置文件的详细解释: 定义头和根元素 在 web.xml ...

    为tomcat服务器配置https,tomcat需要设置的server.xml与web.xml配置

    在Tomcat的`conf`目录下,有两个主要的XML配置文件:`server.xml`和`web.xml`。`server.xml`是Tomcat的主要配置文件,而`web.xml`则定义了应用程序的行为。 在`server.xml`中,我们需要配置`&lt;Connector&gt;`元素来启用...

    web.xml配置详解

    web.xml 配置详解 web.xml 配置详解是指在 Java Web 应用程序中使用的部署描述符配置文件。它是一个 XML 文件,包含了很多描述 servlet/JSP 应用的各个方面的元素,如 servlet 注册、servlet 映射以及监听器注册。 ...

    log4j与web.xml的配置

    Web.xml是Servlet容器(如Tomcat)的部署描述符,用于配置Web应用程序的各种设置,包括日志配置。本文将详细讲解如何将Log4j整合到Web应用并通过web.xml进行配置,以实现日志信息的输出和管理。 1. **Log4j介绍** ...

    web.xml 中的listener、 filter、servlet 加载顺序及其详解.doc

    Web.xml 中的 listener、filter、servlet 加载顺序及其详解 在 Web 应用程序中,web.xml 文件扮演着非常重要的角色,它定义了 Web 应用的结构和配置。其中,listener、filter、servlet 是三个非常重要的概念,它们...

    jboss-web.xml jndi.properties oracle-ds.xml

    在本案例中,"jboss-web.xml"、"jndi.properties"和"oracle-ds.xml"是针对EJB+JPA在JBoss应用服务器中的配置文件,它们各自承担着不同的职责。 首先,"jboss-web.xml"是JBoss特定的Web应用程序部署描述符,它是...

    javaweb项目中web.xml的作用

    javaweb项目中web.xml的作用 web.xml是javaweb项目中一个非常重要的配置文件,它是每一个javaWeb工程都必需的配置文件。web.xml文件的主要作用是用于初始化工程配置信息,例如welcome页面、filter、listener、...

    演示web.xml文件中error-page标签的使用.zip

    在Java Web应用中,`web.xml`文件是部署描述符(Deployment Descriptor),它定义了应用程序的行为、组件配置以及服务器如何处理请求和响应等关键信息。`error-page`标签是`web.xml`中的一个重要元素,用于处理HTTP...

    Maven工程的web.xml模板

    由于经常使用Maven创建web工程所以需要使用web.xml默认模板

    在web.xml中设置错误处理页面.docx

    在 Web.xml 中设置错误处理页面 在 JavaWeb 应用程序中,错误处理页面是一个非常重要的组件,它可以帮助开发者处理和显示异常信息,从而提供更好的用户体验。本文将讲述如何在 web.xml 文件中使用 `&lt;error-page&gt;` ...

    web.xml加载顺序与web.xml常用节点解析

    `web.xml`是Java Web应用程序的核心配置文件,用于定义应用服务器如何初始化和管理Web应用程序。它遵循Java Servlet规范中的标准,为开发者提供了一种结构化的方式来配置Servlet、过滤器、监听器和其他组件。理解`...

    项目配置文件( spring-mvc.xml spring-mybatis.xml web.xml log4j.properties)

    这里提到的四个关键配置文件——`spring-mvc.xml`、`spring-mybatis.xml`、`web.xml`以及`log4j.properties`,对于一个基于Java的Web应用来说至关重要,特别是使用Spring MVC和MyBatis框架的时候。接下来,我们将...

    WEB-INF中的web.xml中之前增加以下配置:

    WEB-INF中的web.xml配置详解 本文将详细介绍WEB-INF中的web.xml文件中的配置,包括Context配置、Resource配置、resource-ref配置,以及对应的Java类编写。 一、Context配置 在WEB-INF中的web.xml文件中,添加以下...

    在web.xml中配置action或.do

    ### 在web.xml中配置action或.do的理解与实践 #### 一、引言 在Web开发领域,特别是基于Java的Web应用程序开发中,`web.xml`文件扮演着至关重要的角色。它不仅定义了Web应用的基本配置,还管理着诸如Servlet、过滤...

    web.xml各种配置

    web.xml是Java Servlet规范定义的一个部署描述文件,用于配置Java Web应用程序。它遵循XML的规则,必须有一个唯一的根节点,大小写敏感,并且标签需要严格配对。在大型Web工程中,web.xml文件非常重要,因为它提供了...

    web.xml配置详解.pdf

    web.xml 各属性作用描述 Web.xml 常用元素 &lt;web‐app&gt; ‐name&gt;‐name&gt;定义了WEB 应用的名字 &lt;description&gt;&lt;/description&gt; 声明WEB 应用的描述信息

    DWR,web.xml,dwr.xml,converted,created

    web.xml dwr.xml 任何一个dwr.xml的文件都需要包含DWR DOCTYPE的声明行,。。 有几个术语有必要理解,参数叫做converted,远程Bean叫做created.如果远程Bean A有个方法A.blah(B),那么你需要为A建立一个created,为B建立...

    SpringMVC基于代码的配置方式(零配置,无web.xml)

    传统的SpringMVC配置往往依赖于XML文件,如web.xml和spring-servlet.xml等,但随着Spring框架的发展,出现了基于代码的配置方式,实现了零XML配置,提高了开发效率。本文将详细介绍如何在不使用web.xml的情况下,...

Global site tag (gtag.js) - Google Analytics