Re : Afficher un contenu en pdf
Bonjour,
Problème résolu ? Merci de passer le sujet en "réglé"
Cordialement,
Bonjour,
Problème résolu ? Merci de passer le sujet en "réglé"

Cordialement,

protected function iniDomPdf()
{
$file = JPATH_LIBRARIES .'/dompdf/autoload.inc.php';
if (!file_exists($file))
{
return false;
}
if (!defined('DOMPDF_ENABLE_REMOTE'))
{
define('DOMPDF_ENABLE_REMOTE', true);
}
//set the font cache directory to Joomla's tmp directory
$config = JFactory::getConfig();
if (!defined('DOMPDF_FONT_CACHE'))
{
define('DOMPDF_FONT_CACHE', $config->get('tmp_path'));
}
require_once($file);
// Default settings are a portrait layout with an A4 configuration using millimeters as units
$this->engine =new Dompdf();
$this->engine->set_option('enable_remote', TRUE);
return true;
}
Commentaire