<! DOCTYPE HTML Public"-//W3C//DTD XHTML 1.0 transitional//en""Http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">"Http://www.w3.org/1999/xhtml">"Content-type"Content="text/html; Charset=utf-8"/><title>panel</title><style type="Text/css">*{margin:0; Padding0;} Body {font-size:13px; Line-height:130%; padding:60px} #panel {width:60px; border:1px solid #0050D0; height:22px; overflow:hidden;}. Head {padding:5px; background: #96E555; cursor:pointer; width:300px;}. content {padding:10px; text-Indent:2em; border-top:1px solid #0050D0; Display:block; width:280px;} </style><script src="Http://www.cnblogs.com/../scripts/jquery-1.3.1.js"Type="Text/javascript"></script><script type="Text/javascript">$ (function () {$ ("Button:eq (0)"). Click (function () {$ ("#panel"). Animate ({height:"150" },. Animate ({width:"300"},(+).Animate ({height: "show",width: "Show", opacity: "Show"}, ) . Animate ({height:"+"}, +); }); //Stop ([Clearqueue][, Gotoend]);
Grammatical structure
$("Button:eq (1)"). Click (function () {$ ("#panel"). Stop ();//Stop the current animation and continue to the next animation}); $("Button:eq (2)"). Click (function () {$ ("#panel"). Stop (true);//Clears all animations of an element}); $("Button:eq (3)"). Click (function () {$ ("#panel"). Stop (Falsetrue);//Let the current animation go directly to the end state and continue to the next animation}); $("Button:eq (4)"). Click (function () {$ ("#panel"). Stop (Truetrue);//Clears all animations of the element so that the current animation reaches the end state directly});}) </script>true) </button><button>stop (Falsetrue) </button><button>stop (True,true) </button><div id="panel" > < H5 class="head" > What is jquery?class="content" > jquery is another excellent JavaScript library following prototype, an open source project created by John Resig in January 2006. With its simple syntax and cross-platform compatibility, jquery greatly simplifies JavaScript developers traversing HTML documents, manipulating the DOM, handling events, performing animations, and developing Ajax. Its unique and elegant code style has changed the way JavaScript programmers design ideas and write programs. </div></div></body>
Article from: http://www.cnblogs.com/vincent_ds/archive/2012/09/23/2699048.html
Several uses of the jquery Stop animation stop