replace \r\n with PHP_EOL