page-break-* doesn't work on Google chrome

前端 未结 6 388
梦如初夏
梦如初夏 2020-12-09 10:25

I just like the divs under .wp_left_col div be placed in separate pages. This is my css code.

.wpi_left_col > div {         


        
6条回答
  •  遥遥无期
    2020-12-09 11:01

    3 years later float:none !important for div was the solution for getting the break working in chrome. Not necessary to float:none all parents (body or html)

    @media print {
        div {
            float: none !important;
        }
    }
    

提交回复
热议问题