NOTICE: This website is no longer updated or supported - as such many of the techniques used to build it may seem antiquated in the modern day. It is preserved for historical reasons only.

HTML XHTML The Complete Reference
home » reference » appendix b » css1 / css2 properties

page-break-after


This property is used to control page breaks when printing a document. The property is set relative to the end of an element. A value of always forces a page break after the element. A value of avoid attempts to avoid a page break after the element. A value of left forces one or two page breaks after the element so that the next page is considered a left page. A value of right forces one or two page breaks after the element so the next page is considered a right page. The default value of auto neither forces nor forbids a page break.

Examples


#breakitdown {page-break-after: always;}
.getitright {page-break-after: right;}

Browser and CSS Support Notes


CSS2
IE 4, 5, 5.5, 6
Nav 6, 7
Opera 7


page-break-before


This property is used to control page breaks when printing a document. This property is set relative to the start of an element. A value of always forces a page break before the element. A value of avoid attempts to avoid a page break before the element. A value of left forces one or two page breaks before the element so that the next page is considered a left page. A value of right forces one or two page breaks before the element so the next page is considered a right page. The default value of auto neither forces nor forbids a page break.

Examples


#breakitdown {page-break-before: always;}
.lefty {page-break-before: left;}

Browser and CSS Support Notes


CSS2
IE 4, 5, 5.5, 6
Nav 6, 7
Opera 7


page-break-inside


This property is used to force or prohibit a printing page break within an element. A value of always forces a page break within the element. A value of avoid attempts to avoid a page break within the element. A value of left forces one or two page breaks within the element so that the next page is considered a left page. Avalue of right forces one or two page breaks within the element so the next page is considered a right page. The default value of auto neither forces nor forbids a page break.

Examples


#breakitdown {page-break-inside: always;}
.nobreaks {page-break-inside: avoid;}

Browser and CSS Support Notes


CSS2
No IE support
Nav 6, 7
Opera 7

(X)HTML Elements
CSS Properties
Back: page Next: position
< Home | About | Chapters | Examples | Errata | Reference | Site Map >