Unsecure refrence to jquery


(Michael Berg) #1

I updated my site name to include https from http and while 99% of the code is ok when I view page source I see the an Item that I think is causing the alert issue as it has http in it.

script type=‘text/javascript’ src=‘http://code.jquery.com/jquery-1.8.3.min.js

is there a way to tell RW to change that to https or to not refer to it there? I suppose its possible that was inserted by rapid cart?


(Nik Fletcher) #2

You’d need to contact the developer of the appropriate stack (or Stacks itself) to ensure this updated.

—Nik


(William Davis) #3

The external solution is to Show Contents of the specific theme (Themes, then right-click to Show Contents), and then physically alter the address on the HTML file.

The internal solution, however, could be mitigated by JavaScript in RapidWeaver.
Under Inspector > HTML > JavaScript:

$(document).ready(function() { 
    	$('script[src*="http://code.jquery.com/jquery-1.8.3.min.js"]').attr('src','https://code.jquery.com/jquery-1.8.3.min.js');
    });

This snippet will find any script containing the specified address, then replace it with the new one. If you intend on indefinitely deferring it, you can substitute ‘attr()’ for ‘remove()’.

See if that works.