最近维护升级一个网站的时候发现以 https 访问网站时页面内容显示异常,打开浏览器控制台可以发现大量的报错信息。

Mixed Content: The page at ‘https://example.com’ was loaded over HTTPS, but requested an insecure stylesheet ‘http://example.com/static/css/example.css’. This request has been blocked; the content must be served over HTTPS.