user1081577
user1081577

Reputation: 469

Can you load in a javascript file with HTTPS on an HTTP website?

If I have a website called http://www.example.com . Can I then load in an external javascript file truw HTTPS link like this: https://platform.twitter.com/widgets.js ?

Is this possible?

Thanks

Upvotes: 0

Views: 626

Answers (2)

MarijnS95
MarijnS95

Reputation: 4793

Do you have acces to the website? then it is fairly easy: 'import' this script on the webpage by setting the src to the url:

<script type="text/javascript" src="https://platform.twitter.com/widgets.js"></script>

Btw this goes in the head of your webpage.

Upvotes: 0

johnnycardy
johnnycardy

Reputation: 3046

Yes.

Just use a script tag as normal.

Upvotes: 1

Related Questions