erot
asked on
Page break, but only on printed docs??
Is it possible to tell where in a web-page it should
be a page-break, bun only only when the client print it?
If it is....which Tag or something else do the trick?
be a page-break, bun only only when the client print it?
If it is....which Tag or something else do the trick?
I've answered this question before (look for Page Break in MSIE 4.0 - 11/04/98). And no BR does not support that style sheet property.
You can use P tag instead.
You can use P tag instead.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
These Style Sheet printing extensions are aimed at documents that will use the <STYLE MEDIA="print"...> style sheet setting, specifying the style sheet as being suitable for printed documents. Note that the printing extensions are only a recent addition to Style Sheets and are claimed to be supported by Internet Explorer 4.0.
page-break-after
Value: auto | always | left | right
Initial: auto
Applies to: block-level elements outside of tables
Inherited: no
Percentage values: N/A
The values are:
auto
do a page break after the element only if necessary (e.g. if there is no remaining space on the current page)
always
always do a page break after the element
left
do one or two page breaks after the element until a blank left page is reached
right
do one or two page breaks after the element until a blank right page is reached
As an example, a hard page break may be inserted in the document with the BR tag as follows:
<STYLE>
BR.page { page-break-after: always }
</STYLE>
.
<BR CLASS=page>
.
If there are conflicts between this property and the 'page-break-before' value on the previous element (as formatted on the canvas), the value that results in the largest number of page breaks will be used.
Note: a way to suppress page breaks after an element is currently under discussion by the W3C, but the syntax is not yet defined.
page-break-before
Value: auto | always | left | right
Initial: auto
Applies to: block-level elements outside of tables
Inherited: no
Percentage values: N/A
The values are:
auto
do a page break before the element only if necessary (e.g. if there is no remaining space on the current page)
always
always do a page break before the element
left
do one or two page breaks before the element until a blank left page is reached
right
do one or two page breaks before the element until a blank right page is reached
As an example, a page break may be inserted in the document before all H1 elements:
<STYLE>
H1 { page-break-before: always }
</STYLE>
.
<H1 CLASS=chapter>
.
If there are conflicts between this property and the 'page-break-after' value on the next element (as formatted on the canvas), the value that results in the largest number of page breaks will be used.
Try and see if it works.