From the course: CSS: Print Style Sheets

Unlock the full course today

Join today to access over 22,600 courses taught by industry experts or purchase this course individually.

Print style sheets and media queries

Print style sheets and media queries - CSS Tutorial

From the course: CSS: Print Style Sheets

Start my 1-month free trial

Print style sheets and media queries

- [Instructor] This first chapter of the course, we'll focus on some of the mechanics of creating CSS for print including the syntax of setting up print style sheets and understanding the cascade and inheritance where different media are involved. So let's get started with a quick overview of comparing and contrasting print style sheets and print media queries. The first way to include print styles in your website, and probably still the most popular is including an external linked document that refers to printing styles. The code looks like this. This is probably already similar to what you do with your screen styles. With the addition of a media equals print on the end of the line. Second and much less popular, you could embed your print styles in the head of your HTML document using code like this. In general embedded styles should be avoided. They apply only to the page in which they're located so they're harder…

Contents