|
| |
|
|
derbz
Posts: 1 Joined: 8/7/2006 Status: offline
|
Fun with IE - 8/7/2006 3:11:47
Is there an alternative to 'margin: 0 auto;' it seems that IE does not honor it. FireFox centers fine ie6 does screwy things with text-align too. I'm having trouble finding an answer. Please help xweb
|
|
|
|
Tailslide
Posts: 6290 Joined: 5/10/2005 From: Out here on the raggedy edge Status: offline
|
RE: Fun with IE - 8/7/2006 3:24:09
Yeah no problem. Firstly, if you add in a proper DOCTYPE then IE6 will honour the margin:0 auto; thing. Without a proper DOCTYPE IE6 reverts to non-standards mode and as you've found out ignores it. The other thing you can do (either with a DOCYTPE to catch IE5 and IE5.5 or without a DOCTYPE to work on IE6 too) is to add text-align:center to the body element which will centre the whole page in IE. Then you normalise the text by adding in text-align:left usually to a containing div lower down in the order so it's like this: body {text-align:center; (all your other rules here too)}
#container {margin:0 auto; text-align:left;}
_____________________________
"My strategy is so simple an idiot could have devised it" Little Blue Plane Web Design | Blood, Sweat & Rust - A Land Rover restoration project
|
|
New Messages |
No New Messages |
Hot Topic w/ New Messages |
Hot Topic w/o New Messages |
Locked w/ New Messages |
Locked w/o New Messages |
|
Post New Thread
Reply to Message
Post New Poll
Submit Vote
Delete My Own Post
Delete My Own Thread
Rate Posts
|
|
|