I need to create a PDF file of a php page that includes php variables and js generated content.
I tried achieving this with mPDF and the following script:
require_once "libraries/mpdf/mpdf.php";
ob_start(); // start output buffering
include 'appartamento.php';
$content = ob_get_clean(); // get content of the buffer and clean the buffer
$mpdf = new mPDF();
$mpdf->SetDisplayMode('fullpage');
$mpdf->WriteHTML($content);
$mpdf->Output(); // output as inline content
However, the generated pdf does only include very few content of the php page and i don't know what needs to be done to display the whole content in the pdf file.
Any ideas?