DOMPDF
tag as header and footer

2019-07-27 08:12发布

I need to create a header and footer on a tag using DOMPDF. How can I achieve this?

Assuming I have a header class like this one:

<div class='header'>
    <div>
        <img scr='image1.png' style="width:100px; height:150px" />
        <h1>This is header</h1>
    </div>
</div>

and a footer like this one

<div class='footer'>
    <div>
        <img scr='image1.png' style="width:100px; height:150px" />
        <h1>This is a footer. All rights reserved.</h1>
        <img src = image2.png style="width:100px; height:150px;">
    </div>
</div>

I want to create those <div> tags (class footer and class header) to create the DOMPDF header and footer.
Any suggestion is highly appreciated! Cheers!

1条回答
放我归山
2楼-- · 2019-07-27 09:02

CSS :

position:fixed; 
top: 0; or bottom: 0;
查看更多
登录 后发表回答