From f6dfcb756c794a7b440ec43b5d87a142e167db77 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Tue, 14 May 2013 23:54:22 +0200 Subject: [PATCH] Text cells must be left align into excel 2007 export. --- htdocs/core/modules/export/export_excel2007.modules.php | 1 + 1 file changed, 1 insertion(+) diff --git a/htdocs/core/modules/export/export_excel2007.modules.php b/htdocs/core/modules/export/export_excel2007.modules.php index 609bbc2d660..65fefd0d39a 100755 --- a/htdocs/core/modules/export/export_excel2007.modules.php +++ b/htdocs/core/modules/export/export_excel2007.modules.php @@ -351,6 +351,7 @@ class ExportExcel2007 extends ExportExcel $this->workbook->getActiveSheet()->SetCellValueByColumnAndRow($this->col, $this->row+1, (string) $newvalue); $coord=$this->workbook->getActiveSheet()->getCellByColumnAndRow($this->col, $this->row+1)->getCoordinate(); $this->workbook->getActiveSheet()->getStyle($coord)->getNumberFormat()->setFormatCode('@'); + $this->workbook->getActiveSheet()->getStyle($coord)->getAlignment()->setHorizontal(PHPExcel_Style_Alignment::HORIZONTAL_LEFT); } else {