Fix PDF samples

This commit is contained in:
Adrien Crivelli
2017-03-24 19:46:19 +09:00
parent 4b75f7d469
commit 2e24a1e1b4
2 changed files with 2 additions and 2 deletions
+1 -1
View File
@@ -53,6 +53,6 @@ header('Content-Type: application/pdf');
header('Content-Disposition: attachment;filename="01simple.pdf"');
header('Cache-Control: max-age=0');
$writer = \PhpOffice\PhpSpreadsheet\IOFactory::createWriter($spreadsheet, 'PDF');
$writer = \PhpOffice\PhpSpreadsheet\IOFactory::createWriter($spreadsheet, 'Pdf');
$writer->save('php://output');
exit;
+1 -1
View File
@@ -91,7 +91,7 @@ foreach ($inputFileNames as $inputFileName) {
// Save
$filename = $helper->getFilename($inputFileName);
$writer = \PhpOffice\PhpSpreadsheet\IOFactory::createWriter($spreadsheet, 'PDF');
$writer = \PhpOffice\PhpSpreadsheet\IOFactory::createWriter($spreadsheet, 'Pdf');
$writer->setIncludeCharts(true);
$callStartTime = microtime(true);
$writer->save($filename);