I am trying to echo the rowIndex of the row in a table, when the dropdown (in td tags) in that row changes and its options (selectdevice is the class for the dropdowns). Currently i am getting undefined being displayed:
$('#tabletomodify').on('change','.selectdevice', function () {
alert( this.parentNode.rowIndex );
var optionSelected = $("option:selected", this);
var valueSelected = this.value;
});