Search code examples
githubgithub-pages

Image not displaying on github pages


I am building a portfolio blog on github I created a folder name img with the image mobil.PNG this image load and display with github when viewing the portfolio on github but does not show on the actual site, it shows a broken file link. This is the path to the file https://github.com/desmond75/desmond75.github.io/blob/master/img/mobil.PNG This img folder is at the root level of the directory this is how I am referencing the file

![Here is the alt text](https://github.com/desmond75/desmond75.github.io/blob/master/img/mobil.PNG "Here is the Title text")

tutorial


Solution

  • The "copy path" button on that page will give you the correct path to a usable image: https://desmond75.github.io/img/mobil.PNG

    So, in markdown:

    ![Here is the alt text](https://desmond75.github.io/img/mobil.PNG "Here is the Title text")
    

    And the rendered output, with the alt-text:

    Here is the alt text