I have made a website in HTML and CSS, then I have used this code to convert it to pdf:
<?php
include("mpdf/mpdf.php");
$mpdf=new mPDF('c','A4','','' , 0 , 0 , 0 , 0 , 0 , 0);
$mpdf->SetDisplayMode('fullpage');
$mpdf->list_indent_first_level = 0; // 1 or 0 - whether to indent the
first level of a list
$mpdf->WriteHTML(file_get_contents('myhtmlcssfile.php'));
$mpdf->Output();
?>
Everything is fine, it's converting the .php file very well, until I use this function:
<?php echo $_POST["something"]; ?>
Where "something" is a field from form.
So it isn't printing what POST method is sent, only php code.
What am I doing wrong?