I have a javascript application and when I run it on firefox I am getting the following erro on the console:
"The stylesheet was not loaded because its MIME type, "text/html" is not "text/css".
DumbStuck!!
EDIT: Note that it tells that "The stylesheet ABCD..." But ABCD is actually an HTML file.
Edit (ANSWER) : Actually I had wrongly put href=""
, and hence the html file was refenecing itself as the CSS. Mozilla had the similar bug once, and it is from there I got the answer. But everyone's else answers helped me too. Thanks.
To Solve MIME type ('text/html') is not a supported stylesheet MIME type, and strict MIME checking is enabled ErrorJust make Sure Your File name and the name You are Using in Link Tag Both Are Same. For Example my File name is style.
A media type (also known as a Multipurpose Internet Mail Extensions or MIME type) indicates the nature and format of a document, file, or assortment of bytes. MIME types are defined and standardized in IETF's RFC 6838.
In the head section of your html document:
<link rel="stylesheet" type="text/css" href="/path/to/ABCD.css">
Your css file should be css only and not contain any markup.
Actually I had wrongly put href="", and hence the html file was referencing itself as the CSS. Mozilla had the similar bug once, and I got the answer from there.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With