Web Server tomcat is not loading the ie related css - css

I have an issue with css.
I have a css file which has ie specific css clauses..Like
.ie7 #div
.ie #table
These css is working good in my local on tomcat server.
But the same css is not loading in IE in my dev system which is also running on tomcat.
When I debug the ie is not recognizing the ie specific css clauses. Also I found out that
the IE is not recognizing even the section and header tags.
Please let me know what can be the work around.
Thanks for your time and help.
Regards,
Varma

Assuming you're running IE9..
Make sure you don't have Compatibility Mode turned on, and make sure you have a valid doctype as the very first line to trigger Standards Mode:
<!DOCTYPE html>
If it still doesn't work, then add this meta tag:
<meta http-equiv="X-UA-Compatible" content="IE=edge">
Concerning this point:
Also I found out that the IE is not recognizing even the section and
header tags.
In older versions of IE, you need this to make the HTML5 semantic tags work properly:
http://code.google.com/p/html5shiv/

Related

Why is this CSS:before statement not working in IE 8, IE9?

Using a :before CSS to get an image/icon here (see round circle in image below), but in Internet explorer 8+ it is just not showing up.
This is the site:
http://www.websiteprofessioneel.nl
Image link below shows right element (it's the icon in the first post header) as circled on this screendump
http://tinypic.com/view.php?pic=xxd9f&s=5#.Ul_WajZRoWY
this is the CSS for that:
.welpen h2:before {
content: url("/wp-content/uploads/z-welpen-category-small.png") !important;
}
Anything missing perhaps? All other browsers work fine and as far as I know peudo CSS is totally supported in at least IE9, but it's not working in both IE8, 9 and up.
IE is Probably Using Quirks Mode
Internet Explorer can run in quirks or standards mode. The purpose of quirks mode was to make the new standards-compliant IEs (8+) able to read and process the code people had previously written for IE7-.
Likely Reason #1: invalid or absent DOCTYPE declaration
Try specifying this on the first line of your HTML document:
<!DOCTYPE html>
Make sure the <html> element is present. Even though HTML5 specification says it's not needed, older IEs (10 and older) tend to enter quirks mode when it's not specified.
Likely reason #2: site fails (X)HTML validation
If this is present, make sure the W3C validator throws no errors as these can also trigger Quirks Mode in IE. Yours has 15.
Actual reason was more unlikely: deliberately triggering Quirks Mode
After comments discussion, turns out I was right about the quirks mode, but wrong about the reason. Make sure you don't have any meta tags telling IE to run in quirks mode such as this:
<meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7" />
problem is because of something wrong in doctype, use <!DOCTYPE html> for html5 and to make it working on ie8 use
<!--[if IE]>
<script src="http://html5shiv.googlecode.com/svn/trunk/html5.js"></script>
<![endif]-->
if you don't want html5 then use
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
this will fix the problem i think

Force Internet Explorer 9 into Quirks Mode

I have a web design class and our teacher wish's for us to force a browser into quirks mode.
Is their any CSS feature or html 5 feature that will do the job? Its for a discussion question but I need to make a simple webpage.
Don't provide a doctype, it will go into quirks mode on its own.
<html>
<head>
<title>I'm in Quirks Mode</title>
</head>
<body>
<p>Quirks mode supports the JavaScript functionality of
IE6, and the Quirks mode of IE7 and IE8.</p>
</body>
</html>
If you need something to cite:
If your webpage uses one or more features that require IE9 mode and you do not include a standards-compliant !DOCTYPE directive, Internet Explorer 9 displays, by default, your webpage in IE5 (Quirks) mode, which does not support features that require IE9 mode. source
Additionally you can force it into Quirks Mode via the developer tools as well; just press F12 and change the Document Mode. Note that this method is usually only used for quick testing, and affects your local copy only.
Adding any HTML comment block above your tag will throw IE9 into Quirks Mode!
Like this
<!-- -->
<!DOCTYPE html>
<html>
Source http://timjames.me/force-ie9-into-quirks-mode
try without doctype but it wont be a good idea
or try
<!-- -->
<!DOCTYPE html>

HTML5 lining up in Firefox and Chrome but not at all in IE

http://www.grossmag.com/2012/september/home.shtml
This link works in both Firefox and Chrome. I am not sure why it won't line up correctly in IE. I am trying to convert from old style tables/td's/tr's and this will be great if I can find out why it isn't lining up in explorer.
Sounds like your site is being viewed in compatibility mode in IE. This can depend on the DOCTYPE of your document.
To cause IE to display using the default mode of the current version, use the following META tag
<meta http-equiv="X-UA-Compatible" content="IE=edge" >
This will not fix the site for IE7 (for example). If you wish to do that, then you will likely need to create custom CSS rules for older browsers

Internet Explorer 9 ignores my Stylesheet

I am currently setting up a new page and wanted to test it with the Internet Explorer (9). I thought it was not going to be a problem, because it does work with FireFox, Opera, and Chrome (newest Versions). However, the IE does not attempt to load my style sheet.
I already searched Google and stackoverflow for an answer, but nothing helped.
My page looks as follows:
<!DOCTYPE HTML>
<html>
<head>
<title>Hello World</title>
<meta charset="UTF-8">
<link href="css/main_styles.css" rel="stylesheet" type="text/css">
</head>
<body>
etc.
Any ideas?
Thanks for your help in advance!
PS: I validated the page and the css styles. No errors found.
Edit (July 2014):
Hey, I'm sorry I forgot to update this question for so long. The answer is simple. I had to put #charset "utf-8"; at the beginning of my stylesheet. That's all it took to make it work. Cheers!
Try changing the reference of the link: href="/css/main_styles.css" or href="../css/main_styles.css"
The most obvious possible cause I can think of for this would be that your server is providing the wrong mime type of the CSS file. It might be that IE is more picky about this sort of thing than the other browsers you've tested.
Check what the mime type is by checking the HTTP headers, either in one of the other browsers debugging tools or with an HTTP sniffing program like Fiddler.
Fiddler will also be good for sniffing exactly what is going on when you try to make the request using IE. Whether it's a mime type issue or something else, this will be the best way to find out exactly what's happening.
Finally, you could also try opening the stylesheet's URL directly in IE. That will prove that IE can access the URL.
Hope that helps.
We had this issue with Internet Explorer 11, it's weird but if you rename the stylesheet to anything without the word "style" it will start working!
This is only the case when the accessing the file local on a machine, on a web server it will work fine

IE not rendering CSS properly when the site is located at networkdrive

This is kinda weird problem we came across with my friend. We located our site at network drive and tried to open it from there. All other browsers render this page just fine but IE (btw. why it's always IE? :) ) can't understand inline-block statement. But if I copy our file to my local drive there is no problem, IE renders everything just like other browsers.
I tested this with IE7-9b.
This sounds like that problem - where IE switches rendering modes depending on where the page is located.
It's insane.
See this answer.
http://127.0.0.1/mysite/mypage.php <-- IE8 by default (updated!)
http://localhost/mysite/mypage.php <-- IE8 by default (updated!)
http://machinename/mysite/mypage.php <-- IE7 by default
http://192.168.100.x/mysite/mypage.php <-- IE7 by default
http://google.com/ <-- IE8 by default
So, because you're accessing your site via "network drive", IE is going into IE7 mode, and IE7 does not support inline-block properly, hence your site does not render properly.
You can request IE8 to render your page in IE8 mode by adding this to your page:
<meta http-equiv="X-UA-Compatible" content="IE=8" />
Or, to request IE8 to use the most recent version of it's rendering engine (think IE9), you should use this:
<meta http-equiv="X-UA-Compatible" content="IE=Edge" />
Or, to use Chrome Frame instead if it's available:
<meta http-equiv="X-UA-Compatible" content="IE=Edge,chrome=1" />
Use an admin account. IE may Denies access to network drive if not admin.

Resources