whoami7 - Manager
:
/
home
/
n170823s
/
www
/
aelaw
/
js
/
Upload File:
files >> /home/n170823s/www/aelaw/js/custom.js
var swiper = new Swiper(".testimonialsSwiper", { pagination: { el: ".swiper-pagination", }, }); var swiper = new Swiper(".partnershipsSwiper", { slidesPerView: 2, spaceBetween: 24, navigation: { nextEl: ".partnerships-n", prevEl: ".partnerships-p", }, breakpoints: { 640: { slidesPerView: 3, }, 768: { slidesPerView: 4, }, 1024: { slidesPerView: 5, }, }, }); // Header load fetch('header.html') .then(response => response.text()) .then(data => { document.getElementById('header').innerHTML = data; }); // Footer load fetch('footer.html') .then(response => response.text()) .then(data => { document.getElementById('footer').innerHTML = data; }); // Get current page file name (e.g. "business-trading.html") const currentPage = window.location.pathname.split("/").pop() || "index.html"; // Add .active to direct nav links document.querySelectorAll(".nav-link").forEach(link => { const href = link.getAttribute("href"); if (href === currentPage) { link.classList.add("active"); } }); // If it's a sub-page of dropdown, highlight the parent menu const dropdownPages = [ "business-trading.html", "family-matters.html", "private-litigation.html", "property-conveyancing.html", "employment-issues.html", "wills-probate.html", "immigration.html" ]; if (dropdownPages.includes(currentPage)) { const parentLink = document.querySelector('a[href="what-we-do.html"]'); if (parentLink) parentLink.classList.add("active"); }
Copyright ©2021 || Defacer Indonesia