207 |
aurelien |
1 |
<?php
|
|
|
2 |
|
|
|
3 |
class OdsExport extends OdsTriple {
|
|
|
4 |
|
|
|
5 |
const PREFIXE = 'get';
|
|
|
6 |
const ABBR_LISTE_EVENEMENTS = 'evenement';
|
|
|
7 |
const ABBR_LISTE_ESPECES = 'espece';
|
249 |
aurelien |
8 |
const ABBR_LISTE_MILIEUX = 'environnement';
|
|
|
9 |
|
246 |
aurelien |
10 |
private $type_mime = 'text/html';
|
|
|
11 |
|
207 |
aurelien |
12 |
/**
|
|
|
13 |
* Méthodes d'extractions d'informations
|
|
|
14 |
*/
|
|
|
15 |
|
|
|
16 |
/**
|
|
|
17 |
* Méthode appelée avec une requête de type GET.
|
|
|
18 |
*
|
|
|
19 |
*/
|
|
|
20 |
function getElement($param = array()) {
|
|
|
21 |
|
|
|
22 |
$type = $param[0];
|
|
|
23 |
|
|
|
24 |
if ($type == '*' || is_numeric($type)) {
|
|
|
25 |
$info = $this->getElementParDefaut($param);
|
|
|
26 |
} else {
|
|
|
27 |
$methode = self::PREFIXE.$type;
|
|
|
28 |
if (method_exists($this, $methode)) {
|
|
|
29 |
array_shift($param);
|
|
|
30 |
$info = $this->$methode($param);
|
|
|
31 |
} else {
|
|
|
32 |
$this->messages[] = "Le type d'information demandé '$type' n'est pas disponible.";
|
|
|
33 |
}
|
|
|
34 |
}
|
249 |
aurelien |
35 |
|
270 |
aurelien |
36 |
$this->envoyer($info,$this->type_mime);
|
207 |
aurelien |
37 |
}
|
270 |
aurelien |
38 |
|
|
|
39 |
public function getExportStationJson() {
|
|
|
40 |
|
|
|
41 |
$donnees = $this->getExportStation();
|
|
|
42 |
$donnees_formatees = $this->formaterListeStationPourExportJson($donnees);
|
|
|
43 |
|
|
|
44 |
$this->type_mime = 'application/json';
|
|
|
45 |
|
|
|
46 |
return $donnees_formatees;
|
|
|
47 |
}
|
|
|
48 |
|
|
|
49 |
public function getExportStation($start = null,$limit = null, $order_by = 'oo_date') {
|
|
|
50 |
|
|
|
51 |
$requete_selection_stations = 'SELECT * FROM ods_stations ';
|
|
|
52 |
$res_selection_stations = $this->executerRequete($requete_selection_stations);
|
|
|
53 |
|
|
|
54 |
return $res_selection_stations;
|
|
|
55 |
}
|
|
|
56 |
|
|
|
57 |
public function formaterListeStationPourExportJson($tableau_stations_infos) {
|
|
|
58 |
|
|
|
59 |
$gestionnaire_especes = new OdsEspece($this->config);
|
|
|
60 |
$gestionnaire_communes = new OdsCommune($this->config);
|
|
|
61 |
$gestionnaire_utilisateurs = new OdsUtilisateur($this->config);
|
|
|
62 |
|
|
|
63 |
$especes = $gestionnaire_especes->getToutesEspeces();
|
|
|
64 |
$evenements = $this->obtenirValeursListeParAbreviation(self::ABBR_LISTE_EVENEMENTS);
|
|
|
65 |
$milieux = $this->obtenirValeursListeParAbreviation(self::ABBR_LISTE_MILIEUX);
|
|
|
66 |
$utilisateurs = $gestionnaire_utilisateurs->getListeUtilisateurAvecInfosComplementairesFormateeId();
|
|
|
67 |
$communes = $gestionnaire_communes->obtenirCommunesLieesAStationIndexeesCodeInsee();
|
|
|
68 |
|
|
|
69 |
$resultats_formates = array();
|
|
|
70 |
$stats = array('total' => count($tableau_stations_infos));
|
|
|
71 |
|
|
|
72 |
foreach($tableau_stations_infos as $stations_infos) {
|
|
|
73 |
$commune = isset($communes[$stations_infos['os_ce_commune']]['oc_nom']) ? $communes[$stations_infos['os_ce_commune']]['oc_nom'] : '';
|
|
|
74 |
|
|
|
75 |
$id_station = $stations_infos['os_id_station'];
|
|
|
76 |
$resultats_formates[$id_station]['nom'] = $stations_infos['os_nom'];
|
|
|
77 |
$resultats_formates[$id_station]['code_commune'] = is_numeric($stations_infos['os_ce_commune']) ? substr($stations_infos['os_ce_commune'], 0, 2) : '';
|
|
|
78 |
$resultats_formates[$id_station]['nom_commune'] = $commune;
|
|
|
79 |
$resultats_formates[$id_station]['latitude'] = $stations_infos['os_latitude'];
|
|
|
80 |
$resultats_formates[$id_station]['longitude'] = $stations_infos['os_longitude'];
|
|
|
81 |
$resultats_formates[$id_station]['altitude'] = $stations_infos['os_altitude'];
|
|
|
82 |
$resultats_formates[$id_station]['type_participant'] = 'Particulier';
|
|
|
83 |
|
|
|
84 |
if(isset($utilisateurs[$stations_infos['os_ce_participant']])) {
|
|
|
85 |
$participant = $utilisateurs[$stations_infos['os_ce_participant']];
|
|
|
86 |
$resultats_formates[$id_station]['participant']['id'] = $participant['uid'];
|
|
|
87 |
$resultats_formates[$id_station]['participant']['nom'] = $participant['name'];
|
|
|
88 |
$resultats_formates[$id_station]['type_participant'] = isset($participant['profile_type']) ? $participant['profile_type'] : 'Particulier';
|
|
|
89 |
} else {
|
|
|
90 |
$resultats_formates[$id_station]['participant']['id'] = null;
|
|
|
91 |
$resultats_formates[$id_station]['participant']['nom'] = 'Anonyme';
|
|
|
92 |
$resultats_formates[$id_station]['type_participant'] = 'Particulier';
|
|
|
93 |
}
|
|
|
94 |
if(isset($stats[$resultats_formates[$id_station]['type_participant']])) {
|
|
|
95 |
$stats[$resultats_formates[$id_station]['type_participant']]++;
|
|
|
96 |
} else {
|
|
|
97 |
$stats[$resultats_formates[$id_station]['type_participant']] = 1;
|
|
|
98 |
}
|
|
|
99 |
}
|
|
|
100 |
$resultat = array('stats' => $stats, 'stations' => $resultats_formates);
|
|
|
101 |
|
|
|
102 |
return $resultat;
|
|
|
103 |
}
|
249 |
aurelien |
104 |
|
207 |
aurelien |
105 |
public function getExportObservation($start = null,$limit = null, $order_by = 'oo_date') {
|
227 |
aurelien |
106 |
|
207 |
aurelien |
107 |
$requete_selection_observations = 'SELECT * FROM ods_observations '.
|
|
|
108 |
' LEFT JOIN ods_individus '.
|
|
|
109 |
' ON oi_id_individu = oo_ce_individu'.
|
|
|
110 |
' LEFT JOIN ods_stations '.
|
263 |
gduche |
111 |
' ON oi_ce_station = os_id_station '.
|
|
|
112 |
' LEFT JOIN ods_communes '.
|
|
|
113 |
'ON os_ce_commune = oc_code_insee ';
|
207 |
aurelien |
114 |
|
|
|
115 |
$requete_selection_observations .= $this->construireConditionRequete();
|
|
|
116 |
$requete_selection_observations .= ' ORDER BY oo_date DESC';
|
|
|
117 |
|
|
|
118 |
$res_selection_observations = $this->executerRequete($requete_selection_observations);
|
|
|
119 |
|
|
|
120 |
return $res_selection_observations;
|
|
|
121 |
}
|
|
|
122 |
|
270 |
aurelien |
123 |
private function creerFiltreIdZoneGeo($valeurMasque) {
|
|
|
124 |
$masque = '';
|
|
|
125 |
$dept = $valeurMasque;
|
|
|
126 |
$dept = sprintf('%02s', $dept);
|
|
|
127 |
$dept = sprintf("%-'_5s", $dept);
|
|
|
128 |
$masque = " oc_code_insee LIKE ".$this->proteger($dept);
|
|
|
129 |
return $masque;
|
263 |
gduche |
130 |
}
|
|
|
131 |
|
207 |
aurelien |
132 |
public function construireConditionRequete() {
|
|
|
133 |
|
235 |
aurelien |
134 |
$condition = ' WHERE oo_date != "0000-00-00" AND DAY(oo_date) != "00" AND ';
|
207 |
aurelien |
135 |
|
|
|
136 |
foreach($_GET as $cle => $valeur) {
|
|
|
137 |
|
|
|
138 |
switch($cle) {
|
|
|
139 |
|
|
|
140 |
case 'type_espece':
|
|
|
141 |
$condition .= 'oi_ce_espece IN (SELECT oe_id_espece FROM ods_especes WHERE oe_ce_type = '.$this->proteger($valeur).')';
|
|
|
142 |
break;
|
|
|
143 |
|
|
|
144 |
case 'annee':
|
235 |
aurelien |
145 |
if($this->anneesMultiplesDemandees($valeur)) {
|
|
|
146 |
$valeur = rtrim($valeur,',');
|
|
|
147 |
$condition .= 'YEAR(oo_date) IN ('.$valeur.')';
|
|
|
148 |
} else {
|
|
|
149 |
$condition .= 'YEAR(oo_date) ';
|
|
|
150 |
$condition .= ' = '.$this->proteger($valeur);
|
|
|
151 |
}
|
207 |
aurelien |
152 |
break;
|
|
|
153 |
|
|
|
154 |
case 'mois':
|
|
|
155 |
$condition .= 'MONTH(oo_date) <= '.$this->proteger($valeur);
|
|
|
156 |
break;
|
|
|
157 |
|
|
|
158 |
case 'espece':
|
235 |
aurelien |
159 |
$condition .= 'oi_ce_espece IN ('.$valeur.') ';
|
207 |
aurelien |
160 |
break;
|
|
|
161 |
|
|
|
162 |
case 'evenement':
|
|
|
163 |
$condition .= 'oo_ce_evenement = '.$this->proteger($valeur);
|
|
|
164 |
break;
|
|
|
165 |
|
|
|
166 |
case 'utilisateur':
|
|
|
167 |
$condition .= 'oo_ce_participant = '.$this->proteger($valeur);
|
|
|
168 |
break;
|
|
|
169 |
|
264 |
gduche |
170 |
case 'departement' :
|
263 |
gduche |
171 |
$condition .= $this->creerFiltreIdZoneGeo($valeur);
|
|
|
172 |
break;
|
264 |
gduche |
173 |
|
|
|
174 |
case 'region' :
|
|
|
175 |
$requete_association_region .= 'SELECT * FROM ods_triples WHERE ot_ce_parent = 36 AND ot_valeur = '.$valeur;
|
|
|
176 |
$listeAssociationRegions = $this->executerRequete($requete_association_region);
|
|
|
177 |
$departements = array();
|
|
|
178 |
foreach ($listeAssociationRegions as $associationRegion) {
|
|
|
179 |
$departements[] = $this->creerFiltreIdZoneGeo($associationRegion['ot_cle']);
|
|
|
180 |
}
|
|
|
181 |
$condition .= ' ('. implode(' OR ', $departements).')';
|
|
|
182 |
break;
|
207 |
aurelien |
183 |
default:
|
|
|
184 |
}
|
|
|
185 |
|
|
|
186 |
$condition .= ' AND ';
|
|
|
187 |
}
|
|
|
188 |
|
|
|
189 |
$condition = rtrim($condition,'AND ');
|
|
|
190 |
|
227 |
aurelien |
191 |
$id_demo = $this->config['appli']['id_participant_demo'];
|
|
|
192 |
$id_admin = $this->config['appli']['id_participant_admin'];
|
|
|
193 |
|
|
|
194 |
$condition .= ' AND oo_ce_participant != '.$id_demo;
|
|
|
195 |
$condition .= ' AND oo_ce_participant != '.$id_admin;
|
|
|
196 |
|
207 |
aurelien |
197 |
return $condition;
|
|
|
198 |
}
|
|
|
199 |
|
235 |
aurelien |
200 |
private function anneesMultiplesDemandees($annee) {
|
|
|
201 |
// un ensemble d'identifiants est une suite d'identifiants séparés par des virgules
|
|
|
202 |
// sans virgule terminale
|
|
|
203 |
$reg_exp = "/^(([0-9])+,)*([0-9])+$/";
|
|
|
204 |
return preg_match($reg_exp, $annee);
|
|
|
205 |
}
|
|
|
206 |
|
210 |
aurelien |
207 |
public function getExportObservationPlat() {
|
|
|
208 |
|
|
|
209 |
$donnees = $this->getExportObservation();
|
270 |
aurelien |
210 |
$donnees_formatees = $this->formaterListeObservationPourExportCSV($donnees);
|
210 |
aurelien |
211 |
|
|
|
212 |
return $donnees_formatees ;
|
|
|
213 |
}
|
|
|
214 |
|
207 |
aurelien |
215 |
public function getExportObservationJson() {
|
|
|
216 |
|
|
|
217 |
$donnees = $this->getExportObservation();
|
270 |
aurelien |
218 |
$donnees_formatees = $this->formaterListeObservationPourExportJson($donnees);
|
249 |
aurelien |
219 |
|
246 |
aurelien |
220 |
$this->type_mime = 'application/json';
|
|
|
221 |
|
207 |
aurelien |
222 |
return $donnees_formatees;
|
|
|
223 |
}
|
|
|
224 |
|
270 |
aurelien |
225 |
public function formaterListeObservationPourExportJson($tableau_observations_infos) {
|
207 |
aurelien |
226 |
|
|
|
227 |
$gestionnaire_especes = new OdsEspece($this->config);
|
|
|
228 |
$gestionnaire_communes = new OdsCommune($this->config);
|
|
|
229 |
|
|
|
230 |
$especes = $gestionnaire_especes->getToutesEspeces();
|
|
|
231 |
$evenements = $this->obtenirValeursListeParAbreviation(self::ABBR_LISTE_EVENEMENTS);
|
249 |
aurelien |
232 |
$milieux = $this->obtenirValeursListeParAbreviation(self::ABBR_LISTE_MILIEUX);
|
207 |
aurelien |
233 |
|
|
|
234 |
$resultats_formates = array();
|
|
|
235 |
|
|
|
236 |
foreach($tableau_observations_infos as $observations_infos) {
|
|
|
237 |
|
|
|
238 |
$id_espece = $observations_infos['oi_ce_espece'];
|
|
|
239 |
$nom_espece = $especes[$id_espece]['nom_scientifique'];
|
|
|
240 |
|
|
|
241 |
$id_evenement = $observations_infos['oo_ce_evenement'];
|
|
|
242 |
$chaine_evenement = $evenements[$id_evenement]['ot_cle'];
|
|
|
243 |
|
|
|
244 |
$infos_evenement = $this->renvoyerInformationStadeAPartirChaineTriple($chaine_evenement);
|
|
|
245 |
|
|
|
246 |
$date_observation_formatee = date($this->config['appli']['format_date'], strtotime($observations_infos['oo_date']));
|
|
|
247 |
|
|
|
248 |
$id_observation = $observations_infos['oo_id_observation'];
|
|
|
249 |
$infos_formatees = array(
|
|
|
250 |
'date' => $date_observation_formatee,
|
|
|
251 |
'evenenement' => $infos_evenement['nom'],
|
|
|
252 |
'code_bbch' => $infos_evenement['numero'],
|
|
|
253 |
'nom_scientifique' => $nom_espece,
|
235 |
aurelien |
254 |
'id_espece' => $id_espece,
|
|
|
255 |
'participant' => $observations_infos['os_ce_participant']
|
207 |
aurelien |
256 |
);
|
|
|
257 |
|
|
|
258 |
$id_station = $observations_infos['oi_ce_station'];
|
|
|
259 |
|
|
|
260 |
if(!isset($resultats_formates[$id_station])) {
|
|
|
261 |
$resultats_formates[$id_station]['station'] = $observations_infos['os_nom'];
|
|
|
262 |
$resultats_formates[$id_station]['code_commune'] = $observations_infos['os_ce_commune'];
|
|
|
263 |
//$resultats_formates[$id_station]['nom_commune'] = $gestionnaire_communes->obtenirNomCommuneParCodeInsee($observations_infos['os_ce_commune']);
|
|
|
264 |
$resultats_formates[$id_station]['latitude'] = $observations_infos['os_latitude'];
|
|
|
265 |
$resultats_formates[$id_station]['longitude'] = $observations_infos['os_longitude'];
|
|
|
266 |
$resultats_formates[$id_station]['altitude'] = $observations_infos['os_altitude'];
|
249 |
aurelien |
267 |
$resultats_formates[$id_station]['milieu'] = $milieux[$observations_infos['os_ce_environnement']]['ot_valeur'];
|
207 |
aurelien |
268 |
$resultats_formates[$id_station]['participant'] = $observations_infos['os_ce_participant'];
|
|
|
269 |
}
|
|
|
270 |
|
|
|
271 |
$resultats_formates[$id_station]['obs'][$id_observation] = $infos_formatees;
|
|
|
272 |
}
|
|
|
273 |
|
|
|
274 |
return $resultats_formates;
|
|
|
275 |
}
|
|
|
276 |
|
210 |
aurelien |
277 |
public function getFichierExportObservationCsv() {
|
|
|
278 |
|
|
|
279 |
$donnees = $this->getExportObservation();
|
270 |
aurelien |
280 |
$donnees_formatees = $this->formaterListeObservationPourExportCSV($donnees);
|
210 |
aurelien |
281 |
$chaine_csv = $this->convertirTableauAssocVersCSV($donnees_formatees);
|
207 |
aurelien |
282 |
|
210 |
aurelien |
283 |
$this->envoyerFichier($chaine_csv);
|
207 |
aurelien |
284 |
}
|
|
|
285 |
|
270 |
aurelien |
286 |
public function formaterListeObservationPourExportCSV($tableau_observations_infos) {
|
207 |
aurelien |
287 |
|
|
|
288 |
$gestionnaire_especes = new OdsEspece($this->config);
|
|
|
289 |
$gestionnaire_communes = new OdsCommune($this->config);
|
227 |
aurelien |
290 |
$gestionnaire_utilisateurs = new OdsUtilisateur($this->config);
|
207 |
aurelien |
291 |
|
|
|
292 |
$especes = $gestionnaire_especes->getToutesEspeces();
|
|
|
293 |
$evenements = $this->obtenirValeursListeParAbreviation(self::ABBR_LISTE_EVENEMENTS);
|
249 |
aurelien |
294 |
$milieux = $this->obtenirValeursListeParAbreviation(self::ABBR_LISTE_MILIEUX);
|
207 |
aurelien |
295 |
|
210 |
aurelien |
296 |
$codes_insee_communes = array();
|
|
|
297 |
|
207 |
aurelien |
298 |
$resultats_formates = array();
|
|
|
299 |
|
|
|
300 |
foreach($tableau_observations_infos as $observations_infos) {
|
|
|
301 |
|
|
|
302 |
$id_espece = $observations_infos['oi_ce_espece'];
|
|
|
303 |
$nom_espece = $especes[$id_espece]['nom_scientifique'];
|
|
|
304 |
|
|
|
305 |
$id_evenement = $observations_infos['oo_ce_evenement'];
|
|
|
306 |
$chaine_evenement = $evenements[$id_evenement]['ot_cle'];
|
|
|
307 |
|
|
|
308 |
$infos_evenement = $this->renvoyerInformationStadeAPartirChaineTriple($chaine_evenement);
|
|
|
309 |
|
|
|
310 |
$date_observation_formatee = date($this->config['appli']['format_date'], strtotime($observations_infos['oo_date']));
|
|
|
311 |
|
|
|
312 |
$id_observation = $observations_infos['oo_id_observation'];
|
|
|
313 |
|
|
|
314 |
$infos_formatees = array(
|
|
|
315 |
'id_observation' => $id_observation,
|
|
|
316 |
'date' => $date_observation_formatee,
|
|
|
317 |
'evenenement' => $infos_evenement['nom'],
|
|
|
318 |
'code_bbch' => $infos_evenement['numero'],
|
|
|
319 |
'nom_scientifique' => $nom_espece,
|
|
|
320 |
'station' => $observations_infos['os_nom'],
|
|
|
321 |
'code_commune' => $observations_infos['os_ce_commune'],
|
210 |
aurelien |
322 |
'nom_commune' => '',
|
207 |
aurelien |
323 |
'latitude' => $observations_infos['os_latitude'],
|
|
|
324 |
'longitude' => $observations_infos['os_longitude'],
|
|
|
325 |
'altitude' => $observations_infos['os_altitude'],
|
249 |
aurelien |
326 |
'milieu' => $milieux[$observations_infos['os_ce_environnement']]['ot_valeur'],
|
227 |
aurelien |
327 |
'id_participant' => $observations_infos['os_ce_participant'],
|
|
|
328 |
'pseudo_participant' => '',
|
|
|
329 |
'mail_participant' => ''
|
207 |
aurelien |
330 |
);
|
|
|
331 |
|
|
|
332 |
$resultats_formates[] = $infos_formatees;
|
210 |
aurelien |
333 |
|
|
|
334 |
if(is_numeric($observations_infos['os_ce_commune'])) {
|
|
|
335 |
$codes_insee_communes[] = $observations_infos['os_ce_commune'];
|
|
|
336 |
}
|
207 |
aurelien |
337 |
}
|
|
|
338 |
|
210 |
aurelien |
339 |
$correspondance_codes_insee_noms = $gestionnaire_communes->obtenirTableauNomsCommunesParTableauCodesInsee($codes_insee_communes);
|
227 |
aurelien |
340 |
$correspondance_id_utilisateur = $gestionnaire_utilisateurs->getListeUtilisateurFormateeId();
|
210 |
aurelien |
341 |
|
|
|
342 |
foreach($resultats_formates as &$resultat) {
|
|
|
343 |
|
227 |
aurelien |
344 |
if(isset($correspondance_codes_insee_noms[$resultat['code_commune']]) && trim($correspondance_codes_insee_noms[$resultat['code_commune']]) != '') {
|
210 |
aurelien |
345 |
$resultat['nom_commune'] = $correspondance_codes_insee_noms[$resultat['code_commune']];
|
|
|
346 |
}
|
227 |
aurelien |
347 |
|
|
|
348 |
$resultat['pseudo_participant'] = $correspondance_id_utilisateur[$resultat['id_participant']]['name'];
|
|
|
349 |
$resultat['mail_participant'] = $correspondance_id_utilisateur[$resultat['id_participant']]['mail'];
|
210 |
aurelien |
350 |
}
|
|
|
351 |
|
207 |
aurelien |
352 |
return $resultats_formates;
|
|
|
353 |
}
|
|
|
354 |
|
|
|
355 |
public function convertirTableauAssocVersCSV($tableau) {
|
|
|
356 |
|
|
|
357 |
$csv = '';
|
|
|
358 |
$colonnes = array_keys($tableau[0]);
|
|
|
359 |
$csv .= implode(';',$colonnes).";\n";
|
|
|
360 |
|
|
|
361 |
foreach($tableau as $elements) {
|
|
|
362 |
$csv .= implode(';',$elements).";\n";
|
|
|
363 |
}
|
|
|
364 |
|
|
|
365 |
return $csv;
|
|
|
366 |
}
|
|
|
367 |
|
|
|
368 |
public function envoyerFichier($contenu) {
|
|
|
369 |
|
|
|
370 |
$nom_fichier = "observations_export.csv";
|
|
|
371 |
$chemin_fichier = $this->config['appli']['chemin_fichiers_temp'].'/'.$nom_fichier;
|
|
|
372 |
|
|
|
373 |
file_put_contents($chemin_fichier, $contenu);
|
|
|
374 |
|
|
|
375 |
$contenu = file_get_contents($chemin_fichier);
|
|
|
376 |
$taille_fichier = filesize($chemin_fichier);
|
|
|
377 |
|
|
|
378 |
unlink($chemin_fichier);
|
|
|
379 |
|
|
|
380 |
ini_set('zlib.output_compression','Off');
|
|
|
381 |
|
|
|
382 |
header('Pragma: public');
|
|
|
383 |
header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT');
|
|
|
384 |
header('Cache-Control: must-revalidate, pre-check=0, post-check=0, max-age=0');
|
|
|
385 |
|
|
|
386 |
header('Content-Tranfer-Encoding: none');
|
|
|
387 |
|
|
|
388 |
header('Content-Type: application/octetstream; name="'.$nom_fichier.'"');
|
|
|
389 |
header('Content-Disposition: attachement; filename="'.$nom_fichier.'"');
|
|
|
390 |
|
|
|
391 |
header('Content-Length: '.$taille_fichier);
|
|
|
392 |
|
|
|
393 |
echo $contenu;
|
|
|
394 |
exit();
|
|
|
395 |
}
|
|
|
396 |
|
|
|
397 |
private function formaterInformationPourEnvoi($tableauinfos) {
|
|
|
398 |
|
|
|
399 |
}
|
|
|
400 |
}
|
|
|
401 |
?>
|