This snippet copies the value of input field #source to another form #hiddenForm.
function copyFieldToForm(source, hiddenForm) { var clone = source.clone(); source.after(clone).appendTo(hiddenForm); } copyFieldToForm($("#source"), $("#hiddenForm"));
No comments:
Post a Comment