wangjialei 发表于 2009-8-25 09:53:07

PHP Version 5.2.8自带的php_pdf.dll为什么不好使

我想用php制作pdf,我的程序是

$pdf = pdf_new();
pdf_open_file($pdf, "pdftest.pdf");

pdf_begin_page($pdf, 595, 842);

$arial = pdf_findfont($pdf, "arial", "host", 1);
pdf_setfont($pdf, $arial, 10);
pdf_show_xy($pdf, "this is an exam of pdf documents, it is a good lib,",50, 750);
pdf_show_xy($pdf, "if you like,please try yourself!", 50, 730);
pdf_end_page($pdf);
pdf_close($pdf);


运行就报错
Fatal error: Uncaught exception 'PDFlibException' with message 'Metrics data for font 'arial' not found' in C:\xampp\htdocs\test\test_pdf.php:9 Stack trace: #0 C:\xampp\htdocs\test\test_pdf.php(9): pdf_findfont() #1 {main} thrown in C:\xampp\htdocs\test\test_pdf.php on line 9

我该怎么办呀!!!99

李白的爸爸 发表于 2009-8-25 10:43:49

意思是在你的系统中没找到 arial 这个字体。
页: [1]
查看完整版本: PHP Version 5.2.8自带的php_pdf.dll为什么不好使