Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我们有在 iis6 中完美运行的扩展较少的图像。但是,在 IIS7.5 中,即使添加了静态文件处理程序,我也无法让它显示图像。我在 IIS7.5 的属性中勾选了静态内容选项,服务器的操作系统是 Windows Server 2008 R2。带有扩展名的图像文件正确可见。但是,那些没有扩展名的人在提琴手中给了我 404。还为 .* 文件扩展名添加了 mime 类型 application/octet-stream
自己找到了答案。我们需要在 ExtensionlessUrlHandler 之上有静态文件模块。
这很有效,现在我也可以看到我的无扩展图像了。