2016-08-31 16:15:54 +00:00
|
|
|
<?php
|
|
|
|
|
|
|
|
require __DIR__ . '/Header.php';
|
|
|
|
|
|
|
|
// Use PCLZip rather than ZipArchive to read the Excel2007 OfficeOpenXML file
|
2016-08-31 17:18:12 +00:00
|
|
|
\PhpOffice\PhpSpreadsheet\Settings::setZipClass(\PhpOffice\PhpSpreadsheet\Settings::PCLZIP);
|
2016-08-31 16:15:54 +00:00
|
|
|
|
|
|
|
$filename = __DIR__ . '/templates/OOCalcTest.ods';
|
|
|
|
$callStartTime = microtime(true);
|
2016-08-31 17:18:12 +00:00
|
|
|
$spreadsheet = \PhpOffice\PhpSpreadsheet\IOFactory::load($filename);
|
2016-08-31 16:15:54 +00:00
|
|
|
$helper->logRead('OOCalc', $filename, $callStartTime);
|
|
|
|
|
|
|
|
// Save
|
|
|
|
$helper->write($spreadsheet, __FILE__);
|