I came through this very funny case while i was developing a site which uses DOMPDF to generate PDF from html.

The problem was I was not getting the images in the PDF generated.

  • I had url_fopen ON on server.
  • I had tried all relative and absolute paths for the image.
  • Everything I could imagine.

Finally I found out that a simple CSS was not letting the image get displayed on PDF

the css was for img tag


I removed the CSS and the images were there. :((

A day wasted by a single line of CSS.