As i have it now my script makes the 3x3 grid clickable, and I dont know exactly how to turn on the click once it has been clicked. This is using jQuery and a simple if else statement to switch between turns.
$(document).ready(function(){
var turn = 0;
$("#cell11, #cell12, #cell21, #cell22, #cell13, #cell23, #cell31, #cell32, #cell33, ")
.click(
function(){
var cell = $(this);
if(turn===0){
turn = 1;
cell.css("background","url(images/o.png)");
}
else{
turn = 0;
cell.css("background","url(images/x.png)");
}
})
});
