Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 2 of 2
  1. #1
    New to the CF scene
    Join Date
    Jan 2006
    Posts
    1
    Thanks
    0
    Thanked 0 Times in 0 Posts

    centering floating div inside centered table

    hi
    my problem is simple (maybe) - i want this page to center itself
    and keep the floating div of text absolute within the table so it also
    follows the centered page when browser is expanded or adjusted.
    but i am not sure where to put the tags - so that it will be universal
    on macs and PC.

    http://zutruhuman.com/zu3/index.html

    any thoughts or suggestions?

    mb

  • #2
    Supreme Master coder! _Aerospace_Eng_'s Avatar
    Join Date
    Dec 2004
    Location
    In a place far, far away...
    Posts
    19,291
    Thanks
    2
    Thanked 1,043 Times in 1,019 Posts
    Code:
    body {
    text-align:center;
    }
    #layer2 { height: 600px; width: 610px; left: 0; top: 0; position: relative;
    margin:auto;}
    Use the above for your CSS, then you will need to move layer1 inside of your layer2 div.
    You may want to run your page through the validator. You have some errors.
    ||||If you are getting paid to do a job, don't ask for help on it!||||


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •