рони, ok
<table>
<tr>
<td>0</td><td class="class"><span>00000000000000</span></td><td>0</td><td class="class">2</td>
</tr>
<tr>
<td>0</td><td class="class">3</td><td>0</td><td class="class">4</td>
</tr>
</table>
<script>
function highlight(item) {
item.style.backgroundColor = "lightgreen";
}
var table = document.querySelector('table');
table.onclick = function(event) {
var target = event.target;
while(target != table) {
if(target.classList.contains('class')) {
highlight(target);
return;
}
target = target.parentNode;
}
};
</script>