开发页面在本地跑挺正常
http://localhost:8080/#/textCheck
但是上到服务器挂到域名下就不行了
testhttps://www.maogoujiaoliuqi.com/#/textCheck
错误提示如下
xhr.js:210 Mixed Content: The page at 'https://www.maogoujiaoliuqi.com/#/textCheck' was loaded over HTTPS, but requested an insecure XMLHttpRequest endpoint 'http://api.maogoujiaoliuqi.com/maomao/v1/check/text'. This request has been blocked; the content must be served over HTTPS.
实际是因为页面是https 的,但是里面的请求时http 的,所以只需要把页面中的请求也换成https 就行了。