我有一张桌子,上面有<thead>
,<tfoot>
和<tbody>
。理论上应该在每一页上打印thead和tfoot,但是由于某种原因,如果它包含某些元素在一起,则不会。是否有任何限制使它不能在Firefox的每个页面上打印?
这工作:
<thead>
<tr>
<td colspan="3">This works</td>
<tr>
<tr>
<th colspan="2">column 1</th>
<th>
column 2
</th>
</tr>
</thead>
这似乎并不工作:
[编辑]
<table>
<thead>
<tr>
<td colspan="3">
<h2>Header</h2>
<address>
<strong>address 1</strong> <br />
address 2 <br />
address 3 <br />
</address>
<img src="http://upload.wikimedia.org/wikipedia/commons/thumb/b/b7/Wikipedia-logo.svg/600px-Wikipedia-logo.svg.png" alt="Logo" />
<h2>Another header</h2>
<hr />
</td>
</tr>
<tr>
<th colspan="2">column 1</th>
<th>
column 2
</th>
</tr>
</thead>
<tfoot>
<tr>
<td>This is the footer</td>
<td>Column 2</td>
<td>Column 3</td>
</tr>
</tfoot>
<tbody>
<?php for ($i = 0; $i < 100; $i ++): ?>
<tr>
<td>Col 1</td>
<td>Col 2</td>
<td>Col 3</td>
</tr>
<?php endfor; ?>
</tbody>
</table>
[/编辑]
它打印:
[page 1]
[header]
[body]
[footer]
[page 2,3,4,5]
[body]
[footer]
有没有这个原因不起作用?
你可以发布信息和示例如何不起作用?发生什么事? – 2010-03-22 15:52:18
恐怕浏览器(甚至Firefox)不能正确地实现所有关于表格的HTML规则。 – 2010-03-25 15:39:01
这似乎是这样的... – SeanJA 2010-03-25 17:11:22