I would like to know how to put a javascript input box, to be more specific, within a given cell of a table (generated through an array). Right now ... J.G.
<!DOCTYPE html>
<html lang="pt-br">
<head>
<meta charset="UTF-8">
</head>
<body onKeyDown="pegadirecao(event.keyCode);">
<div id=principal></div>
<script>
tabuleiro="<table align=center border=1>";
for(x=0;x<2;x++)
{ tabuleiro+="<tr>";
for(y=0;y<5;y++)
{ tabuleiro+="<td id=td"+x+"_"+y+" style='width:70px; height:70px;'></td>";
}
tabuleiro+="</tr>";
}
tabuleiro+="</table>";
document.getElementById('principal').innerHTML=tabuleiro;
</script>
</html>
<!DOCTYPE html>
<html lang="pt-br">
<head>
<meta charset="UTF-8">
</head>
<body onKeyDown="pegadirecao(event.keyCode);">
<div id=principal></div>
<script>