Welcome Guest, Not a member yet? Register   Sign In
cezpdf - putting an image into a PDF
#1

[eluser]Unknown[/eluser]
Hi,

I'm trying to place an image into PDF.

I've managed to get text to display, however when I use the following code:

Code:
$imgImage = imagecreatefrompng($imgPath);// prepare image for pdf
$this->cezpdf->addImage($imgImage, 100, 100, 0, 0);// add image into the pdf.
                      //100,100 x and y coordinate values(integer) 0- width, 0- height.

and I change the values of the height and width of the image to anything other than 0 I get a popup message on my pdf that reads:

"('file is corrupted or not repaired')"

I've checked that the image exists, and I'm pointing it to the files absolute path.

Hopefully someone can point me in the right direction!

Thanks




Theme © iAndrew 2016 - Forum software by © MyBB