I set up a simple JSfiddle..
http://jsfiddle.net/DbetR/
$("div.postdata").next(".content").appendTo(".postdata");
this is probably not working because it's trying to append it's self to it's self or something. Any ideas on how to go about this?
I want content 1 to append to the first div, and content 2 to the second.
Thanks!
Next sibling of each .postdata is <p> element, and not .content. You can use something like that to make the things workable:
$("div.postdata").each(function() {
$(this).nextAll(".content:first").appendTo(this);
});
DEMO: http://jsfiddle.net/DbetR/2/
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With