Forum Moderators: not2easy

Message Too Old, No Replies

print css bug in IE7

         

peacesT

9:27 pm on May 7, 2008 (gmt 0)

10+ Year Member



so I have this problem on two different sites, but they're set up very similarly.
I've created a print.css where I set all the unnecessary tidbits to display:none; zero'd out all my margins and padding, and unfloated all my floats. The only thing that should be displaying at this point is my logo and my main content, stacked on top of each other respectively. But in IE 7, when I try to my logo is appearing at the top of the last page when the content spans multiple pages! I've tried absolutely positioning the logo but that just moves it around on the page that it's on, it doesn't take it to the top of the document. I can't find anybody else that is having this issue. At this point I'm just spinning my wheels. Any suggestions?

Marshall

9:42 pm on May 7, 2008 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month



hi peacesT, welcome to WebmasterWorld.

A little snippet of the CSS code would be helpful in analyzing the problem.

Marshall

peacesT

1:23 pm on May 8, 2008 (gmt 0)

10+ Year Member



sure thing.
this is what my print.css currently looks like.

#jsNav, #mainNav, #sideColumn, #supplement, #breadcrumbs {
display:none;
}
body, #header, #centerWrapper, #content, #contentWide, #content H1, #contentWide H1 {
width: auto !important;
margin: 0 !important;
padding: 0 !important;
}
#header {
position:absolute !important;
top:0px;
left:0;
}
#centerWrapper {
position:relative;
}
#content, #contentWide {
float:none !important;
width:100%;
margin:0 !important;
margin-top:70px;
}

Setek

2:43 am on May 9, 2008 (gmt 0)

10+ Year Member



Hi peacesT,

Have you tried simply removing the

position: absolute;
from
#header
and
position: relative;
from
#centerWrapper
entirely? Or explicitly setting them both to
position: static;
?

Your main screen stylesheet, is that set to

media="all"
or something? It might be mucking with your print styles.

[edited by: Setek at 2:45 am (utc) on May 9, 2008]