• This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn more.

RESOLVED JavaScript not executing

Temyk

Developer & Support
Staff member
Messages
1,102
Likes
40
Points
48
#2
Hello.

Error in your snippet code. The plugin does not affect the operation of your code in any way
1671434879012.png
 

JeanDuc

New member
Messages
3
Likes
0
Points
1
#3
This code works perfectly anywhere else!


<style>
h1 {
font-size: 22px;
}
p {
font-size: 75%;
}
</style>
<script>
function myFunction($nb) {
var x = document.getElementById($nb);
var v=x.value;
v=v.toLowerCase();
var lc=atob(x.name);
lc=lc.toLowerCase();
n="p"+$nb;
var p = document.getElementById(n);
if (v==lc)
{
p.innerHTML=$nb+". <b>"+x.value.toUpperCase()+"</b> (BON)";
p.style.color = "green";
}
else
{
p.style.color = "red";
p.innerHTML=$nb+". <b>"+x.value.toUpperCase()+"</b> (FAUX)";;
}
}
</script>
<h1>Jeu du Fantôme de l'Astroballe</h1>
<p>Quelle personne réelle se cache derrière les quarante-cinq pseudonymes suivants ?</p>
<p>Les personnes suivantes gravitent autour de l'ASVEL (personnel, joueurs, journalistes).</p>
<p>Respectez STRICTEMENT l'orthographe des noms. Au besoin, utilisez Wikipédia...</p>
<hr>
<br><p id='p1'>1 Alain Pointeix ::<input type='text' id='1' name='QWxhaW4gQ2xvdXg=' size="33"> <button onclick='myFunction(1)'> Vérifier </button></p>
<p id='p2'>2 Alicia Clerk ::<input type='text' id='2' name='QWx5c2hhIENsYXJr' size="33"> <button onclick='myFunction(2)'> Vérifier </button></p>
<p id='p3'>3 Antonio Salchicha ::<input type='text' id='3' name='QW50b2luZSBEaW90' size="33"> <button onclick='myFunction(3)'> Vérifier </button></p>
<p id='p4'>4 Antwan Parcoeur ::<input type='text' id='4' name='VG9ueSBQYXJrZXI=' size="33"> <button onclick='myFunction(4)'> Vérifier </button></p>
<p id='p5'>5 Antônio Pernãoboca Junhor ::<input type='text' id='5' name='QW50w7RuaW8gQXVndXN0byBSaWJlaXJvIFJlaXMgSsO6bmlvcg==' size="33"> <button onclick='myFunction(5)'> Vérifier </button></p>
<p id='p6'>6 Caetano Meunier ::<input type='text' id='6' name='R2HDq3RhbiBNw7xsbGVy' size="33"> <button onclick='myFunction(6)'> Vérifier </button></p>
<p id='p7'>7 Carlito Couaty ::<input type='text' id='7' name='Q2hhcmxlcyBLYWh1ZGk=' size="33"> <button onclick='myFunction(7)'> Vérifier </button></p>
<p id='p8'>8 Claude de la Bergerie ::<input type='text' id='8' name='TGF1cmVudCBkZSBsYSBDbGVyZ2VyaWU=' size="33"> <button onclick='myFunction(8)'> Vérifier </button></p>
<p id='p9'>9 Dave Causette ::<input type='text' id='9' name='RGF2aWQgQ296ZXR0ZQ==' size="33"> <button onclick='myFunction(9)'> Vérifier </button></p>
 

Temyk

Developer & Support
Staff member
Messages
1,102
Likes
40
Points
48
#4
I see that you have solved the problem?