I am trying to do some PDF templating work with PHP/PDFLib. I have a template file created and I am able to use all of the php functions for pdf's but I am having a slight problem:
here is part of my code $pdi_file = $_SERVER['DOCUMENT_ROOT'].dirname($_SERVER['PHP_SELF']).'/block_test.pdf'; $pdf = PDF_new(); pdf_open_file($pdf); $src_doc = pdf_open_pdi($pdf,$pdi_file,'', 0); $src_page = pdf_open_pdi_page($pdf,$src_doc,1,''); $src_width = pdf_get_pdi_value($pdf,'width' ,$src_doc,$src_page,0); $src_height = pdf_get_pdi_value($pdf,'height',$src_doc,$src_page,0); everything works great until I get to here: $src_width = pdf_get_pdi_value($pdf,'width' ,$src_doc,$src_page,0); I get a fatal php error: Fatal error: PDFlib error [1118] PDF_get_pdi_value: Handle parameter 'page' has bad value 0 in /var/www/html/active/www.midstatedistributing.com/html/developers/test.php on line 11 >From the user comments on php.net, it says the forth paremeter of pdf_get_pdi_value needs to be a valid PDF page handle. I cant seem to find a way to get a page handle into a variable. Has anyone had any experience with this? I am having troubles finding stuff on the web. Thanks in advance. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php