Reply
Header not displaying correctly Firefox, Opera, Chrome
Old 11-25-2008, 09:07 AM Header not displaying correctly Firefox, Opera, Chrome
shonkyboy's Avatar
Extreme Talker

Posts: 203
Name: Chris
Location: West Yorks , UK
Trades: 0
Hi,
I’m wondering if anyone can help – I’m trying to put a header on a site but I'm having difficulty tracking why it wont display properly – I have just put a test header on the site to see how it will look - it looks ok in IE – but, if you view it in Firefox, however, it is offset – same for Google chrome and Opera . Anyone got any ideas?
I have been trying all morning to trace this without luck.
Is this some sort of bug?
The site was based around an origional design and i didn't write all the css - whaich makes it even more fun!

Cheers

Last edited by chrishirst; 11-25-2008 at 09:25 AM.. Reason: formatting removed
shonkyboy is offline
Reply With Quote
View Public Profile
 
 
When You Register, These Ads Go Away!
Old 11-25-2008, 09:27 AM Re: Header not displaying correctly Firefox, Opera, Chrome
chrishirst's Avatar
Super Moderator

Posts: 26,470
Location: Blackpool. UK
Trades: 0
do we get to see it? or take a guess at no DTD
__________________
Chris. ->> Links are advertising NOT optimising!! <<-
Growing old is mandatory - Growing up is optional
Code Samples | Crowded Nightclub? | Bits & Bobs
chrishirst is online now
Reply With Quote
View Public Profile Visit chrishirst's homepage!
 
Old 11-25-2008, 10:02 AM Re: Header not displaying correctly Firefox, Opera, Chrome
shonkyboy's Avatar
Extreme Talker

Posts: 203
Name: Chris
Location: West Yorks , UK
Trades: 0
oh sorry - it should have been www.uk-computers.co.uk/main.asp
shonkyboy is offline
Reply With Quote
View Public Profile
 
Old 11-25-2008, 10:21 AM Re: Header not displaying correctly Firefox, Opera, Chrome
LadynRed's Avatar
Super Moderator

Posts: 9,033
Location: Tennessee
Trades: 0
Get rid of that hideous and deprecated <center> tag. Put a "wrapper" div around the entire layout, set the width to 970px, and set it to margin: 0 auto; to center the entire layout. Also set the wrapper div to position:relative in case you want to position anything inside it, those get positioned relative to the centered wrapper instead of the body.

You have a 960px header, centered inside a 970px #mainheader - so of course it's not going to line up exactly with the rest of your page. You also need to understand the box model and how it works because your ADDING width to the box with margins and padding - which will push things out.

You're also triggering the doubled-float margin bug in IE6 with the float:right with a right margin on the nav in your header.

1 more thing - z-index ONLY works on elements that are absolutely or relatively positioned - putting it on anything else is a waste of time.
__________________
Web Goddess & Web Standards Evangelist :) - Tables Be Gone !!
"Using or working with IE is like having to wear a 1970's polyester suit with pantyhose and a girdle, to work everyday"
Carolina Corvette Club
LadynRed is offline
Reply With Quote
View Public Profile
 
Reply     « Reply to Header not displaying correctly Firefox, Opera, Chrome
 

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off





   
RSS Feed  Feeds: RSS   JS   XML
RSS Feed  Feeds for this forum: RSS   JS   XML

 


Page generated in 0.09117 seconds with 13 queries