0
I can't quite get this to work. Please help!
https://code.sololearn.com/WhXoPlP1FUHR/?ref=app I want this code to when you click the apples button, it shows you the price. I am sure it's just a simple mistake, but help would be very appreciated. Thanks!
3 ответов
+ 1
the problem could be that javascript is executed before the button is created
try to write onclick in the button tag and declare the function in js code like this
https://code.sololearn.com/Wu6VZ7xBC9ww/?ref=app
+ 2
Omg. Thank you so much @matte
+ 1
you're welcome :)