TwistPHP Documentation

CSV

File path: dist/twist/Core/Helpers/CSV.helper.php
Namespace: Twist\Core\Helpers
Extends: Base

Type: Class

CSV — Simply Create, Serve and Import CSV files. Create a CSV file from and array of data, database query results can be directly exported as a CSV file with. Import CSV files into a usable indexed array of data.

Example Usage

<?php
//Set the variables for the example
$arrData = array(=> 'foo'=> 'bar');
$strDelimiter ';
$strEnclosure = '"';

//Call the function generateCSV with the example vars
Twist::CSV() -> generateCSV($arrData$strDelimiter$strEnclosure);

Method List

Method Access Returns
exportpublicvoid
servepublicvoid
generateCSVprotectedvoid
importpublicvoid