|
@@ 359-362 (lines=4) @@
|
| 356 |
|
if (file_exists($dbf_name)) { |
| 357 |
|
unlink($dbf_name); |
| 358 |
|
} |
| 359 |
|
if (!($this->DBFFile = @dbase_create($dbf_name, $this->DBFHeader))) { |
| 360 |
|
$this->setError(sprintf('It wasn\'t possible to create the DBase file "%s"', $dbf_name)); |
| 361 |
|
return false; |
| 362 |
|
} |
| 363 |
|
|
| 364 |
|
$offset = 50; |
| 365 |
|
if (is_array($this->records) && (count($this->records) > 0)) { |
|
@@ 432-435 (lines=4) @@
|
| 429 |
|
$dbf_name = $this->_getFilename('.dbf'); |
| 430 |
|
$checkFunction = $toWrite ? 'is_writable' : 'is_readable'; |
| 431 |
|
if (($toWrite) && (!file_exists($dbf_name))) { |
| 432 |
|
if (!@dbase_create($dbf_name, $this->DBFHeader)) { |
| 433 |
|
$this->setError(sprintf('It wasn\'t possible to create the DBase file "%s"', $dbf_name)); |
| 434 |
|
return false; |
| 435 |
|
} |
| 436 |
|
} |
| 437 |
|
if ($checkFunction($dbf_name)) { |
| 438 |
|
$this->DBFFile = @dbase_open($dbf_name, ($toWrite ? 2 : 0)); |