How to remove all tags after certain tag?

Posted by Kirzilla on Stack Overflow See other posts from Stack Overflow or by Kirzilla
Published on 2010-05-12T10:19:49Z Indexed on 2010/05/12 10:24 UTC
Read the original article Hit count: 268

Filed under:
|

Hello,

I need to remove tags going after #first and only in #container. How can I do it with jQuery?

<div id="container">
  <div id="first"></div>
  <div id="remove_me_1"></div>
  <div id="remove_me_2"></div>
  <div id="remove_me_3"></div>
  <a href="" id="remove_me_too">Remove me too</a>
</div>

Thank you

© Stack Overflow or respective owner

Related posts about JavaScript

Related posts about jQuery