// 滑到不同内容块,上面相应导航变色var current_nav = 'qiye';scroll_function = function() {$(".about_content_list").each(function(index) {var h = $(this).offset().top;var y = $(window).scrollTop();if (y >= h && y < h + $(this).height() && $(this).attr('id') != current_nav) {current_nav = $(this).attr('id');$('.aboutus_navtxt a').removeClass('aboutus_change');$('.nav_' + current_nav).addClass('aboutus_change').show("fast");}});}$(window).scroll(function() {scroll_function();});
效果如e车宝的网站