Created
January 11, 2016 08:31
-
-
Save nucreativa/76c3fd053317a6828075 to your computer and use it in GitHub Desktop.
PHP - One line to parse a CSV file into an array
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$csv = array_map('str_getcsv', file('filename.csv')); | |
?> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment