What is wrong with my code? | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
+ 6

What is wrong with my code?

Why is it not loading as normally? It worked fine until i made a few improvements at the images. Please help! 😩😩😩 The last time i checked it WORKED FINE on PC , but on phone it takes a lot of time to load and it leave a white screen while scrolling. https://code.sololearn.com/WNhi7hQJ3jSm/?ref=app

28th Dec 2018, 10:15 PM
🍇 Alex Tușinean 💜
🍇 Alex Tușinean 💜 - avatar
8 Answers
0
Whether appear one question each time or appear all at same time is not the problem. The problem is because you try to set cursor style which mobile does not have. Remove all cursor styling on li and loading can become fast again
29th Dec 2018, 6:52 AM
Gordon
Gordon - avatar
+ 5
If i add a confirm box... Asking the user if he uses pc or phone and use js to make the cursor settings only if the user is on pc... And if hes on phone the cursor will not appear.
29th Dec 2018, 9:31 AM
🍇 Alex Tușinean 💜
🍇 Alex Tușinean 💜 - avatar
+ 4
What if i would make only one question per time to appear. , and use a "Next Question" button to hude the last question and show the next one.
29th Dec 2018, 5:22 AM
🍇 Alex Tușinean 💜
🍇 Alex Tușinean 💜 - avatar
+ 2
I noticed that your html is particularly difficult to parse because the value are not contained in quotation marks. Revise all attributes like this way id="something.ro"
29th Dec 2018, 2:26 AM
Gordon
Gordon - avatar
+ 1
I think that you "display" too many things same time even though they all don't fit in the screen.
28th Dec 2018, 10:56 PM
Seb TheS
Seb TheS - avatar
+ 1
<li style=cursor:pointer; Change all these to 1. Only li in html 2. In css li{ cursor:pointer; }
29th Dec 2018, 2:28 AM
Gordon
Gordon - avatar
+ 1
I think in a PC, it knows cursor and do that directly. In mobile, it doesn't know what cursor is, so the mobile browser takes some time and figure out : "OK, I'm going to ignore this" each time it comes across this attribute style of li
29th Dec 2018, 2:29 AM
Gordon
Gordon - avatar
+ 1
Yes you can add cursor style for computer only That's @media @media only screen and (min-width: 500px) { li { cursor:pointer; } } Add above to CSS, then when screen width less than 500px (mobile), no cursor style will be set.
29th Dec 2018, 9:52 AM
Gordon
Gordon - avatar