how to import CSV using zend

前端 未结 4 356
故里飘歌
故里飘歌 2021-02-04 09:36

How do I import CSV files using zend framework? Should I use zend_file_transfer or is there any special class that I have to look into? Also if I use zend_file_transfer is there

4条回答
  •  迷失自我
    2021-02-04 10:20

    There is currently no way to do this with the Zend Framework. How can one be sure?

    For example, Zend_Translate supports translation with CSV files, but if you check the the source code of the respective adapter (Zend_Translate_Adapter_Csv), you can verify it uses fgetcsv, and not a specific Zend class. Besides, this CSV adapter comes with the following warning:

    Note: Beware that the Csv Adapter has problems when your Csv files are encoded differently than the locale setting of your environment. This is due to a Bug of PHP itself which will not be fixed before PHP 6.0 (http://bugs.php.net/bug.php?id=38471). So you should be aware that the Csv Adapter due to PHP restrictions is not locale aware.

    which is related with the problems of the fgetcsv function.

提交回复
热议问题