I have a page with dynamic content and would like the user who creates the report to send the result as an email attachment (pdf & excel). How would be the best way to do this ?

Thanks

有帮助吗?

解决方案

  • For email: PHPMailer()
  • For excel: PHPExcel()
  • For PDF: domPDF or prince

Just use google to find each of these. This is a pretty complicating process, but if you do it step by step then you should be able to figure it out. Prince is not free, but looks much better than domPDF.

  1. Create excel version of report on server.
  2. Create PDF version of report on server.
  3. Email both files with reports attached.
  4. Delete files from the server.
许可以下: CC-BY-SA归因
不隶属于 StackOverflow
scroll top