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 3 of 3
  1. #1
    New to the CF scene
    Join Date
    Jan 2007
    Posts
    3
    Thanks
    0
    Thanked 0 Times in 0 Posts

    CSS DIV Footer Positioning - Help

    I am designing a page (I'm relatively new to css, so sorry if this is an obvious question).

    I'm not sure if I did the div positioning/coding the correct way, but basically I have this site: http://www.piratebay.us/hoodia/hoodiatemplate.html

    Looks fine as it is, but when I add more content I can't get the footer (just an image of the lower rounded corners and lower border) to expand given more content on the main page.

    How do I get this footer to move in relation to content on the page?

    As it is right now if I add more content it overlaps onto the footer and just keeps streaming down.


    Any help would be greatly appreciated. The CSS of the page can be found here: http://www.piratebay.us/hoodia/hoodiastyle.css


    Thanks a lot for any help.

  • #2
    Senior Coder koyama's Avatar
    Join Date
    Dec 2006
    Location
    Copenhagen, Denmark
    Posts
    1,246
    Thanks
    1
    Thanked 5 Times in 5 Posts
    Watch out using absolute positioning for your building blocks. Because if these have unknown height it will be hard to get content flowing beneath.

    You have two columns below your horizontal navigation bar. For this I would recommend using floats. Using your names, take a look at this approach:

    Code:
    .leftbar {
      float: left;
      width: 131px;
    }
    .mainimage {
      float: left;
      width: 601px;
    }
    .footer {
      clear: both;
    }
    Instead of using class="footer" together with .footer, it is probably more natural to use id="footer" together with #footer since you for sure only will have one footer element. The same holds for your other main building blocks.

  • #3
    New to the CF scene
    Join Date
    Jan 2007
    Posts
    3
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Thanks a lot!

    I will try it out as soon as I can.


  •  

    Posting Permissions

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