From a5a71a3cb13ffc4e513df820309edfe7398038d9 Mon Sep 17 00:00:00 2001 From: Michael RICOIS Date: Fri, 2 Dec 2011 14:52:05 +0000 Subject: [PATCH] exportcsv --- includes/export/ExportCSV.php | 5 +++-- includes/recherche/recherchescsv.php | 2 +- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/includes/export/ExportCSV.php b/includes/export/ExportCSV.php index 2c317b69f..772e54662 100644 --- a/includes/export/ExportCSV.php +++ b/includes/export/ExportCSV.php @@ -20,9 +20,10 @@ class ExportCSV { $row = 0; foreach($this->data as $itemKey => $itemVal) - { + { foreach($this->enteteKey as $key){ - $this->list[$row][] = $itemVal[$key]; + $val = html_entity_decode($itemVal[$key]); + $this->list[$row][] = $val; } $row++; } diff --git a/includes/recherche/recherchescsv.php b/includes/recherche/recherchescsv.php index 2bde4f907..89d780fcb 100644 --- a/includes/recherche/recherchescsv.php +++ b/includes/recherche/recherchescsv.php @@ -141,6 +141,6 @@ if ($typeRech=='ent' && $siret<>'') { $etabs = $O['results']['reponses']; $export = new ExportCSV($etabs, 'rechercheEntreprise'); -$export->writeFile(PATH_SITE . '/cache/pages/marecherche.csv'); +$export->writeFile(PATH_SITE . '/cache/pages/rech-'.$_SESSION['login'].'.csv');