ristuart
07-20-2003, 01:20 PM
Hi!
I've been working/experimenting with layers quite a lot in the past day or two. I'm thinking about creating two separately scrolling frame-style sections on a site, something I haven't tried before. So far it's looking pretty good in a variety of browsers, but I have turned my attention to printing.
Having set the content layer to scroll when needed (using overflow: auto), rather than having the whole body of the document scroll, when I came to print the page it was printed with only the first screen's worth of content and scroll bars. Since then, I've linked a second stylesheet setting the media to print, which sets the scrolling back to normal. The printout is now absolutely fine in IE, just going on to a second page as it should. Obviously that stylesheet won't work in NN4, but nor will the scrolling on the layers, so that's OK.
However, I still find that in NN6 and NN7, although there are now no scrollbars printed, it still only prints one page worth of content. I guessed that that might be just to do with the fact that it's a fixed layer... made a test file with one layer with lots of text and the following css, and got the same thing when printing in NN7. Don't know about NN6, but guess it'd be the same.
#testlayer
{
position:absolute;
left: 0px;
top: 0px;
width: 100%;
height: 100%;
}
Anyone got any ideas on how to avoid this problem? I did find this topic when searching before posting [http://forums.webdeveloper.com/showthread.php?threadid=8628&highlight=print+layer] but that did not even solve the printing of scrollbars. Other than this problem, I am very pleased with the layout I have got so far, and I would very much appreciate any thoughts anyone has about this! Thanks in advance,
ristuart
---Edit---
I found this article on ALA - http://www.alistapart.com/stories/goingtoprint/ - which discussed a Gecko bug which I thought might have been relevant. I tried adding float: none; to the css style I gave above, but it doesn't appear to have had any effect... :(
I've been working/experimenting with layers quite a lot in the past day or two. I'm thinking about creating two separately scrolling frame-style sections on a site, something I haven't tried before. So far it's looking pretty good in a variety of browsers, but I have turned my attention to printing.
Having set the content layer to scroll when needed (using overflow: auto), rather than having the whole body of the document scroll, when I came to print the page it was printed with only the first screen's worth of content and scroll bars. Since then, I've linked a second stylesheet setting the media to print, which sets the scrolling back to normal. The printout is now absolutely fine in IE, just going on to a second page as it should. Obviously that stylesheet won't work in NN4, but nor will the scrolling on the layers, so that's OK.
However, I still find that in NN6 and NN7, although there are now no scrollbars printed, it still only prints one page worth of content. I guessed that that might be just to do with the fact that it's a fixed layer... made a test file with one layer with lots of text and the following css, and got the same thing when printing in NN7. Don't know about NN6, but guess it'd be the same.
#testlayer
{
position:absolute;
left: 0px;
top: 0px;
width: 100%;
height: 100%;
}
Anyone got any ideas on how to avoid this problem? I did find this topic when searching before posting [http://forums.webdeveloper.com/showthread.php?threadid=8628&highlight=print+layer] but that did not even solve the printing of scrollbars. Other than this problem, I am very pleased with the layout I have got so far, and I would very much appreciate any thoughts anyone has about this! Thanks in advance,
ristuart
---Edit---
I found this article on ALA - http://www.alistapart.com/stories/goingtoprint/ - which discussed a Gecko bug which I thought might have been relevant. I tried adding float: none; to the css style I gave above, but it doesn't appear to have had any effect... :(