__/ [Pierre Jelenc] on Tuesday 20 September 2005 00:30 \__
> The demo page at http://www.robschwimmer.com/tmp/test.html has a menu at
> the bottom, which should be centered 50 pixels from both left and right
> edges. As the dotted green line around the enclosing div indicates, it is
> --in Mozilla at least-- actually pushed to the right.
> Both HTML and CSS validate fine (there are some warnings on the CSS having
> to do with color, but that's deliberate for the way I set the text
> Any idea what's happening?
There is a way of forcing divs to lie in the centre using some negative
values, but I could not find a reference. What you are trying to do will
not work in the Mozilla renderer. The margin-right will be ignored. You can
either compromise and go for:
"margin-left: 50px; width: 90%;"
which in practice looks quite OK if I reside the window quite widely. Also,
consider adding two fixed-sized divs to the left and the right of your
menu. Not elegant, but does the trick
__/ [RobG] on Tuesday 20 September 2005 05:52 \__
> Get rid of the 50px margin-left/right.
This doesn't appear to be "doing the trick" in Firefox.
Roy S. Schestowitz | "Free the mind, the source will follow"
http://Schestowitz.com | SuSE Linux | PGP-Key: 74572E8E
7:35am up 25 days 19:49, 3 users, load average: 1.22, 0.65, 0.44