Answer the question
In order to leave comments, you need to log in
How to submit each line of an AJAX form?
Colleagues, hello!
This is the task before me. There is a form in a modal window with n lines (the number of lines can be different) because the form is created dynamically. Each line has a hidden input with an id value .
The question is, how do I send each row to be processed by the server?
Thank you in advance for your time and helpful information.
Answer the question
In order to leave comments, you need to log in
0. some kind of card ID (42)
1. creating a row - (probably do nothing? but create an identifier (23))
2. data entry - (wait for completion and send POST /api/form/42/row/23 to the server {some kind of jison describing the string} )
Somewhere like that.
In javascript subscribe to onchange events. Well, then you call something like fetch or https://developer.mozilla.org/ru/docs/Web/API/XMLH...
Handling line deletion at your discretion
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question