How to clone only one of multiple nested elements
Posted
by eknown
on Stack Overflow
See other posts from Stack Overflow
or by eknown
Published on 2010-03-22T01:59:11Z
Indexed on
2010/03/22
2:01 UTC
Read the original article
Hit count: 335
jQuery
How do I find if the div I'm cloning has more than one of a child div with a certain class, and if so only clone one of them.
Say the cloned div is .diseaseCon, and the child div(s) is .symptomCon, in the cloning action, how can I detect if there's more than one .symptomCon divs and only clone one if there are?
© Stack Overflow or respective owner