I'm attempting to build a CSV parser in PHP. Unfortunately I'm unable to use fgetcsv so I'm building a custom function.
I have the contents of the csv held in a string, I'm attempting to explode the string on the new line character but I'm having difficulties with this.
$array_of_lines = explode(PHP_EOL,$csv_string);
This doesn't work, neither does exploding on "\n", could any suggest what character I might need to explode on?