js代码
<script>$(document).ready(function() { $('.user_before').show(); function shockCat (){ $('.user_before').hide(); $('.user_after').show(); } function ReCat (){ $('.user_after').hide(); $('.user_before').show(); } function picShow(object){ object.fadeIn("slow"); } function picHide(object){ object.fadeOut("slow"); } var Long = $(".user_point li").length; var pIndex = 0; var autoChange = setInterval(function(){ var pic =$(".point").eq(pIndex); picShow(pic); picHide(pic); ReCat (); if( pIndex < Long-1){ pIndex ++; } else { pIndex =0; shockCat (); } },100); }); </script>