+ 6
Undefined value?
Please tell me qhats wrong with this code https://code.sololearn.com/Ww05laCeNLgu/?ref=app
5 Antworten
+ 5
Change line 36 to:
alert(document.getElementsByClassName("nomove")[0].value)
because you get all the elements with the class name nomove, it returns an array not a single element.
+ 5
Oh yes, i always forget to do that, thanks for reminding Zephyr Koo
+ 4
Jingga Sona 🐺 [ON PROJECT] Seeing your problem was already resolved it would be great if you can mark the answer that you find useful to encourage the community to help each other out. 😉
+ 3
Thanks @rowsej, i learn something now!