title: @media print not respecting for Safari. works fine in firefox
body: <p>Use case : I am using air print to print a html document from iOS device.</p>
  
  <p>Problem : I want to add page breakers for printing the page. I was able to with media print tag, which works well for firefox but not able to make it work for safari (Since inbuilt browser in UIWebView for iOS is safari) . Please help in solving this.</p>
  
  <p>EDIT : Page break is working fine. But the real problem is we cannot group the headers using the tag “table-header-group”. which is necessary to show the table header in each page.</p>
  
  <p>What i have tried?</p>
  
  <pre><code> &lt;style type="text/css"&gt;
  @media print
  {
    table { page-break-after:auto }
    tr    { page-break-inside:avoid; page-break-after:auto }
    td    { page-break-inside:avoid; page-break-after:auto }
    thead { display:table-header-group }
    tfoot { display:table-footer-group }
  }
  &lt;/style&gt;
  
  &lt;table border="1" cellpadding="2" cellspacing="0"&gt;
      &lt;thead&gt;
          &lt;tr&gt;
              &lt;th&gt;ID&lt;/th&gt;
              &lt;th&gt;First Name&lt;/th&gt;
              &lt;th&gt;Last Name&lt;/th&gt;
          &lt;/tr&gt;
      &lt;/thead&gt;
      &lt;tbody&gt;
          &lt;tr&gt;
              &lt;td&gt;1&lt;/td&gt;
              &lt;td&gt;2&lt;/td&gt;
              &lt;td&gt;3&lt;/td&gt;
          &lt;/tr&gt; ....
  
  
          &lt;tr&gt;
              &lt;td&gt;1&lt;/td&gt;
              &lt;td&gt;2&lt;/td&gt;
              &lt;td&gt;3&lt;/td&gt;
          &lt;/tr&gt;
      &lt;/tbody&gt;
  &lt;/table&gt;
  </code></pre>
  
  <p>Actual result, as in safari
   <img src="https://i.stack.imgur.com/S2tgH.png" alt="Actual result, as in safari"></p>
  
  <p>Expected result, as in firefox
  <img src="https://i.stack.imgur.com/x6HsS.png" alt="Expected result, as in firefox "></p>