当我的页面加载了https
时,我的相对链接仍在尝试通过http加载。当我尝试使用https转到脚本时脚本就在那里并加载但不会在页面上加载。
Mixed Content: The page at 'https://site-qa-cloned.us-east-2.elasticbeanstalk.com/' was loaded over HTTPS, but requested an insecure script 'http://site-qa-cloned.us-east-2.elasticbeanstalk.com/public_html/scripts/lib/stripe.js'. This request has been blocked; the content must be served over HTTPS.
简单的脚本加载。我也尝试了//public_html...
,它会尝试在http://public_html/..
找到该脚本,但不会更改协议。
<script src="public_html/scripts/lib/stripe.js"></script>
的.htaccess
RewriteEngine on
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule . index.php [L]