Wednesday 4 December 2013

CSS : CENTER ALIGNING BY MARGIN PROPERTY


Center Aligning Using the margin Property

Block elements can be aligned by setting the left and right margins to "auto".

HINT: Using margin:auto will not work in IE8 and earlier, unless a !DOCTYPE is declared.

Setting the left and right margins to auto specifies that they should split the available margin equally. The result is a centered element:


Example

No comments:

Post a Comment

Physics basic inventions and inventors

1.Which instrument is used to measure altitudes in aircraft's ? Audiometer Ammeter Altimeter Anemometer Explanation : ...