MySQL to Excel generation using PHP

后端 未结 7 1061
遇见更好的自我
遇见更好的自我 2021-01-06 22:00


        
相关标签:
7条回答
  • 2021-01-06 22:38

    Modify the code to use pure CSV, and then return the file to the browser as a filename ending in .csv and content type text/csv.

    I have seen people try to do this before, and it only works with certain specific versions of Office Excel. It does not work on other platforms with other spreadsheet programs or with every version of Excel. Use a standard file format, or at least generate a proper OLE2 Compound Document file that contains XLS data in the manner which Excel expects if you're going to send the file to the browser as that file type.

    0 讨论(0)
提交回复
热议问题