diff options
-rw-r--r-- | LICENSE | 2 | ||||
-rw-r--r-- | composer.json | 2 | ||||
-rwxr-xr-x | examples/bom.php | 2 | ||||
-rw-r--r-- | src/AbstractCsv.php | 2 | ||||
-rw-r--r-- | src/Config/Controls.php | 2 | ||||
-rw-r--r-- | src/Config/Output.php | 13 | ||||
-rw-r--r-- | src/Config/StreamFilter.php | 2 | ||||
-rw-r--r-- | src/Iterator/MapIterator.php | 2 | ||||
-rw-r--r-- | src/Iterator/Query.php | 2 | ||||
-rw-r--r-- | src/Reader.php | 2 | ||||
-rw-r--r-- | src/Writer.php | 2 |
11 files changed, 16 insertions, 17 deletions
@@ -1,6 +1,6 @@ The MIT License (MIT) -Copyright (c) 2013-2014 ignace nyamagana butera +Copyright (c) 2013-2015 ignace nyamagana butera Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in diff --git a/composer.json b/composer.json index 54c1735..f2d26e1 100644 --- a/composer.json +++ b/composer.json @@ -36,7 +36,7 @@ }, "extra": { "branch-alias": { - "dev-master": "6.2-dev" + "dev-master": "6.3-dev" } } } diff --git a/examples/bom.php b/examples/bom.php index 8414542..38f1230 100755 --- a/examples/bom.php +++ b/examples/bom.php @@ -12,6 +12,6 @@ require '../vendor/autoload.php'; stream_filter_register(FilterTranscode::FILTER_NAME."*", "\lib\FilterTranscode"); $csv = Reader::createFromPath(__DIR__.'/data/prenoms.csv'); -$csv->setBOMOnOutput(Reader::BOM_UTF16_LE); +$csv->setOutputBOM(Reader::BOM_UTF16_LE); $csv->appendStreamFilter(FilterTranscode::FILTER_NAME."UTF-8:UTF-16LE"); $csv->output('test.csv'); diff --git a/src/AbstractCsv.php b/src/AbstractCsv.php index 509f414..74a13ec 100644 --- a/src/AbstractCsv.php +++ b/src/AbstractCsv.php @@ -4,7 +4,7 @@ * * @license http://opensource.org/licenses/MIT * @link https://github.com/thephpleague/csv/ -* @version 6.2.0 +* @version 6.3.0 * @package League.csv * * For the full copyright and license information, please view the LICENSE diff --git a/src/Config/Controls.php b/src/Config/Controls.php index 1601e88..6479d88 100644 --- a/src/Config/Controls.php +++ b/src/Config/Controls.php @@ -4,7 +4,7 @@ * * @license http://opensource.org/licenses/MIT * @link https://github.com/thephpleague/csv/ -* @version 6.2.0 +* @version 6.3.0 * @package League.csv * * For the full copyright and license information, please view the LICENSE diff --git a/src/Config/Output.php b/src/Config/Output.php index f4eb104..4540be0 100644 --- a/src/Config/Output.php +++ b/src/Config/Output.php @@ -4,7 +4,7 @@ * * @license http://opensource.org/licenses/MIT * @link https://github.com/thephpleague/csv/ -* @version 6.2.0 +* @version 6.3.0 * @package League.csv * * For the full copyright and license information, please view the LICENSE @@ -125,12 +125,11 @@ trait Output $iterator = $this->getIterator(); //@codeCoverageIgnoreStart if (! is_null($filename) && self::isValidString($filename)) { - $fname = (string) $filename; - $fname = trim($fname); - $fname = filter_var($fname, FILTER_UNSAFE_RAW, ['flags' => FILTER_FLAG_STRIP_LOW]); - header('Content-Type: application/octet-stream'); - header('Content-Transfer-Encoding: binary'); - header("Content-Disposition: attachment; filename=\"$fname\"; filename*=UTF-8 ".rawurlencode($fname)); + $filename = trim($filename); + $filename = filter_var($filename, FILTER_SANITIZE_ENCODED, FILTER_FLAG_STRIP_LOW); + header("Content-Type: application/octet-stream"); + header("Content-Transfer-Encoding: binary"); + header("Content-Disposition: attachment; filename=\"$filename\"; filename*=UTF-8 $filename"); } //@codeCoverageIgnoreEnd echo $this->bom; diff --git a/src/Config/StreamFilter.php b/src/Config/StreamFilter.php index 23d28ad..330f62d 100644 --- a/src/Config/StreamFilter.php +++ b/src/Config/StreamFilter.php @@ -4,7 +4,7 @@ * * @license http://opensource.org/licenses/MIT * @link https://github.com/thephpleague/csv/ -* @version 6.2.0 +* @version 6.3.0 * @package League.csv * * For the full copyright and license information, please view the LICENSE diff --git a/src/Iterator/MapIterator.php b/src/Iterator/MapIterator.php index e6b0816..f1123c7 100644 --- a/src/Iterator/MapIterator.php +++ b/src/Iterator/MapIterator.php @@ -4,7 +4,7 @@ * * @license http://opensource.org/licenses/MIT * @link https://github.com/thephpleague/csv/ -* @version 6.2.0 +* @version 6.3.0 * @package League.csv * * For the full copyright and license information, please view the LICENSE diff --git a/src/Iterator/Query.php b/src/Iterator/Query.php index b338252..f732af7 100644 --- a/src/Iterator/Query.php +++ b/src/Iterator/Query.php @@ -4,7 +4,7 @@ * * @license http://opensource.org/licenses/MIT * @link https://github.com/thephpleague/csv/ -* @version 6.2.0 +* @version 6.3.0 * @package League.csv * * For the full copyright and license information, please view the LICENSE diff --git a/src/Reader.php b/src/Reader.php index 00a368d..080cc79 100644 --- a/src/Reader.php +++ b/src/Reader.php @@ -4,7 +4,7 @@ * * @license http://opensource.org/licenses/MIT * @link https://github.com/thephpleague/csv/ -* @version 6.2.0 +* @version 6.3.0 * @package League.csv * * For the full copyright and license information, please view the LICENSE diff --git a/src/Writer.php b/src/Writer.php index f022b85..e6ee9d0 100644 --- a/src/Writer.php +++ b/src/Writer.php @@ -4,7 +4,7 @@ * * @license http://opensource.org/licenses/MIT * @link https://github.com/thephpleague/csv/ -* @version 6.2.0 +* @version 6.3.0 * @package League.csv * * For the full copyright and license information, please view the LICENSE |