Does JavaScript work on SSL?

robertdn

Moderator
Hello everybody,

While enabling SSL on my website, I noticed that Login Control created with JavaScript no longer appeared, yet if I browse the website without SSL, the control is present.
What am I doing wrong and how do I fix this problem?

Thank you for your assistance.
 

elcidofaguy

Active Member
I cant say for sure but it sounds to me that the Javascript is referencing a non secure URL i.e. non https version... I would check the code for URLs which reference your site and change them to the https version...
 
Be sure that your Javascript is being loaded correctly to function on both SSL and Non-SSL;

i.e.

Code:
<script src="//www.domain.com/script.js"></script>

INSTEAD OF

Code:
<script src="http://www.domain.com/script.js"></script>

Be sure to do this for all images/css as well, otherwise you will be provided with a warning that there is insecure content on the website.
 
Top