So, I have two servers (one with Windows OS, and another with Linux), then I have one and the same code which does exactly the same procedure over the same variable with the exact same value. However, on Linux machine this works:
$var = str_replace(PHP_EOL,'', $var);
but on the Windows machine it does not. I expect this code to remove all new blank lines (\n\r
or \r\n
- I don't remeber the order, but I guess you understand what I mean). So, what I'm doing wrong and how can I fix it?