How do you make an image appear when a button is clicked with JavaScript? | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
+ 3

How do you make an image appear when a button is clicked with JavaScript?

I would appreciate if someone could explain the logic behind their code as Iโ€™m new to javascript! Thank you so much in advance! https://code.sololearn.com/WoEqahKki902/?ref=app

14th Feb 2020, 9:01 PM
tori the crafter ๐Ÿ’›
tori the crafter ๐Ÿ’› - avatar
2 Answers
+ 1
thanks Mirielle๐Ÿ‘ฝ did you use jquery?
14th Feb 2020, 11:33 PM
tori the crafter ๐Ÿ’›
tori the crafter ๐Ÿ’› - avatar
0
When the button is clicked, the image element visibility is changed from none to visible
14th Feb 2020, 9:20 PM
Gabriel Ilie
Gabriel Ilie - avatar