PHPExcel export
S丶轩丶S
S丶轩丶S 2018-06-08 20:24:46
0
5
1215

This is the code written:

1528460667281356.jpg

The final result does not generate a table and download it, only garbled characters appear on the console. I don’t know the reason? Asking God for advice?

S丶轩丶S
S丶轩丶S

reply all (2)
力挽狂澜

Confirm whether the two libraries imported by the vendor are loaded. In addition, this process is encapsulated. Most scenarios are to export a two-dimensional associative array to excel. Logically speaking, the parameters only need a two-dimensional array [must] and some of your own custom parameters. config configuration array parameters [optional] There may be table title, author time, etc.

    无忌哥哥

    Let’s take a look at what specific error message the console reports.

    • reply It's a bunch of letters. You can't add pictures in the reply area. There are no pictures. It was originally a bunch of garbled characters. After I added ob_end_clean(), it turned into a bunch of letters. It should be encoding. These things always appear, but no substance is generated. Excel table. A bunch of letters look like this: 0M8R4KGxGuEAAAAAAAAAAAAAAAAAAAAAOwADAP7/CQAGAAAAAAAAAAAAAAAAABAAAABQAAAAAAAAAAEAAAAAAAAAEAAAD+////AAAAAAYAAAD////
      S丶轩丶S author 2018-06-09 09:14:24
    • reply There are two imported external files in this code. Are you sure the import was successful?
      无忌哥哥 author 2018-06-09 09:47:52
    • reply Yes, I always look for files according to the path, otherwise I will get the error that there is no PHPExcel.
      S丶轩丶S author 2018-06-09 10:03:10
    Latest Downloads
    More>
    Web Effects
    Website Source Code
    Website Materials
    Front End Template
    About us Disclaimer Sitemap
    php.cn:Public welfare online PHP training,Help PHP learners grow quickly!