Html 在 Chrome 中,查看文档 MIME 类型的最简单方法是什么?
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/15148497/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
In Chrome, what's the simplest way to view the mime type of a document?
提问by Matthew Butterick
In Firefox, you can select "View Page Info" from the right-click menu, and the mime type will be displayed.
在 Firefox 中,您可以从右键菜单中选择“查看页面信息”,将显示 MIME 类型。
But the same "View Page Info" command in Chrome does not show the mime type.
但是 Chrome 中相同的“查看页面信息”命令不显示 mime 类型。
Feels like I'm overlooking something obvious.
感觉就像我忽略了一些明显的东西。
采纳答案by ?ukasz Wojciechowski
Hit F12
and then go to Network tab. If you want html document then narrow the filter to Documents (on the bottom).
点击F12
然后转到网络选项卡。如果你想要 html 文档,那么将过滤器缩小到文档(在底部)。
回答by Prancer
Earlier & later versions of Chrome may be slightly different
早期和更高版本的 Chrome 可能略有不同
Chrome v50.0.2661.102 m
Chrome v50.0.2661.102米
To open Chromes developer tools (several options):
要打开 Chromes 开发人员工具(几个选项):
- Menu -> More Tools -> Developer Tools
Ctrl + Shift + I
- Hit the
F12
key
- 菜单 -> 更多工具 -> 开发者工具
Ctrl + Shift + I
- 敲
F12
关键
Once open, select the Networktab, select the name of the resource on the lefthand side, then hit the Headerstab. Under Response Headersfind Content-Typewhich is your mime type.
打开后,选择“网络”选项卡,在左侧选择资源名称,然后点击“标题”选项卡。在Response Headers 下找到Content-Type,这是您的 MIME 类型。
With images you can select the Previewtab and you will be able to see some information about the resource, including the mime type, located at the bottom of the developer window.
对于图像,您可以选择“预览”选项卡,您将能够在开发人员窗口底部看到有关资源的一些信息,包括 MIME 类型。