I am generating PDFs using DOMPDF. Everything works fine. However, when I open the pdf file I can see the default grey background color. I had some other tables to print but it had the same issue, I thought may be something is wrong with my CSS. I tried to change the background color of all divs
and tables
but nothing worked. Therefore, I decided to print only dummy data with no css to see if there is any other issue. When i tried to print the only one word then below is the result i can see in PDF.
So, I am wondering how can i change it in to white color.
Following is my simple 5 lines code to generate this.
$dompdf = new DOMPDF();
$dompdf->load_html($listing);
$dompdf->set_paper('a4', 'landscape');
$dompdf->render();
file_put_contents('file.pdf', $dompdf->output());