CJones
Final Approach
I'm creating barcodes on an HTML page using a barcode generator in PHP. I would like to export those barcodes (and some other data) into a PDF.
I can export the other data with no problem using FPDF. When I try to export the barcode (as an image), it doesn't go through. I looked through the barcode generator and it is creating the barcode image using ImageJPEG. To display the barcode in HTML, I simply use an <img src='barcode.php?barcode=[text]&width=500&height=75'>. This displays the image on the webpage with no problem.
When try to put the image into the PDF using $pdf->Image('barcode.php?barcode=[text]&width=500&height=75'), I get an error saying "Invalid image type .php?......"
Digging deeper into the barcode generator, the ImageJPEG is simply outputting the image stream without ever saving the file anywhere. I tried putting a filename in the ImageJPEG call, but I can't find if/where it is saving the images to make a call to the image file itself.
Any ideas on how I can get a dynamically generated image file to export to PDF through PHP?
I can export the other data with no problem using FPDF. When I try to export the barcode (as an image), it doesn't go through. I looked through the barcode generator and it is creating the barcode image using ImageJPEG. To display the barcode in HTML, I simply use an <img src='barcode.php?barcode=[text]&width=500&height=75'>. This displays the image on the webpage with no problem.
When try to put the image into the PDF using $pdf->Image('barcode.php?barcode=[text]&width=500&height=75'), I get an error saying "Invalid image type .php?......"
Digging deeper into the barcode generator, the ImageJPEG is simply outputting the image stream without ever saving the file anywhere. I tried putting a filename in the ImageJPEG call, but I can't find if/where it is saving the images to make a call to the image file itself.
Any ideas on how I can get a dynamically generated image file to export to PDF through PHP?