Answer the question
In order to leave comments, you need to log in
Can't pass values to modal window using JSTL?
Hello.
There was a question. I am writing applications in Java, I want to pass values to the modal window using JSTL, but when I try to exit a different table element, the modal window pops up for the first entry.
The html code:
This is how the table itself looks like:
And here I get in the modal window when I click the edit link (3rd key) on any of the elements:
Tell me how you can fix this moment. Thank you very much in advance.
Answer the question
In order to leave comments, you need to log in
If you look at the resulting html code, you'll see that the loop created a bunch of div.modal-windows with the same id. But IDs must be unique, there can't be two elements with the same id on the page. Either generate different id's, or create one modal window outside the loop, and fill the form fields in it when opened with javascript.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question