开发者

Adding new input row to form on event click

开发者 https://www.devze.com 2022-12-28 03:18 出处:网络
Using JQuery to a开发者_如何学JAVAdd or remove form elements when i click the add link the information in the existing input field disappears.

Using JQuery to a开发者_如何学JAVAdd or remove form elements

when i click the add link the information in the existing input field disappears.

How do i tell it to retain this information.


tried that Tim but what that does is move the info from the existing input and put it in the new row input instead.


Try changing

$('input', addRow).val('');

to

$('input', addRow).val($(this).val());
0

精彩评论

暂无评论...
验证码 换一张
取 消