How to generate pdf file from dynamic data coming from mysql database in php?

纵饮孤独 提交于 2019-12-18 13:47:36

问题


I am doing one web application society management system. In this application I want to generate pdf file for each user separately. Means during invoice generation , if there are 10 users then for each user separate invoice should get generated as a pdf after clicking on generate PDF button. My invoice got generated for each user but now I dont understand how to convert it into pdf dynamically. So please help me in this question ?


回答1:


Use any of the following php scripts to generate dynamic PDF documents

fpdf: http://www.fpdf.org/

tcpdf: http://www.tcpdf.org/




回答2:


You probably have to check out this lib: mPDF

It's quite easy to use and allows you to generate PDF from HTML templates.



来源:https://stackoverflow.com/questions/22349873/how-to-generate-pdf-file-from-dynamic-data-coming-from-mysql-database-in-php

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!