Saving a HTTP request by combining screen and print styles

Instead of defining two stylesheet links in your head tag, you can define one and for screen & print styles and divide the different styles in the one stylesheet.

@media screen {
	body { font-size:14px; }
}

@media print {
	body { font-size:10pt; }
	h1, h2, h3 { page-break-after:avoid; }
}

Read the full article at the blog of Geert De Deckere

This entry was posted in css, frontend development and tagged , , , . Bookmark the permalink. Follow any comments here with the RSS feed for this post. Both comments and trackbacks are currently closed.

Post a Comment

Your email is never published nor shared. Required fields are marked *

*
*

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>