jQuery(function() { jQuery("a[href^=#]").click(function(){ var elmID = jQuery(this).attr("href"); var posi = 0; if(jQuery(elmID).size()){ posi = jQuery(elmID).offset().top -0; BodySlider(posi); return false; } }); function BodySlider(HashOffset){ jQuery("html,body").animate({ scrollTop: HashOffset }, 600); } }); /*============================================== 要素の高さを揃える ==============================================*/ $(function(){ $('#main .sec02 .town__body .town__item a').matchHeight(); $('#model-course .box h4').matchHeight(); $('#model-course .box .STF_WEBNAME').matchHeight(); $('#model-course .box .txt-box').matchHeight(); });