我想使用ezPDF
in codeigniter 创建一个简单的 pdf。我正在关注这篇文章。我的控制器代码如下所示:
<?php
class Hello extends CI_Controller {
function index()
{
$this->load->library('Cezpdf');
$this->Cezpdf->ezText('Hello World', 12, array('justification' => 'center'));
$this->Cezpdf->ezSetDy(-10);
$content = 'The quick, brown fox jumps over a lazy dog. DJs flock by when MTV ax quiz prog.
Junk MTV quiz graced by fox whelps. Bawds jog, flick quartz, vex nymphs.';
$this->Cezpdf->ezText($content, 10);
$this->Cezpdf->ezStream();
}
}
我复制了应用程序目录中的Cezpdf.php
和文件夹。所以现在我收到此错误:Cpdf.php
/application/libraries
fonts
A PHP Error was encountered
Severity: Error
Message: Call to a member function ezText() on a non-object
Filename: controllers/hello.php
Line Number: 6
Backtrace:
我怎样才能解决这个问题???任何帮助,将不胜感激..