needs_upgrade Posted April 25, 2011 Share Posted April 25, 2011 Hello Guys! My system needs to print billing accounts of all subscribers in bulk. Accounts must be printed in a 8.5" x 5.5" paper. Accounts may consume a page or more. My problem is that if the previous account consumed a page and a half, the next account will start from the lower half of the last page of the previous account. My question is how to insert a page break so that every account starts at the top of a page. What i have in mind so far is to generate an excel file with all the accounts and with page breaks after every account. If there's a way on how to print accounts with page breaks directly on the browser, that would be great. Other insights are highly appreciated. Thank you guys in advanced! Quote Link to comment https://forums.phpfreaks.com/topic/234640-adding-page-breaks-in-printing-using-the-browser/ Share on other sites More sharing options...
gristoi Posted April 25, 2011 Share Posted April 25, 2011 have you thought of looking into printing to a PDF format instead. The reason i bring this up is that you can set the 'real world size' of the document not the resolution. There are a few good php PDF classes out there on the internet. All of the pdf classes have a new page function. So when you re loop a new bill it would start on a new page. Hope this helps Quote Link to comment https://forums.phpfreaks.com/topic/234640-adding-page-breaks-in-printing-using-the-browser/#findComment-1205798 Share on other sites More sharing options...
Adam Posted April 26, 2011 Share Posted April 26, 2011 There's the CSS page-break-before property. Quote Link to comment https://forums.phpfreaks.com/topic/234640-adding-page-breaks-in-printing-using-the-browser/#findComment-1206544 Share on other sites More sharing options...
needs_upgrade Posted April 28, 2011 Author Share Posted April 28, 2011 Thanks Adam! Quote Link to comment https://forums.phpfreaks.com/topic/234640-adding-page-breaks-in-printing-using-the-browser/#findComment-1207423 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.