I'm New to Fpdf library, i need to create a pdf from data base in smarty. i have checked the data from data base is fine, when pass the font name the below error was show
Warning: in_array() expects parameter 2 to be array, null given in /var/www/html/irmt/library/class/fpdf/fpdf.php on line 526
<b>FPDF error:</b> Undefined font: helvetica B
my code is
$pdf->AddPage();
$pdf->SetFont('Arial','B',14);
$pdf->FancyTable($result);
$pdf->Output();
Please help me how can i solve this problem. thank adv
I think your __construct in the pdf creation is problem, try this one in
require_once("fpdf.php");
class pdf extends FPDF
{
function __construct()
{
parent::FPDF();
}
}