What is @media print in CSS?

What is @media print in CSS?

You can use CSS to change the appearance of your web page when it’s printed on a paper. You can specify one font for the screen version and another for the print version. You have seen @media rule in previous chapters.

How do I add a print media query in CSS?

FYI: you can print from the web using the keyboard shortcut Ctrl/cmd+P.

  1. Step 1: CSS Media Queries for Print. First of all, we define the media query: @media print { /* styles here */ }
  2. Step 2: Hiding Redundancy. When downloading webpages as PDF, users don’t need:
  3. Step 3: Customizing Page Margins.
  4. Step 4: Handling Links.

How do I apply a media rule in CSS?

The @media CSS at-rule can be used to apply part of a style sheet based on the result of one or more media queries. With it, you specify a media query and a block of CSS to apply to the document if and only if the media query matches the device on which the content is being used.

What is print media?

Print media is one of the oldest and basic forms of mass communication. It includes newspapers, weeklies, magazines, monthlies and other forms of printed journals. The contribution of print media in providing information and transfer of knowledge is remarkable.

What is the use of media query in CSS?

Media queries are useful when you want to modify your site or app depending on a device’s general type (such as print vs. screen) or specific characteristics and parameters (such as screen resolution or browser viewport width).

What are the 6 types of print media?

Print media advertising is physically printed media including newspapers, magazines, posters and billboards and direct mail.

  • Newspapers and Weeklies.
  • Consumer and Trade Magazines.
  • Billboards and Posters.
  • Direct Mail: Letters and Postcards.
  • Print Media Selection.

Begin typing your search term above and press enter to search. Press ESC to cancel.

Back To Top