Download the PHP package bentools/csviterator without Composer
On this page you can find all versions of the php package bentools/csviterator. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Table of contents
Download bentools/csviterator
More information about bentools/csviterator
Files in bentools/csviterator
Download bentools/csviterator
More information about bentools/csviterator
Files in bentools/csviterator
Vendor bentools
Package csviterator
Short Description An easy way to iterate over a CSV file
License MIT
Homepage https://github.com/bpolaszek/bentools-csviterator
Package csviterator
Short Description An easy way to iterate over a CSV file
License MIT
Homepage https://github.com/bpolaszek/bentools-csviterator
Please rate this library. Is it a good library?
Informations about the package csviterator
CSVIterator
An easy way to iterate over a CSV file. Consider the example "example.csv"
"FirstName";"LastName";"City"
"Bill";"Gates";"Seattle"
"Steve";"Jobs";"Palo Alto"
Example usage :
Outputs :
array (size=3)
0 => string 'FirstName' (length=9)
1 => string 'LastName' (length=8)
2 => string 'City' (length=4)
array (size=3)
0 => string 'Bill' (length=4)
1 => string 'Gates' (length=5)
2 => string 'Seattle' (length=7)
array (size=3)
0 => string 'Steve' (length=5)
1 => string 'Jobs' (length=4)
2 => string 'Palo Alto' (length=9)
CSVIteratorExtended
An extension to CSV Iterator taking the first row as keys.
Outputs :
array (size=3)
'FirstName' => string 'Bill' (length=4)
'LastName' => string 'Gates' (length=5)
'City' => string 'Seattle' (length=7)
array (size=3)
'FirstName' => string 'Steve' (length=5)
'LastName' => string 'Jobs' (length=4)
'City' => string 'Palo Alto' (length=9)
You can optionnally pass a callable as a 2nd argument to ensure you have php-friendly keys :
Outputs :
array (size=3)
'firstname' => string 'Bill' (length=4)
'lastname' => string 'Gates' (length=5)
'city' => string 'Seattle' (length=7)
array (size=3)
'firstname' => string 'Steve' (length=5)
'lastname' => string 'Jobs' (length=4)
'city' => string 'Palo Alto' (length=9)
Installation
Add the following line into your composer.json :
{
"require": {
"bentools/csviterator": "dev-master"
}
}
Enjoy.
All versions of csviterator with dependencies
PHP Build Version
Package Version
Requires
php Version
>=5.3
The package bentools/csviterator contains the following files
Loading the files please wait ....