【问题标题】:Firefox not able to open subdomainsFirefox 无法打开子域
【发布时间】:2015-12-06 14:04:14
【问题描述】:

我有一个以 express 作为后端的 nodejs 应用程序,它在 localhost 上运行。我有与之关联的子域,例如user1.localhost。这些子域在 Chrome 中打开,但 Firefox 抛出 Server Not Found 错误。

Firefox 是否需要一些配置来允许子域?

【问题讨论】:

标签: node.js google-chrome firefox express


【解决方案1】:

我认为原因是 Chrome 在内部将 *.localhost 解析为 localhost ,而其他浏览器请求 DNS 服务器获取 subdomain.localhost (显然失败了)。您可以使用 hosts 文件使其适用于他们。

Chrome 这样做是出于安全原因,您可以阅读更多关于它的信息here

【讨论】:

    猜你喜欢
    • 2015-12-05
    • 1970-01-01
    • 2014-10-28
    • 2021-09-14
    • 1970-01-01
    • 2018-02-16
    • 2017-05-24
    • 1970-01-01
    • 2017-08-02
    相关资源
    最近更新 更多