Reputation: 92581
If I am accessing a page via https://mypage.com
if I load a script tag via <script src="/js/myscript.js"></script>
Is the above script called via http or https?
Upvotes: 3
Views: 62
Reputation: 4883
yes since the SSL certificate is applied to the page in which you request the javascript. When you connect to HTTPS it means you open a new port, so you are no longer in HTTP at the point you request that .js file. Then it will be loaded via HTTPS
Upvotes: 2