-2

I work on design of the report for my customer. I need to display logo on each page when customer prints the report.

here is my html row that I want to put on the header of each page when I on print mode:

<img style="page-break-before:always" src="/somepath/Content/images/logo.png" class="visible-print" style="width:200px;height:100px" alt="" />

Is there any way to implement it?

Michael
  • 13,950
  • 57
  • 145
  • 288

1 Answers1

1

There is no official support in HTML/CSS for what you need.

There has been a workaround using position:fixed and top:0 for the element you want to use as a header (or bottom:0 for footer) but it's not working on WebKit browsers, so more or less is useless.

Perhaps you could use a library for exporting to PDF where you can specify header/footer or any other needed elements. Example of one library is jsPDF

  • Thank you for answer. I tried to use position:fixed and top:0 but I get overlap.Do you have any idea how can I avoid overlapping? – Michael Sep 15 '16 at 14:50