export to PDF: no images
Moderator: Thorsten
export to PDF: no images
Seems like there are no images in the PDF's when I create them with version 1.5.0
With the 1.4.7 version, I have no problems. Could the location of the images have something to do with it?
With the 1.4.7 version, I have no problems. Could the location of the images have something to do with it?
Hi,
there are some problems with images in 1.5. How do you include the images?
bye
Thorsten
there are some problems with images in 1.5. How do you include the images?
bye
Thorsten
phpMyFAQ Maintainer and Lead Developer
amazon.de Wishlist
amazon.de Wishlist
Hi,
can you show me your FAQ?
bye
Thorsten
can you show me your FAQ?
bye
Thorsten
phpMyFAQ Maintainer and Lead Developer
amazon.de Wishlist
amazon.de Wishlist
Same Problem version 1.6.9
I run PMF on RHEL 4, I've also got full 777 permissions to all the PMF folders/files.
When I try to generate a PDF from an article, the images do not export. I get no error messages at all. The PDF file loads fine, but the images don't work.
At first, I had .png files, I changed that to .gif, still no luck.
I tried relative paths, and full paths to the images, and still no luck.
Any ideas on what else could be causing this?
Thanks
George
When I try to generate a PDF from an article, the images do not export. I get no error messages at all. The PDF file loads fine, but the images don't work.
At first, I had .png files, I changed that to .gif, still no luck.
I tried relative paths, and full paths to the images, and still no luck.
Any ideas on what else could be causing this?
Thanks
George
Hi,
.gif is not supported in the PDFs. Do you see any errors in your errorlog?
bye
Thorsten
.gif is not supported in the PDFs. Do you see any errors in your errorlog?
bye
Thorsten
phpMyFAQ Maintainer and Lead Developer
amazon.de Wishlist
amazon.de Wishlist
Image Format and inclusion in PDF
Thanks Thorsten for the reply. I just created a new entry in my FAQ and this time, I uploaded the images in JPEG format. The PDF export worked as expected. The images were visible.
I have tried this with PNG images but it did not work. Obviously, like you said, GIFs don't work either.
So, unless I'm mistaken, it seems that only JPEGs get loaded into PDFs.
I have a question though. You mention if I've looked at the error log. Can you please let me know where is or which error log I should be looking at.
Thanks
George
I have tried this with PNG images but it did not work. Obviously, like you said, GIFs don't work either.
So, unless I'm mistaken, it seems that only JPEGs get loaded into PDFs.
I have a question though. You mention if I've looked at the error log. Can you please let me know where is or which error log I should be looking at.
Thanks
George
Hi,
if the PNGs have an alpha channel you can't see them. Only 8Bit and 24Bit PNGs were shown in the PDFs.
If you have an own server you could look in the apache errorlog for example.
bye
Thorsten
if the PNGs have an alpha channel you can't see them. Only 8Bit and 24Bit PNGs were shown in the PDFs.
If you have an own server you could look in the apache errorlog for example.
bye
Thorsten
phpMyFAQ Maintainer and Lead Developer
amazon.de Wishlist
amazon.de Wishlist
Hello,
I have a problem with PDF generation and images with V2.0.4.
I have tried to include a .gif, a .jpg and a .png in a test record. None of these pictures are printed on the PDF file.
I read this forum about this problem, and tried to modify the path to my images from :
/images/... to ./images/.. but the HTML Editor automatically changes this path.
I have no error message and the text part of the PDF file is OK.
Is there a way to solve this?
Thank you.
Y.
I have a problem with PDF generation and images with V2.0.4.
I have tried to include a .gif, a .jpg and a .png in a test record. None of these pictures are printed on the PDF file.
I read this forum about this problem, and tried to modify the path to my images from :
/images/... to ./images/.. but the HTML Editor automatically changes this path.
I have no error message and the text part of the PDF file is OK.
Is there a way to solve this?
Thank you.
Y.
I don't know, if this has been fixed. Fix for 2.0.6 and above may be:
AddImage method in Pdf.php in inc\PMF_Export:
Change
to
($image line only)
Explanation: If an image isn't fully referenced (incl. http), "http" and the domain will be added to the path. If you use PHPMyFAQ in a subfolder, this folder won't get added to the path. tinyMCE itself uses a relative path excluding the PHPMyFAQ subfolder, so the subfolder is always missing.
Regards,
HerrB
AddImage method in Pdf.php in inc\PMF_Export:
Change
Code: Select all
if ('http' != substr($image, 0, 4)) {
// Please note that the image must be accessible by HTTP NOT ONLY by HTTPS
$image = 'http://'.$_SERVER['HTTP_HOST'].$image;
}
Code: Select all
if ('http' != substr($image, 0, 4)) {
// Please note that the image must be accessible by HTTP NOT ONLY by HTTPS
$image = 'http://'.$_SERVER['HTTP_HOST'].dirname($_SERVER['PHP_SELF']).'/'.$image;
}
Explanation: If an image isn't fully referenced (incl. http), "http" and the domain will be added to the path. If you use PHPMyFAQ in a subfolder, this folder won't get added to the path. tinyMCE itself uses a relative path excluding the PHPMyFAQ subfolder, so the subfolder is always missing.
Regards,
HerrB
Re: export to PDF: no images
I just updated to 2.0.15 and noticed that export to PDF with images doesn't work at all. Export with no images works nicely. Am I doing something wrong or is this a bug?
Re: export to PDF: no images
Hi Johanna,
could you please try toi enable the DEBUG mode in inc/Init.php and post the error messages here.
bye
Thorsten
could you please try toi enable the DEBUG mode in inc/Init.php and post the error messages here.
bye
Thorsten
phpMyFAQ Maintainer and Lead Developer
amazon.de Wishlist
amazon.de Wishlist