本文实例讲述了jQuery实现仿Alipay支付宝首页全屏焦点图切换特效。分享给大家供大家参考。具体实现方法如下:
<!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> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <title>kinMaxShow 扩展效果</title> <link type="text/css" href="_doc/base.css" rel="stylesheet" /> <style type="text/css"> body{ margin:0; padding:0;} #Login{ position:relative;} #loginPlane{ position:absolute;width:100%; height:330px; top:0; left:0;z-index:88; } #loginWrap{ width:960px;margin:0 auto; padding-top:20px; } #loginBox{ width:286px;height:330px; filter:progid:DXImageTransform.Microsoft.gradient( startcolorstr=#88000000,endcolorstr=#88000000); background:rgba(0,0,0,0.2); float:right; margin-right:20px; } #loginBox h3{ border-bottom:1px solid #ccc; margin:10px; color:#fff; font-weight:normal; font-size:16px; line-height:26px; } #loginBox form{ color:#fff; font-size:12px; padding:8px 0 0 20px } #loginBox .text{ padding:4px;border:1px solid; border-color:#aaa #ddd #ddd #aaa; height:20px; width:230px; font-family:Verdana } #loginBox .submit{ color:#fff; border:0; background:#FFA600;width:236px; height:35px; font-weight:bold; font-family:"Microsoft Yahei"; font-size:14px; } #kinMaxShow{ display:none;} #kinMaxShow .sub_1_1{ display:block; position:absolute;left:110px; top:136px; } #kinMaxShow .sub_1_2{ display:block; position:absolute;left:110px; top:120px; } #kinMaxShow .sub_2_1{ display:block; position:absolute;left:-160px; bottom:0px; } #kinMaxShow .sub_2_2{ display:block; position:absolute;left:110px; top:20px; } #kinMaxShow .sub_3_1{ display:block; position:absolute;right:180px; bottom:0px; } #kinMaxShow .sub_3_2{ display:block; position:absolute;left:30px; top:40px; } </style> <script src="js/jquery-1.10.2.min.js" type="text/javascript"></script> <script src="js/jquery.kinMaxShow-1.1.min.js" type="text/javascript"></script> <script type="text/javascript"> $(function(){ $("#kinMaxShow").kinMaxShow({ height:400, button:{ showIndex:false, normal:{background:'url(images/button.png) no-repeat -14px 0', marginRight:'8px',border:'0',right:'44%',bottom:'20px' }, focus:{background:'url(images/button.png) no-repeat 0 0', border:'0' } }, callback:function(index,action){ switch(index){ case 0 : if(action=='fadeIn'){ $(this).find('.sub_1_1').animate({left:'70px'},600) $(this).find('.sub_1_2').animate({top:'60px'},600) }else{ $(this).find('.sub_1_1').animate({left:'110px'},600) $(this).find('.sub_1_2').animate({top:'120px'},600) }; break; case 1 : if(action=='fadeIn'){ $(this).find('.sub_2_1').animate({left:'-100px'},600) $(this).find('.sub_2_2').animate({top:'60px'},600) }else{ $(this).find('.sub_2_1').animate({left:'-160px'},600) $(this).find('.sub_2_2').animate({top:'20px'},600) }; break; case 2 : if(action=='fadeIn'){ $(this).find('.sub_3_1').animate({right:'350px'},600) $(this).find('.sub_3_2').animate({left:'180px'},600) }else{ $(this).find('.sub_3_1').animate({right:'180px'},600) $(this).find('.sub_3_2').animate({left:'30px'},600) }; break; } } }); }); </script> </head> <body> <div id="Login"> <div id="kinMaxShow"> <div> <img src="/static/imghwm/default1.png" data-src="images/1.jpg" class="lazy" / alt="jQuery实现仿Alipay支付宝首页全屏焦点图切换特效_jquery" > <div> <img class="sub_1_1 lazy" src="/static/imghwm/default1.png" data-src="images/sub_1_1.png" / alt="jQuery实现仿Alipay支付宝首页全屏焦点图切换特效_jquery" > <img class="sub_1_2 lazy" src="/static/imghwm/default1.png" data-src="images/sub_1_2.png" usemap="#Map_1_2" border="0" /> <map name="Map_1_2" id="Map_1_2"> <area shape="rect" coords="2,96,106,123" href="http://www.jb51.net" target="_blank"/> </map> </div> </div> <div> <img src="/static/imghwm/default1.png" data-src="images/2.jpg" class="lazy" / alt="jQuery实现仿Alipay支付宝首页全屏焦点图切换特效_jquery" > <div> <img class="sub_2_1 lazy" src="/static/imghwm/default1.png" data-src="images/sub_2_1.png" / alt="jQuery实现仿Alipay支付宝首页全屏焦点图切换特效_jquery" > <img class="sub_2_2 lazy" src="/static/imghwm/default1.png" data-src="images/sub_2_2.png" usemap="#Map_2_2" border="0" /> <map name="Map_2_2" id="Map_2_2"> <area shape="rect" coords="3,97,104,124" href="http://www.jb51.net" target="_blank"/> </map> </div> </div> <div> <img src="/static/imghwm/default1.png" data-src="images/3.jpg" class="lazy" / alt="jQuery实现仿Alipay支付宝首页全屏焦点图切换特效_jquery" > <div> <img class="sub_3_1 lazy" src="/static/imghwm/default1.png" data-src="images/sub_3_1.png" / alt="jQuery实现仿Alipay支付宝首页全屏焦点图切换特效_jquery" > <img class="sub_3_2 lazy" src="/static/imghwm/default1.png" data-src="images/sub_3_2.png" usemap="#Map_3_2" border="0" /> <map name="Map_3_2" id="Map_3_2"> <area shape="rect" coords="1,98,106,124" href="http://www.jb51.net" target="_blank"/> </map> </div> </div> </div> <div id="loginPlane"> <div id="loginWrap"> <div id="loginBox"> <h3 id="登陆支付宝">登陆支付宝</h3> <form> <label>账户名:</label> <p><input type="text" class="text" /></p> <label>登陆密码:</label> <p><input type="password" class="text" /></p> <br /> <p><input type="button" value=" 登 陆 " class="submit" /></p> </form> </div> </div> </div> </div> </body> </html>
jquery.kinMaxShow-1.1.min.js点击此处本站下载。
希望本文所述对大家的jQuery程序设计有所帮助。

JavaScript核心数据类型在浏览器和Node.js中一致,但处理方式和额外类型有所不同。1)全局对象在浏览器中为window,在Node.js中为global。2)Node.js独有Buffer对象,用于处理二进制数据。3)性能和时间处理在两者间也有差异,需根据环境调整代码。

JavaScriptusestwotypesofcomments:single-line(//)andmulti-line(//).1)Use//forquicknotesorsingle-lineexplanations.2)Use//forlongerexplanationsorcommentingoutblocksofcode.Commentsshouldexplainthe'why',notthe'what',andbeplacedabovetherelevantcodeforclari

Python和JavaScript的主要区别在于类型系统和应用场景。1.Python使用动态类型,适合科学计算和数据分析。2.JavaScript采用弱类型,广泛用于前端和全栈开发。两者在异步编程和性能优化上各有优势,选择时应根据项目需求决定。

选择Python还是JavaScript取决于项目类型:1)数据科学和自动化任务选择Python;2)前端和全栈开发选择JavaScript。Python因其在数据处理和自动化方面的强大库而备受青睐,而JavaScript则因其在网页交互和全栈开发中的优势而不可或缺。

Python和JavaScript各有优势,选择取决于项目需求和个人偏好。1.Python易学,语法简洁,适用于数据科学和后端开发,但执行速度较慢。2.JavaScript在前端开发中无处不在,异步编程能力强,Node.js使其适用于全栈开发,但语法可能复杂且易出错。

javascriptisnotbuiltoncorc; saninterpretedlanguagethatrunsonenginesoftenwritteninc.1)javascriptwasdesignedAsalightweight,解释edganguageforwebbrowsers.2)Enginesevolvedfromsimpleterterterpretpreterterterpretertestojitcompilerers,典型地提示。

JavaScript可用于前端和后端开发。前端通过DOM操作增强用户体验,后端通过Node.js处理服务器任务。1.前端示例:改变网页文本内容。2.后端示例:创建Node.js服务器。

选择Python还是JavaScript应基于职业发展、学习曲线和生态系统:1)职业发展:Python适合数据科学和后端开发,JavaScript适合前端和全栈开发。2)学习曲线:Python语法简洁,适合初学者;JavaScript语法灵活。3)生态系统:Python有丰富的科学计算库,JavaScript有强大的前端框架。


热AI工具

Undresser.AI Undress
人工智能驱动的应用程序,用于创建逼真的裸体照片

AI Clothes Remover
用于从照片中去除衣服的在线人工智能工具。

Undress AI Tool
免费脱衣服图片

Clothoff.io
AI脱衣机

Video Face Swap
使用我们完全免费的人工智能换脸工具轻松在任何视频中换脸!

热门文章

热工具

ZendStudio 13.5.1 Mac
功能强大的PHP集成开发环境

记事本++7.3.1
好用且免费的代码编辑器

VSCode Windows 64位 下载
微软推出的免费、功能强大的一款IDE编辑器

SublimeText3 Linux新版
SublimeText3 Linux最新版

SublimeText3 英文版
推荐:为Win版本,支持代码提示!