Page Breaks using page-break-after

Results 1 to 3 of 3

Thread: Page Breaks using page-break-after

  1. #1
    Shona Guest

    Default Page Breaks using page-break-after

    10 ASP pages pulling dynamic data off an MS access database. Print Preview page which includes all 10 pages above using &#060;!-- include--&#062; statement. Trying to format print preview page such that there is a page break between each of the 10 pages included. I&#039;ve put the following in:<BR><BR>H6 {page-break-after: always} but the page breaks are being inserted willy nilly. WHY?!?!?!?! My brain is fried and I can&#039;t work it out.

  2. #2
    John Pennington Guest

    Default RE: Page Breaks using page-break-after

    I define: <BR><BR>P.pagebreak {page-break-before: always;}<BR><BR>in the CSS header and then use<BR><BR>&#060;p class="pagebreak"&#062;&#060;/p&#062;<BR><BR>in the HTML body at the break points. <BR><BR>If you&#039;re using tables, you might want to look at how they are being structured. IE and Netscape both will pagebreak between tables whenever possible.<BR><BR>For better control of the whole print job, I define<BR><BR>@media print {<BR> BODY {font-size: 12pt; line-height: 120%; color: black; background: white; size: portrait; margin: 1in;}<BR>}<BR><BR>in the CSS header. This allows me to specify a different body setting for printing then I use for displaying to the browser which is very useful. You can see the results in the print preview of IE.<BR><BR>John<BR>

  3. #3
    Shona Guest

    Default RE: Page Breaks using page-break-after

    Thanks. That certainly has helped. The page breaks certainly aren&#039;t willy nilly anymore. You were right though, there is something about the tables that isn&#039;t right. If I remove the tables, the breaks are in the correct place but the minute I put them back, the breaks are inside the tables themselves. Is it something to do with the positioning? The length of the table? The structure? I&#039;m working on it but any pointers would be appreciated.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts