Setting Your Web Pages for Print

September 23rd, 2006

Web pages look really nice onscreen but what if you found a great page full of information (like web tutorials) and you want to print that information for you to read? What if the web page is set on a black background with white text? That”ll eat up your printer ink fast! There is a way to make your pages print friendly.

Creat a new style sheet that designates a white background and black text for your web page. You can further format that by specifying the font, font size and link effects.

body, p {
background: white;
color: black;
font: 12px/14px Verdana;
}

Save the file as print.css.

In the head section of your web page, add the following code just below your main stylesheet:

<link href="print.css" rel="stylesheet" media="print" />

Your web pages are now ready for printing! Make sure you test out various settings to optimize the look of your pages on print.

  • Share/Bookmark
divider

You can follow any responses to this entry through the RSS 2.0 feed. You can leave a response, or trackback from your own site.

divider

1 Comment »

Lulu on September 24th, 2006 at 5:09 am
  1. Yay! I hate it when you can’t print out webpages because of the background. Thanks for this. =D

RSS feed for comments on this post. TrackBack URL

Leave a comment

divider