A LIST Apart: For People Who Make Websites

No. 144

Discuss: CSS Design: Going to Print

Pages

« First  <  9 10 11

101 Left Margins

Great article and making me change how our new site is formatted. However…
Like someone else in this thread I have menus on the left and removing them with display: none just leaves a blank space with the content still shifted across the page.
How do I get the content back to use the empty space to the left?

Thanks in anticipation.

posted at 09:33 am on May 6, 2003 by Bob

102 Not working in IE6

I’ve used the similar
http://alistapart.com/stories/alternate/
alternate CSS to create a fixed point font size for printing. But both on that, and also your sample page, my IE6 continues to print as if the screen font is not changed. (NN6 is fine though). In other words, IE6 completely disregards the visible changes on the screen, although it DOES print out according to size if I use the mousewheel to resize the print.

Is this a known Win IE6 problem? Is it my setup? Is there any way round it?

Many thanks

Tony

posted at 06:20 am on June 11, 2003 by Tony

103 CSS - Display None

I cannot get the display: none to work. I’m using IE 6.0 to view my pages. I see it working on the article’s page but it isn’t working on mine. Ugh!!!!

posted at 11:29 am on June 25, 2003 by Jennifer

104 Great

Very good article, I use tricks that explain and everithing works fine!

posted at 04:48 am on July 15, 2003 by Raf

105 CSS - Display None

Try {display: none !important;}

posted at 03:53 pm on July 16, 2003 by Aleksey

106 Great article. Is this a useful tip?

Hi,

First, thank you for a very good idea on print style sheets. I am a complete novice at this CSS thing so please be kind if the idea I’m about to suggest is flawed.

I created a separate print style sheet as per the article and added it to my template with the following declaration:

<style type=“text/css” media=“all”> @import “styles.css”; </style>
<link rel=“stylesheet” type=“text/css” media=“print” href=“print.css” />

But I found that when I validated the CSS by URI it did so but the validator gave me warnings saying that I had several redefinitions in my CSS. Obviously the W3C validator reads both style sheets and adds them together, I don’t know. So I searched for a hack and couldn’t find anything until I came across the @ media tag.

Within my style sheet (styles.css) I added the following:

@media print {

/* I then cut and pasted my print style sheet into this section */

}

It worked great and validated correctly, naturally that meant I could remove the line.

<link rel=“stylesheet” type=“text/css” media=“print” href=“print.css” />

So now I have a single style sheet that does two jobs. Some of you gurus may already know about this technique but I thought I’d share it anyway, plus someone may be able to develop it further.

regards,

Terry

posted at 06:34 am on July 23, 2003 by Terry

107 Telling the browser which document to print

While I find the solution discussed in this article interesting, sometimes you want to offer visitors more than just the same page with different looks.

Is it possible to instruct the web browser to choose a specific document when the user wants to print a page? Something like
<link rel=“printable” href=“resume.pdf” />
that basicallt says: “if the user wants to print this page, use the document resume.pdf”.

posted at 10:24 am on September 9, 2003 by @m!n

108 Work with Tables

This is a great article but I’m working with a site currently built with tables. Most of the code has worked (getting rid of graphics, changing fonts, etc.), but my text is being cut off by the right margin of the printed page. I’m not sure if this is b/c of tables or some other problem. The content is the center column of a three column table. Left and right columns are set to display:none. Any ideas?

posted at 01:02 pm on September 16, 2003 by Aaron

109 Printing from Safari

I printed this article in Safari 1.0 (v85) and the main content wrapped to a column only about 25% the width of the page. From IE, it looked fine. Is there a something in the CSS that can fix this? Or perhaps it’s a browser-bug?

posted at 12:33 pm on September 22, 2003 by schwabv

Pages

« First  <  9 10 11

Discussion Closed

New comments are not being accepted, but you are welcome to explore what people said before we closed the door.

Got something to say?

Discuss this article. We reserve the right to delete flames, trolls, and wood nymphs.

Create a new account or sign in below if you’d like to leave a comment.

Remember me

Forgot your password?

Subscribe to this article's comments: RSS (what’s this?)