brolyn
January 30, 2020, 12:59pm
1
image framework7 cli path
I’m using cli framework v5, and I’m trying to load an image in my page and it doesn’t work, I created the img folder inside src and I call it as follows:
img data-src="…/img/avatar.png"
img data-src="./img/avatar.png"
Why doesn’t it work?
@brolyn , there is no code in your post.
I think you have too many period characters in your file path. Just try using ‘…’ to move back a folder (two dots, not three or not just one)
https://www.w3schools.com/html/html_filepaths.asp
brolyn
January 31, 2020, 7:24am
5
I have it on two points, it was a mistake to put it here, I’ll correct it:
<img data-src="../img/avatar.png">
<img data-src="./img/avatar.png">
brolyn
January 31, 2020, 10:04am
6
so I got it to show on http://localhost:8080 , but when I compile on iOS or Android you don’t see the image
<img src="../static/img/avatar.png">
I created a directory inside static with the image
thanks.
brolyn
January 31, 2020, 10:12am
7
it’s already solved
<img src="static/img/avatar.png">
thanks