Line 78... |
Line 78... |
78 |
if ($this->onglet == 'synthese' && $niveau != null) {
|
78 |
if ($this->onglet == 'synthese' && $niveau != null) {
|
79 |
$squelette .= '_niveau'.$niveau;
|
79 |
$squelette .= '_niveau'.$niveau;
|
80 |
}
|
80 |
}
|
Line 81... |
Line 81... |
81 |
|
81 |
|
82 |
// Récupération parametres et données
|
- |
|
83 |
$donnees = $this->parametres;
|
82 |
// Récupération parametres et données
|
84 |
$donnees = array_merge($this->obtenirDonnees(), $donnees);
|
83 |
$donnees = array_merge($this->obtenirDonnees(), $this->parametres);
|
85 |
$donnees['i18n'] = I18n::get('Fiche');
|
84 |
$donnees['i18n'] = I18n::get('Fiche');
|
Line 86... |
Line 85... |
86 |
$verna = (isset($donnees['ethnobotanique']['nomsVerna'])) ? $donnees['ethnobotanique']['nomsVerna'][0]['nom_vernaculaire'] : "";
|
85 |
$verna = isset($donnees['ethnobotanique']['nomsVerna']) && count($donnees['ethnobotanique']['nomsVerna']) ? $donnees['ethnobotanique']['nomsVerna'][0]['nom_vernaculaire'] : "";
|
87 |
|
86 |
|
88 |
// titre, description et tag de la page
|
87 |
// titre, description et tag de la page
|
89 |
$this->setSortie('titre', $this->nom_retenu->get('nom_sci'));
|
88 |
$this->setSortie('titre', $this->nom_retenu->get('nom_sci'));
|
- |
|
89 |
// ( <meta name="description" ...> )
|
90 |
$this->setSortie('description', "Fiche descriptive de ".$this->nom_retenu->get('nom_sci')." ".
|
90 |
$this->setSortie('description', sprintf("Fiche descriptive de %s %s (%s)", $this->nom_retenu->get('nom_sci'), $verna ? ('/ ' . $verna) : '', $donnees['description']['titre']));
|
91 |
$verna." ".$donnees['description']['titre']." ".implode(" ", $donnees['description']['description']));
|
91 |
|
Line 92... |
Line 92... |
92 |
$this->setSortie('tags', $this->nom_retenu->get('nom_sci').",".$verna.
|
92 |
$this->setSortie('tags', $this->nom_retenu->get('nom_sci').",".$verna.
|
93 |
",botanique,plante,description,ecologie,reconnaitre,fiche espece");
|
93 |
",botanique,plante,description,ecologie,reconnaitre,fiche espece");
|
Line 153... |
Line 153... |
153 |
header('Content-type: text/html');
|
153 |
header('Content-type: text/html');
|
154 |
$this->setSortie(self::RENDU_CORPS, $this->getVue('fiche_'.$this->onglet, $donnees));
|
154 |
$this->setSortie(self::RENDU_CORPS, $this->getVue('fiche_'.$this->onglet, $donnees));
|
155 |
}
|
155 |
}
|
Line 156... |
Line 156... |
156 |
|
156 |
|
157 |
private function obtenirDonnees() {
|
- |
|
158 |
$donnees = array();
|
157 |
private function obtenirDonnees() {
|
159 |
$classe = ucfirst($this->onglet);
|
158 |
$classe = ucfirst($this->onglet);
|
160 |
$onglet = new $classe($this->conteneur); // grep-friendly: new Synthese()
|
159 |
$onglet = new $classe($this->conteneur); // grep-friendly: new Synthese()
|
161 |
$donnees = $onglet->obtenirDonnees();
|
- |
|
162 |
return $donnees;
|
160 |
return $onglet->obtenirDonnees();
|
163 |
}
|
161 |
}
|
164 |
}
|
162 |
}
|
165 |
?>
|
163 |
?>
|