― TAG ―

ミラブルキッチン

//スクロールで固定ボタン表示 $(window).scroll(function(){ if ($(window).width() <= 767) {//ブラウザ画面が767pxより小さい時 if(window.pageYOffset > $(document).height()-$(window).height()-2500){ $('.fixed-wrap').fadeIn(300); }else{ $('.fixed-wrap').fadeOut(300); } } else {//ブラウザ画面が767pxより大きい時 if(window.pageYOffset > $(document).height()-$(window).height()-2000){ $('.fixed-wrap').fadeIn(300); }else{ $('.fixed-wrap').fadeOut(300); } } }); $(function() { $('#sidebar').after($('.fixed-wrap')); });