Forum Moderators: coopster

Message Too Old, No Replies

Creation of PDF's from mysql

         

arunmj82

4:00 pm on Mar 23, 2010 (gmt 0)

10+ Year Member



Hi,

My task is to extract the data's from mysql and to convert the same in to PDF. There are nearly 5000 records in mysql. Right now, using php I have dynamically created 5000 word documents. But after that I am manually opening each and every word document(MS WORD 2007) to set page number in header and adding contents to footer. Its time consuming. Is there any way to create PDF's on the fly?

Its urgent. Please help...

Regards,
Arun.

astupidname

8:53 am on Mar 24, 2010 (gmt 0)

10+ Year Member



php has a php_pdflib extension for generating .pdf files, but I think there is too much confusion about it... look in to FPDF (do search for it, is what you may want) or TCPDF instead.

lammert

11:07 am on Mar 25, 2010 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month



I use TCPDF to generate PDF files directly from PHP scripts. The only problem you may see is that when you want to generate a large PDF file, your script crashes due to memory limitations. It depends on the complexity of the pages and the number of pages, but experimenting with the PHP memory limit settings and possibly splitting the output in multiple PDF files may be necessary.