這個其實是在web
<mime
<extension>doc</extension>
<mime
</mime
<mime
<extension>xls</extension>
<mime
</mime
<mime
<extension>pdf</extension>
<mime
</mime
<mime
<extension>zip</extension>
<mime
</mime
<mime
<extension>rar</extension>
<mime
</mime
<mime
<extension>txt</extension>
<mime
</mime
<mime
<extension>chm</extension>
<mime
</mime
這樣就可以防止在浏覽器是直接打開文件
From:http://tw.wingwit.com/Article/program/Java/hx/201311/26610.html