开发者

Workaround for floats in DOMPDF

开发者 https://www.devze.com 2022-12-27 17:01 出处:网络
DOMPDF does not support floats. However I am listing many tables, and they are mainly key & value pairs. I would like 2 of these tables to appear side by side.

DOMPDF does not support floats.

However I am listing many tables, and they are mainly key & value pairs. I would like 2 of these tables to appear side by side.

i.e. if I could use floats

HTML

<table id="stuff">
...
</table>

<table id="other-stuff">
...
</table>

CSS

table#stuff {
    float: left;
}

table#other-stuff {
    float: right;
}

What sort of workaround can I do to support this? Or is 开发者_运维知识库it impossible?

If anyone has any ideas, there is a place to test here.


It looks like it may be supported in the beta.

You can download that from the Google Code page.


Make a table with 2 cells (50% if needed). Align 1st to left and the 2nd to right. In each cell you place your tables.

It should look like 2 floats.

0

精彩评论

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