Generating PDF files ezpdf |
[eluser]Zied[/eluser]
Hi! I used this tutorial http://codeigniter.com/news/codeigniter_...deigniter/ to generate pdf file but when i use addJpegFromFile() or addFromFile() i have problem Code: $this->cezpdf->addFromFile("images/image.jpg",100,600); Code: $this->cezpdf->addJpegFromFile(base_url().'images/image.jpg',199,100,200,0); the file is created but without images. I need to put same images in my document. thinks
[eluser]tastatura[/eluser]
i am also having problem with Images and EzPDF. Did you find any solution?
[eluser]Zied[/eluser]
I changed it, i use now Dompdf, and it's very easy and very good
[eluser]Unknown[/eluser]
I know this is a slightly old thread... But I found the solution. addJpegFromFile requires a "file" not a "url"... So for example, here is my code: Code: $image = $_SERVER{'DOCUMENT_ROOT'} . "/images/my_image.jpg"; If you pass a URL (like an img src) it will always fail. It took me forever to figure this out, but what made it clear was when I used the file_exists() function and it always failed... I remembered "duh, it's looking for a file on the server". I hope this helps someone. |
Welcome Guest, Not a member yet? Register Sign In |