Hi,
i want to generate a pdf in moodle 2.9. when a particular function is called. i have tried the following.
public function test()
{
$doc = new pdf;
$doc->AddPage();
$doc->Write(5, 'Hello World!');
$doc->Output();
}
but its not working. i have included require_once('../../config.php') and require_once("$CFG->libdir/pdflib.php"); . please help me