75網(LieHuo97.Net)教88程 自寫一個翻書的Js效果,jquery-1.4.2.min.js,還正在完善中,希望大家能喜歡,我覺得不錯。
為解決一些網頁特效運行后不能顯示效果(例如:jQuery則需要刷新)問題,特別新增網頁版演示
網頁演示:猛擊此處
運行演示:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml" ><head><title>自寫一個翻書的Js效果 - Liehuo.Net</title><script type="text/javascript" language="javascript" src="http://www.vxbq.cn/uploads/common/js/jquery-1.4.2.min.js"></script><script type="text/javascript" language="javascript">$(function() {$("#right").click(function() {var roll = $("<div/>", { css: { position: "absolute", border: "solid 1px #999", left: "806px", top: "10px", height: "494px", width: "1px", background: "#fff url(http://www.vxbq.cn/uploads/allimg/1011/eCX.png) repeat-y -200px 0px"} }).appendTo($("#book").parent());$(roll).animate({left: "10px",width: "398px","background-position": "272px 0px"}, 1000, function() {$("#left").css({"background":"#fff"});$(roll).fadeOut(300, function() {$(roll).remove();})});});});</script></head><body style="padding:5px;margin:0;"><div id="book" style="width:797px;height:494px;background:#ccc;border:solid 6px #ccc;"><div id="left" style="width:398px;height:494px;float:left;cursor:pointer;"></div><div id="right" style="width:398px;height:494px;float:left;background:#fff;cursor:pointer;margin-left:1px;text-align:right;"><p style="margin-top:470px;font-size:12px;color:#999;">點這翻頁 </p></div></div></body></html><br /><center>如不能顯示效果,請按Ctrl+F5刷新本頁,更多網頁代碼:<a href='http://www.vxbq.cn/' target='_blank'>http://www.vxbq.cn/</a></center>提示:可修改后代碼再運行!
上一篇 CSS基礎文章:CSS3的新特性介紹
下一篇 Access入門教程 10.5 補充內容二
程序員人生,我編程,我富裕,記住wfuyu網,php教程,php學習,php手冊,CMS模版制作
聲明:本站大部分內容是作者原創,少部分收集于互聯網供大家一起學習,原版權很多不明,如有侵權請聯系本站,謝謝!
粵ICP備14040726號-1?? 2015-2020 程序員人生 版權所有