;

PDA

Click to See Complete Forum and Search --> : CSS div problem, header and footer image


Dan Abz
01-08-2007, 11:14 AM
Hey!

Im having a problem with my div style for my header div and my footer div.

These are the styles in my css:

.div.footer
{
background-color: #73BF1F;
width: 100%;
height: 35px;
position: absolute;
border:1px solid green;
top: 665px;
right: 0px;
left: 5px;
}

.div.header
{
background-image : url(../images/toolbar.jpg);
background-color: #FFE000;
background-repeat: repeat-y;
position: absolute;
border:1px solid green;
width : 100%;
height : 48px;
top : 0px;
left : 5px;
right :0px;
visibility: visible;
}

Does anyone know why it would show up in IE6 but not IE7?

thanks for any help

Dan

catbert303
01-08-2007, 12:24 PM
Hi,

the CSS selectors .div.header and .div.footer don't look quite right. Or at least I think they may be doing something different than you're expecting,

.div.header { }

should select elements in the page that have both the class name div and header. For example,

<p class="div header">This paragraph has the class names div and header, it would be selected by the selector .div.header</p>

if you want to select div elements with the class name header you would simply remove the leading .

div.header {
/* css rules here */
}

<div class="header">This would be selected by div.header</div>

Hope this helps :)

I guess this is one of the CSS parsing bugs that was fixed between IE 6 and IE 7.

Dan Abz
01-08-2007, 12:29 PM
Thanks!

Thats it working now!

Hopefully thats my first site with div's fully working now.

thanks again