вопрос
Помогите объединить два скрипта в один.
function showSpoiler(obj) {var inner = obj.parentNode.getElementsByTagName("div")[0]; if (inner.style.display == "none") inner.style.display = ""; else inner.style.display = "none"; };
$(document).ready(function(){
$('.slider ul').bxSlider({ minSlides:1, prevSelector:'.sliderprev', nextSelector:'.slidernext', pager:false, controls:true, auto:true, mode:'fade' });
$('.footslide ul').bxSlider({ minSlides:5, maxSlides:5, prevSelector:'.footslideprev', nextSelector:'.footslidenext', pager:false, controls:true, auto:false });
var menuLeft = document.getElementById( 'cbp-spmenu-s1' ),
menuRight = document.getElementById( 'cbp-spmenu-s2' ),
showRightPush2 = document.getElementById( 'showRightPush2' ),
body = document.body;
showRightPush2.onclick = function() {
classie.toggle( this, 'active' );
classie.toggle( body, 'cbp-spmenu-push-toleft' );
classie.toggle( menuRight, 'cbp-spmenu-open' );
disableOther( 'showRightPush2' );
};
function disableOther( button ) {
if( button !== 'showRightPush2' ) {
classie.toggle( showRightPush2, 'disabled' );
}
};
$(window).scroll(function(){
if ($(this).scrollTop() > 550) {
$('.scrollup').fadeIn();
} else {
$('.scrollup').fadeOut();
}
});
$('.scrollup').click(function(){
$("html, body").animate({ scrollTop: 0 }, 400);
return false;
});
})