0

The onclick button is not functioning, any idea what might have caused this?

https://code.sololearn.com/W7Zha2qqw2ZB/?ref=app

16th May 2019, 3:23 PM
Adefisoye Ayomide
Adefisoye Ayomide - avatar
2 RĂ©ponses
+ 1
It's the usual problem here of JavaScript running before the HTML is fully loaded. To fix it, simply encase everything in the JavaScript tab within: window.onload = function(){ All of your current JavaScript here } That will cause the JavaScript to not run until the HTML is fully loaded and so fixes that error.
16th May 2019, 3:25 PM
Decimis † 𝕯𝖊𝖈𝖎𝖒𝖎𝖘
Decimis † 𝕯𝖊𝖈𝖎𝖒𝖎𝖘 - avatar
+ 1
Thank you very much
16th May 2019, 3:30 PM
Adefisoye Ayomide
Adefisoye Ayomide - avatar