diff options
Diffstat (limited to 'src')
-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 |
8 files changed, 13 insertions, 14 deletions
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 |