PHP_EOL is newline character in a cross-platform-compatible

PHP_EOL = cross-platform-compatible newline character

PHP_EOL is ostensibly used to find the newline character in a cross-platform-compatible way, so it handles DOS/Unix issues.

Note that PHP_EOL represents the endline character for the current system. For instance, it will not find a Windows endline when executed on a unix-like system.

Example (Save the $DataArray to $filename):

file_put_contents($filename, implode(PHP_EOL, $DataArray), LOCK_EX);
Reference:
Adam Bellaire (2008), https://stackoverflow.com/questions/128560/when-do-i-use-the-php-constant-php-eol