Skip to content

Github pages' images not working #23086

Answered by Gisgar3
amagalla1394 asked this question in General
Feb 17, 2022 · 19 comments · 42 replies
Discussion options

You must be logged in to vote

You should be able to call back to the parent directory so you can pull the images from there. I’d say that’s good practice. Looking at your repository now, the reason the images won’t display is because there’s no period at the start of the specified path. Instead of:
<img src="/images/lasagna.png" alt="lasagna">
use
<img src="./images/lasagna.png" alt="lasagna">

I tested it on my end and it fixed the issue. Hope this helps out!

Replies: 19 comments 42 replies

Comment options

You must be logged in to vote
9 replies
@alaina96
Comment options

@Gisgar3
Comment options

@alaina96
Comment options

@manel118
Comment options

@Abunnasarmomin
Comment options

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
23 replies
@WDWaleed
Comment options

@dnahol
Comment options

@supunrathnayake007
Comment options

@codingwithkushal
Comment options

@omrojas
Comment options

Answer selected
Comment options

You must be logged in to vote
1 reply
@randomswords
Comment options

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
1 reply
@hafizafiz
Comment options

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
3 replies
@iamnexxed
Comment options

@bell-kevin
Comment options

@bell-kevin
Comment options

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
1 reply
@MarczanHub
Comment options

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
1 reply
@WDWaleed
Comment options

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
1 reply
@V-Rezende
Comment options

Comment options

You must be logged in to vote
1 reply
@BigYajuu
Comment options

Comment options

You must be logged in to vote
1 reply
@supriya101
Comment options

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet