CSS PAGE-BREAK-BEFORE - CSS3 Examples

CSS PAGE-BREAK-BEFORE

Written by jon on 7:20 AM
This property specifies the page-breaking behavior that should occur before an element box and on what side of the page the content that follows should resume on. Page breaks are not allowed in absolutely positioned elements.


CSS2 “suggests” when page-breaking should occur:

  • Page-breaking should occur as few times as possible.
  • Page-breaking should be avoided inside these elements: tables, floated elements and block elements with borders.
  • Pages that are not forced to break should have approximately the same height.

Example
p { page-break-before: always }

<p style=”page-break-before: always”>Test text in the paragraph</p>

Possible Values
Value Description
inherit Explicitly sets the value of this property to that of the parent.
auto Insert a page break before the element as necessary.
avoid Avoid inserting a page break before the current element box.
leftright left: Force one or two page breaks before the current element box until a blank left page is reached.

right: Force one or two page breaks before the current element box until a blank right page is reached.

always Always force a page break before the current element box.
{empty string] No property value is used in this case. A page break is not inserted before the current element box.

Related Posts by Categories



Widget by John | Interviewghost
  1. 0 comments: Responses to “ CSS PAGE-BREAK-BEFORE ”

RECENT COMMENTS

SUBSCRIBE TO CSS3 EXAMPLES

 Subscribe to css3 Examples via RSS
Or, subscribe via email:
Find CSS3 Examples Entries :