These two pages got me thinking about print.css for web pages:
I’m starting to create a print.css for my pages (on a very small static site). The pages have drop-downs in several sections, and those drop-downs don’t display in print. The second link above tells me how to print them out in a print.css file. Specifically:
/* Insert user-defined messages before the content */
#page-header:before {
content: "\ http://www.companyname.com (c) 2016 Your company name";
color: #777 !important;
font-size: 12px;
}
My first question: In the age of Internet bookmarking, is there even a need for creating a print.css anymore?
My second question: how do we find out how many pages are being printed out from our hobby site? The answer to that question will answer the first question.
I think people do still print stuff if they want a hard copy for whatever reason. I occasionally do.
To see what the print css needs, use print preview, and see what could look better.
I will hide stuff that’s no use in print, like the nav. Re-style things that will use too much ink and just alter whatever looks bad in the preview.
I think browsers generally put that stuff on anyway.
gandalf458: Why bother? Because if nobody is using the print function of their browser, then there is no reason to take on the extra work of making the print.css.
SamA74:“Browsers print that anyway”: That was only an example. I am using the print function to add details that are not visible, such as the drop-down box Select contents.
I use the browser Print Preview too. That is helpful in deciding what to display: none.
Mitteneague: Like background-image? I don’t see any other way to embed an image in a css file, but I doubt it would be recorded in Analytics. That’s a cool idea, though.