let button = document.getElementsByTagName('button');
button.value = 8;
//button.textCont = 'X'; --- DOESN'T WORK.
//button.innerHTML = 'X'; --- DOESN'T WORK.
body {
background-color: navy;
}
h1 {
font-family: 'monospace';
text-align: center;
}
button {
width: 80px;
height: 80px;
position: relative;
left: 25px;
top: 15px;
background-color: darkblue;
border: none;
margin: 6px;
}
.game-box {
background-color: black;
width: 360px;
height: 360px;
border-radius: 12%;
margin: auto;
}
.shave-left-top {
border-top-left-radius: 12%;
}
.shave-right-top {
border-top-right-radius: 12%;
}
.shave-left-bottom {
border-bottom-left-radius: 12%;
}
.shave-right-bottom {
border-bottom-right-radius: 12%;
}
<!DOCTYPE html>
<html>
<head>
<title>Tic Tac Toe Game</title>
<link rel="stylesheet" type="text/css" href="style.css">
<meta charset="utf-8">
</head>
<body class="container">
<h1>Tic Tac Toe Game</h1>
<div class="game-box">
<div class="row-1">
<button class="shave-left-top"></button>
<button ></button>
<button class="shave-right-top"></button>
</div>
<div class="row-2">
<button></button>
<button></button>
<button></button>
</div>
<div class="row-3">
<button class="shave-left-bottom"></button>
<button></button>
<button class="shave-right-bottom"></button>
</div>
</div>
<script type="text/javascript" src="script.js"></script>
</body>
</html>
Hey everyone, struggling to change the button value with my JS code. Encountering an error in the console: SCRIPT7002: XMLHttpRequest: Network Error 0x80700013,
Downloaded the file but it doesn't seem to work, and the same error persists. Seeking help on this issue. Faced a similar problem while building a JS calculator. Posted about it but still no solution. Utilizing Sublime 3 and Edge browser. Appreciate any assistance. Thank you.