You have float right and left but not center.
It occasionally would be nice to flow content around both sides of an
element. It would also be nice to be able to flow content above and
below an element. But you're not really talking about floating in the
rest of the post so let's not go down that road.
To center something you have to scratch your head a lot and use some tricks.
There are simple methods to float block and inline items in CSS.
The only tricks needed are for IE5 which gets it wrong.
With IE and Front Page I can center anything without any tricks!
How do you know? What tricks are going on under the hood? If it's
centering in IE5 then it's either using deprecated code or a trick.
Maybe MS is bad but I can center anything without any problems.
Just press the button and select - center.
So what? A decent HTML/CSS editor could easily use the valid CSS
methods for centering and tie them to a single button.
Can someone tell me a reason, why to center something in css is such a
drama and people are asking so many question at alt.html?
And if is hard to center, who's fault it is?
It's not hard, but if you want to start pointing fingers:
Netscape's for inventing the crude <center>.
Microsoft for copying them.
The W3C for using the propertry name text-align rather than
inline-align.
The W3C for saying that <center> = <div align=center> = <div
style="text-align: center"> despite the fact that <center> has always
centered block level children as well, though as tables were the only
block level children with widths less than 100% in pre-CSS days the
problem wouldn't be as widespread if not for the next one...
Microsoft for making text-align apply to block level children.
Microsoft for not supporting margin: auto for several version.
People like you for not reading the specs.
Why to center pic is not as obvious as center of text?
It is. images and text are both inline elements and so text-align:
center works for both.
Steve