22 Commits

Author SHA1 Message Date
agolovenkin
f9aa61d6f3
Merge 956056511a13683bbbb2531e557d42c0e9bee5ce into dbdf5f7f386118ab4ef9341924e8463c9bc3f47c 2019-10-28 01:18:31 +01:00
Adrien Loison
2716d7eeed [PHP 7.4] Updated way to disable the fgetcsv/fputcsv escape character
From PHP 7.4, the recommended way to disable the escape character for fgetcsv() and fputcsv() is an empty string, instead of "\0".
Discussed here: https://github.com/php/php-src/pull/3515
2019-07-21 23:15:34 +02:00
Alexander Golovenkin
956056511a Fix coding style 2019-01-16 05:49:54 -08:00
Alexander Golovenkin
abddc0b48f XLSX performance 2019-01-16 05:12:58 -08:00
Adrien Loison
c826d15472 Fix charachters escaping with CSV reader/writer
PHP's built-in functions fputcsv and fgetcsv are not RFC-4180 compliant and include an escape character that's not defined in the spec.
This results in escaping characters that should not be escaped.
This commit disables this escaping mechanism.
2017-11-11 16:21:05 +01:00
Adrien Loison
b968513cb9 Fix code style 2017-09-06 00:33:43 +02:00
Adrien Loison
740fcfb8c1 Fix code before applying PHP CS Fixer 2017-09-06 00:33:43 +02:00
Adrien Loison
77178122c3 Fix output file deletion after exception thrown on write (#328)
For relative paths, it would not work as the FileSystemHelper would not allow deleting a file that's not part of its base folder.
2016-10-12 11:15:07 -07:00
Adrien Loison
23f8cc4f05 Temp files should be deleted when an exception is thrown (#327)
If an exception is thrown while writing data, instead of letting the developer handle this situation gracefully, Spout can attempt to delete all the temporary files that were created so far, as well as the output file as it won't be completed and therefore corrupted.
2016-10-11 15:08:37 -07:00
madflow
a43c13a36f Fix #252 (#253) 2016-06-14 10:02:01 -07:00
Adrien Loison
8edd8e2401 Clear previous output when openToBrowser() called (#243)
If any character has been outputted before, the generated file will be corrupted.
2016-06-08 13:53:41 -07:00
skeleton
d6e8fe4b54 Fix line breaks on CSV reader 2016-03-23 23:26:49 +01:00
Adrien Loison
d2ac54c578 Custom stream wrapper support
Added support for custom stream wrappers, such as "fly" or "s3".
Support is determined per reader.
2016-03-18 17:09:13 -07:00
Adrien Loison
01cc8b3da0 Fix "Cannot open file" issue with XMLReader::open on Windows
This occurred when using relative paths. Using realpath() solves this issue.
2015-10-15 09:19:47 -07:00
Adrien Loison
8a3b895afc Fix CSV reader when last line is empty
If the last line was empty, it would create an infinite loop...
2015-07-29 10:17:51 -07:00
Adrien Loison
5e1cfbfdbd Attempt to convert the non UTF-8 strings to UTF-8 2015-07-27 20:59:12 -07:00
Adrien Loison
37d87a8a27 Fix various problems 2015-07-27 00:23:18 -07:00
Adrien Loison
2dcb86aae9 Move shared strings caching strategy into its own component
This will help implementing different caching strategies:
- file based
- in-memory
2015-07-11 14:12:18 -07:00
Adrien Loison
3b4dfba38e Improve code coverage 2015-04-29 11:39:21 -07:00
Adrien Loison
e9ec4e745c Expose a Sheet object on Reader::XLSX::nextSheet()
Added Sheet class for the XLSX reader that exposes basic sheet info, such as name or ID.
When retrieving the sheet data XML, added extra XML parsing to retrieve sheet data.
Added test
2015-04-29 00:27:45 -07:00
Adrien Loison
3f3461b002 Add and improve test coverage 2015-04-16 14:51:48 -07:00
Adrien Loison
5e199009e6 First external release 2015-01-15 18:14:07 -08:00