Skip to content

Instantly share code, notes, and snippets.

@mrabbitt
Last active September 9, 2017 19:42
Show Gist options
  • Save mrabbitt/d4535d8078d59c1a567888e161749f17 to your computer and use it in GitHub Desktop.
Save mrabbitt/d4535d8078d59c1a567888e161749f17 to your computer and use it in GitHub Desktop.
Switch to https §
// javascript:(function%20(window)%20{if%20(window.location.protocol%20===%20%27https:%27)%20{window.alert(%27The%20current%20URL%20is%20already%20https:%20<%27%20+%20window.location.href%20+%20%27>%27);}%20else%20{window.location.protocol%20=%20%27https:%27;}})(window);
(function (window) {
if (window.location.protocol === 'https:') {
window.alert('The current URL is already https: <' + window.location.href + '>');
} else {
window.location.protocol = 'https:';
}
})(window);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment