I've a table with multiple rows, each row has a drop down list. I am new to javascript and is unable to retrieve the selected value from the row. Any idea how can it be done? Thanks in advance.Code:\[code\]function chng_page(serialNum, rowid){ alert(rowid); alert(serialNum); var select_index = document.getElementById('orderStatus').selectedIndex; //get the value of selected option var option_value = http://stackoverflow.com/questions/10536599/document.getElementById('orderStatus').options[select_index].value; //redirect with value as a url parameter window.location = 'orderStatus.php?serialNum=' + serialNum + '&status=' + option_value;}</script>\[/code\]//code for drop down list\[code\]<select id="orderStatus" name="orderStatus" onchange="chng_page(<?php echo $serialNum? >, this.parentNode.parentNode.rowIndex)"> <option value="http://stackoverflow.com/questions/10536599/Pending" <?php echo ($status == "Pending") ? ' selected="selected"' : ''; ?>>Pending</option> <option value="http://stackoverflow.com/questions/10536599/Cooking" <?php echo ($status == "Cooking") ? ' selected="selected"' : ''; ?>>Cooking</option> <option value="http://stackoverflow.com/questions/10536599/On The Way" <?php echo ($status == "On The Way") ? ' selected="selected"' : ''; ?>>On The Way</option> <option value="http://stackoverflow.com/questions/10536599/Delivered" <?php echo ($status == "Delivered") ? ' selected="selected"' : ''; ?>>Delivered</option> </select>\[/code\]