How can I copy copy content of a ul
that is li
's inside it to another ul
.
Say we have t = $("ul#target")
and s = $("ul#source")
.
You can .clone()
the children then use .appendTo()
to put them on the destination <ul>
, like this:
$("#source").children().clone().appendTo("#target");
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