469,344 Members | 6,227 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 469,344 developers. It's quick & easy.

[jQuery] Can I animate a Floating element that should get moved to next line?

Samishii23
246 100+
I have a thought. Consider the following:
Expand|Select|Wrap|Line Numbers
  1. <script>
  2. $(function(){
  3.  $("#b").click(function(){
  4.   $("div").animate({width: "200px"},1000);
  5.   });
  6.  });
  7. </script>
  8.  
  9. <div style="width:225px;">
  10.  <button id="b">C</button>
  11.  <div style="float:left;width:100px;">Test</div>
  12.  <div style="float:left;width:100px;"></div>
  13. </div>
On my test case I basicly animate the 1 div, but the 2nd div after "Snaps" to 2nd line. I would like to animate the move to the next line. Anyone know how this can be done?

Thanks.
Sep 12 '11 #1
0 1261

Post your reply

Sign in to post your reply or Sign up for a free account.

Similar topics

19 posts views Thread by les_ander | last post: by
6 posts views Thread by Alan J. Flavell | last post: by
reply views Thread by jstathan | last post: by
4 posts views Thread by Oliver Block | last post: by
22 posts views Thread by ashkaan57 | last post: by
reply views Thread by zhoujie | last post: by
reply views Thread by suresh191 | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.