summaryrefslogtreecommitdiffstats
path: root/examples/writing.php
diff options
context:
space:
mode:
Diffstat (limited to 'examples/writing.php')
-rwxr-xr-xexamples/writing.php1
1 files changed, 1 insertions, 0 deletions
diff --git a/examples/writing.php b/examples/writing.php
index 53b6ec7..557e74a 100755
--- a/examples/writing.php
+++ b/examples/writing.php
@@ -9,6 +9,7 @@ require '../vendor/autoload.php';
$writer = Writer::createFromFileObject(new SplTempFileObject()); //the CSV file will be created into a temporary File
$writer->setDelimiter("\t"); //the delimiter will be the tab character
+$writer->setLineEnding("\r\n"); //use windows line endings for compatibility with some csv libraries
$writer->setEncodingFrom("utf-8");
$headers = ["position" , "team", "played", "goals difference", "points"];