I am trying to parse certain excel sheets. I converted them to csv files to strip out any excess formatting. To parse these files, my system is dependant on new lines ("/n"). I use this code to get the data from the uploaded csv file:
The problem is that any of the new lines in the csv show up as single spaces in $data. I was wondering if there is a way to preserve the new lines in $data.
Code:
$data = file_get_contents($_FILES["file"]["tmp_name"], FILE_USE_INCLUDE_PATH);
Comment