modify function printer and dompdf_generator