在网站中配置MIME类型

 经常会遇到这样的情况,某种类型的文件不能够正常下载,*.7z,自定义的文件类型等,需要在配置文件里配置后才能正常下载。

打开Web.Config文件:

  <system.webServer>
    <staticContent>
      <remove fileExtension=".exe.config" />
      <mimeMap fileExtension=".pdb" mimeType="text/xml" />
      <mimeMap fileExtension=".config" mimeType="application/msaccess" />
      <mimeMap fileExtension=".log" mimeType="text/xml" />
    </staticContent>
  </system.webServer>

 

posted on 2014-11-13 11:37  qiu2013  阅读(1814)  评论(0编辑  收藏  举报

导航