From e1f8eb13769b47a2c33b9a265225d248eb7c2b13 Mon Sep 17 00:00:00 2001 From: Daniel Seifert Date: Sat, 17 May 2025 22:23:35 +0200 Subject: [PATCH] fix development mode document type --- Application/Model/AbstractClasses/pdfdocumentsGeneric.php | 4 ++-- Application/views/admin/de/pdfdocuments_lang.php | 4 ++-- Application/views/admin/en/pdfdocuments_lang.php | 4 ++-- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/Application/Model/AbstractClasses/pdfdocumentsGeneric.php b/Application/Model/AbstractClasses/pdfdocumentsGeneric.php index 993ecb6..f560938 100644 --- a/Application/Model/AbstractClasses/pdfdocumentsGeneric.php +++ b/Application/Model/AbstractClasses/pdfdocumentsGeneric.php @@ -339,7 +339,7 @@ abstract class pdfdocumentsGeneric extends Base implements genericInterface */ public function outputDev(Html2Pdf $oPdf, $sFilename, $target, $html) { - $sFilename = str_replace('.pdf', '.html', $sFilename); + $sFilename = str_replace('.pdf', '.sgml', $sFilename); switch($target) { case 'I': { @@ -380,7 +380,7 @@ abstract class pdfdocumentsGeneric extends Base implements genericInterface header('Content-Type: application/force-download'); header('Content-Type: application/octet-stream', false); header('Content-Type: application/download', false); - header('Content-Type: text/html', false); + header('Content-Type: text/sgml', false); // use the Content-Disposition header to supply a recommended filename header('Content-Disposition: attachment; filename="'.basename($sFilename).'";'); header('Content-Transfer-Encoding: binary'); diff --git a/Application/views/admin/de/pdfdocuments_lang.php b/Application/views/admin/de/pdfdocuments_lang.php index ec60742..bba0c6f 100644 --- a/Application/views/admin/de/pdfdocuments_lang.php +++ b/Application/views/admin/de/pdfdocuments_lang.php @@ -19,8 +19,8 @@ $aLang = array( 'SHOP_MODULE_GROUP_d3PdfDocumentsmain' => 'Grundeinstellungen', 'SHOP_MODULE_d3PdfDocumentsbDev' => 'Entwicklermodus', - 'HELP_SHOP_MODULE_d3PdfDocumentsbDev' => 'Mit aktiviertem Entwicklermodus wird das Dokument im '. - 'HTML-Format ausgegeben. Inhaltliche Fehler können so besser nachvollzogen werden.', + 'HELP_SHOP_MODULE_d3PdfDocumentsbDev' => 'Mit aktiviertem Entwicklermodus kann das Dokument im '. + 'SGML-Format ausgegeben werden. Inhaltliche Fehler können so besser nachvollzogen werden.', 'SHOP_MODULE_d3PdfDocumentsbasicAuthUserName' => 'BasicAuth des Shops - Benutzername (optional)', 'HELP_SHOP_MODULE_d3PdfDocumentsbasicAuthUserName' => $basicAuthHelp, 'SHOP_MODULE_d3PdfDocumentsbasicAuthPassword' => 'BasicAuth des Shops - Passwort (optional)', diff --git a/Application/views/admin/en/pdfdocuments_lang.php b/Application/views/admin/en/pdfdocuments_lang.php index c5bc47a..df09af7 100644 --- a/Application/views/admin/en/pdfdocuments_lang.php +++ b/Application/views/admin/en/pdfdocuments_lang.php @@ -19,8 +19,8 @@ $aLang = array( 'SHOP_MODULE_GROUP_d3PdfDocumentsmain' => 'Basic settings', 'SHOP_MODULE_d3PdfDocumentsbDev' => 'Developer mode', - 'HELP_SHOP_MODULE_d3PdfDocumentsbDev' => 'If developer mode is activated, the document is output in '. - 'HTML format. This makes it much easier to trace content errors.', + 'HELP_SHOP_MODULE_d3PdfDocumentsbDev' => 'If developer mode is activated, the document can exported '. + 'in SGML format. This makes it much easier to trace content errors.', 'SHOP_MODULE_d3PdfDocumentsbasicAuthUserName' => 'BasicAuth of the shop - user name (optional)', 'HELP_SHOP_MODULE_d3PdfDocumentsbasicAuthUserName' => $basicAuthHelp, 'SHOP_MODULE_d3PdfDocumentsbasicAuthPassword' => 'BasicAuth of the shop - password (optional)',