print stylesheet, one page prints and cuts off remaining text

后端 未结 12 1031
攒了一身酷
攒了一身酷 2020-12-24 00:41

I\'m working on a printable list of events, the printer prints one page fine, but cuts off some of the text on the bottom, then it print a second blank page

I\'ve tr

12条回答
  •  悲&欢浪女
    2020-12-24 01:24

    In print.css, set overflow: visible instead of overflow: auto on div#content. That fixed it for me in Firefox at least. The definition of overflow auto is: "If overflow is clipped, a scroll-bar should be added to see the rest of the content" -- but scroll bars don't exist on printed pages.

    I'm guessing that since the content div should span across multiple pages, the browser thinks "you're flowing outside your container and must be clipped with a scroll bar". The container in that case is the first page the content div appears on.

提交回复
热议问题