title: How to print a page with dynamic content with borders without it breaking?
body: <p>The content inside the <code>ol</code> tag will be dynamic in length (entered by user). Is there any way to print with borders in each page for this scenario? I can't use JS as the current module I'm working on is converting pure html to pdf.</p>
  
  <p><a href="https://i.stack.imgur.com/u1ts1.png" rel="nofollow noreferrer">Currently, the border works for the first page only since I put a static height.</a></p>
  
  <p><div class="snippet" data-lang="js" data-hide="false" data-console="true" data-babel="false">
  <div class="snippet-code">
  <pre class="snippet-code-html lang-html prettyprint-override"><code>&lt;div style="border: 1px solid #999; margin-top:11px; height:270mm;"&gt;
      &lt;table border="0" cellpadding="0" cellspacing="0" style="width:100%; word-break: break-word;"&gt;
   &lt;tr&gt;
       &lt;td colspan="2" style="text-align:left; vertical-align:bottom;height:20px"&gt;Lorem ipsum dolor sit amet, consectetur adipiscing elit.&lt;/td&gt;
   &lt;/tr&gt;
   &lt;tr&gt;
       &lt;td colspan="2" style="text-align:left; vertical-align:bottom;height:50px; text-align:justify"&gt;
           &lt;ol style="padding-left: 10px; padding-right: 10px; margin-top: 0.5em; margin-bottom: 0.5em;"&gt;LONG CONTENT HERE&lt;/ol&gt;
       &lt;/td&gt;
          &lt;/tr&gt;
      &lt;/table&gt;
  &lt;/div&gt;</code></pre>
  </div>
  </div>
  </p>