12345 |
- $(document).ready(function(){$('[data-toggle="tooltip"]').tooltip({container:'body'});$('.navbar-toggle').click(function(){$(this).toggleClass('activated');});$(".toggle-search").click(function(){$('.overlay-search').toggleClass('display-overlay');});$('body').on("click",".dropdown-menu",function(e){$(this).parent().is(".open")&&e.stopPropagation();});$("form").each(function(){})
- $('input[type="file"]').change(function(e){var maxsize=parseInt($(this).attr("data-maxfilesize"));if(!maxsize){return;}
- if(this.files[0].size>maxsize){alert('Sorry, that file size exceeds the maximum allowed size of '+parseInt(maxsize/1024/1024)+'Mb');$(this).val('');}});});function scrollTop(){return document.body.scrollTop||document.documentElement.scrollTop;}
- function debounce(func,wait,immediateFunc){var timeout;return function(){var context=this,args=arguments;var later=function(){timeout=null;func.apply(context,args);};if(immediateFunc){immediateFunc.apply(context,args);}
- clearTimeout(timeout);timeout=setTimeout(later,wait);};};
|