Suppose you have cell 3.2 as
<td id="cell32">cell data</td>
If you want to hide it, do
cell32 = document.getElementById("cell32"); cell32.style.display = "none";
However, if you hide the middle cell, your other cells will move to the left. To preserve the structure of the table, you need to replace the hidden cell with a special cell that has empty ( ) content, and without borders.
source share