[PHP] pdflib greek problem
Hi, I am trying the following code to generate a pdf: try { // Create a new pdf handler $pdf = new PDFlib(); // open new PDF file if ($pdf-begin_document(, ) == 0) { die(Error: . $p-get_errmsg()); } // Set some info to the new pdf $pdf-set_info(Creator, Test); $pdf-set_info(Author, Test); $pdf-set_info(Title, Test); // Start the page $pdf-begin_page_ext(595, 842, ); // Load the documents font and set the details $font = $pdf-load_font(Times-Roman, iso8859-7, ); $pdf-setfont($font,24.0); $pdf-set_parameter('autospace',TRUE); // Set the position inside the document $pdf-set_text_pos(50, 700); // Now start to show the data $str = 'Αυτό είναι ένα τεστ.'; mb_convert_variables('ISO-8859-7','UTF-8',$str); $pdf-show($str); // End the page and the document $pdf-end_page_ext(); $pdf-end_document(); // Get the document from the buffer find it's length $buf = $pdf-get_buffer(); $len = strlen($buf); // And finally print it out to the browser header(Content-type: application/pdf); header(Content-Length: $len); header(Content-Disposition: inline; filename=hello.pdf); print $buf; } catch (PDFlibException $e) { die(PDFlib exception occurred in hello sample:\n . [ . $e-get_errnum() . ] . $e-get_apiname() . : . $e-get_errmsg() . \n); } catch (Exception $e) { die($e); } Although greek are printed normally the characters are overlapping on each other. The script in encoded in UTF-8. Does anybody have any suggestions on this? Please any help would be appreciated. -- Thodoris -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] pdflib greek problem
Thodoris wrote: Hi, I am trying the following code to generate a pdf: try { // Create a new pdf handler $pdf = new PDFlib(); // open new PDF file if ($pdf-begin_document(, ) == 0) { die(Error: . $p-get_errmsg()); } // Set some info to the new pdf $pdf-set_info(Creator, Test); $pdf-set_info(Author, Test); $pdf-set_info(Title, Test); // Start the page $pdf-begin_page_ext(595, 842, ); // Load the documents font and set the details $font = $pdf-load_font(Times-Roman, iso8859-7, ); $pdf-setfont($font,24.0); $pdf-set_parameter('autospace',TRUE); // Set the position inside the document $pdf-set_text_pos(50, 700); // Now start to show the data $str = 'Αυτό είναι ένα τεστ.'; mb_convert_variables('ISO-8859-7','UTF-8',$str); $pdf-show($str); // End the page and the document $pdf-end_page_ext(); $pdf-end_document(); // Get the document from the buffer find it's length $buf = $pdf-get_buffer(); $len = strlen($buf); // And finally print it out to the browser header(Content-type: application/pdf); header(Content-Length: $len); header(Content-Disposition: inline; filename=hello.pdf); print $buf; } catch (PDFlibException $e) { die(PDFlib exception occurred in hello sample:\n . [ . $e-get_errnum() . ] . $e-get_apiname() . : . $e-get_errmsg() . \n); } catch (Exception $e) { die($e); } Although greek are printed normally the characters are overlapping on each other. The script in encoded in UTF-8. Does anybody have any suggestions on this? Please any help would be appreciated. LaTeX has some greek stuff that works fairly well - though you have to use one of the fonts encoded for LaTeX. If you mean to have a web app generate the PDF you'll have to output to .tex and then use a shell command to compile the document, but it is a solution that is fairly well tested for creation of Greek (monotonic and polytonic) PDF documents. I know that isn't what you asked, but in case there isn't a PDFLib solution to the typesetting issue, I suspect an application designed for typesetting will give better results anyway. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] PDFlib problem
Hi, I have problem with PDFlib on Windows 2000, PHP 5.2.0 and Apache 2.2.3 When I try to execute: $p = new PDFlib(); in the Apache log I receive: PDFlib exception (fatal): [1202] PDF_set_parameter: Unknown key 'objorient' [.] [notice] Parent: child process exited with status 99 -- Restarting. And nothing happens - I receive Problem loading page. Can someone help? Thanks in advance, Rosen -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP] PDFlib problem
Try this one: http://pecl.php.net/bugs/bug.php?id=9491edit=1 /Peter www.dwsasia.com - company web site www.lauri.se - personal web site www.carbonfree.org.uk - become Carbon Free -Original Message- From: Rosen [mailto:[EMAIL PROTECTED] Sent: Wednesday, December 27, 2006 2:58 PM To: php-general@lists.php.net Subject: [PHP] PDFlib problem Hi, I have problem with PDFlib on Windows 2000, PHP 5.2.0 and Apache 2.2.3 When I try to execute: $p = new PDFlib(); in the Apache log I receive: PDFlib exception (fatal): [1202] PDF_set_parameter: Unknown key 'objorient' [.] [notice] Parent: child process exited with status 99 -- Restarting. And nothing happens - I receive Problem loading page. Can someone help? Thanks in advance, Rosen -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] PDFlib problem
Rosen wrote: Hi, I have problem with PDFlib on Windows 2000, PHP 5.2.0 and Apache 2.2.3 When I try to execute: $p = new PDFlib(); in the Apache log I receive: PDFlib exception (fatal): [1202] PDF_set_parameter: Unknown key 'objorient' [.] [notice] Parent: child process exited with status 99 -- Restarting. And nothing happens - I receive Problem loading page. Can someone help? read this (it might help): http://pecl.php.net/bugs/bug.php?id=9491edit=1 basically, if your lucky, all you need to do is update PDFlib to a newer version. Thanks in advance, Rosen -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] pdflib - change text color mid-sentence
Hi, I'm having some problems with a pdf file I'm compiling dynamically with pdflib, and my searches for answers have come up empty, so I'm hoping someone else out there has faced the same problem and came up with a solution. I want to change the text color of a word mid-sentence when outputting text to a pdf file. I've looked at pdf_show_boxed and pdf_show_xy, but I dont think either would actually work the way I need, and I'm hoping their is an easier way than trying to step through a long string word by word, then changing color to display one word, and then trying to continue while making it all look as though it flows. This, of course, would open up all kinds of issues in terms of line feeds and the like If anyone has any advice or could help in any way, please let me know because this has been frustrating. Thanks in advance, Michael. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] pdflib - change text color mid-sentence
On Tue, October 17, 2006 9:50 am, [EMAIL PROTECTED] wrote: I want to change the text color of a word mid-sentence when outputting text to a pdf file. I've looked at pdf_show_boxed and pdf_show_xy, but I dont think either would actually work the way I need, and I'm hoping their is an easier way than trying to step through a long string word by word, then changing color to display one word, and then trying to continue while making it all look as though it flows. This, of course, would open up all kinds of issues in terms of line feeds and the like If anyone has any advice or could help in any way, please let me know because this has been frustrating. After you do pdf_show_boxed() for the one color, do this: $textx = pdf_get_value($pdf, 'textx', 0); $texty = pdf_get_value($pdf, 'texty', 0); Now you know where PDFlib left off for the last word of that color. You can begin again at that point with a new color. Rinse. Repeat. It's probably going to be a pain to finish off a line, and then do a large chunk of text after that, but it's totally do-able. Note that pdf_show_boxed returns all the text that didn't fit -- so if you do this with boxes that are one line, and just keep doing that line after line, interspersing with the colored text and using the pdf_get_value() above, this is totally do-able, if somewhat tedious. If the colored text is rare enough, it might be worth doing something like: 1. text up to next colored text 2. pdf_get_value() 3. colored text 4. pdf_get_value() 5. one_line box size for pdf_show_boxed, returns rest of text 6. GOTO 1. particularly if you have huge texts and need performance to not loop through it one line at a time for ALL of it. On the plus side, pdflib, in my experience, tends to generate VERY small and compact PDF output, so the bandwidth is as cheap as it can be... YMMV -- Some people have a gift link here. Know what I want? I want you to buy a CD from some starving artist. http://cdbaby.com/browse/from/lynch Yeah, I get a buck. So? -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] PDFLib or some free solution?
Hi I have used fpdf quite a lot (http://www.fpdf.org) and have been really impressed with its performance. There are plenty of example scripts on their website and i think you can use it comercially for free although you will have to check that one out. Regards Pure Web Solution http://www.purewebsolution.co.uk PHP, MYSQL, Web Design Web Services [EMAIL PROTECTED] wrote: Hi, I have to create some flyers and invoices (simple stuff) in one my project. On php.net/pdf is mentioned PDFLib, but I know there is a free solution too. It's commercial and can't have PDFLib for free. My questions are: - Is really $450 for PDFLib worth comparing to free solution? (I need for really simple stuff) - Is there a difference (look and programming) and how big it is, between PDFLib and free solution? Could you please give me some directions? Thanks. -afan Pure Web Solution http://www.purewebsolution.co.uk PHP, MYSQL, Web Design Web Services -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] PDFLib or some free solution?
As I said in prev post, there is a problem with converting HTML to PDF: FAQ 19. Can I convert an HTML page to PDF with FPDF? Not real-world pages. But a GPL C utility does exist, htmldoc, which allows to do it and gives good results: http://www.htmldoc.org Does it has anything with building flyer using php and html tags? Hi I have used fpdf quite a lot (http://www.fpdf.org) and have been really impressed with its performance. There are plenty of example scripts on their website and i think you can use it comercially for free although you will have to check that one out. Regards Pure Web Solution http://www.purewebsolution.co.uk PHP, MYSQL, Web Design Web Services [EMAIL PROTECTED] wrote: Hi, I have to create some flyers and invoices (simple stuff) in one my project. On php.net/pdf is mentioned PDFLib, but I know there is a free solution too. It's commercial and can't have PDFLib for free. My questions are: - Is really $450 for PDFLib worth comparing to free solution? (I need for really simple stuff) - Is there a difference (look and programming) and how big it is, between PDFLib and free solution? Could you please give me some directions? Thanks. -afan Pure Web Solution http://www.purewebsolution.co.uk PHP, MYSQL, Web Design Web Services -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] PDFLib or some free solution?
Hi, I have to create some flyers and invoices (simple stuff) in one my project. On php.net/pdf is mentioned PDFLib, but I know there is a free solution too. It's commercial and can't have PDFLib for free. My questions are: - Is really $450 for PDFLib worth comparing to free solution? (I need for really simple stuff) - Is there a difference (look and programming) and how big it is, between PDFLib and free solution? Could you please give me some directions? Thanks. -afan -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] PDFLib or some free solution?
Results may well vary Depending on the complexity of the html pages, but have you tried using the example script 'HTML Conversion'? you could modify this/expand it to fit your needs. worth a try i would of thought. Pure Web Solution http://www.purewebsolution.co.uk PHP, MYSQL, Web Design Web Services [EMAIL PROTECTED] wrote: As I said in prev post, there is a problem with converting HTML to PDF: FAQ 19. Can I convert an HTML page to PDF with FPDF? Not real-world pages. But a GPL C utility does exist, htmldoc, which allows to do it and gives good results: http://www.htmldoc.org Does it has anything with building flyer using php and html tags? Hi I have used fpdf quite a lot (http://www.fpdf.org) and have been really impressed with its performance. There are plenty of example scripts on their website and i think you can use it comercially for free although you will have to check that one out. Regards Pure Web Solution http://www.purewebsolution.co.uk PHP, MYSQL, Web Design Web Services [EMAIL PROTECTED] wrote: Hi, I have to create some flyers and invoices (simple stuff) in one my project. On php.net/pdf is mentioned PDFLib, but I know there is a free solution too. It's commercial and can't have PDFLib for free. My questions are: - Is really $450 for PDFLib worth comparing to free solution? (I need for really simple stuff) - Is there a difference (look and programming) and how big it is, between PDFLib and free solution? Could you please give me some directions? Thanks. -afan Pure Web Solution http://www.purewebsolution.co.uk PHP, MYSQL, Web Design Web Services -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php Pure Web Solution http://www.purewebsolution.co.uk PHP, MYSQL, Web Design Web Services -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP] PDFLib or some free solution?
-Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Sent: Tuesday, March 21, 2006 7:27 AM To: Pure Web Solution Cc: [EMAIL PROTECTED]; php-general@lists.php.net Subject: Re: [PHP] PDFLib or some free solution? As I said in prev post, there is a problem with converting HTML to PDF: FAQ 19. Can I convert an HTML page to PDF with FPDF? Not real-world pages. But a GPL C utility does exist, htmldoc, which allows to do it and gives good results: http://www.htmldoc.org Does it has anything with building flyer using php and html tags? I've started looking at htmldoc for some upcoming projects. You can generate a flyer (or any other kind of document you want) using HTML and convert it to HTML very easily. Take a look at http://www.easysw.com/htmldoc/examples.php for examples using htmldoc. Brady -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] PDFlib-Lite-6.0.1
http://www.pdflib.com/products/pdflib/download/601src/PDFlib-Lite-6.0.1.tar.gzI am trying to install PDFlib-Lite-6.0.1 on my testing server. So far no luck. I am starting with php 4.3.3 and apache 2.0 on an SUSE 9.0 machine. Apache and php were installed with the OS. I started by getting tiff-3.7.1.tar.gz and jpegsrc.v6b.tar.gz and those both installed with out a problem then I got PDFlib-Lite-6.0.1.tar.gz and that configured compiled fine then came the problems. Here is the command and out put... PIII500x2:~ # pear install pdflib downloading pdflib-2.0.4.tgz ... ...done: 36,082 bytes 7 source files, building running: phpize Configuring for: PHP Api Version: 20020918 Zend Module Api No: 20020429 Zend Extension Api No: 20021010 `phpize' failed Any ideas? -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] PDFLIB error 2516
Hi All, I upgraded my test system to 4.3.9 (from 4.3.4) and now run into problems with pdf creation. Scripts that ran fine before now return the following error: Fatal error: PDFlib error: [2516] PDF_findfont: Metrics data for font 'Arial' not found in d:\website\pdf_graph.php on line 50 Has anybody seen this before and knows of the solution? Google returned no hits that solved the problem. snip pdf_open_file($pdf, d:\\website\\graphs.pdf); pdf_set_info($pdf, Author, Automatically Generated); pdf_set_info($pdf, Title, Management graphs); pdf_set_info($pdf, Creator, Jacob A. van Zanen); pdf_set_info($pdf, Subject, Management Graphs); pdf_begin_page($pdf, 700, 600); $bookmark1 = pdf_add_bookmark($pdf, Information for machine SBPXXA1); $arial = pdf_findfont($pdf, Arial, host, 1); pdf_setfont($pdf, $arial, 12); //-this is line 50 pdf_show_xy($pdf, 1Information for machine SBPXXA1 for $_POST[day]/ $_POST[month]/$_POST[year],50, 510); /snip TiA Jack van Zanen
Re: [PHP] PDFLIB error 2516
Hi, Friday, November 5, 2004, 8:18:16 PM, you wrote: JvZnc Hi All, JvZnc I upgraded my test system to 4.3.9 (from 4.3.4) and now run into problems JvZnc with pdf creation. Scripts that ran fine before now return the following JvZnc error: JvZnc Fatal error: PDFlib error: [2516] PDF_findfont: Metrics data for font JvZnc 'Arial' not found in d:\website\pdf_graph.php on line 50 JvZnc Has anybody seen this before and knows of the solution? Google returned no JvZnc hits that solved the problem. JvZnc snip JvZnc pdf_open_file($pdf, d:\\website\\graphs.pdf); JvZnc pdf_set_info($pdf, Author, Automatically Generated); JvZnc pdf_set_info($pdf, Title, Management graphs); JvZnc pdf_set_info($pdf, Creator, Jacob A. van Zanen); JvZnc pdf_set_info($pdf, Subject, Management Graphs); JvZnc pdf_begin_page($pdf, 700, 600); JvZnc $bookmark1 = pdf_add_bookmark($pdf, Information for machine SBPXXA1); JvZnc $arial = pdf_findfont($pdf, Arial, host, 1); pdf_setfont($pdf, $arial, JvZnc 12); //-this is line 50 JvZnc pdf_show_xy($pdf, 1 Information for machine SBPXXA1 for $_POST[day]/ JvZnc $_POST[month]/$_POST[year],50, 510); JvZnc /snip JvZnc TiA JvZnc Jack van Zanen You have to tell pdf where to find the font, I do it this way pdf_set_parameter($pdf, FontOutline, Arial=/path/to/arial.ttf); -- regards, Tom -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP] PDFLIB error 2516
Thx That was it. Anybody have any ideas as to why this behaviour changed?? Regards Jack -Original Message- From: Tom Rogers [mailto:[EMAIL PROTECTED] Sent: Friday, November 05, 2004 12:46 PM To: [EMAIL PROTECTED] Cc: [EMAIL PROTECTED] Subject: Re: [PHP] PDFLIB error 2516 Hi, Friday, November 5, 2004, 8:18:16 PM, you wrote: JvZnc Hi All, JvZnc I upgraded my test system to 4.3.9 (from 4.3.4) and now run into JvZnc problems with pdf creation. Scripts that ran fine before now JvZnc return the following JvZnc error: JvZnc Fatal error: PDFlib error: [2516] PDF_findfont: Metrics data for JvZnc font 'Arial' not found in d:\website\pdf_graph.php on line 50 JvZnc Has anybody seen this before and knows of the solution? Google JvZnc returned no hits that solved the problem. JvZnc snip JvZnc pdf_open_file($pdf, d:\\website\\graphs.pdf); JvZnc pdf_set_info($pdf, Author, Automatically Generated); JvZnc pdf_set_info($pdf, Title, Management graphs); JvZnc pdf_set_info($pdf, Creator, Jacob A. van Zanen); JvZnc pdf_set_info($pdf, Subject, Management Graphs); JvZnc pdf_begin_page($pdf, 700, 600); JvZnc $bookmark1 = pdf_add_bookmark($pdf, Information for machine JvZnc SBPXXA1); $arial = pdf_findfont($pdf, Arial, host, 1); JvZnc pdf_setfont($pdf, $arial, 12); //-this is line 50 JvZnc pdf_show_xy($pdf, 1 Information for machine SBPXXA1 for $_POST[day]/ JvZnc $_POST[month]/$_POST[year],50, 510); JvZnc /snip JvZnc TiA JvZnc Jack van Zanen You have to tell pdf where to find the font, I do it this way pdf_set_parameter($pdf, FontOutline, Arial=/path/to/arial.ttf); -- regards, Tom -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] pdflib tables
Is there anyone who is using pdflib +php and formatting your data to the pdf via tables? Thanks! -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] pdflib tables
On Thursday 04 November 2004 01:39, blackwater dev wrote: Is there anyone who is using pdflib +php and formatting your data to the pdf via tables? I don't. But if you're having trouble you may find google php pdf class useful. -- Jason Wong - Gremlins Associates - www.gremlins.biz Open Source Software Systems Integrators * Web Design Hosting * Internet Intranet Applications Development * -- Search the list archives before you post http://marc.theaimsgroup.com/?l=php-general -- /* A rolling stone gathers no moss. -- Publilius Syrus */ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] PDFlib 6 and PHP 4.3.8/9
Hi Everyone, I am hoping someone out there may be able to help... I have recently installed PDFlib 6 and am running PHP 4.3.8. I am having trouble with the pdf_open_file() function. I would like to create a PDF to memory by leaving the second parameter (filename) in the above function empty. However, every time I do this, I get the following error message: Warning: pdf_open_file() expects exactly 2 parameters, 1 given in xxx This means I always have to create the PDF file before outputting it to the browser... which is very annoying. Has anyone else encountered this? I have been unable to find much in the groups to this point! Thanks in advance for the help. -brendan -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] PDFlib 6 and PHP 4.3.8/9
Hi, Friday, October 22, 2004, 7:44:37 AM, you wrote: BPC Hi Everyone, BPC I am hoping someone out there may be able to help... BPC I have recently installed PDFlib 6 and am running PHP 4.3.8. I am having BPC trouble with the pdf_open_file() function. I would like to create a PDF BPC to memory by leaving the second parameter (filename) in the above function BPC empty. However, every time I do this, I get the following error message: BPC Warning: pdf_open_file() expects exactly 2 parameters, 1 given in xxx BPC This means I always have to create the PDF file before outputting it to BPC the browser... which is very annoying. BPC Has anyone else encountered this? I have been unable to find much in the BPC groups to this point! BPC Thanks in advance for the help. BPC -brendan try pdf_open_file($pdf, ); -- regards, Tom -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] PDFLib pdf_get_pdi_value
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
Re: [PHP] PDFLib pdf_get_pdi_value
I figured out what was wrong. If you are interested in my solution here it is: I did some searching in the PDFLIB documentation and I needed to set this at the top of my script to show some errors pdf_set_parameter($pdf, 'pdiwarning', 'true'); then, to fix the problem I needed to add this parameter. pdf_set_parameter($pdf, 'compatibility','1.5'); -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] pdflib alternatives
Is there are any alternatives to the pdflib for on the fly generation of printable documents? May be a postcript lib? http://www.fpdf.org/?lang=en -- Jim Kaufman Linux Evangelist public key 0x6D802619 http://www.linuxforbusiness.net Thanks Jim, it's what i need. -- Fernando M. Maresca Cel: (54) 221 15 502 3938 Cel: 0221-15-502-3938 -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] pdflib alternatives
Hello everybody: Is there are any alternatives to the pdflib for on the fly generation of printable documents? May be a postcript lib? I need no fancy things, just speed and minimal formating facilities, even no graphics support is ok. Any sugestions? Thanks in advance to all of you -- Fernando M. Maresca Cel: (54) 221 15 502 3938 Cel: 0221-15-502-3938 -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] pdflib alternatives
On Mon, Feb 16, 2004 at 09:35:10PM -0300, Fernando M. Maresca wrote: Hello everybody: Is there are any alternatives to the pdflib for on the fly generation of printable documents? May be a postcript lib? I need no fancy things, just speed and minimal formating facilities, even no graphics support is ok. Any sugestions? Thanks in advance to all of you -- Fernando M. Maresca http://www.fpdf.org/?lang=en -- Jim Kaufman Linux Evangelist public key 0x6D802619 http://www.linuxforbusiness.net -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] PDFlib, transparency and TIFF images
Hi everyone - hope there's someone good at PDFlib out there I'm trying to use a picture, a TIFF image, with transparency, in a PDF created by a PHP-script... The manual says that only explicit transparency can be used when working with TIFF images, and that this operation requires two steps But then the manual loses me, and I don't understand what the two steps that seems to be required actually meens Isn't it sufficiant to have a TIFF image with transparency, or do I have to have some kind of second image and use that as some kind of mask to acquire transparency effects? Will this, if so, require two image files per image instead as one? Hope this is not OT, if so, i apologize Sincerely Victor Spng Arthursson Sweden / Denmark -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] PDFlib error 2516
On Thu, 15 Jan 2004, Mark Wouters wrote: Hello! Tried out this simple script from a tutorial on creating PDF with PHP: ?php $pdf = PDF_new(); PDF_open_file($pdf, testpdf.pdf); PDF_set_info($pdf, Author, Someone); PDF_set_info($pdf, Title, PDF creation with PHP); PDF_set_info($pdf, Creator, Someone); PDF_set_info($pdf, Subject, Creating PDFs); PDF_begin_page($pdf, 595, 842); $arial = PDF_findfont($pdf, Arial, host, 1); PDF_setfont($pdf, $arial, 14); PDF_show_xy($pdf, Pricelist, 40, 780); PDF_end_page($pdf); PDF_close($pdf); ? However got this error: Fatal error: PDFlib error: [2516] PDF_findfont: Metrics data for font 'Arial' not found in /usr/local/psa/home/vhosts/resilion.be/httpdocs/test/createpdf.php on line 23 Does anyone have an idea what the problem could be? What does the host mean in the example above ($arial = PDF_findfont($pdf, Arial, host, 1); )? Thanks for any help Mark. Hello It very much looks like you are running your script under Un*x. That is why Arial font is not found when using host setting. You should use Helvetica instead. The host refers to font selection available to PDFlib. I tried a year or so ago setting up PDFlib so that I could use other than host with no luck. As I did not need more than those three basic fonts, I spent no more time sorting out the other options. Take a look at sopdf.php that you can found from dataxi.sourceforge.net, and download latest solib-ver.tar.gz that contains the script. It is a fully functional class to produce PDF using PDFlib. Cheers, -- --Jyry C|:-(C|:-/C|8-OC|8-/C|:-( -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] PDFlib error 2516
Hello! Tried out this simple script from a tutorial on creating PDF with PHP: ?php $pdf = PDF_new(); PDF_open_file($pdf, testpdf.pdf); PDF_set_info($pdf, Author, Someone); PDF_set_info($pdf, Title, PDF creation with PHP); PDF_set_info($pdf, Creator, Someone); PDF_set_info($pdf, Subject, Creating PDFs); PDF_begin_page($pdf, 595, 842); $arial = PDF_findfont($pdf, Arial, host, 1); PDF_setfont($pdf, $arial, 14); PDF_show_xy($pdf, Pricelist, 40, 780); PDF_end_page($pdf); PDF_close($pdf); ? However got this error: Fatal error: PDFlib error: [2516] PDF_findfont: Metrics data for font 'Arial' not found in /usr/local/psa/home/vhosts/resilion.be/httpdocs/test/createpdf.php on line 23 Does anyone have an idea what the problem could be? What does the host mean in the example above ($arial = PDF_findfont($pdf, Arial, host, 1); )? Thanks for any help Mark. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] PDFlib not working with explorer based on PHP created file in memory
If anyone can help, please... I have a page that points to a PHP page that dynamically creates a pdf file using PDFlib. The page uses a link such as site.com/page.php?variable=value. That in turn executes the script that uses the variable/value to pull info from the db and generate the page. The result is that when you click the link you are prompted to save or open the document. By openning the document you are presented with the pdf by acrobat. This is seemless with Mozilla. However, on IE it hangs with the message Getting File information:. If you try to save it you get another error. I have read some information indicating that the problem is with the length parameter not being sent. However, the page I'm using was off an example someone provided and it already has what seems to be the fix for page length. The code that creates the file is as follows... $p = PDF_new(); if(PDF_open_file($p, ) == 0) { die(Error: .PDF_get_errmsg($p)); } ...body goes here... PDF_end_page($p); PDF_close($p); $buf = PDF_get_buffer($p); $len = strlen($buf); header(Content-type: application/pdf); header(Content-Length: $len); header(Content-Disposition: inline; filename=filename.pdf); print $buf; PDF_delete($p); Again, this is only a problem with m$ IE. I know this is one of the largest toolkits (PDFlib) in use for creating well defined printable documents so I can't believe that this is not a common problem or that I am doing something really wrong. Someone on PDFlib's mailing list once mentioned sending the document for download via chunks instead of getting the length except he wrote something in C/C++ to accomplish it in his app. Is there some way to tell the browser to accept via chunks in php? Does the above header look right for IE? Any help would be greatly appreciated... -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP] PDFlib not working with explorer based on PHP created file in memory
My apologies for waisting anyone's time. I found the posting in the archives that had the correct code to use. -Original Message- From: Larry Brown [mailto:[EMAIL PROTECTED] Sent: Wednesday, October 29, 2003 3:39 PM To: PHP List Subject: [PHP] PDFlib not working with explorer based on PHP created file in memory If anyone can help, please... I have a page that points to a PHP page that dynamically creates a pdf file using PDFlib. The page uses a link such as site.com/page.php?variable=value. That in turn executes the script that uses the variable/value to pull info from the db and generate the page. The result is that when you click the link you are prompted to save or open the document. By openning the document you are presented with the pdf by acrobat. This is seemless with Mozilla. However, on IE it hangs with the message Getting File information:. If you try to save it you get another error. I have read some information indicating that the problem is with the length parameter not being sent. However, the page I'm using was off an example someone provided and it already has what seems to be the fix for page length. The code that creates the file is as follows... $p = PDF_new(); if(PDF_open_file($p, ) == 0) { die(Error: .PDF_get_errmsg($p)); } ...body goes here... PDF_end_page($p); PDF_close($p); $buf = PDF_get_buffer($p); $len = strlen($buf); header(Content-type: application/pdf); header(Content-Length: $len); header(Content-Disposition: inline; filename=filename.pdf); print $buf; PDF_delete($p); Again, this is only a problem with m$ IE. I know this is one of the largest toolkits (PDFlib) in use for creating well defined printable documents so I can't believe that this is not a common problem or that I am doing something really wrong. Someone on PDFlib's mailing list once mentioned sending the document for download via chunks instead of getting the length except he wrote something in C/C++ to accomplish it in his app. Is there some way to tell the browser to accept via chunks in php? Does the above header look right for IE? Any help would be greatly appreciated... -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] PDFlib Page Dimensions and Word Wrap
Hello, I have read the http://us4.php.net/manual/en/ref.pdf.php and am unable to find a solution for what I'm trying to do. I've also tried googling for what I'm trying to do. No luck there either. I've also downloaded the PDFlib docs but no luck there. When using PDFlib you specify page dimensions. Why then, does it not automatically wrap words/texts/sentences to the next line? Is there something I'm missing to have PDFlib automatically do this? No matter the amount of text in the variable I'm trying to print in the pdf, it just runs off the right side of the pdf document. Thanks, Roger -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] PDFlib Page Dimensions and Word Wrap
* Thus wrote Roger Spears ([EMAIL PROTECTED]): Hello, I have read the http://us4.php.net/manual/en/ref.pdf.php and am unable to find a solution for what I'm trying to do. I've also tried googling for what I'm trying to do. No luck there either. I've also downloaded the PDFlib docs but no luck there. When using PDFlib you specify page dimensions. Why then, does it not automatically wrap words/texts/sentences to the next line? Is there something I'm missing to have PDFlib automatically do this? No matter the amount of text in the variable I'm trying to print in the pdf, it just runs off the right side of the pdf document. You might want to refer to the API documentation at: http://www.pdflib.com/ It seems that the pdflib documentation on the php site needs some work :) Curt -- My PHP key is worn out PHP List stats since 1997: http://zirzow.dyndns.org/html/mlists/ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] PDFlib Page Dimensions and Word Wrap
Tried that. Unless I overlooked something, the PDFlib.com docs were of no help. Thanks, Roger Curt Zirzow wrote: * Thus wrote Roger Spears ([EMAIL PROTECTED]): Hello, I have read the http://us4.php.net/manual/en/ref.pdf.php and am unable to find a solution for what I'm trying to do. I've also tried googling for what I'm trying to do. No luck there either. I've also downloaded the PDFlib docs but no luck there. When using PDFlib you specify page dimensions. Why then, does it not automatically wrap words/texts/sentences to the next line? Is there something I'm missing to have PDFlib automatically do this? No matter the amount of text in the variable I'm trying to print in the pdf, it just runs off the right side of the pdf document. You might want to refer to the API documentation at: http://www.pdflib.com/ It seems that the pdflib documentation on the php site needs some work :) Curt -- Roger Spears Technology Project Coordinator College of Arts and Sciences Bowling Green State University Bowling Green, Ohio 43403 VOICE: (419) 372-2015 FAX: (419) 372-8548
Re: [PHP] PDFlib Page Dimensions and Word Wrap
On Wednesday 08 October 2003 23:34, Roger Spears wrote: I have read the http://us4.php.net/manual/en/ref.pdf.php and am unable to find a solution for what I'm trying to do. I've also tried googling for what I'm trying to do. No luck there either. I've also downloaded the PDFlib docs but no luck there. When using PDFlib you specify page dimensions. Why then, does it not automatically wrap words/texts/sentences to the next line? Is there something I'm missing to have PDFlib automatically do this? No matter the amount of text in the variable I'm trying to print in the pdf, it just runs off the right side of the pdf document. I don't there are any such automatic niceties in the raw PDFlib. In any case if you want something that's easier to use try google php pdf class -- Jason Wong - Gremlins Associates - www.gremlins.biz Open Source Software Systems Integrators * Web Design Hosting * Internet Intranet Applications Development * -- Search the list archives before you post http://marc.theaimsgroup.com/?l=php-general -- /* System going down in 5 minutes. */ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] pdflib output reolution higher than 72 dpi possible?
Hi there, I would like to output a pdf with pdflib with 300 dpi How could I define the output resolution? Default seems to be 72 dpi Thanx for any hint, Andy -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] pdflib encoding error
Hello, maybe someone can help me. i have specified the *.PFB and the *.AFM file. this all works by setting the encoding to pdf_set_font(the_typo_name,size,winansi,1); i got the error : Warning: Internal PDFlib warning: Can't reencode Symbol font 'TheSansBold-Caps' (using builtin) in where_the_file_is on line 222 i have to use builtin encoding, but this don't look fine (its maybe a german prob;-( ) does anybody knows the matter of this error? a corrupt afm file maybe? please help -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] PDFlib error help --
I've got an old, inherited codebase (18months) that generates PDFs -- just upgraded the server and libraries and php versions and now the PDF stuff is broken -- a quick scan of the archive and on google didn't this issue on there. The error I'm getting is: PDFlib error: function 'PDF_stroke' must not be called in 'page' scope I started to just comment out the offending line and see what happened, but it complains on every instance of function call throughout the scripts and a couple of supporting classes --- eww. I did notice a lot of calls to the deprecated API, but I'd really like to find a bandaid to put on this rather than rewrite the class library and all the scripts under time pressure -- Anyone else run into this? ... any pointers, faqs, etc. -- Hank Marquardt [EMAIL PROTECTED] GPG Id: 2BB5E60C Fingerprint: D807 61BC FD18 370A AC1D 3EDF 2BF9 8A2D 2BB5 E60C -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] PDFlib error help --
There is no bandaid for this. Your code is simply wrong. You are calling a stroke function without having a path to stroke. You need to fix the code. -Rasmus On Thu, 22 Aug 2002, Hank Marquardt wrote: I've got an old, inherited codebase (18months) that generates PDFs -- just upgraded the server and libraries and php versions and now the PDF stuff is broken -- a quick scan of the archive and on google didn't this issue on there. The error I'm getting is: PDFlib error: function 'PDF_stroke' must not be called in 'page' scope I started to just comment out the offending line and see what happened, but it complains on every instance of function call throughout the scripts and a couple of supporting classes --- eww. I did notice a lot of calls to the deprecated API, but I'd really like to find a bandaid to put on this rather than rewrite the class library and all the scripts under time pressure -- Anyone else run into this? ... any pointers, faqs, etc. -- Hank Marquardt [EMAIL PROTECTED] GPG Id: 2BB5E60C Fingerprint: D807 61BC FD18 370A AC1D 3EDF 2BF9 8A2D 2BB5 E60C -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] PDFlib error help --
Well an answer, even one I didn't want is better than no answer -- I only thought a band-aid might be around as the code did work at one time ... oh well, I guess I'm going to go learn more about PDFlib than I ever wanted to:( Thanks for the help. On Thu, Aug 22, 2002 at 07:53:13AM -0700, Rasmus Lerdorf wrote: There is no bandaid for this. Your code is simply wrong. You are calling a stroke function without having a path to stroke. You need to fix the code. -Rasmus On Thu, 22 Aug 2002, Hank Marquardt wrote: I've got an old, inherited codebase (18months) that generates PDFs -- just upgraded the server and libraries and php versions and now the PDF stuff is broken -- a quick scan of the archive and on google didn't this issue on there. The error I'm getting is: PDFlib error: function 'PDF_stroke' must not be called in 'page' scope I started to just comment out the offending line and see what happened, but it complains on every instance of function call throughout the scripts and a couple of supporting classes --- eww. I did notice a lot of calls to the deprecated API, but I'd really like to find a bandaid to put on this rather than rewrite the class library and all the scripts under time pressure -- Anyone else run into this? ... any pointers, faqs, etc. -- Hank Marquardt [EMAIL PROTECTED] GPG Id: 2BB5E60C Fingerprint: D807 61BC FD18 370A AC1D 3EDF 2BF9 8A2D 2BB5 E60C -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- Hank Marquardt [EMAIL PROTECTED] GPG Id: 2BB5E60C Fingerprint: D807 61BC FD18 370A AC1D 3EDF 2BF9 8A2D 2BB5 E60C -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] PDFlib --pixels?
Hello, I'm developing a web app, that needs to generate a PDF file. The background of the PDF will be a high resolution image (300dpi). and I calculate the scaling factor from the resolution of the image. $dpi_x =PDF_get_value($p,resx,$image); $dpi_y =PDF_get_value($p,resy,$image); /*calculate scaling factors from the dpi values */ if ($dpi_x 0 $dpi_y 0){ $scale_x =(72.0)/$dpi_x; $scale_y =(72.0)/$dpi_y; Now, I have the pixel coordenates of the text that will be written (I have the text, color, font, textX and textY). This coordenates were taken from the way it looked on a 72 dpi image. How can I get the cordenates that I sould use on the PDF??.. because if I use the same coord I have, it places the text wy out of where it's supposed to be. Please advice!. Oscar.-
[PHP] PDFlib --pixels? 2
Sorry, The code wasn't complete for the scaling thing. $dpi_x =PDF_get_value($p,resx,$image); $dpi_y =PDF_get_value($p,resy,$image); /*calculate scaling factors from the dpi values */ if ($dpi_x 0 $dpi_y 0){ $scale_x =(72.0)/$dpi_x; $scale_y =(72.0)/$dpi_y; } else if ($dpi_x 0 $dpi_y 0){ $scale_x = 1.0; $scale_y = $dpi_y / $dpi_x; } else { $scale_x =1.0; $scale_y =1.0; } PDF_begin_page($p,PDF_get_value($p,imagewidth,$image)*$scale_x, PDF_get_value($p,imageheight,$image)*$scale_y); PDF_scale($p,$scale_x,$scale_y); PDF_place_image($p,$image,0.0,0.0,1.0); PDF_close_image($p,$image); THANKS! :) Oscar.-
[PHP] pdflib, NEED HELP with function problem (newby)
Hello, Using php v 4.2.2 with pdflib support, on apache v. 1.3, and redhat linux 7.2. I for some reason can not get a pdf_setfont, pdf_set_text_pos, pdf_[anything], to work inside a function. What is going on. All the pdf extensions work find as long as I dont try to use them inside a function that I create. ie: PDF_set_text_pos($p, 80, 670); PDF_show($p, Requirements:); works just fine outside of a function but if I put the same thing inside a function like so function help() { PDF_set_text_pos($p, 80, 670); PDF_show($p, Test:); } I will not get Test text to display inside the PDF document, If I change this, so that I add a position to it, like so: function help($position_y) { PDF_set_text_pos($p, 80, $position_y); PDF_show($p, Test:); } I get this error: Warning: pdf_set_text_pos(): supplied argument is not a valid pdf object resource in /var/www/html/form/test.php on line 16 What am I doing wrong? Jeff -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] pdflib
Hello, can you tell me what i have to do to generate more than one pdf document with pdflib. At the moment i am not able to do this. the only thing i can do is actually to make one pdf. It is really important for me to bring more sites in one document. the problem is not solved if i just make more than one doc. thx Joey -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] PDFlib error - pdf_color or pdf_setrgbcolor
Hi, I'm trying to fill a rectangle with color in a php generated PDF document. I get the following error: *Fatal error*: PDFlib error: illegal state 0x in */usr/local/apache/htdocs/EDR/generate_edr.php* on line *144* I have tried both of the following on line 144: pdf_setcolor($pdf, both, gray, 1); pdf_setrgbcolor($pdf,1,1,0); If I comment out the line to set color the PDF document gets generated correctly. I can't find any reference* *to this error on mailing lists or documentation. I'm using PHP Version 4.1.1 and PDFlib 4.0.1. Does anyone have any ideas, thanks. Wayne Bastow -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] pdflib
This looks good, however when I try the examples I get: %PDF-1.3 3 0 obj endobj 4 0 obj stream 2.834646 0 0 2.834646 0 841.89 cm 2 J 0.2 w BT /F1 5.64 Tf ET BT 11 -16.692 Td (Hello World !) Tj ET endstream endobj 5 0 obj endobj 1 0 obj endobj 2 0 obj endobj 6 0 obj endobj 7 0 obj endobj xref 0 8 00 65535 f 000337 0 n 000424 0 n 09 0 n 87 0 n 000236 0 n 000512 0 n 000586 0 n trailer startxref 664 %%EOF Rather than acrobat being started. Any ideas? ben At 03:19 18/03/2002, Richard Baskett wrote: Or look into fpdf.org.. I have it dynamically generate my invoices every month :) Great class indeed! Rick When one door closes, another opens; but we often look so long and so regretfully upon the closed door that we do not see the one which has opened for us. - Alexander Graham Bell From: Ben Edwards [EMAIL PROTECTED] Date: Sun, 17 Mar 2002 20:03:55 + To: [EMAIL PROTECTED] Subject: [PHP] pdflib I have a html report and am looking into using phplib to generate a pdf instead. I have got it installed and started experimenting with it but ether it is extremely convoluted or I am missing something. How would I create a simple list report (the type you would do in a table). It seems all I can to is specify X/Y coordinates and print text. Don't know how many pages the report will be for a start. Ben * Ben Edwards +44 (0)117 9400 636 * * Critical Site Builderhttp://www.criticaldistribution.com * * online collaborative web authoring content management system * * i-Contact Progressive Video http://www.videonetwork.org * * Smashing the Corporate image http://www.subvertise.org * * Bristol Indymedia http://bristol.indymedia.org * * Bristol's radical news http://www.bristle.org.uk * * PGP : F0CA 42B8 D56F 28AD 169B 49F3 3056 C6DB 8538 EEF8 * -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php * Ben Edwards +44 (0)117 9400 636 * * Critical Site Builderhttp://www.criticaldistribution.com * * online collaborative web authoring content management system * * i-Contact Progressive Video http://www.videonetwork.org * * Smashing the Corporate image http://www.subvertise.org * * Bristol Indymedia http://bristol.indymedia.org * * Bristol's radical news http://www.bristle.org.uk * * PGP : F0CA 42B8 D56F 28AD 169B 49F3 3056 C6DB 8538 EEF8 * -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] pdflib
On Mon, 18 Mar 2002, Ben Edwards wrote: This looks good, however when I try the examples I get: %PDF-1.3 3 0 obj endobj 4 0 obj stream 2.834646 0 0 2.834646 0 841.89 cm 2 J 0.2 w BT /F1 5.64 Tf ET BT 11 -16.692 Td (Hello World !) Tj ET endstream endobj 5 0 obj endobj 1 0 obj endobj 2 0 obj endobj 6 0 obj endobj 7 0 obj endobj xref 0 8 00 65535 f 000337 0 n 000424 0 n 09 0 n 87 0 n 000236 0 n 000512 0 n 000586 0 n trailer startxref 664 %%EOF Rather than acrobat being started. Any ideas? header('Content-Type: application/pdf'); miguel -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] FPDF (was Re: [PHP] pdflib)
sorry, should of made it clear I amusing FPDF (http://fpdf.org/) library which looks like it douse the headers for you. Ben At 18:05 18/03/2002, [EMAIL PROTECTED] wrote: On Mon, 18 Mar 2002, Ben Edwards wrote: This looks good, however when I try the examples I get: %PDF-1.3 3 0 obj endobj 4 0 obj stream 2.834646 0 0 2.834646 0 841.89 cm 2 J 0.2 w BT /F1 5.64 Tf ET BT 11 -16.692 Td (Hello World !) Tj ET endstream endobj 5 0 obj endobj 1 0 obj endobj 2 0 obj endobj 6 0 obj endobj 7 0 obj endobj xref 0 8 00 65535 f 000337 0 n 000424 0 n 09 0 n 87 0 n 000236 0 n 000512 0 n 000586 0 n trailer startxref 664 %%EOF Rather than acrobat being started. Any ideas? header('Content-Type: application/pdf'); miguel * Ben Edwards +44 (0)117 9400 636 * * Critical Site Builderhttp://www.criticaldistribution.com * * online collaborative web authoring content management system * * i-Contact Progressive Video http://www.videonetwork.org * * Smashing the Corporate image http://www.subvertise.org * * Bristol Indymedia http://bristol.indymedia.org * * Bristol's radical news http://www.bristle.org.uk * * PGP : F0CA 42B8 D56F 28AD 169B 49F3 3056 C6DB 8538 EEF8 * -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] pdflib
I have a html report and am looking into using phplib to generate a pdf instead. I have got it installed and started experimenting with it but ether it is extremely convoluted or I am missing something. How would I create a simple list report (the type you would do in a table). It seems all I can to is specify X/Y coordinates and print text. Don't know how many pages the report will be for a start. Ben * Ben Edwards +44 (0)117 9400 636 * * Critical Site Builderhttp://www.criticaldistribution.com * * online collaborative web authoring content management system * * i-Contact Progressive Video http://www.videonetwork.org * * Smashing the Corporate image http://www.subvertise.org * * Bristol Indymedia http://bristol.indymedia.org * * Bristol's radical news http://www.bristle.org.uk * * PGP : F0CA 42B8 D56F 28AD 169B 49F3 3056 C6DB 8538 EEF8 * -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] pdflib
On Sun, 17 Mar 2002, Ben Edwards wrote: I have a html report and am looking into using phplib to generate a pdf instead. I have got it installed and started experimenting with it but ether it is extremely convoluted or I am missing something. How would I create a simple list report (the type you would do in a table). It seems all I can to is specify X/Y coordinates and print text. Don't know how many pages the report will be for a start. I haven't found it to be particularly easy. It works okay for simple things - our example being a web-based generator for simple office stationery like business cards and envelopes - but for serious text processing you should probably look into adding a few pieces to the process. You can easily generate, for instance, RTF from a database and then pipe it through any of several freely-available programs that will turn that into a PDF. This way you don't have to deal with painful details like page breaks, word wrapping and line lengths, etc. miguel -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] PDFLib
From http://www.pdflib.com/pdflib/faq.html: This demo stamp appears when one of our binaries distributed by PDFlib GmbH is used. It can be disabled by purchasing a PDFlib license, and applying the delivered license key (serial) at runtime with the PDF_set_parameter() function as indicated in the manual. With the ActiveX/COM edition of PDFlib the serial can also be supplied during the installation process. I have a license key, now what parameters do I pass PDF_set_parameter()? The PHP man doesn't say, nor does the PDFLib man (so far as I can tell). Any help would be greatly appreciated- I'm getting pretty frustrated. Thanks in advance, Evan Nemerson -- Employ your time in improving yourself by other men's writings, so that you shall gain easily what others have labored hard for. -Socrates -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] PDFLib
On Sunday 10 March 2002 16:29, Evan Nemerson wrote: From http://www.pdflib.com/pdflib/faq.html: This demo stamp appears when one of our binaries distributed by PDFlib GmbH is used. It can be disabled by purchasing a PDFlib license, and applying the delivered license key (serial) at runtime with the PDF_set_parameter() function as indicated in the manual. With the ActiveX/COM edition of PDFlib the serial can also be supplied during the installation process. I have a license key, now what parameters do I pass PDF_set_parameter()? The PHP man doesn't say, nor does the PDFLib man (so far as I can tell). Any help would be greatly appreciated- I'm getting pretty frustrated. Manual, chapter 3.1.1 The PDFlib Demo Stamp and Serial Numbers. PDF_set_parameter(p, serial, ...your serial string...); -- Jason Wong - Gremlins Associates - www.gremlins.com.hk /* One can't proceed from the informal to the formal by formal means. */ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP] pdflib
Hey, Has anyone successfully installed it with php 4.0.6 ? I have tried everything from re-compiling php to compiling pdflib from scratch.. but im totally lost.. any help would be great.. the pdflib site dint help much either.. :( Regards, Kunal Jhunjhunwala -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] pdflib
* Kunal Jhunjhunwala ([EMAIL PROTECTED]) [Dec 29. 2001 17:17]: Has anyone successfully installed it with php 4.0.6 ? I have tried everything from re-compiling php to compiling pdflib from scratch.. but im totally lost.. any help would be great.. What OS/distribution? A few months ago I installed 4.0.6 and pdflib on a SuSE server and it went just fine. http://www.pdflib.com/pdflib/download/index.html wget newest tarball. $ cd pdflib-x.x.x $ ./configure \ --with-jpeg-dir=/usr/local \ --with-png-dir=/usr/local \ --with-tiff-dir=/usr/local \ --with-zlib-dir=/usr $ make $ make test $ make install And in the PHP configure: --with-pdflib=/usr/local -- Brian Clark | Avoiding the general public since 1805! Fingerprint: 07CE FA37 8DF6 A109 8119 076B B5A2 E5FB E4D0 C7C8 Therein lies the major problem facing the world. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] pdflib
I am using red hat 7.2... Regards, Kunal Jhunjhunwala - Original Message - From: Brian Clark [EMAIL PROTECTED] To: PHP is not a drug. [EMAIL PROTECTED] Sent: Sunday, December 30, 2001 7:00 AM Subject: Re: [PHP] pdflib * Kunal Jhunjhunwala ([EMAIL PROTECTED]) [Dec 29. 2001 17:17]: Has anyone successfully installed it with php 4.0.6 ? I have tried everything from re-compiling php to compiling pdflib from scratch.. but im totally lost.. any help would be great.. What OS/distribution? A few months ago I installed 4.0.6 and pdflib on a SuSE server and it went just fine. http://www.pdflib.com/pdflib/download/index.html wget newest tarball. $ cd pdflib-x.x.x $ ./configure \ --with-jpeg-dir=/usr/local \ --with-png-dir=/usr/local \ --with-tiff-dir=/usr/local \ --with-zlib-dir=/usr $ make $ make test $ make install And in the PHP configure: --with-pdflib=/usr/local -- Brian Clark | Avoiding the general public since 1805! Fingerprint: 07CE FA37 8DF6 A109 8119 076B B5A2 E5FB E4D0 C7C8 Therein lies the major problem facing the world. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] pdflib
* Kunal Jhunjhunwala ([EMAIL PROTECTED]) [Dec 29. 2001 20:39]: I am using red hat 7.2... Then, what was the problem? IOW, how did you know it didn't work? (Sounds like I'm asking a stupid question, but you didn't say exactly what was happening. :-))) ) [...] * Kunal Jhunjhunwala ([EMAIL PROTECTED]) [Dec 29. 2001 17:17]: Has anyone successfully installed it with php 4.0.6 ? I have tried everything from re-compiling php to compiling pdflib from scratch.. but im totally lost.. any help would be great.. What OS/distribution? A few months ago I installed 4.0.6 and pdflib on a SuSE server and it went just fine. [...] -- Brian Clark | Avoiding the general public since 1805! Fingerprint: 07CE FA37 8DF6 A109 8119 076B B5A2 E5FB E4D0 C7C8 Fortune cookie: Outlook not so good, Microsoft ships anyway. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] pdflib
If I already have php compiled and running on my server, how can I add the pdfLib. Do I have to compile again? Thanks, rodney
[PHP] PDFLib - Builds Installs, but doesn't show up in phpinfo()
Hi all, I've been banging my head against the wall for a few days and have finally decided to consult the list. Here's what I'm trying to do and what is happening: Platform: Various version of RH Linux, primary 6.2 (on an i586), but when that failed (repeatedly) I started trying it on a 7.1 box (Athlon). Goal: Build libpdf support into PHP for dynamic pdf generation What is Happening: -libpdf appears to configure, build, and install properly (from source) -php is rebuilt and appears to configure, build, and install properly -the output of phpinfo() does _not_ list any information on libpdf and libpdf functions do not work What I've Been Doing: Aside from beating my head against the wall I have been configuring libpdf builds with the following: ./configure --enable-shared-pdflib --enable-php --enable-cxx The output at the end of the ./configure process indicates that shared library, C++, and PHP support (among others) has been enabled. pdflib then appears to build and install properly with 'make; make install' * Note, I have been blowing away the pdflib source directory and re-untaring each time I do a build. For PHP builds I have been configuring with the following: ./configure --with-apxs --with-pdflib=/usr/local/lib --with-mysql=/usr/local/mysql/lib/mysql --with-zlib=/usr/include --with-ttf=/usr/lib --with-jpeg-dir=/usr/lib --with-tiff-dir=/usr/lib Again, it appears to configure properly. I then build PHP with ./make and ./make install. When apache is restarted and the output of testinfo() is checked pdflib is _not_ listed and pdflib specific functions do _not_ work. The configure options shown above are listed in the Configure Command portion of the output. Any pointers or tips would be most appreciated. I would be happy to provide any additional information that might explain what I've done. Thanks, Ben -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] PDFLib to generate 2+ page with same content
Hi ! I have used the PDFLib to generate a pdf by myself. I would like to know how to make a page break and then draw second page which the content is exactly the first page. I need to repeat this step 9 times so I can use printer function to print 9-in-1 page. Thank you very much !! Regards, Norman -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] PDFLib to generate 2+ page with same content
I have used the PDFLib to generate a pdf by myself. I would like to know how to make a page break and then draw second page which the content is exactly the first page. I need to repeat this step 9 times so I can use printer function to print 9-in-1 page. Why not just put a loop around your code? ie. ? $pdf = pdf_new(); pdf_open_file($pdf); ... $i=0; while($i9) { pdf_begin_page($pdf, $x, $y); ... pdf_end_page($pdf); $i++; } pdf_close($pdf); $data = pdf_get_buffer($pdf); header('Content-type: application/pdf'); header(Content-disposition: inline; filename=foo.pdf); header(Content-length: . strlen($data)); echo $data ? -Rasmus -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] pdflib?
hello had everything working and fine. when i went back to the page today, nothing worked. i can (almost) bet my sack on that i haven't changed any code. Fatal error: PDFlib error: function 'PDF_set_info' must not be called in 'object' scope is the error i get. the code is $pdf = pdf_new(); pdf_set_info($pdf, Author, AuralQuest); pdf_set_info($pdf, Title, Invoice); pdf_set_info($pdf, Creator, AuralQuest); pdf_set_info($pdf, Subject, Invoice); pdf_set_parameter($pdf, warning, true); the error is on the highlighted line. if i comment out these lines, i get the same error on the line with pdf_begin_page($pdf, 595, 842); what have i missed? thanks in advance / d -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] pdflib?
You need a call to pdf_open_file($pdf) before you can start doing anything. -Rasmus On Wed, 5 Sep 2001, Daniel Andersson wrote: hello had everything working and fine. when i went back to the page today, nothing worked. i can (almost) bet my sack on that i haven't changed any code. Fatal error: PDFlib error: function 'PDF_set_info' must not be called in 'object' scope is the error i get. the code is $pdf = pdf_new(); pdf_set_info($pdf, Author, AuralQuest); pdf_set_info($pdf, Title, Invoice); pdf_set_info($pdf, Creator, AuralQuest); pdf_set_info($pdf, Subject, Invoice); pdf_set_parameter($pdf, warning, true); the error is on the highlighted line. if i comment out these lines, i get the same error on the line with pdf_begin_page($pdf, 595, 842); what have i missed? thanks in advance / d -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] pdflib?
a-ha. that works. wonder why it worked without it? oh well, it works now. thanks a million! / d Rasmus Lerdorf [EMAIL PROTECTED] wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... You need a call to pdf_open_file($pdf) before you can start doing anything. -Rasmus On Wed, 5 Sep 2001, Daniel Andersson wrote: hello had everything working and fine. when i went back to the page today, nothing worked. i can (almost) bet my sack on that i haven't changed any code. Fatal error: PDFlib error: function 'PDF_set_info' must not be called in 'object' scope is the error i get. the code is $pdf = pdf_new(); pdf_set_info($pdf, Author, AuralQuest); pdf_set_info($pdf, Title, Invoice); pdf_set_info($pdf, Creator, AuralQuest); pdf_set_info($pdf, Subject, Invoice); pdf_set_parameter($pdf, warning, true); the error is on the highlighted line. if i comment out these lines, i get the same error on the line with pdf_begin_page($pdf, 595, 842); what have i missed? thanks in advance / d -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
RE: [PHP] pdflib + pdf_findfont
I got the same error message, and couldn't figure out why... In the example for pdf_findfont(), it has: $font = pdf_findfont($pdf, Times New Roman, winansi, 1); Try changing your embed parameter to 0... $font = pdf_findfont($pdf, Times New Roman, winansi, 0); ... That fixed it for me. Give it a try. --Matt -Original Message- From: Adam Oliver [mailto:[EMAIL PROTECTED]] Sent: Wednesday, August 29, 2001 9:58 PM To: [EMAIL PROTECTED] Subject: [PHP] pdflib + pdf_findfont I can't get pdf_findfont to work in Linux. I keep getting a message that the font metrics are not found. It works fine in windows. Anybody have any ides what I need to have set? -- -- Adam Oliver http://www.meyedev.com/people/aoliver.htm [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] pdflib+pdi
Hi, we recently purchased the whole PDFlib+PDI package, however I've been having trouble installing it. Many of the different installation instructions i've found have told me contradictory things. I have tried using both the binary distribution aswell as the source. After many rounds of recompiling and testing different options I'm getting kinda beat. Can anyone please instruct me on how to get PDFlib and PDI working on my machine. I need it urgently for a project. What configure options, what tarballs and what files to copy between source directories. I'm using Redhat Linux 7.1 Any help is GREATLY appreciated. Sincerely Jonathan Svensson / Sweden -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] PDFlib beginners request
Hi. I have just started to play with PDFlib, but the manual and php.net notes are not, to my simple self, particularly digestible. Does anyone have any links to any tutorial pages or any handy hints they could point me to? Cheers Lee -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] PDFlib beginners request
In the comments on the php.net pages, i found a few, but i gave up on using pdf within php, because you had to pay about a thousand odd dollars just to use the thing, so be prepared to put some cash in to it :D - James ReDucTor Mitchell - Original Message - From: By Proxy [EMAIL PROTECTED] To: php general list [EMAIL PROTECTED] Sent: Tuesday, July 24, 2001 12:11 PM Subject: [PHP] PDFlib beginners request Hi. I have just started to play with PDFlib, but the manual and php.net notes are not, to my simple self, particularly digestible. Does anyone have any links to any tutorial pages or any handy hints they could point me to? Cheers Lee -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] PDFLib and php 4.0.5
After a great deal of swear words, preassure from my boss and numberous tries I now cry out for help. Can anyone compile a howto on installing pdflib so tha tit works with php 4.0.5 ? I've tried so many times and neither me or our sysadmin can manage to make php understand that I really need to get pdflib and php working together. It's not only giving me headache, it's a real pain. to compile everything else into or make php use is a like running a hot knife through butter but this really ticks me off. -- php developer / CoreTrek AS| transvestite, n.: Someone who likes to Sandnes / Rogaland / Norway| eat, drink, and be Mary. web: http://www.moijk.net/ | -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
RE: [PHP] PDFlib 4.0.0.... any experiences..
I just sent a post yesterday on how to get this to work. I does work well. Here is the post I sent yesterday: Try using the new pdflib-4.0.0 It works great. Here is what you have to do: Goto: http://www.pdflib.com/pdflib/download/index.html and download the source for unix. Unzip and untar. cd to pdflib-4.0.0/bind/php/ext/pdf copy * php-4.0.4pl1/ext/pdf --- You may want to remove the current contents of this directory first... cd pdflib-4.0.0 configure --enable-php make - you will get an error indicating that a makefile was not found ... just ignore it. make install Link the newly created libraries to the /usr/lib directory: ln -s /usr/local/lib/libpdf* /usr/lib Next just rebuild PHP as normal only add --with-pdflib. Have fun... Dean -Original Message- From: David Bouw [mailto:[EMAIL PROTECTED]] Sent: Thursday, April 19, 2001 6:08 PM To: [EMAIL PROTECTED] Subject: [PHP] PDFlib 4.0.0 any experiences.. Hi there, Months ago I had a bad time getting PDFlib 3.0.0 to compile with PHP.. After I succeeded I was so glad I promised myself to never touch it again.. :-) Well, I now have a barcode font which I need to embed into a PDF document.. I did this a long time ago, but have forgotten what the exact settings were that I used to accomplish this... With some searching I suddenly saw that PDFlib 4.0.0 was available.. !! When I looked at the documentation I got a tinteling feeling in my stomach.. Finally the package comes with all the Tif/Png etc libraries which you first had to download seperately and try to compile with PDFlib.. Further this package has also been adapted to PHP (they even talk about it in the manual!!!) and it seems that you can also load the pdf as some kind of library when starting the script via the 'dl' function.. ( which I don't yet have any experience with..) My question: Who has got some experience with this..? I grabbed a tarball of php-4.0.4pl1 and pdflib4.0.0.. Compiled both and tried to load the library via de dl option.. PHP can't seem to find this.. I am now busy to try and do it the old way and compile PHP with the PDFlib option enabled.. (did copy the /ext/pdf directory from pdflib to my php!) But if possible I would rather use the option in which the library is loaded into PHP as an library.. Speed isues aren't important, I want an easy and flexible way the change PDFlib versions without needing to recompile anything.. I also read that this was possible with the GD library.. I will be glad if I can hear anyone with some experiences with this new PDFlib.. I look forward getting this to work! Thanks in advance.. With kind regards David Bouw -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
RE: [PHP] PDFlib 4.0.0.... any experiences..
Dean, I too want to instal pdflib4, however I can't see a reference to pdflib4 on the web page you've given (unless my visions not working correctly of course). All the links are for pdflib3.3 Are they on this actual page or are they hidden somewhere. -Stewart -Original Message- From: Grimes, Dean [mailto:[EMAIL PROTECTED]] Sent: 20 April 2001 13:23 To: 'David Bouw'; [EMAIL PROTECTED] Subject: RE: [PHP] PDFlib 4.0.0 any experiences.. I just sent a post yesterday on how to get this to work. I does work well. Here is the post I sent yesterday: Try using the new pdflib-4.0.0 It works great. Here is what you have to do: Goto: http://www.pdflib.com/pdflib/download/index.html and download the source for unix. Unzip and untar. cd to pdflib-4.0.0/bind/php/ext/pdf copy * php-4.0.4pl1/ext/pdf --- You may want to remove the current contents of this directory first... cd pdflib-4.0.0 configure --enable-php make - you will get an error indicating that a makefile was not found ... just ignore it. make install Link the newly created libraries to the /usr/lib directory: ln -s /usr/local/lib/libpdf* /usr/lib Next just rebuild PHP as normal only add --with-pdflib. Have fun... Dean -Original Message- From: David Bouw [mailto:[EMAIL PROTECTED]] Sent: Thursday, April 19, 2001 6:08 PM To: [EMAIL PROTECTED] Subject: [PHP] PDFlib 4.0.0 any experiences.. Hi there, Months ago I had a bad time getting PDFlib 3.0.0 to compile with PHP.. After I succeeded I was so glad I promised myself to never touch it again.. :-) Well, I now have a barcode font which I need to embed into a PDF document.. I did this a long time ago, but have forgotten what the exact settings were that I used to accomplish this... With some searching I suddenly saw that PDFlib 4.0.0 was available.. !! When I looked at the documentation I got a tinteling feeling in my stomach.. Finally the package comes with all the Tif/Png etc libraries which you first had to download seperately and try to compile with PDFlib.. Further this package has also been adapted to PHP (they even talk about it in the manual!!!) and it seems that you can also load the pdf as some kind of library when starting the script via the 'dl' function.. ( which I don't yet have any experience with..) My question: Who has got some experience with this..? I grabbed a tarball of php-4.0.4pl1 and pdflib4.0.0.. Compiled both and tried to load the library via de dl option.. PHP can't seem to find this.. I am now busy to try and do it the old way and compile PHP with the PDFlib option enabled.. (did copy the /ext/pdf directory from pdflib to my php!) But if possible I would rather use the option in which the library is loaded into PHP as an library.. Speed isues aren't important, I want an easy and flexible way the change PDFlib versions without needing to recompile anything.. I also read that this was possible with the GD library.. I will be glad if I can hear anyone with some experiences with this new PDFlib.. I look forward getting this to work! Thanks in advance.. With kind regards David Bouw -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] PDFlib 4.0.0.... any experiences..
Hi Stewart, Try again my friend. I've just been there and version 4 is definately available. I won't ask why your vision is blury - you know what they say, hairy palms and all that! ;o) Thanks Dean for the info, I'll give it a whirl when I've got some free time. Best regards, - Paul - - Original Message - From: "Taylor, Stewart" [EMAIL PROTECTED] To: "'Grimes, Dean'" [EMAIL PROTECTED]; [EMAIL PROTECTED] Sent: Friday, April 20, 2001 1:39 PM Subject: RE: [PHP] PDFlib 4.0.0 any experiences.. Dean, I too want to instal pdflib4, however I can't see a reference to pdflib4 on the web page you've given (unless my visions not working correctly of course). All the links are for pdflib3.3 Are they on this actual page or are they hidden somewhere. -Stewart -Original Message- From: Grimes, Dean [mailto:[EMAIL PROTECTED]] Sent: 20 April 2001 13:23 To: 'David Bouw'; [EMAIL PROTECTED] Subject: RE: [PHP] PDFlib 4.0.0 any experiences.. I just sent a post yesterday on how to get this to work. I does work well. Here is the post I sent yesterday: Try using the new pdflib-4.0.0 It works great. Here is what you have to do: Goto: http://www.pdflib.com/pdflib/download/index.html and download the source for unix. Unzip and untar. cd to pdflib-4.0.0/bind/php/ext/pdf copy * php-4.0.4pl1/ext/pdf --- You may want to remove the current contents of this directory first... cd pdflib-4.0.0 configure --enable-php make - you will get an error indicating that a makefile was not found ... just ignore it. make install Link the newly created libraries to the /usr/lib directory: ln -s /usr/local/lib/libpdf* /usr/lib Next just rebuild PHP as normal only add --with-pdflib. Have fun... Dean -Original Message- From: David Bouw [mailto:[EMAIL PROTECTED]] Sent: Thursday, April 19, 2001 6:08 PM To: [EMAIL PROTECTED] Subject: [PHP] PDFlib 4.0.0 any experiences.. Hi there, Months ago I had a bad time getting PDFlib 3.0.0 to compile with PHP.. After I succeeded I was so glad I promised myself to never touch it again.. :-) Well, I now have a barcode font which I need to embed into a PDF document.. I did this a long time ago, but have forgotten what the exact settings were that I used to accomplish this... With some searching I suddenly saw that PDFlib 4.0.0 was available.. !! When I looked at the documentation I got a tinteling feeling in my stomach.. Finally the package comes with all the Tif/Png etc libraries which you first had to download seperately and try to compile with PDFlib.. Further this package has also been adapted to PHP (they even talk about it in the manual!!!) and it seems that you can also load the pdf as some kind of library when starting the script via the 'dl' function.. ( which I don't yet have any experience with..) My question: Who has got some experience with this..? I grabbed a tarball of php-4.0.4pl1 and pdflib4.0.0.. Compiled both and tried to load the library via de dl option.. PHP can't seem to find this.. I am now busy to try and do it the old way and compile PHP with the PDFlib option enabled.. (did copy the /ext/pdf directory from pdflib to my php!) But if possible I would rather use the option in which the library is loaded into PHP as an library.. Speed isues aren't important, I want an easy and flexible way the change PDFlib versions without needing to recompile anything.. I also read that this was possible with the GD library.. I will be glad if I can hear anyone with some experiences with this new PDFlib.. I look forward getting this to work! Thanks in advance.. With kind regards David Bouw -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED] -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] pdflib
Hello, how do I get a whole paragraph written in pdf using pdflib function PDF-show-xy? Or is there another function or method to manage this? I appreciate any hint. Thank you. Ali -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] PDFLib, PHP 4.0.4, Arrrrrrgh!
Ok this used to work but now I've done something to break it. My info.php says that I have PHP support: pdf PDF Support enabled PDFLib Version 3.03 CJK Font Support yes In-memory PDF Creation Support yes BUT when I try and run the clock test code, I get: Fatal error: Call to undefined function: pdf_new() in /home/httpd/pwn/htdocs/test/test.php on line 6 The first 6 lines of code are: ?php $radius = 200; $margin = 20; $pagecount = 10; $pdf = PDF_new(); It seems that PHP doesn't want to recognize any fo the PDF functions. Anybody got ANY idea what's wrong? TIA, Cal http://www.calevans.com -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] pdflib: unable to generate on the fly, need to write to file
On Thu, 25 Jan 2001 18:42:41 -0700 (MST), [EMAIL PROTECTED] wrote: I don't know, but I'd love to know the answer to this, too. I currently have to do the same as you: output to file and then direct the browser to the disk- based file. (Then I have to bother about file cleanup.) I had pdflib version 3.03 and found the patch that Uwe talked about and that fixed my problem with the creating pdfs out of memory. However, with IE, you will need to create it from file so you can get the document length so that IE displays the document appropriately. What I do to get around this is create the document in a tmp folder with the time stamp and then unlink the same file after I have appropriately fpassthru() the file to the browser with the appropriate headers for IE (Content-length). -- Dominic -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] PDFLib and PHP and pdf_open_image_file
Hello goood, (gg == "goood goood") [EMAIL PROTECTED] writes: gg I have an problem with PDFLib and PHP. I'm trying to include gg images in PDF file using pdf_open_image_file If in my source code gg is line: gg $o=pdf_open_image_file($pdf,"gif","pict.gif"); gg i get the error: Cannot find server or DNS Error (The page cannot gg be displayed). What's wrong. This sounds more like a server or browser problem to me. I don't think this has anything to do with the pdf* functions. -Brian -- You may be recognized soon. Hide. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] PDFLib and PHP and pdf_open_image_file
I have an problem with PDFLib and PHP. I'm trying to include images in PDF file using pdf_open_image_file If in my source code is line: $o=pdf_open_image_file($pdf,"gif","pict.gif"); i get the error: Cannot find server or DNS Error (The page cannot be displayed). What's wrong. _ Get Your Private, Free E-mail from MSN Hotmail at http://www.hotmail.com. -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
[PHP] PDFLIB 3.0 PHP 4.04
Has anyone gotten PHP 4.04 to compile with PDFLIB support? I have successfully compiled pdflib and all of it's supporting libs. (It runs the tests that come with it) But when I ./configure php, I use: ./configure --with-pdflib=/usr/local/lib And in the output of configure I see: ... checking whether to include Pdflib 3.x support... /usr/local/lib no ... I can't seem to figure out how to make it say YES! Any help would be greatly appreciated. Cal Cal http://www.calevans.com -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]
Re: [PHP] PDFLIB 3.0 PHP 4.04
On Mon, 15 Jan 2001, Cal Evans wrote: But when I ./configure php, I use: ./configure --with-pdflib=/usr/local/lib Leave the /lib part out..ie. use --with-pdflib=/usr/local instead. --Jani -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]