Installing PDFLib


#1

Hi!
I’m trying to install PDFLib extension for PHP in one site of mine.

I just successfully compiled an own installation of PHP, as described at http://wiki.dreamhost.com/Installing_PHP5 , and it works fine.

After that, I did the operations described at http://wiki.dreamhost.com/PDFlib#Installing_PDFlib , but using PDFlib-8.0.1 instead of PDFlib-7.0.3 (not available now).
So I did, from home directory:
wget http://www.pdflib.com/binaries/PDFlib/801/PDFlib-8.0.1-Linux-php.tar.gz
tar -xvvzf PDFlib-8.0.1-Linux-php.tar.gz
cd test.mywebsite.it/cgi-bin/
cp …/…/PDFlib-8.0.1-Linux-php/bind/php/php-520/libpdf_php.so .
cp …/…/php5/etc/php5/test.mywebsite.it/php.ini .

then I’ve updated my extensions list in php.ini with
extension=libpdf_php.so

All works right, without errors.
But nothing changes: phpinfo() tells me always the same and miss PDF support. I’ve also tryied to execute some PDF functions from PHP, but fails.

I’m sure I’m using the right php.ini: I’ve changed others variables and can see this changes in phpinfo() page.
I’ve also tryied to change extension_dir, or to use a non-sense name for extension, but nothig change… no errors and no PDF support.

Someone can help me?
Thanks, Roberto


#2

Are you on VPS? If so, try restarting your VPS

$50 off and 3 free domains with code: [color=#CC0000]DH3[/color] Sign Up NOW or More Codes Here


#3

No, I’m not on VPS


#4

So, I fail the PDFLib installation, but I found that I can use GhostScript for my needs.
GhostScript is running in all domains, I easily executed it in my PHP script to merge different PDF files (also the ones encoded with >PDF1.4 crypt standard):

gs -dBATCH -q -dNOPAUSE -sDEVICE=pdfwrite -sPAPERSIZE=a4 -sOutputFile=tmp.pdf file1.pdf file2.pdf file3.pdf

it works!