registration form to two PDF files then send them to an emails

[亡魂溺海] 提交于 2019-12-13 09:37:19

问题


We have a website registration form, where the fields will need to be inserted into 2 PDF documents and then send those PDF documents via email to our customer service department, after reading blogs and watch videos, I can not find the best solution for our problem, how can we accomplish that using html, php in a windows hosting account?


回答1:


If you talk about real PDF forms you may check out the SetaPDF-FormFiller component (not free!). It allows you to fill in a PDF forms (AcroForm/XFA) in PHP. If it is a plain flat PDF document, you can use FPDI to import the pages into FPDF and write the dynamic content to the specific locations.

To send the resulting PDF I would suggest a common email class like swiftmailer.




回答2:


The fastest way is to store those pdf files with an unique id name, and just send the links to them in the mail. So you can do it with just the mail() function after build the pdf files. You can use a library as FPDF (www.fpdf.org) to create the files.

If you must put the pdf files inside the mail, you can do it with the phpmailer library.



来源:https://stackoverflow.com/questions/28722429/registration-form-to-two-pdf-files-then-send-them-to-an-emails

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