CodingForums.com

CodingForums.com (http://www.codingforums.com/index.php)
-   HTML & CSS (http://www.codingforums.com/forumdisplay.php?f=13)
-   -   Stretching Header to Accomodate Background Color (http://www.codingforums.com/showthread.php?t=283494)

jihanemo 12-03-2012 10:26 PM

Stretching Header to Accomodate Background Color
 
Hi, everyone. Here's the site I'm working on: http://bit.ly/QCMdge (password to log in is "freoly").

I'm trying to stretch this top section of the header all the way out so that it spans from the far left of the browser to the right (please see pic below. This is what I want it to look like. I'm trying to stretch it out so I can use that sea-green background). How do I do that? I need to stretch it out I can use a colorful background that stretches all the way across the top, from left edge to right edge. I want the width of everything else to stay the same.



https://cdn.shopify.com/s/files/1/01...shot2.jpg?1734

aaronhockey_09 12-03-2012 11:08 PM

Well the problem is that you have all the content inside of the "container" div. Which is centered and a specific wdith.

What you need to do is have something like this

Code:

<div class="top">
    <div class="container">
        <div id="cart-summary"></div>
    </div>
</div>

So you make the top div span 100% and have the background colour
Then you have all of the content for that inside of the container div which is centered.

Hope this helps.

jihanemo 12-03-2012 11:57 PM

That helps. Thanks!

I figured that was the problem but I was afraid to move around containers... I was worried about the effects.

I will try that. Thank you!


All times are GMT +1. The time now is 06:01 AM.

Powered by vBulletin®
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.