Welcome Guest, Not a member yet? Register   Sign In
CodeIgniter Community Voice - Generating PDF files using CodeIgniter
#34

[eluser]Unknown[/eluser]
Thanks for the great article.

I had couple of questions about the landscape parameter and displaying the PDF document in landscape mode.

When I tried loading the landscape parameter through an array, I was unsuccessful. I was unable to display the PDF document in landscape mode using the code below.

Code:
$config = array('paper'=>'a4', 'orientation'=>'landscape');
$this->load->library('cezpdf', $config);

I was however able to to load the landscape parameter and display the PDF document in landscape mode with the code below.

Code:
$this->load->library('cezpdf');    
$this->cezpdf->cezpdf('a4', 'landscape');

First, what is the correct way to load the parameters using an array for this library? Second, is the second snippet of code correct?


Thanks,

Alcarj


Messages In This Thread
CodeIgniter Community Voice - Generating PDF files using CodeIgniter - by El Forum - 07-29-2009, 11:52 AM



Theme © iAndrew 2016 - Forum software by © MyBB