Home > Web Front-end > CSS Tutorial > ## How to Print Background Images with CSS Sprites?

## How to Print Background Images with CSS Sprites?

Mary-Kate Olsen
Release: 2024-10-25 02:33:29
Original
334 people have browsed it

## How to Print Background Images with CSS Sprites?

Printing Background Images in CSS

When utilizing CSS sprites for website imagery, it may be encountered that images do not print when the page is printed. To enable printing of the background image, consider the following solutions:

  • For Chrome and Safari:

Add the following CSS rule to your print stylesheet:

<code class="css">@media print {
  * { -webkit-print-color-adjust: exact; }
}</code>
Copy after login
  • For Other Browsers:

Unfortunately, other web browsers (e.g., IE 9, 10, and 11) require manual user intervention. Users need to:

  1. Click the print settings icon (usually a gear or wrench).
  2. Select "Print."
  3. In the "Page Setup" dialog box, enable the option to print "Background Graphics."

The above is the detailed content of ## How to Print Background Images with CSS Sprites?. For more information, please follow other related articles on the PHP Chinese website!

source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Latest Articles by Author
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template