1. Home
  2. Computing & Technology
  3. Web Design / HTML

How do you write a print style sheet?

By , About.com Guide

Question: How do you write a print style sheet?
Answer:

A print style sheet can be created to go with every Web page on your site. This style sheet would only apply when someone printed your Web page. This would allow you to set specific styles to make your page more printer friendly. You can also do things like hide advertisements and add in special footers or headers when the document is printed.

Simply add a second style sheet to the head of your document with the print styles you would like to apply.

<head>
<link rel="stylesheet" href="styles.css" type="text/css" media="print" />
</head>
Explore Web Design / HTML
About.com Special Features

The Best Web Trends of the Decade

A look back at the best innovations, ideas and technologies over the last 10 years, More >

Family Tech Center

Stay connected and entertained with reviews on tips on the latest HDTVs, cellphones and more. More >

  1. Home
  2. Computing & Technology
  3. Web Design / HTML

©2009 About.com, a part of The New York Times Company.

All rights reserved.