首页 > 其他 > 详细

浏览器报Mixed Content错误的解决

时间:2020-01-07 19:47:10      阅读:152      评论:0      收藏:0      [点我收藏+]

正常来说一个网页中要么全部使用http,要么全部使用https 但是偶尔有些不完善的库自己会写死了调用的链接。

技术分享图片

一个简单的方法是在网页的head下加入下面这句

<meta http-equiv="Content-Security-Policy" content="upgrade-insecure-requests">

这将会把http请求转化为https请求。这样就不会再出现Mixed Content的错误了。

浏览器报Mixed Content错误的解决

原文:https://www.cnblogs.com/sexintercourse/p/12162884.html

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!