Subversion Repositories eFlore/Archives.eflore-consultation-v2

Rev

Rev 174 | Details | Compare with Previous | Last modification | View Log | RSS feed

Rev Author Line No. Line
174 jp_milcent 1
<?php
2
/*vim: set expandtab tabstop=4 shiftwidth=4: */
3
// +------------------------------------------------------------------------------------------------------+
4
// | PHP version 5.0.3                                                                                    |
5
// +------------------------------------------------------------------------------------------------------+
6
// | Copyright (C) 2004 Tela Botanica (accueil@tela-botanica.org)                                         |
7
// +------------------------------------------------------------------------------------------------------+
8
// | This file is part of eRibo.                                                                          |
9
// |                                                                                                      |
10
// | Foobar is free software; you can redistribute it and/or modify                                       |
11
// | it under the terms of the GNU General Public License as published by                                 |
12
// | the Free Software Foundation; either version 2 of the License, or                                    |
13
// | (at your option) any later version.                                                                  |
14
// |                                                                                                      |
15
// | Foobar is distributed in the hope that it will be useful,                                            |
16
// | but WITHOUT ANY WARRANTY; without even the implied warranty of                                       |
17
// | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the                                        |
18
// | GNU General Public License for more details.                                                         |
19
// |                                                                                                      |
20
// | You should have received a copy of the GNU General Public License                                    |
21
// | along with Foobar; if not, write to the Free Software                                                |
22
// | Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA                            |
23
// +------------------------------------------------------------------------------------------------------+
177 jp_milcent 24
// CVS : $Id: info_taxon_sup_xml.php,v 1.2 2005-07-01 19:06:59 jp_milcent Exp $
174 jp_milcent 25
/**
26
* Vue affichant la liste des taxons d'un projet.
27
*
28
* Permet de retourner le xhtml correspondant à une liste hiérarchisées des taxons d'un projet.
29
*
30
*@package eFlore
31
*@subpackage Vues
32
//Auteur original :
33
*@author        Frédéric LEGENS <flegens@free.fr>
34
//Autres auteurs :
35
*@author        Jean-Pascal MILCENT <jpm@tela-botanica.org>
36
*@copyright     Tela-Botanica 2000-2004
177 jp_milcent 37
*@version       $Revision: 1.2 $ $Date: 2005-07-01 19:06:59 $
174 jp_milcent 38
// +------------------------------------------------------------------------------------------------------+
39
*/
40
 
41
// +------------------------------------------------------------------------------------------------------+
42
// |                                            ENTETE du PROGRAMME                                       |
43
// +------------------------------------------------------------------------------------------------------+
44
require_once EFSE_CHEMIN_FONCTION.'eribo_encodage.fonct.php';
45
 
46
// +------------------------------------------------------------------------------------------------------+
47
// |                                            CLASSE de la VUE                                          |
48
// +------------------------------------------------------------------------------------------------------+
177 jp_milcent 49
class info_taxon_sup_xml implements iVue {
174 jp_milcent 50
 
51
    protected $leBlock;
52
 
53
    function __construct($unBlock)
54
    {
55
        $this->leBlock = $unBlock;
56
    }
57
 
58
    function serialiser()
59
    {
60
 
61
        $retour = '<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>'."\n";
62
        $retour .= $this->leBlock->afficherPattern('FICHE_TAXON_SUPERIEUR>TAXON_SUPERIEUR','afficherInfoTaxon');
63
 
64
        // Envoi au navigateur après encodage en entité des caractères posant problème
65
        header('Content-Type: text/xml');
66
        echo utf8_encode($retour);
67
    }
68
}
69
 
70
// +------------------------------------------------------------------------------------------------------+
71
// |                                            LISTE des FONCTIONS                                       |
72
// +------------------------------------------------------------------------------------------------------+
73
function afficherInfoTaxon($donnees)
74
{
75
    $retour = '';
76
    $retour .= '<taxon>'."\n";
77
    $retour .= '  <etr_id_t2>'.$donnees['etr_id_taxon_2'].'</etr_id_t2>'."\n";
78
    $retour .= '  <etr_id_vpt2>'.$donnees['etr_id_version_projet_taxon_2'].'</etr_id_vpt2>'."\n";
79
    $retour .= '  <en_ce_r>'.$donnees['en_ce_rang'].'</en_ce_r>'."\n";
80
    $retour .= '  <en_id_n>'.$donnees['en_id_nom'].'</en_id_n>'."\n";
81
    $retour .= '</taxon>'."\n";
82
    return $retour;
83
}
84
 
85
 
86
// +------------------------------------------------------------------------------------------------------+
87
// |                                            PIED du PROGRAMME                                         |
88
// +------------------------------------------------------------------------------------------------------+
89
 
90
 
91
/* +--Fin du code ----------------------------------------------------------------------------------------+
92
*
93
* $Log: not supported by cvs2svn $
177 jp_milcent 94
* Revision 1.1  2005/07/01 18:31:30  jp_milcent
95
* changement de nom
96
*
174 jp_milcent 97
* Revision 1.1  2005/06/30 15:25:07  jpm
98
* Début des modifications pour ajout de l'arborescence de la classif.
99
*
100
*
101
* +-- Fin du code ----------------------------------------------------------------------------------------+
102
*/
103
?>