SitePoint Sponsor

User Tag List

Results 1 to 2 of 2
  1. #1
    SitePoint Enthusiast Redheadskater's Avatar
    Join Date
    Jul 2003
    Location
    USA
    Posts
    80
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    getting a div to stay below the content

    Hi-

    I am currently working on a site that is a modification of an OSWD.org template. I tried working with the full css template, but I got so frustrated that I gave up and switched the design to tables.

    Here's where my problem lies. The BACKGROUND of the header and footer are supposed to be 100% width. THe main table is a fixed width of 900px.

    I got the background to display 100% width using the <body> element in the CSS file. The problem is now I can't get the bottom footer to do the same.

    you can take a look here:
    www dot alcoholanddrugsrehab dot com / beta / index2.php

    I thought I could just create an absolute positioned div like this:

    #blackbox100 {
    background:#323232;
    width:100%;
    height: 100px;
    position: absolute;
    margin: 0 auto 150px 0;
    z-index: -1;
    }

    But it didn't work. Any ideas on what I am doing wrong?

  2. #2
    SitePoint Member
    Join Date
    Mar 2008
    Posts
    21
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    it looks like your header is set via background image repeating on the x axis in the body tag in your CSS. The footer div is being placed inside the tables cell and therefore is being restricted to the width of the table.
    Load the webmaster toolkit addon in Firefox and turn on outlines for tables and you'll see it pretty quick.


Bookmarks

Posting Permissions

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