diff options
| author | Hannah Isopod <me@bathynomus.xyz> | 2025-05-10 03:03:58 -0600 |
|---|---|---|
| committer | Hannah Isopod <me@bathynomus.xyz> | 2025-05-10 03:03:58 -0600 |
| commit | eb61c1bae2ffad114e17393d91d86fb00d7ac8cd (patch) | |
| tree | 4f997d73e0843dab760e5d988679a1a86b76f5da /chromealert.php | |
| parent | 4b9500ddeedbea21f80f41dfe4149cf3bf9be4c3 (diff) | |
Initialer commit
Just remade the repo because I don't *need* need a comprehensive source history for my personal website and this is easier than getting filter-repo to work good
Diffstat (limited to 'chromealert.php')
| -rw-r--r-- | chromealert.php | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/chromealert.php b/chromealert.php new file mode 100644 index 0000000..087bbf4 --- /dev/null +++ b/chromealert.php @@ -0,0 +1,21 @@ +<?php + +if($_GET['donotsee'] === 'yes') { + setcookie( + "niceopodNoChromiumWarning", + "true", + time() + 60 * 60 * 24 * 365 * 5, + "/", + $_SERVER['HTTP_HOST'], + false, + true + ); + header("Location: " . $_GET['originalpage']); +} else if($_SERVER["REQUEST_URI"] == "/chromealert.php") { + http_response_code(403); + die(); +} else if (preg_match('/(chrome|opera|edge|brave)/i', $_SERVER['HTTP_USER_AGENT']) && !preg_match('/(headlesschrome)/i', $_SERVER['HTTP_USER_AGENT']) && $_COOKIE['niceopodNoChromiumWarning'] !== "true") { + $ogpg = $_SERVER['REQUEST_URI']; + echo "<style type='text/css'>#cacb { margin-right: 0.7rem; padding: 0; border: none; background: none; font-size: 0; display: flex; justify-content: center; align-items: center; } #cacb:hover { cursor: pointer; } #chromealert { width: min(40rem, 90vw); z-index: 100000; display: none; position: fixed; top: 1rem; left: 50%; transform: translateX(-50%); background-color: #ffcccc; box-shadow: 3px 3px 3px black; padding: .7rem; border-radius: .7rem; text-shadow: none; color: black; } #cadc:checked + #chromealert { display: flex; } #cadc { display: none; } #chromealert a { color: #df1955; } </style> <input type='checkbox' name='cadc' id='cadc' checked> <div id='chromealert'> <label for='cadc' id='cacb'><svg xmlns='http://www.w3.org/2000/svg' viewBox='-6 -6 24 24' width='24' fill='currentColor'><path d='M7.314 5.9l3.535-3.536A1 1 0 1 0 9.435.95L5.899 4.485 2.364.95A1 1 0 1 0 .95 2.364l3.535 3.535L.95 9.435a1 1 0 1 0 1.414 1.414l3.535-3.535 3.536 3.535a1 1 0 1 0 1.414-1.414L7.314 5.899z'></path></svg></label> <div>It seems you're using a browser based on Google Chrome. Chrome itself is effectively spyware, but even if you're using <a href='https://en.wikipedia.org/wiki/List_of_web_browsers#Blink-based'>something else</a> Google still controls the engine and there are <a href='https://www.cnet.com/tech/computing/chrome-banishes-jpeg-xl-photo-format-that-could-save-phone-space/'>various</a> <a href='https://arstechnica.com/gadgets/2022/01/google-drops-floc-after-widespread-opposition-pivots-to-topics-api-plan/'>compelling</a> <a href='https://www.theverge.com/2022/6/10/23131029/mozilla-ad-blocking-firefox-google-chrome-privacy-manifest-v3-web-request'>reasons</a> to avoid that. I recommend switching to <a href='https://www.mozilla.org/en-US/firefox/new/'>Firefox</a> or <a href='https://librewolf.net/'>Librewolf</a>.</div> </div>"; +} +?>
\ No newline at end of file |
