Grow your CSS skills. Land your dream job.

Can you centre a page with elements of Absolute Positioning?

  • # December 31, 2009 at 9:01 am

    Hi All,

    Bit of a newbish question but it has been bothering me for ages and ages.

    Can you centre a page with elements of Absolute Positioning??

    Cheers,

    Liam

    # December 31, 2009 at 12:18 pm

    Yes you can! You just need to make sure that the absolutely positioned items and being positioned within a div that is being positioned relatively, and not to the body or browser window. So:

    Code:

    PS. This was my 1,000th post!

    # January 1, 2010 at 8:15 pm

    Congrats on 1000 Doc! That’s amazing.

Viewing 3 posts - 1 through 3 (of 3 total)

You must be logged in to reply to this topic.

*May or may not contain any actual "CSS" or "Tricks".