Create a CSV File for a user in PHP

前端 未结 19 2052
故里飘歌
故里飘歌 2020-11-22 11:52

I have data in a MySQL database. I am sending the user a URL to get their data out as a CSV file.

I have the e-mailing of the link, MySQL query, etc. covered.

<
19条回答
  •  深忆病人
    2020-11-22 12:20

    Writing your own CSV code is probably a waste of your time, just use a package such as league/csv - it deals with all the difficult stuff for you, the documentation is good and it's very stable / reliable:

    http://csv.thephpleague.com/

    You'll need to be using composer. If you don't know what composer is I highly recommend you have a look: https://getcomposer.org/

提交回复
热议问题