我想知道我的浏览器当前使用什么 IP 地址来访问网站的主机。
在大多数情况下,我可能会使用诸如ping显示操作系统认为的 IP 之类的工具,但至少在一种情况下,Firefox 可能不同意操作系统使用的内容。
ping
热门搜索结果似乎发现 Mozilla 支持线程基本上推荐附加组件,但我不想信任附加组件,而且我不知道它们是否一定会报告 Firefox 内部使用的相同 IP。
firefox
我已在我的文件中设置foo.com为(位于 Windows 上的此处:)。127.0.0.1/etc/hostsC:\Windows\System32\drivers\etc\hosts
foo.com
127.0.0.1
/etc/hosts
C:\Windows\System32\drivers\etc\hosts
虽然Chrome使用端口 80 上本地托管的加载 foo.com,但Firefox加载实际的foo.com。
如何让 Firefox 加载我本地指向的 foo.com?
firefox google-chrome hosts localhost hosts-file
firefox ×2
google-chrome ×1
hosts ×1
hosts-file ×1
localhost ×1