【发布时间】:2019-03-18 13:57:48
【问题描述】:
ol 标签内的内容长度是动态的(由用户输入)。对于这种情况,有没有办法在每页中打印边框?我不能使用 JS,因为我正在处理的当前模块是将纯 html 转换为 pdf。
Currently, the border works for the first page only since I put a static height.
<div style="border: 1px solid #999; margin-top:11px; height:270mm;">
<table border="0" cellpadding="0" cellspacing="0" style="width:100%; word-break: break-word;">
<tr>
<td colspan="2" style="text-align:left; vertical-align:bottom;height:20px">Lorem ipsum dolor sit amet, consectetur adipiscing elit.</td>
</tr>
<tr>
<td colspan="2" style="text-align:left; vertical-align:bottom;height:50px; text-align:justify">
<ol style="padding-left: 10px; padding-right: 10px; margin-top: 0.5em; margin-bottom: 0.5em;">LONG CONTENT HERE</ol>
</td>
</tr>
</table>
</div>
【问题讨论】: