Good day.
There is a generated page, on it - for example, 50 buttons:
<a data-toggle="n1" href="1" id="button" class="c1">Ответить 1</a> <a data-toggle="n2" href="2" id="button" class="c2">Ответить 2</a> и т.д. I know how to call an event when I click on it, but after clicking I have to open the form, let the user fill it in and send it to the server with an Ajax. But how can I pass the button ID in the event to distinguish them from each other? Perhaps there is a special tag, the value of which you can pick up?
When I click on id="button" the event works, and how do I get the value from the data-toggle href class or any other specials? tag, to understand that they clicked on the 2nd, and you need to work with the 2nd entry in the database.
Thank.