jquery find h2 tags and append into div

Posted by SoulieBaby on Stack Overflow See other posts from Stack Overflow or by SoulieBaby
Published on 2010-05-10T22:26:50Z Indexed on 2010/05/10 22:34 UTC
Read the original article Hit count: 225

Filed under:
|
|
|

Hi all, I'm trying to write a bit of jquery which finds all h2 tags inside a div (.content), then appends each one into another div (.intro).

So far I have this:

var h2 = $(".content").find("h2");
$(h2).each(function() {
  $(this).append(".intro");
});

But it's not working.. if someone could help me out, that'd be great :)

© Stack Overflow or respective owner

Related posts about jQuery

Related posts about find