This commit is contained in:
2025-02-05 03:51:15 +05:30
parent c4c8ba334e
commit 7977ddc04e
31 changed files with 643 additions and 513 deletions

View File

@@ -1,14 +1,3 @@
window.addEventListener('scroll', function () {
const header = document.querySelector('.header'); // Get the header element
// Check if the page has been scrolled
if (window.scrollY > 0) {
header.classList.add('scrolled'); // Add the "scrolled" class
} else {
header.classList.remove('scrolled'); // Remove the "scrolled" class
}
});
const form = document.querySelector(".shorten-form"),
urlInput = document.querySelector("#url-input"),
shortenBtn = document.querySelector("#shorten-btn"),
@@ -47,7 +36,7 @@ shortenBtn.onclick = () => {
let data = xhr.response;
if (data.length <= 5) {
//This is your domain name
const domain = "xeorl.buzz/";
const domain = "http://localhost/Php-Projects/xeorl/htdocs/";
let shortenURL = domain + data;
// Remove the default message if it exists