CSS – Centering Elements

There are many ways to center elements on a web page, I read from many blogs, tutorials, and find the easiest way to center different elements.

Below is a demo page that shows how to center: text, table and image on a page.


below is a demo page that shows how to center an image both horizontally and vertically.


Be Sociable, Share!

About Shi Chuan

I am a web developer.
This entry was posted in CSS Core and tagged , , , , . Bookmark the permalink.

Leave a Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>