Can I change page layout when using window.print()?

后端 未结 4 1955
无人及你
无人及你 2021-02-20 02:09

In our application we enable users to print pages. We do this by supplying a button which when click calls the window.print() function.
Some of the pages would look better i

4条回答
  •  抹茶落季
    2021-02-20 02:55

    I think your question is not so much about using CSS to define print styles, but to force the print as landscape rather than portrait?

    CSS 2 defined 'size', but I don't think this is widly supported: http://www.w3schools.com/css/css_ref_print.asp

    CSS 3 has better print control, but again not widly supported.

提交回复
热议问题