Is there a way to clone HTML elements using JQuery?
However, I want to be able to assign the cloned elements new attributes "id, name". So if I had a textfield element, I want to clone it without its value and change its id and name attribute to "exmple2" if it was named "example" previously.
I would appreciate any help on this and any other implementation I can use to add more elements to my html form that already exists on the page.
Thanks all
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…