Please can some help me out? I don't know why am getting the error and hiw to fix it. | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
+ 1

Please can some help me out? I don't know why am getting the error and hiw to fix it.

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

29th Jul 2018, 9:59 PM
Reward
Reward - avatar
2 Answers
+ 3
Mishin870 thanks bro i appreciate alot
29th Jul 2018, 10:14 PM
Reward
Reward - avatar
+ 1
Your problem is that the element #wss is loaded after you get it through document.getElementById(). So it is null. Working version: https://code.sololearn.com/WcUZJDToJe1L/#js
29th Jul 2018, 10:12 PM
Mishin870
Mishin870 - avatar