找到你要的答案

Q:Using fpdf for generating A4 Prints

Q:使用FPDF生成A4打印

I need to take bill print in 80 x 110 mm. am using FPDF format to create a PDFs. The size shown in the browser is correct that is 80 x 110, but when I take a print it comes under A4 size. I change to try A4 to letter, legal to set the size of 80 x 110.

Can anyone guide me further towards the resolution ??

我需要采取法案打印在80×110毫米。我使用FPDF格式创建一个PDF文件。在浏览器中显示的尺寸是正确的,是80×110,但当我把打印在A4大小。我尝试A4信,法律设置80×110的大小。

谁能指导我进一步解决这个问题??

answer1: 回答1:

Please look at the FPDF Constructor, as it has your answer. I'd also recommend the rest of the FPDF API for future reading. You can set a custom size for a PDF document as such:

$pdf = new FPDF('P','mm',array(80,110));

请看FPDF构造函数,因为它有你的答案。我也建议的FPDF REST API为未来的阅读。你可以设置一个PDF文件作为自定义大小:

$pdf = new FPDF('P','mm',array(80,110));
php  fpdf