title: Creating html table with fixed dimensions
body: <h1>Short</h1>
  <p>Trying to get table with exact dimensions for a4 print</p>
  <ul>
  <li>Table's first and last rows' margin from <strong>top and bottom</strong> sides of paper must be <strong>11 mm</strong></li>
  <li>Margin between rows' 0 mm</li>
  <li>Table's rows must be at <strong>4 mm</strong> from <strong>left and right</strong> sides of paper</li>
  <li><strong>2 mm</strong> between every column</li>
  <li><strong>38 mm width x 21.2 mm height</strong> each cell</li>
  <li>13 x rows, 5 x columns, 13x5=65 cells</li>
  </ul>
  <p>Here is JS fiddle</p>
  <p><a href="http://jsfiddle.net/tt13/ZjBrV/" rel="nofollow noreferrer">http://jsfiddle.net/tt13/ZjBrV/</a></p>
  <h1>Question</h1>
  <p>What can I do in this case? How to get the table with conditions that I explained above?</p>
  <h1>Detailed</h1>
  <p>html table looks like that</p>
  <pre><code>&lt;body&gt;
    &lt;table&gt;
      &lt;td&gt; 
       &lt;div class=&quot;bcell&quot;&gt;
        sample text2&lt;br/&gt;
        &lt;img src=&quot;...&quot;/&gt;&lt;br/&gt;
        sample text2
       &lt;/div&gt;
       &lt;/td&gt;
     ....
    &lt;/table&gt;
  &lt;/body&gt;
  </code></pre>
  <p>Using css below to achieve A4 size print result, but getting something absolutely different from conditions that I explained above.</p>
  <pre><code>        body {      
              padding:11mm 4mm 0 4mm;
              background: white;
              font-family: Arial;
              width: 210mm;
              font-size:3mm;
          }
  
          table { 
              page-break-after:always;
              width: 100%;
              height: 275mm;
              margin:0 auto;
              page-break-inside:avoid;                 
              border-collapse: collapse;
  
          }
  
          td img {
              height:10mm;
          }
  
          td {
              width: 38mm;
              height:21.2mm;
              padding: 0 1mm 0 1mm;
              font-style: bold;
              text-align: center; 
              vertical-align:middle;
          }
  
  
          tr    { 
              page-break-after:auto;
              page-break-inside:avoid; 
              height:21.2mm;
              margin:0;
              padding:0;
              page-break-inside:avoid;             
          }
  </code></pre>