Mixed Content: The page at ‘<URL>‘ was loaded over HTTPS, but requested an insecure frame ‘<URL>‘...

简介: Mixed Content: The page at ‘<URL>‘ was loaded over HTTPS, but requested an insecure frame ‘<URL>‘...

在添加了SSL证书的HTTPS中引入用HTTP的链接,就报错,请求协议的不同导致的



所有有关https带有http的文件或者链接例如:images / js等文件都会报请求



“网页的“ < url > ”是通过 HTTPS 加载的,但是请求一个不安全的帧“ < url > ”。此请求已被阻止; 内容必须通过 HTTPS 提供。”



20201026134542431.png


解决方法:


第一种:查看http的文件,放到https路径中,引入方式添加https



第二种 页面的head中加入: <meta http-equiv="Content-Security-Policy" content="upgrade-insecure-requests">意思是自动将http的不安全请求升级为https (注意尽在需要的地方引入)



结合第一二种一起解决


相关文章
|
27天前
|
JavaScript
【干货】js判断url是否是合法http/https
【干货】js判断url是否是合法http/https
57 1
|
11天前
|
Web App开发 前端开发
canvas保存图片时,谷歌浏览器Chrome报错【解决方案】Not allowed to navigate top frame to data URL
canvas保存图片时,谷歌浏览器Chrome报错【解决方案】Not allowed to navigate top frame to data URL
8 0
|
2月前
|
存储 Linux
linux上SVN出现 "Unable to connect to a repository at URL 'svn://xx.xx.xx.xx/xxx' 和 No repository ...
centos上安装了svn, 有时候会不知道什么原因出现客户端小乌龟无法连接或无法提交等情况
31 5
|
2月前
解决Error:All flavors must now belong to a named flavor dimension. Learn more at https://d.android.com
解决Error:All flavors must now belong to a named flavor dimension. Learn more at https://d.android.com
38 5
|
数据安全/隐私保护 Python
解决CondaHTTPError:HTTP 000 CONNECTION FAILED for url<https://mirrors.tuna.tsinghua.edu.cn/anaconda***
今天做项目的时候,Python导入一个包一直有各类问题,而后最终锁定问题是CondaHTTPError:HTTP 000 CONNECTION FAILED for url<https://mirrors.tuna.tsinghua.edu.cn/anaconda*** 这就是清华的源出问题了,配置没配对。
解决CondaHTTPError:HTTP 000 CONNECTION FAILED for url<https://mirrors.tuna.tsinghua.edu.cn/anaconda***
|
9月前
|
存储 XML 数据格式
【SVN异常】svn: E175003: The server at ‘https://svn.example.com/!/%23MyRepo/‘ does not support the HTTP/
【SVN异常】svn: E175003: The server at ‘https://svn.example.com/!/%23MyRepo/‘ does not support the HTTP/
169 0
|
9月前
|
JSON 前端开发 JavaScript
什么是 HTTP Over the wire
什么是 HTTP Over the wire
|
11月前
|
安全 网络协议 Ubuntu
解决CondaHTTPError: HTTP 000 CONNECTION FAILED for url <https://mirrors.tuna.tsinghua.edu.cn/anaconda/
解决CondaHTTPError: HTTP 000 CONNECTION FAILED for url <https://mirrors.tuna.tsinghua.edu.cn/anaconda/
2123 0
|
前端开发 JavaScript
【WEB前端】【报错解决】This request has been blocked; the content must be served over HTTPS.
【WEB前端】【报错解决】This request has been blocked; the content must be served over HTTPS.
763 0
|
网络协议 安全 前端开发
【网络小知识】当我在浏览器url输入文本后的解析流程/http协议对比https协议
当我在浏览器url输入文本后的解析流程/http协议对比https协议