I have an HTML table. This table has a contenteditable
td
, so when the user clicks a button, the text on that editable td
gets passed to my POST
action on the controller.
I think is simple, but I don't know how to do it, and all the related answers that I found include JavaScript code. I think is unnecessary to this case. How can I do this with using form method in the view code?
This is my code on the view
<table class="table table-hover" style="white-space:nowrap;">
<tr>
<th>Campo</th>
<th>Columna en Excel</th>
</tr>
<tr>
<td> Nombre</td>
<td contenteditable="true" title="editar" > Nombre en excel</td>
</tr>
</table>
Note that I'm using ASP.NET MVC Framework on the server side.