I am completely stumped as to why this doesn\'t work. It seems the HTML file can\'t load the CSS for some reason, even though both are in the same directory. Any idea what m
I was having similar problem but resolved changing the Style.css to style.css Because of this name caps letter "S"change it was throwing 404 error we won't notice small changes in my system it was working but when I hosted in cloud it was throwing this error make sure this all being checked after uploading in cloud
After digging and digging on this issue, for me it was solved by Johannes on another thread: Local CSS file is not loading from HTML
The
type
attribute in yourlink
tag has typographical quote characters:type=“text/css”
. Try to change these to "plain" quotes liketype="text/css"
Your css file should be defined as UTF-8. Put this in the first line of you css file.
@charset "UTF-8";
You have to add type="text/css"
you can also specify href="./style.css"
which the .
specifies the current directory
You could try this:
<link href="style.css" rel="stylesheet" type="text/css" media="screen, projection"/>
Make sure that the browser actually makes the request and doesn't return a 404.
guys the best thing to try is to refreash the whole website by pressing ctrl + F5 on mac it is CMD + R