开发者

auto page breaks when printing long pages with ruby on rails

开发者 https://www.devze.com 2022-12-14 11:33 出处:网络
I have a rails app that creates quotations with information and images on that can be very different in size and the data they display.

I have a rails app that creates quotations with information and images on that can be very different in size and the data they display.

Each quote contains many setions of varying sizes.

I need to find a way to auomatically put page breaks into the quote when printing so that none of th sections are 开发者_如何学运维cut into printing on 2 pages.

Any ideas or experience with this would be great

thanks alot rick


I think you are looking for the page-break-beforeand page-break-after CSS properties:

<br style='page-break-after: always'>

Check the documentation for caveats and notes.

0

精彩评论

暂无评论...
验证码 换一张
取 消