Feedback welcome! I couldn't get the css to load on GitPages. Any advice for that? Thanks.
Chris
@WebDevRockAll comments
- @whunter413Submitted about 2 years ago@WebDevRockPosted about 2 years ago
Hi Will,
Your link to your stylesheet and also to your images in the html and in the stylesheet are referencing the root directory "/" which is incorrect when you host on GitPages.
You should fashion the links to be relative to where they're being called from so "/css/styles.css" would become "./css/styles.css"
From there you'll notice your images won't show either so you'll need to do the same to any reference to your images bearing in mind that the image referenced in your CSS is one level up from your css folder so "background-image: url(/images/image-product-desktop.jpg);" becomes "background-image: url(../images/image-product-desktop.jpg);"
Hope that makes sense
Marked as helpful1