/*============================================================= Authour URL: www.designbootstrap.com http://www.designbootstrap.com/ License: MIT http://opensource.org/licenses/MIT 100% Free To use For Personal And Commercial Use. IN EXCHANGE JUST TELL PEOPLE ABOUT THIS WEBSITE ======================================================== */ $(document).ready(function () { /*==================================== SCROLLING SCRIPTS ======================================*/ $('.scroll-me a').bind('click', function (event) { //just pass scroll-me in design and start scrolling var $anchor = $(this); $('html, body').stop().animate({ scrollTop: $($anchor.attr('href')).offset().top }, 1200, 'easeInOutExpo'); event.preventDefault(); }); /*==================================== SLIDER SCRIPTS ======================================*/ $('#carousel-slider').carousel({ interval: 8000 //TIME IN MILLI SECONDS }); /*==================================== VAGAS SLIDESHOW SCRIPTS ======================================*/ $.vegas('slideshow', { backgrounds: [ { src: templateDir + '/assets/img/bg.jpg', fade: 1000, delay: 19000 }, ] })('overlay', { /** SLIDESHOW OVERLAY IMAGE **/ //src: templateDir + '/assets/js/vegas/overlays/06.png' // THERE ARE TOTAL 01 TO 15 .png IMAGES AT THE PATH GIVEN, WHICH YOU CAN USE HERE }); /*==================================== POPUP IMAGE SCRIPTS ======================================*/ $('.fancybox-media').fancybox({ openEffect: 'elastic', closeEffect: 'elastic', helpers: { title: { type: 'inside' } } }); /*==================================== FILTER FUNCTIONALITY SCRIPTS ======================================*/ $(window).load(function () { var $container = $('#work-div'); $container.isotope({ filter: '*', animationOptions: { duration: 750, easing: 'linear', queue: false } }); $('.caegories a').click(function () { $('.caegories .active').removeClass('active'); $(this).addClass('active'); var selector = $(this).attr('data-filter'); $container.isotope({ filter: selector, animationOptions: { duration: 750, easing: 'linear', queue: false } }); return false; }); }); /*==================================== WRITE YOUR CUSTOM SCRIPTS BELOW ======================================*/ $(document).ready(function() { // Window load event used just in case window height is dependant upon images $(window).bind("load", function() { var footerHeight = 0, footerTop = 0, $footer = $("#footer"); positionFooter(); function positionFooter() { footerHeight = $footer.height(); footerTop = ($(window).scrollTop()+$(window).height()-footerHeight)+"px"; if ( ($(document.body).height()+footerHeight) < $(window).height()) { $footer.css({ position: "absolute", width: "100%" }).animate({ top: footerTop }) } } $(window) .scroll(positionFooter) .resize(positionFooter) }); }); });