From b27fcf12a8cad1e6909efc122fd77ac2ab72a655 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Tue, 13 Sep 2011 21:59:44 +0000 Subject: [PATCH] New: Can export into Excel 2007 format --- htdocs/includes/modules/export/export_excel.modules.php | 2 +- htdocs/includes/modules/export/export_excel2007.modules.php | 2 +- htdocs/lib/files.lib.php | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/htdocs/includes/modules/export/export_excel.modules.php b/htdocs/includes/modules/export/export_excel.modules.php index 63864456f8b..b6061a245da 100644 --- a/htdocs/includes/modules/export/export_excel.modules.php +++ b/htdocs/includes/modules/export/export_excel.modules.php @@ -58,7 +58,7 @@ class ExportExcel extends ModeleExports $this->id='excel'; // Same value then xxx in file name export_xxx.modules.php $this->label='Excel 95'; // Label of driver - $this->desc='Excel file format (.xls)
This is native Excel 95 format (BIFF5).'; + $this->desc='Excel file format (.xls)
This is native Excel 95 format.'; $this->extension='xls'; // Extension for generated file by this driver $this->picto='mime/xls'; // Picto $this->version='1.30'; // Driver version diff --git a/htdocs/includes/modules/export/export_excel2007.modules.php b/htdocs/includes/modules/export/export_excel2007.modules.php index 8c381d02cd1..af826212d03 100755 --- a/htdocs/includes/modules/export/export_excel2007.modules.php +++ b/htdocs/includes/modules/export/export_excel2007.modules.php @@ -59,7 +59,7 @@ class ExportExcel2007 extends ExportExcel $this->id='excel2007'; // Same value then xxx in file name export_xxx.modules.php $this->label='Excel 2007'; // Label of driver - $this->desc='Excel file format (.xslx)
This is native Excel 2007 format (SpreadsheetML).'; + $this->desc='Excel file format (.xslx)
This is native Excel 2007 format.'; $this->extension='xslx'; // Extension for generated file by this driver $this->picto='mime/xls'; // Picto $this->version='1.30'; // Driver version diff --git a/htdocs/lib/files.lib.php b/htdocs/lib/files.lib.php index d94969be227..a369c1861fb 100644 --- a/htdocs/lib/files.lib.php +++ b/htdocs/lib/files.lib.php @@ -235,7 +235,7 @@ function dol_mimetype($file,$default='application/octet-stream',$mode=0) if (preg_match('/\.xls(b|m|x)?$/i',$tmpfile)) { $mime='application/vnd.ms-excel'; $imgmime='xls.png'; } if (preg_match('/\.xlt(x)?$/i',$tmpfile)) { $mime='application/vnd.ms-excel'; $imgmime='xls.png'; } if (preg_match('/\.xla(m)?$/i',$tmpfile)) { $mime='application/vnd.ms-excel'; $imgmime='xls.png'; } - if (preg_match('/\.xsl(b|m|x)?$/i',$tmpfile)) { $mime='application/vnd.openxmlformats-officedocument.spreadsheetml.sheet'; $imgmime='xls.png'; } + if (preg_match('/\.xsl(b|m|x)?$/i',$tmpfile)) { $mime='application/vnd.ms-excel'; $imgmime='xls.png'; } if (preg_match('/\.pps(m|x)?$/i',$tmpfile)) { $mime='application/vnd.ms-powerpoint'; $imgmime='ppt.png'; } if (preg_match('/\.ppt(m|x)?$/i',$tmpfile)) { $mime='application/x-mspowerpoint'; $imgmime='ppt.png'; } // Other