Normalize.css <link> not working

html
css

#1

http://prnt.sc/cauavm you can see the "link rel = “stylesheet” style = “text/css” href = “/css/normalize.css” because I have my normalize.css in my folder “css” http://prntscr.com/caubod

The problem is, the linking of the css seems to be glitchy. ex, im going to change the font to “fantasy” and then it looks like a different font.

But, when I open the preview, or switch out of the CSS development tab, it turns back to fantasy font

and when I refresh again, it becomes the standard font again

(this continues every time I refresh it, and in the workspace, it kind of just flips back and forth between the standard font and the fantasy font… I’m not sure what is happening.

Then, when I save the css file, it just stays at the normal font, and doesnt change.

same with the development preview

Anybody have a solution? Or how to do a normalize.css in cloud9?


#2

I could not post the screenshots, because “new members cannot post more than 2 links”


#3

both screenshots seem to be broken.
Could you share a link to the ide, if it’s a public workspace, someone can help you to debug the issue


#4

https://ide.c9.io/orange0401/portfolio
does that work?


#5

when you open preview as https://preview.c9users.io/orange0401/portfolio/index.html your css will be at https://preview.c9users.io/orange0401/portfolio/css/normalize.css, but href = "/css/normalize.css" tries to load https://preview.c9users.io/css/normalize.css instead which doesn’t exist. Use relative path like href = "./css/normalize.css"


#6

Try Typing This Link:

< link rel=“stylesheet” type=“text/css” href="/css/normalize.css" />

<link not < link to be able to see it

i hope is works :slight_smile:


#7

Thank you, I did the “/css” because I thought that WAS the format for a relative link, how does the “.” in front of the “/css” change it?


#8

say you have a page at https://example.com/my/site/index.html, then
//otherdomain.com/some/path will take protocol from current url and resolve to https://otherdomain.com/some/path
/otherdomain.com/some/path will take domain https://example.com/otherdomain.com/some/path
some/path or ./some/path will be relative to the index.html: https://example.com/my/site/some/path
and “…/some/path” will go one level up https://example.com/my/some/path

see https://developer.mozilla.org/en-US/docs/Learn/Common_questions/What_is_a_URL


#9

so in other words, the “.” clarifies that it is a relative domain? (sorry, I must fully understand something before I use it too often)