JSFiddle - React, Tailwind, and code Playground
http://stackoverflow.com/questions/38671598/populating-data-from-an-html-table-row/38671666#38671666
HTML
<table>
<tr>
<td><input class='m_id' value='123' /></td>
<td><button type="button" onclick="view_message(this);">click</button></td>
</tr>
<tr>
<td><input class='m_id' value='456' /></td>
<td><button type="button" onclick="view_message(this);">click</button></td>
</tr>
<tr>
<td><input class='m_id' value='789' /></td>
<td><button type="button" onclick="view_message(this);">click</button></td>
</tr>
</table>
JavaScript
function view_message(el) {
var row = $(el).closest("tr");
alert($(".m_id", row).val())
}