Why isn't my image loading | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
+ 3

Why isn't my image loading

I uploaded the image to google drive then i used the link in the src attribute Am using a phone https://code.sololearn.com/WO9vdpUjJR23/?ref=app

10th Jun 2019, 2:29 PM
YaYa
YaYa - avatar
6 Answers
+ 8
Remove www and put dl...and check your code https://code.sololearn.com/WQZ73KUvEWG0/?ref=app
10th Jun 2019, 3:56 PM
Hëllo Wörld🔰
Hëllo Wörld🔰 - avatar
+ 4
https://code.sololearn.com/WAYZjgRJO0uz/?ref=app
10th Jun 2019, 2:37 PM
Calviղ
Calviղ - avatar
+ 3
Google drive by default does not allow you share image without api key. I just open your link from a browser, use devtool to find the image link. However this link maybe temp link, could be not effective later.
10th Jun 2019, 3:22 PM
Calviղ
Calviղ - avatar
+ 2
Can you explain to me how you fixed it?
10th Jun 2019, 2:41 PM
YaYa
YaYa - avatar
+ 1
#Part 2 This started to become tricky as the url comes with token/signature that will expire after a specific duration to prevent hotlinking. Therefore if you would like to embed cloud hosted image in your website, make sure that it supports hotlinking or at least the url resolves to a valid image. Hopefully it helps! 😉
10th Jun 2019, 3:26 PM
Zephyr Koo
Zephyr Koo - avatar