最近中文字幕高清中文字幕无,亚洲欧美高清一区二区三区,一本色道无码道dvd在线观看 ,一个人看的www免费高清中文字幕

為了賬號(hào)安全,請(qǐng)及時(shí)綁定郵箱和手機(jī)立即綁定
已解決430363個(gè)問題,去搜搜看,總會(huì)有你想問的

jquery動(dòng)畫在谷歌瀏覽器無效,其他瀏覽器都沒有問題

jquery動(dòng)畫在谷歌瀏覽器無效,其他瀏覽器都沒有問題

我家在玉堆 2015-07-30 21:12:29
//jquery請(qǐng)不要用遠(yuǎn)程引入的//動(dòng)畫效果在谷歌瀏覽器中 無效 其他瀏覽器都實(shí)現(xiàn)了<!DOCTYPE html><html><head>? ? <meta charset="UTF-8">? ? <title>test</title>? ? <style type="text/css">? ? * {? ? ? ? padding: 0px;? ? ? ? margin: 0px;? ? }? ??? ? .wrap {? ? ? ? width: 100px;? ? ? ? height: 100px;? ? ? ? overflow: hidden;? ? ? ? margin: 0 auto;? ? ? ? position: relative;? ? }? ??? ? ul {? ? ? ? overflow: hidden;? ? ? ? position: absolute;? ? ? ? left: 0;? ? ? ? top: 0;? ? }? ??? ? li {? ? ? ? float: left;? ? ? ? width: 100px;? ? ? ? height: 100px;? ? ? ? list-style: none;? ? ? ? font-size: 30px;? ? ? ? font-weight: bolder;? ? }? ??? ? .item1 {? ? ? ? background: red;? ? }? ??? ? .item2 {? ? ? ? background: green;? ? }? ??? ? .item3 {? ? ? ? background: orange;? ? }? ??? ? .item4 {? ? ? ? background: blue;? ? }? ??? ? .item5 {? ? ? ? background: black;? ? }? ? </style></head><body>? ? <div>? ? ? ? <ul>? ? ? ? ? ? <li>1</li>? ? ? ? ? ? <li>2</li>? ? ? ? ? ? <li>3</li>? ? ? ? ? ? <li>4</li>? ? ? ? ? ? <li>5</li>? ? ? ? </ul>? ? </div>? ? <script src="jquery.js"></script>? ? <script type="text/javascript" src="js.js">? ? </script></body></html>//以下是js可以直接粘貼運(yùn)行$(function() {? ? /*為什么我這樣寫,在谷歌里面只會(huì)移動(dòng)一個(gè)畫面*/? ? /* li的寬度*/? ? var liw = $('li').width();? ? /* li的個(gè)數(shù)*/? ? var lin = $('li').length;? ? var index = 0;? ? /* 定時(shí)器*/? ? var timer = null;? ? /*給ul設(shè)置寬度*/? ? $('ul').css({? ? ? ? width: liw * lin + 'px'? ? });? ? /*每2秒移動(dòng)一次*/?$('ul').hover(function() {? ? ? ? clearInterval(timer);? ? }, function() {? ? ? ? timer = setInterval(move, 2000);? ? }).trigger('mouseleave');function move() {? ? ? ? index++;? ? ? ? left = index * liw;? ? ? ? if (index == 5) {? ? ? ? ? ? index = 0;? ? ? ? } else {? ? ? ? ? ? $('ul').stop(true, false).animate({? ? ? ? ? ? ? ? /*每次移動(dòng)的距離*/? ? ? ? ? ? ? ? left: -left? ? ? ? ? ? }, 300);? ? ? ? }? ? };})
查看完整描述

目前暫無任何回答

  • 0 回答
  • 0 關(guān)注
  • 3655 瀏覽
慕課專欄
更多

添加回答

舉報(bào)

0/150
提交
取消
微信客服

購(gòu)課補(bǔ)貼
聯(lián)系客服咨詢優(yōu)惠詳情

幫助反饋 APP下載

慕課網(wǎng)APP
您的移動(dòng)學(xué)習(xí)伙伴

公眾號(hào)

掃描二維碼
關(guān)注慕課網(wǎng)微信公眾號(hào)