PHP code example of ronnilix / fpdfmct

1. Go to this page and download the library: Download ronnilix/fpdfmct library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

ronnilix / fpdfmct example snippets


$data[0] = "...";
$data[1] = "...";
$pdf = new fpdfmct ();
$pdf->AddPage ();
$pdf->SetFont ( 'Arial', '', 9 );
foreach( $data as $value )
{
	$lines = max ( $lines, $pdf->NbLines ( 40, $value ) );
}

$pdf->MultiCellTable ( 40, 5, $lines, $data[0], "L" );
$pdf->MultiCellTable ( 40, 5, $lines, $data[1], "L" );
$pdf->Output ( "D", "test.pdf" );