Housekeeping
This commit is contained in:
parent
bff5339961
commit
52184bb67c
@ -144,8 +144,6 @@ END;
|
||||
$properties->setCreator('HACHE Membership Portal');
|
||||
$properties->setCompany('HACHE');
|
||||
$properties->setTitle('HACHE Member Directory');
|
||||
$paperSize = new \PhpOffice\PhpWord\Style\Paper();
|
||||
$paperSize->setSize("Letter");
|
||||
|
||||
$phpWord->addTitleStyle(1, ['bold' => true, 'size' => 24, 'alignment' => \PhpOffice\PhpWord\SimpleType\Jc::CENTER]);
|
||||
$phpWord->addTitleStyle(2, ['bold' => true, 'size' => 16]);
|
||||
@ -210,6 +208,9 @@ END;
|
||||
break;
|
||||
case "odt":
|
||||
default:
|
||||
// Paper size is stuck at A4 and margins don't work.
|
||||
// See https://github.com/PHPOffice/PHPWord/issues/1531
|
||||
// Hopefully they'll get this fixed.
|
||||
$objWriter = \PhpOffice\PhpWord\IOFactory::createWriter($phpWord, 'ODText');
|
||||
header("Content-Type: application/vnd.oasis.opendocument.text");
|
||||
header("Content-disposition: attachment; filename=\"HACHE_Directory_" . date("Y-m-d") . ".odt\"");
|
||||
|
Loading…
x
Reference in New Issue
Block a user