Creating a Print CSS

By default, the corev4.css file includes two print @media rules to remove unnecessary artifacts from printed pages, including ribbon and navigation (see Listings 16.5 and 16.6). The @media rule in Listing 16.5 defines SharePoint CSS classes and the @media rule in Listing 16.6 defines a SharePoint CSS ID. When you define print CSS, including in the @media rule and separate print.CSS file, you can include CSS classes, IDs, and elements, such as

.ms-listdescription {display: none}

Body{background:white;}

Body.v4master{background:blue;}

.ms-pagetitleareaframe TD{display:none;}

Body #s4-titlerow{display:none;}

Note

The @media rule, defined by the W3C, enables you to include print classes in the same CSS file used for ...

Get Microsoft® SharePoint® Designer 2010 Unleashed now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.