◆ __construct()
ilCSVReader::__construct |
( |
| ) |
|
◆ close()
Definition at line 98 of file class.ilCSVReader.php.
101 ini_set(
"auto_detect_line_endings", $this->line_ends);
103 return(@fclose($this->ptr_file));
◆ getDataArrayFromCSVFile()
ilCSVReader::getDataArrayFromCSVFile |
( |
| ) |
|
Get data as array from csv file.
public
- Returns
- array $this->data Data of file
Definition at line 113 of file class.ilCSVReader.php.
References $data, $row, data, and unquote().
117 while (($line = fgetcsv($this->ptr_file, $this->length, $this->separator)) !==
false) {
118 for ($col = 0; $col < count($line); $col++) {
◆ open()
ilCSVReader::open |
( |
|
$file = "" | ) |
|
Definition at line 89 of file class.ilCSVReader.php.
References ilUtil\stripSlashes().
92 $this->line_ends = ini_get(
"auto_detect_line_endings");
93 ini_set(
"auto_detect_line_endings",
true);
static stripSlashes($a_str, $a_strip_html=true, $a_allow="")
strip slashes if magic qoutes is enabled
◆ setDelimiter()
ilCSVReader::setDelimiter |
( |
|
$a_del | ) |
|
Set delimiter.
public
- Parameters
-
Definition at line 72 of file class.ilCSVReader.php.
74 $this->delimiter = $a_del;
◆ setLength()
ilCSVReader::setLength |
( |
|
$a_length | ) |
|
◆ setSeparator()
ilCSVReader::setSeparator |
( |
|
$a_sep | ) |
|
◆ unquote()
ilCSVReader::unquote |
( |
|
$a_str | ) |
|
|
private |
◆ $data
ilCSVReader::$data = array() |
|
private |
◆ $delimiter
ilCSVReader::$delimiter = '""' |
|
private |
◆ $length
ilCSVReader::$length = 1024 |
|
private |
◆ $ptr_file
ilCSVReader::$ptr_file = null |
|
private |
◆ $separator
ilCSVReader::$separator = ';' |
|
private |
The documentation for this class was generated from the following file: