Images folder not loading from Github repo to Github Pages - github-pages

Website link hosted on Github pages : https://rohanchoudhary.in
Repository Link: https://github.com/therohanchoudhary/Portfolio-Rohan/
When you try inspect element it doesn't load images folder.

please change your image file extension from uppercase to lowercase. Eg:
<img src="./images/rohan.jpeg" alt="Rohan Choudhary Profile Photo" class="profile-image">
instead of
<img src="./images/rohan.JPEG" alt="Rohan Choudhary Profile Photo" class="profile-image">

I inspected your code, there is a spelling mistake in your Image filename.
The image https://rohanchoudhary.in/images/cloud.PNG is not available on the repository instead there is a image https://rohanchoudhary.in/images/cloud.png available in the repository.
This gives you a 404 File Not Found error.
So you'll need to fix the following:
<img src="./images/cloud.PNG" alt="cloud-img" class="bottom-cloud">
To:
<img src="./images/cloud.png" alt="cloud-img" class="bottom-cloud">
Just rename all the images properly and your error will be solved.

Related

Images not visible while deploying on github

I am facing a problem with the site published using GitHub. The images are not getting displayed when I publish the site. However, it is displayed on my local computer.
The images are present in the img folder.
I am not able to get where is the problem occurring and how to resolve it.
github repo link: https://github.com/Scientist69/Gym-Webpage
GitHub deployment link: https://scientist69.github.io/Gym-Webpage/
try removing the first slash(/) in image links in index.html.
<img src="/img/bg.webp" alt="" />
To
<img src="img/bg.webp" alt="" />

photolouge gallery only uploads one picture

I have a django site with photologue installed, and I followed the official documentation to get it setup. Whenever I go to the admin site to create a gallery I can choose multiple pictures to put in that gallery but once I hit save only the first selected photo gets saved to the gallery. Does anyone know why this is happening. I'm using photologues default template to view my pictures on the front end.
I had the same problem. Looking at web debugger, when loading the gallery page, it says:
Loading failed for the with source http://xxxxxxxx.com/static/sortedm2m/widget.js Loading failed for the with source http://xxxxxx.com/static/sortedm2m/jquery-ui.js
I solved it by:
cd <static_dir>
cp -R .../python3.6/sortedm2m/static/sortedm2m .

project set up using github pages not loading

I hosted one of my project using GitHub pages but, for some reason, when I access the URL the page doesn't loads, and when I check it in the dev console it shows this error.
This is my GitHub page URL: https://prasunk96.github.io/colorsgame/
I checked that all the internal links that I have in my html file are all correct.
I have tried it several times but it showing the same problem again and again.
There are two issues with your CSS link:
It is not relative to your html file so the browser is trying to go directly from the base prasunk96.github.io/ and not include the /colorsgame/.
Github.io urls are case sensitive so your colorGamepro.css isn't being matched to the ColorGamepro.css file.
To correct the relative url you can either add a base tag to your HTML file or use a relative href. Once you correct the file name it should be able to find your file at https://prasunk96.github.io/colorsgame/css/ColorGamepro.css
In short use: href="./css/ColorGamepro.css"
Github project pages can sometime take a bit before being updated. See "My GitHub page won't update its content" for a similar issue.
I do see (a few hours later) a 404 for your css:
Try and see if using an anchored url works better:
<link rel="stylesheet" type="text/css" href="/css/colorGamepro.css">
^^^
|

Github Pages Background Image Not Showing Up

I am new to website building and recently found out how to use Github Pages to build my own website on a domain I bought from Google Domains.
I have the photo I want to display in the hero section in the photos folder, titled hero.jpg. However, once I commit to GitHub, the photo doesn't show up.
I noticed that I cannot access hero.jpg at my-site.com/photos/hero.jpg so maybe this is the problem.
Could someone please advise me on the proper way to specify the path to images in HTML using the url function? Right now, I'm trying background: url("assets/photos/hero.jpg")
Thanks so much in advance!
Though i cannot find the said repository as the link is broken, i got similar issue of displaying background image.
This is my project tree structure
-- assets
-- images
-- image.jpg
-- js
-- css
-- styles.css
index.html
My background image didn't display when i did this
background: url("assets/images/image.jpg")
My background image displayed when i did this instead
background: url("../images/image.jpg")
This has worked for me, i hope it works for you.
On everything except OSX and Windows paths are case sensitive. Change the .jpg in your CSS to .JPG or rename the file in your git repo.

Displaying a PDF from the Blobstore

I have various PDF documents as blobs in the App Engine blobstore. Now, I want to preview them on a HTML page. From various other questions, I figured the HTML setup should be:
<embed src="{{ url_to_my_pdf_blob }}" width="500" height="600">
While experimenting, I found that in the SDK the get_serving_url function will not only work for images but will also work for PDF blobs. This approach unfortunately fails in production.
I looked at the example using blobstore_handlers.BlobstoreDownloadHandler but could not figure out how to wire this to my view (my app is based on Django, the HTML file with the preview is served by a Django view class).
How do I get the url of the blob?
You need to define a ServeHandler, as described here:
https://developers.google.com/appengine/docs/python/blobstore/#Python_Serving_a_blob
For examples of the implementation, see Downloaded filename with Google App Engine Blobstore.