Redirect to SSL

Chris Coyier on
window.location = "https://" + window.location.hostname + window.location.pathname + window.location.search;

You might wanna test if window.location.href doesn’t start with “https” before doing that, so you don’t redirect unless you have to.