dokeos-library
[ class tree: dokeos-library ] [ index: dokeos-library ] [ all elements ]

Class: Import

Source Location: /main/inc/lib/import.lib.php

Class Overview


This class provides some functions which can be used when importing data from


Author(s):

Methods



Class Details

[line 31]
This class provides some functions which can be used when importing data from

external files into Dokeos




Tags:

filesource:  Source Code for this file


[ Top ]


Class Methods


method csv_to_array [line 49]

array csv_to_array( string $filename)

Reads a CSV-file into an array. The first line of the CSV-file should contain the array-keys.

Example: FirstName;LastName;Email John;Doe;john.doe@mail.com Adam;Adams;adam@mail.com returns $result [0]['FirstName'] = 'John'; $result [0]['LastName'] = 'Doe'; $result [0]['Email'] = 'john.doe@mail. com'; $result [1]['FirstName'] = 'Adam'; ...




Tags:

return:  An array with all data from the CSV-file


Parameters:

string   $filename   Path to the CSV-file which should be imported

[ Top ]


Documentation generated on Thu, 12 Jun 2008 13:47:10 -0500 by phpDocumentor 1.4.1