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.
我正在做一个 Ionic 2 应用程序。它使用 Angular 2。
当使用 http 对服务器进行 http 请求时,它可以工作。
当我尝试使用 https 访问服务器时,它没有。我收到一个 javascript 警报,提示“访问 https://... 不允许”
该服务器在使用常规 Web 浏览器时会发出警告:
然后单击高级并单击“继续到 10.97.222.210(不安全)”。
所以这里是我的问题:
https请求是否有特殊的Angula 2 http.get()?
提前致谢
此警告 (ERR_CERT_COMMON_NAME_INVALID) 表示您的服务器需要适当的证书来验证 https 请求。
如果您认为这不是证书问题,请尝试以下操作:
run > CMD > ipconfig /flushdns