Hey there everyone, i am having difficulties trying to code my css file so that it correctly displays my website in Firefox and Internet Explorer as intended.

I have validated both my html and css yet that still hasnt resolved alongwith identifing the charset in different areas within the head of the html file. My webiste is to understand what i am talking about.

Can anyone walk me through what I need to do to get a solution?

Any help would be much appreciated as this is slowly giving me a headahce.

Thanks alot

Dani AI

Generated

In this case reported that styles were not applying in Firefox and Internet Explorer; correctly identified a malformed stylesheet link and that resolved the immediate problem. The following checklist and quick diagnostics help catch related causes so the fix holds across browsers and server setups.

The browser developer tools are the fastest way to confirm delivery and application: open DevTools (F12) → Network tab → reload and locate the stylesheet request. Confirm an HTTP 200 response and that the response body is the CSS file (not an HTML error page). The command line can also show headers, for example:

curl -I https://example.com/path/to/style.css

If headers look wrong or the request returns an HTML page, the issue is server-side (wrong path, permissions, or header configuration).

Common additional causes and remedies: ensure the link element sits inside <head> and uses valid attributes; configure the web server to send the correct Content‑Type mapping for .css files; remove any UTF‑8 byte-order mark from the start of the CSS file (save as UTF‑8 without BOM); verify file permissions so the webserver can read the file; and use a standards DOCTYPE to prevent IE compatibility/quirks modes. Place the charset declaration early in the <head> (before resources) to avoid encoding surprises. Caching can mask fixes—clear the browser cache or test in private/incognito mode.

A final isolation step is to place the CSS inline in a small <style> block in the head: if inline rules render, the delivery (path/headers) is at fault; if inline rules also fail, validate CSS syntax and check selector specificity. Credit to for finding the malformed link — the extra checks above make the solution robust across browsers.

Recommended Answers

All 3 Replies

You aren't linking to your style sheet correctly, instead of:

<link href="./css/style.css" type="style/css" charset="utf-8" rel="stylesheet">" it should be
<link rel = "stylesheet" type = "text/css" href = "/css/style.css" />

Note the 'text/css'

AHarrisGsy! Your a Legend thank you soooo much was doing my head in.

Thanks alot mate

No Problem, don't forget to mark the question as solved so that others know (and a thumbs up wouldn't hurt.... :P)

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.