Jeckky / dompdf

Automatically exported from code.google.com/p/dompdf
0 stars 0 forks source link

Use of display: table-header-group on non-table element causes fatal error #467

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1. Use CSS to add a display value of "table-header-group" to a regular div in 
the document body. (My intention in doing so was to have that div rendered on 
every page.)
2. Render the document with DOMPDF.

What is the expected output? What do you see instead?
I expected the div with the table-header-group display property to render on 
every page. What happened was I got the following error:

Fatal error: Call to a member function get_cellmap() on a non-object in 
/home/ianfp/ianstix.com/www/rialto/lib/dompdf_0-6-0_beta3/include/table_row_grou
p_frame_reflower.cls.php on line 48

What version of dompdf are you using? What version of PHP? On what
operating system?
dompdf 0.6.0 beta3 on 5.3.3-1ubuntu9.10 on Ubuntu 10.10.

Please provide the HTML source code you want to convert, or any additional
information.
The abbreviated source code is:

<html>
<head>
<style type="text/css">
.header {
    display: table-header-group;
}
</style>
</head>

<body>
<div class="header">
This should repeat on every page.
</div>
</body>
</html>

Original issue reported on code.google.com by ian.f.ph...@gmail.com on 13 Apr 2012 at 9:22

GoogleCodeExporter commented 8 years ago
Hello, changing the default display from/to table* is not supported in dompdf. 
There is already an issue about this: 
http://code.google.com/p/dompdf/issues/detail?id=443
To repeat on each page, you need to use 

position: fixed;
top: 0;

Like in the first example here : http://pxd.me/dompdf/www/examples.php

Original comment by fabien.menager on 14 Apr 2012 at 9:41

GoogleCodeExporter commented 8 years ago

Original comment by eclecticgeek on 30 May 2013 at 5:16