Style pageBreakAfter attribute
- Pya kwa picha paddingTop
- Pya kwa picha pageBreakBefore
- Retunza kwa ukweli Inayofanywa na HTML DOM Style Object
Definition and Usage
The pageBreakAfter attribute sets or returns the pagination behavior after the element (used for printing or print preview).
Note:pageBreakAfter
The attribute has no effect on elements with absolute positioning. Pagination symbols are only visible in print preview or when printing.
See also:
CSS Reference Manual:page-break-after attribute
Example
Always set a pagination symbol after each <p> element with id="footer":
document.getElementById("footer").style.pageBreakAfter = "always";
Syntax
Return pageBreakAfter attribute:
object.style.pageBreakAfter
Set pageBreakAfter attribute:
object.style.pageBreakAfter = "auto|always|avoid|emptystring|left|right|initial|inherit"
Attribute value
Value | Description |
---|---|
auto | Insert a pagination symbol after the element if necessary. Default. |
always | Always insert a pagination symbol after the element. |
avoid | Avoid inserting a pagination symbol after the element. |
"" (empty string) | Do not insert a pagination symbol after the element. |
left | Insert enough pagination symbols after the element until a blank left page. |
right | Insert enough pagination symbols after the element until a blank right page. |
initial | Set this property to its default value. See also initial. |
inherit | Inherit this property from its parent element. See also inherit. |
Technical details
Default value: | auto |
---|---|
Return value: | A string indicating the pagination behavior of the element when printed. |
CSS Version: | CSS2 |
Msaada wa kifungu
Chrome | Edge | Firefox | Safari | Opera |
---|---|---|---|---|
Chrome | Edge | Firefox | Safari | Opera |
Msaada | Msaada | Msaada | Msaada | Msaada |
- Pya kwa picha paddingTop
- Pya kwa picha pageBreakBefore
- Retunza kwa ukweli Inayofanywa na HTML DOM Style Object