When I press a button I get the value of the 1st button. I want the value of the button that was pressed.
JavaScript
function GetHadess() {
var title = $(".myButtonn").val();
alert(title);
}
The value of the button that was pressed should be shown in alert, but here value of the 1st button is shown.
HTML code
<tbody id="tbl">
<tr><td><input class="myButtonn" type="submit" name="title1" value=" bbb " onclick="GetHadess()"></td></tr>
<tr><td><input class="myButtonn" type="submit" name="title1" value=" bb " onclick="GetHadess()"></td></tr>
</tbody>