title: Replicating text with FPDF and setting page size
body: <p>I'm using FPDF. The class is implemented and working in its most basic form. I created a business card (3.5" x 2") and placed it on an 8.5" x 11" page. The card is replicated 10 times on a single page.</p>
  
  <p>Here is what I'm trying to do:</p>
  
  <ol>
  <li><p>Replicate a variable 10 times and define a custom offset for each (string prints at the bottom of each card)</p></li>
  <li><p>Change the page size from <code>$unit='mm', $size='A4'</code> to <code>$unit='inch', $size='letter'</code>. Doing so gives me an error <code>FPDF error: Incorrect unit: inch</code></p></li>
  </ol>
  
  <p>The code I'm working with is below:</p>
  
  <pre><code>       switch($_POST['picker']){
          case 'option1':
             // initiate FPDI 
              $pdf = new FPDI(); 
              // add a page 
              $pdf-&gt;AddPage(); 
              // set the sourcefile 
              $pdf-&gt;setSourceFile('10-up.pdf'); 
              // import page 1 
              $tplIdx = $pdf-&gt;importPage(1); 
              // use the imported page and place it at point 10,10 with a width of 100 mm 
              $pdf-&gt;useTemplate($tplIdx, 0, 0, 216, 279); 
              // now write some text above the imported page 
              $pdf-&gt;SetFont('Arial'); 
              $pdf-&gt;SetTextColor(0,0,0); 
              $pdf-&gt;SetXY(12, 12); 
  
               //This is the variable I want to repeat 10 times and define custom offsets for each
              $pdf-&gt;Write(0, $user); 
              $pdf-&gt;Output('final.pdf', 'D'); 
             break;
  </code></pre>
  
  <p>The documentation I've read seems really limited. If you know of any good documentation, please let me know. Thanks.</p>