Jump to content

CPDF_import_jpeg


gamer10101

Recommended Posts

I am having a big problem with cpdf_import_jpeg. It just doesn't seem to work. After days of googling to no success, I found this forum so decided to try my luck here. The main problem is that the image doesn't show up. I have tried everything possible but must be missing something simple. My code:

 

cpdf_import_jpeg($cpdf, "test.jpg", 300, 50, 0.0, 0.0, 300.0, 0.0, 0.0, 0, 1);

 

I tried both 1 and 0 for gsave but no dofference. I even tried $result=cdpf_import_jpeg(... and displaying $result to see if there was an error and it seems to be fine as it returns 1. I don't know where to go from here. Any advice?

 

specs:

PHP 5.2.6

apache 2.2

Clibpdf installed correctly and working according to phpinfo() as well as a full pdf page being created properly (except the jpeg)

GD 2.1.9 (so cpdf_place_inline_image is out of the question, as it only works with 1.3, if not then something doesn't work with my GD because the command cpdf_place_inline_image throws an "undefined function" error)

Link to comment
Share on other sites

If no one knows of why this isn't working, I will be more than happy to use an alternative command. I need to input an image (can be any type) into my pdf document. Are there any other commands to do it other than place_inline_image or import_jpeg?

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.