MOON
Server: Apache
System: Linux nserver.cafsindia.com 4.18.0-553.104.1.lve.el8.x86_64 #1 SMP Tue Feb 10 20:07:30 UTC 2026 x86_64
User: cafsindia (1002)
PHP: 8.2.30
Disabled: NONE
Upload Files
File: //home/cafsindia/patroniss.com/assets/js/index.js
// for menu start mobile view
const tooglebtn     = document.querySelector('.toogle_btn')
const tooglebtnicon = document.querySelector('.toogle_btn i')
const dropdown      = document.querySelector('.drop_down')
tooglebtn.onclick = function () {
	dropdown.classList.toggle('open')
	const isOpen = dropdown.classList.contains('open')
	tooglebtnicon.classList = isOpen ? 'fa-solid fa-xmark' : 'fa-solid fa-bars'
}

// scroll inidicate while scrolling
const sections = document.querySelectorAll("section");
const navLi    = document.querySelectorAll("header .navbar ul li");
window.addEventListener("scroll", () => {
	let current = "";
	sections.forEach((section) => {
		console.log(section)
		const sectionTop = section.offsetTop;
		const sectionHeight = section.clientHeight;
		if (scrollY >= sectionTop - sectionHeight / 5) {
			current = section.getAttribute("id");
		}
	});
	console.log(current)
	navLi.forEach((li) => {
		li.classList.remove("active");
		if (li.classList.contains(current)) {
			li.classList.add("active");
		}
	});
});
// menu end
// automatic slider
function simulateRadioClick() {
	var radioButtons = document.getElementsByName("slider");
	for (var i = 0; i < radioButtons.length; i++) {
	  	if (radioButtons[i].checked) {
			radioButtons[i].checked = false;
			var nextIndex = (i + 1) % radioButtons.length;
			radioButtons[nextIndex].checked = true;
			break;
	  	}
	}
}
setInterval(simulateRadioClick, 5000);