1 reply [Last post]
latempest
latempest's picture
Offline
Regular
UK
Last seen: 6 years 9 weeks ago
UK
Timezone: GMT+1
Joined: 2012-08-06
Posts: 12
Points: 22

HELP,
I have been staring at this CSS and HTML for days now and cannot get it to display correctly in IE. I'm trying to get the minimum to display in version 8, I don't care about IE6 or IE7 but need to get it at least looking reasonable in IE8.

www.bowcora.com

Can anyone tell me why:

1) The header area is displaying further down the page and the background image is not

2) Why is it not centered

It displays and works perfectly in Firefox, Safari and Chrome, but IE is throwing a complete nightmare.

Any help most appreciated!

Thanks

Lee

surajnaikin
surajnaikin's picture
Offline
Enthusiast
india
Last seen: 5 years 30 weeks ago
india
Timezone: GMT+5.5
Joined: 2007-06-09
Posts: 111
Points: 72

there can not be any content above doctype

you've these comment code appearing above the doctype declration, have them in the tag & everything should work in IE.

Existing code

<!--[if lt IE 7]>      <html class="no-js lt-ie9 lt-ie8 lt-ie7"> <![endif]-->
<!--[if IE 7]>         <html class="no-js lt-ie9 lt-ie8"> <![endif]-->
<!--[if IE 8]>         <html class="no-js lt-ie9"> <![endif]-->
<!--[if gt IE 8]><!--> <html class="no-js"> <!--<![endif]-->
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en-gb" lang="en-gb" dir="ltr">
<head>

Updated code

<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en-gb" lang="en-gb" dir="ltr">
<head>
<!--[if lt IE 7]>      <html class="no-js lt-ie9 lt-ie8 lt-ie7"> <![endif]-->
<!--[if IE 7]>         <html class="no-js lt-ie9 lt-ie8"> <![endif]-->
<!--[if IE 8]>         <html class="no-js lt-ie9"> <![endif]-->
<!--[if gt IE 8]><!--> <html class="no-js"> <!--<![endif]-->