Background: I have a PHP script that generates a long HTML/CSS document that gets converted to a PDF with WkHtmlToPdf.

At one point in the document, we enter a dynamic area with a variable number of entries, some of which include large images. I want to redraw a header on every page.

**Point of clarification: This is a repeated header in the print view of a section of a webpage, not just a header for the entire page.**

How I *want* to do that is via CSS. For example (pseudocode):

```
    #some_region:pagebreak {
      background-color: #fcc;
      border-color: #000;
      border-style: solid;
      border-width: 0 0 1px 0;
      content: "Our Header Here";
    }

```

**Of course, this fictitious CSS3 selector does not exist!**

Are there any clever CSS hacks that can be used to display an element after any page-breaks within a certain container?

**To illustrate: <https://scott.arciszewski.me/public/23277702.php>**