Codes not working at playground | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
+ 3

Codes not working at playground

Hallo, Can anybody tell what am I doing wrong, because all of this codes doesn’t work in SoloLearn Playground. I wrote them at my iOS device and here is no problem. Thank you Pap https://code.sololearn.com/WAq9wr2xg6S4/?ref=app https://code.sololearn.com/WAP61q424wBd/?ref=app https://code.sololearn.com/W5zwDz9ofTBN/?ref=app https://code.sololearn.com/WiTnDzvSKWQ9/?ref=app https://code.sololearn.com/W3qrutLMG9Kv/?ref=app

1st Mar 2019, 10:11 PM
pap
pap - avatar
9 Answers
+ 5
pap The problem is http, should be https to have it work in playground on pc <script src="https://code.jquery.com/jquery-3.1.1.js"></script>
1st Mar 2019, 11:02 PM
ODLNT
ODLNT - avatar
+ 5
It works for me fine, and I’m using the SoloLearn iOS app.
1st Mar 2019, 10:15 PM
Rowsej
Rowsej - avatar
+ 5
Hmm... because the jQuery needs to load, I would wrap everything in: window.onload = function() { // your code... };
1st Mar 2019, 10:19 PM
Rowsej
Rowsej - avatar
+ 5
ODLNT that was it! I tried it today and it works now! thanks man! Gordon You are right, but the typo was only in my answer not in the code itself. there it was right. cheers
6th Mar 2019, 6:00 AM
pap
pap - avatar
+ 4
It may be the problem, but I’m not sure, because I’m not sure what BrowserKit is.
1st Mar 2019, 10:42 PM
Rowsej
Rowsej - avatar
+ 3
Rowsej thanks for the reply. i wrote the in sololearn ios app and there is no problem here also, but those days i tries them at pc and there was an error with the jquery $(document).ready()... Any ideas?
1st Mar 2019, 10:18 PM
pap
pap - avatar
+ 3
Rowsej I’ll give it a try. My original thought was that it have something to do with “BrowserKit”. Could this also be a solution? like adding BrowserKit?
1st Mar 2019, 10:40 PM
pap
pap - avatar
+ 3
It's $(document).ready Don't (ready)
1st Mar 2019, 11:15 PM
Gordon
Gordon - avatar
+ 3
Pap, you are welcome.
6th Mar 2019, 2:40 PM
ODLNT
ODLNT - avatar