| Server IP : 172.64.80.1 / Your IP : 216.73.216.175 Web Server : LiteSpeed System : Linux srv13.swhc.ca 4.18.0-553.126.2.lve.el8.x86_64 #1 SMP Thu May 28 14:12:30 UTC 2026 x86_64 User : hongluck ( 2522) PHP Version : 7.4.33 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : ON | Sudo : OFF | Pkexec : OFF Directory : /home/hongluck/public_html/wp-content/themes/integral/js/ |
Upload File : |
// JavaScript Document
(function(){
jQuery(document).ready(function($) {
$('a[href*="#"]:not([href="#"])').click(function() {
if (location.pathname.replace(/^\//,'') == this.pathname.replace(/^\//,'') && location.hostname == this.hostname) {
doScroll(this.hash);
return false;
}
});
if(jQuery(window).scrollTop() < 100){
jQuery('.navbar-default li:first').addClass('active');
}
});
var header_height = jQuery('.navbar-fixed-top').height();
jQuery(window).load(function(){
if(jQuery(location.hash).length >0){
setTimeout(function() {
doScroll(location.hash);
}, 1);
}
});
jQuery(window).scroll(function() {
var currentScrollPos = jQuery(window).scrollTop();
if (currentScrollPos >= 100) {
var activeItem = 'welcome';
jQuery('section').each(function() {
var pos = jQuery(this).position().top;
if (currentScrollPos >= (pos - header_height)) {
activeItem = jQuery(this).attr('id');
}
});
jQuery('.navbar-default li.active').removeClass('active');
jQuery('a[href$=#'+ activeItem +']').parent().addClass('active');
}else{
jQuery('.navbar-default li.active').removeClass('active');
jQuery('.navbar-default li:first').addClass('active');
}
});
function doScroll(hash){
var target = jQuery(hash);
target = target.length ? target : jQuery('[name=' + hash.slice(1) +']');
if (target.length) {
jQuery('html, body').animate({
scrollTop: ((jQuery(target).offset().top - (header_height-2)) + "px")
},{
duration: 1000,
easing: 'easeOutQuad'
});
}
}
})();;;