Answers for "js https redirect"

0

js https redirect

if (location.protocol !== 'https:') {
    location.replace(`https:${location.href.substring(location.protocol.length)}`);
}
Posted by: Guest on August-27-2021

Code answers related to "Javascript"

Browse Popular Code Answers by Language