Solved

CSS expanding footer

Posted on 2010-09-14
2
753 Views
Last Modified: 2012-05-10
I'm trying to make a footer, which has a fixed center with an expanding background. Something like this:

<<<expanding>>>   <<<fixed>>>  <<<expanding>>>

The header on my page is arranged the same way and it is working properly, but when I try to duplicate the same thing for my footer the sides are pushed beneath the fixed center. My page is here:

http://www.glowfishtw.com/play3on3/index.aspx

I'm trying to get the footer to look just like the header. My CSS and page is below. Thanks for any help.

The footer HTML:
  <div id="content_footer">&nbsp;</div>
  <div class="left_footer column_footer">
    <div id="leftcol_footer">&nbsp;</div>
  </div>
<div class="right_footer column_footer">
    <div id="rightcol_footer">&nbsp;</div>
</div>

The CSS:
#content_footer {
      width: 900px;
      height: 80px;
      text-align: left;
      overflow:auto;
      margin-top: 0;
      margin-right: auto;
      margin-bottom: 0;
      margin-left: auto;
      background-image: url(../images/header.png);
      padding-top: 150px;
      padding-left: 80px;
}

.column_footer {
      width: 50%;
      position: absolute;
}

.left_footer {
      left: 0;
}        
.right_footer {right: 0;}

#leftcol_footer {
      margin-right: 486px;
      height: 230px;
      background-image: url(../images/top_bg_stripe_long.png);
}

#rightcol_footer {
      margin-left: 480px;
      height: 230px;
      background-image: url(../images/top_bg_stripe_long.png);
}

0
Comment
Question by:elliottbenzle
2 Comments
 
LVL 15

Accepted Solution

by:
ludofulop earned 500 total points
ID: 33669788
hi, what about something like this?

<div style="background-color: red; height: 230px; margin: 0px 50px; text-align: center;">
    <div style="background-color: yellow; width: 900px; height: 80px; margin-top: 150px;">lorem ipsum</div>
</div>
0
 
LVL 4

Author Closing Comment

by:elliottbenzle
ID: 33676571
Thanks, that helped a lot.
0

Featured Post

Do You Know the 4 Main Threat Actor Types?

Do you know the main threat actor types? Most attackers fall into one of four categories, each with their own favored tactics, techniques, and procedures.

Join & Write a Comment

Suggested Solutions

This is a PowerShell web interface I use to manage some task as a network administrator. Clicking an action button on the left frame will display a form in the middle frame to input some data in textboxes, process this data in PowerShell and display…
Not sure what the best email signature size is? Are you worried about email signature image size? Follow this best practice guide.
In this tutorial viewers will learn how to style different bullet points for unordered lists in CSS. Begin with a normal unordered list; the default bullet point is a solid circle: In the CSS, create a defined class of unordered list by typing "ul.S…
In this tutorial viewers will learn how to style rounded corners for elements in CSS using the border-radius property Begin with a normal styled element such as a div: To style all four corners of the div to be the same degree of roundness, use the …

708 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now