- I have an unknown amount of clickable buttons. (generated)
- Every button is connected to multiple values that should be sent through the Ajax call.
I found this to start with:
$.ajax({
type: "POST",
url: "some.php",
data: parameters,
success: function(msg){
alert("nothing");
}
});
data
contains parameters as far as I know. My parameters are different depending on what button that is clicked.
My guess is that I could use this
somewhere? But what if I need to send 3 values?
<input type="button" id="unique-1"> <!-- With values 'test', 3 and 5 -->
<input type="button" id="unique-2"> <!-- With values 'doh2', 8 and 6 -->
I use PHP if you need that info.
Thanks!