Jump to content

Browser differences and centering problems


daddy.j
 Share

Recommended Posts

Hello all, I have recently began playing with css and I like it. I am however having some trouble though. I have two questions that kind of go together. I have made my entire page center using the css. /Index centers fine. None of my others pages center though, they all stay to the left margin. Shouldnt the rules in my css file apply to all pages? I am using IE6 btw. Some people have told me they do center though. Brings me to my secound point. I had someone email me saying they used firefox and the pics were way messed up. So I downloaded firefox and sure enough the layout is all messed up! The weird part is firefox centered every page, it just didnt load them right. IE loads everything right but doesnt center them all....my address is http://rainsuniquepits.bravehost.comAny help with this will be greatly appreciated. Ive been searching css tutorials but cant find what Im looking for. Thanks in advance-John

Link to comment
Share on other sites

Your code is all weird :)View the page source, and you'll see what I mean.It centeres fine in Firefox and you have valid CSS, so that's all good :)I'd work on validating your HTML though.In your CSS, have you tried centering the body itself?I see this is the only thing in your body (the centering you seem to reply on .wrapper)body { height:100%; margin-top:0px; font:normal 12px "times new roman"; background-color:black;}Where you have this in .wrapper (part in red), try adding to the body and see if it centered in IE..wrapper { margin-left: auto; margin-right: auto; position: relative; background: url(theme_images/back2.gif); width:744px;}

Link to comment
Share on other sites

Thank you guys! This is what I was missing:<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">My main page had it but none of the others.. my other problem is with firefox.Click on my males or females tab and you will see what I mean. My layout is all messed up in firefox. I was reading about quirks mode and normal mode on here from a previous thread and it said this could cause extra padding around images and make them all out of wack and I think that may bee what is going on or something along those lines

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...