简体   繁体   English

从HTTP页面通过HTTPS获取JS文件

[英]Get JS file via HTTPS from a HTTP page

Okay, so what are the ramifications of getting a JS file via an HTTPS call while on a HTTP page. 好的,那么在HTTP页面上通过HTTPS调用获取JS文件的后果是什么呢? I assume it would just be a little bit of extra overhead. 我认为它只是一点额外的开销。 Would there be any warnings about this call from any certain browser? 是否会从任何某个浏览器发出有关此呼叫的警告?

Don't ask why. 不要问为什么。 It's just hypothetical. 这只是假设。

There shouldn't be any warnings in any browser. 任何浏览器都不应该有任何警告。 You can try it out this URL - http://www.530geeks.com/mixed-content.html . 您可以尝试使用此URL - http://www.530geeks.com/mixed-content.html I tested with ie6 and firefox 3.5, they don't complain. 我用ie6和firefox 3.5测试过,他们不抱怨。

Its logical too - the host page is being served over http, there is no implied trust with the connection. 它的逻辑性 - 主机页面通过http提供,对连接没有隐含的信任。 So there is nothing to warn the user. 所以没有什么可以警告用户。

这可能会触发Internet Explorer中的“安全和不安全混合”内容警报。

Sometimes IE (and maybe other browsers) get nervous and complain about pages having a mix of secure and insecure content. 有时,IE(以及其他浏览器)会感到紧张,并抱怨有安全和不安全内容混合的网页。 Whether what you're doing would cause that would require a simple test. 你正在做什么会导致这需要一个简单的测试。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM