derniers ajustements
This commit is contained in:
parent
da54a002e3
commit
b1c5fe657f
2 changed files with 6 additions and 3 deletions
|
@ -4,12 +4,14 @@
|
|||
<meta charset="UTF-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<title>Prog Web Legend</title>
|
||||
<script> alert("click")</script>
|
||||
</head>
|
||||
<body>
|
||||
<p>Click</p>
|
||||
<script src="./js/intro.js" deref></script>
|
||||
<script src="./js/element.js"></script>
|
||||
<div id="divButton_score">
|
||||
|
||||
</div>
|
||||
<table>
|
||||
<thead>
|
||||
<th>nom</th>
|
||||
|
|
|
@ -4,14 +4,15 @@ document.addEventListener("click",firstClick)
|
|||
|
||||
|
||||
function firstClick(){
|
||||
let position_button=document.getElementById("divButton_score")
|
||||
const click = document.createElement("button")
|
||||
click.innerText="click"
|
||||
document.body.appendChild(click)
|
||||
position_button.appendChild(click)
|
||||
|
||||
const scoreAff = document.createElement("output")
|
||||
scoreAff.innerText="SCORE"
|
||||
scoreAff.id = "score_affichage"
|
||||
document.body.appendChild(scoreAff)
|
||||
position_button.appendChild(scoreAff)
|
||||
click.addEventListener("click",scoreCount)
|
||||
document.removeEventListener("click",firstClick)
|
||||
|
||||
|
|
Loading…
Reference in a new issue