grid with title per bot

This commit is contained in:
gnieark 2015-12-11 13:22:29 +01:00
parent e1d16b1cb5
commit 7f71d281f2
2 changed files with 4 additions and 3 deletions

View File

@ -30,8 +30,8 @@ function battleship(bot1,bot2,gridWidth,gridHeight,nbShip1,nbShip2,nbShip3,nbShi
//ligne de titre
var trTitre1=createElem("tr");
var trTitre2=createElem("tr");
var tdTitre1=createElem("td",{"colspan":gridWidth});
var tdTitre2=createElem("td",{"colspan":gridWidth});
var tdTitre1=createElem("th",{"colspan":gridWidth});
var tdTitre2=createElem("th",{"colspan":gridWidth});
tdTitre1.innerHTML = bot1IdName[1];
tdTitre2.innerHTML = bot2IdName[1];
trTitre1.appendChild(tdTitre1);

View File

@ -4,4 +4,5 @@ article p select {}
td{min-width: 15px; height: 15px;}
.battleshipGrid{float: left; border-collapse:collapse; margin: 20px 20px 20px 20px;}
.battleshipGrid tr{}
.battleshipGrid tr td{border: 1px dashed green;}
.battleshipGrid tr td{border: 1px dashed green;}
.battleshipGrid tr th{text-align: center;}