2021.2

Table Of Contents
l .frontside
l .backside (does not apply to simplex documents)
l .contentpage
l .nocontentpage
The MediaBox contains the Master Page objects and section backgrounds. This means that
these classes can only be used to format a Master Page and section background. They do not
let you change the formatting of elements residing in the main text flow (e.g. a <h1> element on
page 3).
Formatting Master Page objects depending on the sheet position
The following CSS rule sets the color of <h1> elements on a Master Page when that Master
Page is present on the front of a sheet.
.frontside h1 {
color: green;
}
The next style rule is a bit more specific: it colors <h1> elements on a Master Page when that
Master Page is applied to the front of a sheet in Section 1:
[section='Section 1'] .frontside h1 {
color: green;
}
The following rule hides <h1> elements on the back of a sheet on which no content (from the
main text) is allowed.
.backside.nocontentpage .h1 {
display: none;
}
Print section background selector
When you inspect a Print section in a browser, you will see that it has a <div id="pages">
element as the first child of the <body> element. Inside this <div> there are one or more
MediaBoxes: elements with the class page_mediabox. Each MediaBox contains the Media,
section background and Master Page that apply to one page (see "Media" on page510,
"Master Pages" on page506 and "Using a PDF file or other image as background" on
page492).
Page 901