javascript - Working With Dynamically Created Inputs -
I have a dynamic form that you can add elements like, you type in a name, and then if you To write a new name, you click on 'Add Name', and another text box appears.
Their names are However, because these inputs, those textboxes are dynamically created, Javascript only selects the first text box with the name What should I do to solve this problem? I used both and But it was not working. Thanks in advance Try to use: names [] . I can process those inputs with PHP on the server side. However, I want to make a calculation with those inputs, such as by typing on all types of pages as the user type
name [] < P> Let me clear it. In this way it would be better to get me a textbox I input in the age of the age if I want to enter a new era, then I will click on the 'Add Age' button, and a new input box will be pop out. I write the value of the new age and as I type, on the third lesson text, the values of those ages are printed on average. But due to those input boxes name
age [] with execution time (not on collection time, I'm not sure that these are suitable words for those people. Probably not, because there is nothing compilation ? - or is it?), I can not process them.
$ ('input [name = ages] \ \ [\\]]'). Change (function () {console.log ('1');});
$ ('input [name = age \\ [\\]]'). ('Input', function () {Console.log ('2');});
$ (document) .on ('change', 'input [name = age \\ [\\]]', function () {console.log ('2');});
Comments
Post a Comment