FPDF - How can I have different pages with different sizes

自作多情 提交于 2019-12-11 11:14:57

问题


Using FPDF, I wish to have multiple pages each with a different size, but I can't work out how to get it to work. I assumed that the following:

$pdf ->AddPage(Array(55,85));       
//add first page content

$pdf ->AddPage(Array(139,99));
//add second page content

would work, but it just makes them both the default (A4) if I don't specify a width on the constructor, or the width I specify if I do.

What am I doing wrong?


回答1:


You need to pass 'P' or 'L' as the first argument. Then the size in array.



来源:https://stackoverflow.com/questions/19161733/fpdf-how-can-i-have-different-pages-with-different-sizes

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!