js代码
<script src="js/jquery.liMarquee.js"></script> <script> $(window).load(function(){ $('.str1').liMarquee(); $('.str2').liMarquee({ direction: 'right' }); var stringEl = $('.str3').liMarquee(); $('.speedChange').on('click',function(){ var speedChange = $(this); var dataSpeed = speedChange.data('scrollamount'); stringEl.trigger('mouseenter'); stringEl.data({scrollamount:dataSpeed}); stringEl.trigger('mouseleave'); return false; }); $('.str4').liMarquee({ drag: false }); $('.str5').liMarquee({ hoverstop: false }); $('.str6').liMarquee(); $('.btnPause').on('click',function(){ $('.str6').liMarquee('pause'); }); $('.btnPlay').on('click',function(){ $('.str6').liMarquee('play'); }) }); </script>