So the idea is that the PHP script decides when a page is full (after printing x number of rows), then it inserts a CSS class (.pagePL) which forces a new page to start. This new page should start just before your printer decides that the page is full. If it starts a new page after the printer does, extra (blank) pages will be the result.
This is the CSS that tells the printer to start a new page (unless it's the first page):
Code:
.pagePL
{
page-break-before: always;
}
#pageOnePL, .pageOnePL
{
page-break-before: avoid !important;
}
(note: Do not change this! Only telling this because I can't stop talking!
)