Skip to content

techjacket1022/http-check

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 

Repository files navigation

HTTP Exit Script # html #javascript # Security

This simple script checks if a website is being accessed via http:// instead of https://, and automatically exits or redirects the user.

Support the project

https://www.donationalerts.com/r/techjacket1022

How It Works

When the page is opened in a browser, the JavaScript code checks the protocol. If the site is loaded using http://, it redirects to a blank page.

if (location.protocol === 'http:') {
    window.location.href = 'about:blank';
}

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages