ryan.od Posted November 22, 2006 Share Posted November 22, 2006 OK, I am using the following technique for centering my page:#container{ width:800px; margin:0px auto;}This has worked fine until I installed and tested it in IE7. Now, when I scale the text down, the page slides off to the left.Anyone have any thoughts on this?The page is www.finwebdesign.comThanks.RyanOD Quote Link to comment Share on other sites More sharing options...
wildteen88 Posted November 22, 2006 Share Posted November 22, 2006 Not sure what you mean there. I have IE7 installed and your site display fine when Window is maximixed (1280 x 1024) and when I reduce the width of the window until I cannot resize the window any smaller (100px or so) , Instead i get a horizontal scroll bar, which is the same behaviour I get with FF too. Quote Link to comment Share on other sites More sharing options...
exploo Posted November 25, 2006 Share Posted November 25, 2006 I haven't checked your site with IE, but i remember having a similiar problem with a site i made.I had to set body { text-align: center; }to get the container centered in IE.and of course also text-align: left; in the container../Magnus Quote Link to comment Share on other sites More sharing options...
ToonMariner Posted November 26, 2006 Share Posted November 26, 2006 you sohould not use text-align to centre block level elements.In order to get margin: auto to work in centering a page the parent container must be given some width - either % or fixed width. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.