08th Jun2011

Center your site

by admin

Back in the day when I was learning CSS, I was banging my head against the wall on how to get my page centered.  When I would go to larger resolution the page was off center, and then in Firefox and IE…. let’s not go there.  Just a big headache.  Finally I learned to center a page.

The CSS would be:

body {

text-align: center;

}

 

#page {

margin-left: auto;

margin-right: auto;

}

There you have it.  If you do not know the rest please search for the nearest HTML tutorial.  Have a great Summer!

 

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>