0
HELP ! Js sololearn code editor doesn't work for me !
I was trying to try hiding some element in my html by giving the command (document.getElementById ('hide').style.display = 'none';) but I always find this answer (Uncaught typeError: cannot read property 'style' of null line:2 ) and if did the same code inside of an html doc or in another word Internal js it work normal <html> <head> <title></title> </head> <body> <div id="hide">Lets go to school tomorrow</div> </body> </html> this is my html code
2 odpowiedzi
+ 1
Do you have any HTML element with id = 'hide'?
+ 1
yes I have an id of hide inside of div element