I am trying to attach an event to an element but when I fire this event, it uses the value of the last element in the loop.
I tried thousands of things, but nothing w