mirror of
https://github.com/owncloudarchive/contacts.git
synced 2024-12-04 15:24:35 +01:00
fix php 4.3
This commit is contained in:
parent
07217e0ec4
commit
73c35f43aa
@ -68,7 +68,8 @@ class ImportCsvConnector extends ImportConnector {
|
|||||||
$delimiter = (string)$this->configContent->import_core->delimiter;
|
$delimiter = (string)$this->configContent->import_core->delimiter;
|
||||||
} else {
|
} else {
|
||||||
// Look for the delimiter in the first line, should be the most present character between ',', ';' and '\t'
|
// Look for the delimiter in the first line, should be the most present character between ',', ';' and '\t'
|
||||||
$firstLine = (new SplFileObject($file))->fgets();
|
$splFile = new SplFileObject($file);
|
||||||
|
$firstLine = $splFile->fgets();
|
||||||
$nbComma = substr_count($firstLine, ',');
|
$nbComma = substr_count($firstLine, ',');
|
||||||
$nbSemicolon = substr_count($firstLine, ';');
|
$nbSemicolon = substr_count($firstLine, ';');
|
||||||
$nbTab = substr_count($firstLine, "\t");
|
$nbTab = substr_count($firstLine, "\t");
|
||||||
|
Loading…
Reference in New Issue
Block a user