I have a CSV text file which contains serval entries of "books", each book is on one line (separator: line break), and each column is separated by a tabulation.
I'm reading the content the file with :
$books = file( "/path/to/file/mycsv.txt" , FILE_SKIP_EMPTY_LINES );
That way I can go throuhg each element of the "books" array and read my individual "book" data.
The problem is that each book has a "description" column, which also contains line breaks. On import, this messes up the data, as it creates a line break before the end of an item.
How can I prevent that ?