Reputation: 41
I want to add page breaks to my site so that other elements will not be cut in half when a user tries to print the page. I've tried adding the css "page-break-after: always", but it only works on Firefox, and can't find any other solutions.
There are a couple similar questions (one here: Google Chrome Printing Page Breaks) but they're very old (2009) and the solution no longer works.
Does anyone know of a way to do this with current versions of Safari and Chrome?
Upvotes: 4
Views: 1417
Reputation: 19967
I had an issue similar to this but I found the solution eventually. I had overflow-x: hidden; applied to the tag so no matter what I did below in the DOM, it would never allow page breaks. By reverting to overflow-x: visible; it worked fine.
Hopefully this helps somebody out there.
Upvotes: 3