Internet Explorer is not showing CSS at all
I have gone over the entire file including validating and sniffing out missing or out-of-place characters.
I have also removed all but a couple lines of the CSS file and tried this as well.
Internet Explorer is simply not showing CSS 开发者_如何学Cwhile FF, Chrome, and Safari all have no issues.
Anybody know of a setting in IE that may have been changed or a possible schema I am missing/using that could cause this?
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head profile="http://www.w3.org/2005/10/profile">
<meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7"/>
<meta http-equiv="Content-Type" content="text/html;charset=ISO-8859-1" />
<meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7"/>
<meta http-equiv="content-LANGUAGE" content="EN"/>
<meta name="ROBOTS" content="ALL"/>
<meta name="revisit-after" content="14 days"/>
<meta name="resource-type" content="document"/>
<meta name="distribution" content="Global"/>
<meta name="rating" content="General"/>
<link rel="stylesheet" type="text/css" href="http://www.****************.css" />
<script .......
</head>
You have 2 <head>
elements on your page:
<head>
<head profile="http://www.w3.org/2005/10/profile">
Maybe it's the fact that you have an extra <head>
tag within your <head>
tag that's confusing IE?
<head>
<!-- snip other stuff ... -->
<head profile="http://www.w3.org/2005/10/profile">
<link rel="stylesheet" type="text/css" href="http://www.**************.css" />
If removing that doesn't work, then I would recommend trying to produce a minimal example that demonstrates your problem. Start by removing all of the content, except for an example to show that the style isn't being applied. Then remove more and more of your headers and code, until you find a small example in which the problem is still present, but it has nothing other than the bare minimum to demonstrate the problem. The process of doing that might help you to find your own problem; but if not, then you can post a complete example here, by editing your question, and we can give better advice based on actual code that demonstrates the problem, as opposed to an incomplete excerpt that doesn't contain enough information to determine what's wrong. Remember to post both the HTML and CSS for your example.
You have duplicate <meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7"/>
declarations. This declaration should only appear once and should be the first thing in your <head>
.
Check for rel
attribute and type
attributes in the link tag used to include the css file.
For example:
<link rel="stylesheet" href="styles.css" type="text/css" />
Declare a Doctype
<!DOCTYPE html>
You have a head tag inside your head tag, right before the link tag. Remove that and see if it helps.
Apparently, css rules only apply to documents listed as text/html
http://www.w3.org/MarkUp/2004/xhtml-faq#css
Could this be the issue?
精彩评论