From 0457ead04a39e77afd1f00e457ccb3d5c10eda19 Mon Sep 17 00:00:00 2001 From: quegzacov Date: Mon, 2 Jan 2023 11:21:54 +0100 Subject: [PATCH] 3.141592653589793238462643383279502884197197 --- index.html | 4 ++-- script.js | 6 ++++++ 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/index.html b/index.html index f70355f..34f403a 100644 --- a/index.html +++ b/index.html @@ -17,8 +17,8 @@

- Ajouter quelqu'un: - + Ajouter quelqu'un: +
diff --git a/script.js b/script.js index 4220c0e..83a0057 100755 --- a/script.js +++ b/script.js @@ -75,3 +75,9 @@ function validateForm() { names.push(x); draw_roulette(200,200,200, names); } + +document.getElementById('submit').addEventListener('click', function(event){ + event.preventDefault(); + names.push(document.getElementById("entry").innerText); + draw_roulette(200, 200, 200, names); +})