- 1
Django - loop: which button clicked?
I put a list on my html {% for L in List %} {{L.name}} {{L.price}} ... And then a button/form like: <form name={{L.id}} action="myDef"> / <input name ={{L.id}} > / <button name = {{L.id}} > {% endfor In my views, I would like to get the button/form name/value, whatever helps, to check which button was clicked. Can you give me a hint?
1 Antwort
0
Omg simple. I used a hidden input. Got the value by the name...