Subversion Repositories eFlore/Applications.bibliobota

Rev

Rev 2 | Only display areas with differences | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 2 Rev 30
1
<?php
1
<?php
2
/*vim: set expandtab tabstop=4 shiftwidth=4: */ 
2
/*vim: set expandtab tabstop=4 shiftwidth=4: */ 
3
// +------------------------------------------------------------------------------------------------------+
3
// +------------------------------------------------------------------------------------------------------+
4
// | PHP version 4.1                                                                                      |
4
// | PHP version 4.1                                                                                      |
5
// +------------------------------------------------------------------------------------------------------+
5
// +------------------------------------------------------------------------------------------------------+
6
// | Copyright (C) 2005 Tela Botanica (accueil@tela-botanica.org)                                         |
6
// | Copyright (C) 2005 Tela Botanica (accueil@tela-botanica.org)                                         |
7
// +------------------------------------------------------------------------------------------------------+
7
// +------------------------------------------------------------------------------------------------------+
8
// | This file is part of BiblioBota - Organisme Carto.                                                   |
8
// | This file is part of BiblioBota - Organisme Carto.                                                   |
9
// |                                                                                                      |
9
// |                                                                                                      |
10
// | Foobar is free software; you can redistribute it and/or modify                                       |
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                                 |
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                                    |
12
// | the Free Software Foundation; either version 2 of the License, or                                    |
13
// | (at your option) any later version.                                                                  |
13
// | (at your option) any later version.                                                                  |
14
// |                                                                                                      |
14
// |                                                                                                      |
15
// | Foobar is distributed in the hope that it will be useful,                                            |
15
// | Foobar is distributed in the hope that it will be useful,                                            |
16
// | but WITHOUT ANY WARRANTY; without even the implied warranty of                                       |
16
// | but WITHOUT ANY WARRANTY; without even the implied warranty of                                       |
17
// | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the                                        |
17
// | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the                                        |
18
// | GNU General Public License for more details.                                                         |
18
// | GNU General Public License for more details.                                                         |
19
// |                                                                                                      |
19
// |                                                                                                      |
20
// | You should have received a copy of the GNU General Public License                                    |
20
// | You should have received a copy of the GNU General Public License                                    |
21
// | along with Foobar; if not, write to the Free Software                                                |
21
// | along with Foobar; if not, write to the Free Software                                                |
22
// | Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA                            |
22
// | Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA                            |
23
// +------------------------------------------------------------------------------------------------------+
23
// +------------------------------------------------------------------------------------------------------+
24
// CVS : $Id: bb_organisme_carto.php,v 1.1 2005-11-23 10:22:25 jp_milcent Exp $
24
// CVS : $Id: bb_organisme_carto.php,v 1.4 2005/05/30 09:10:26 jpm Exp $
25
/**
25
/**
26
* Application affichant une cartographie des organismes
26
* Application affichant une cartographie des organismes
27
*
27
*
28
* Fournit une carte des organimes liés à la botanique stockés dans la base Biblio Bota.
28
* Fournit une carte des organimes liés à la botanique stockés dans la base Biblio Bota.
29
*
29
*
30
*@package BiblioBota-OrganismeCarto
30
*@package BiblioBota-OrganismeCarto
31
//Auteur original :
31
//Auteur original :
32
*@author        Jean-Charles GRANGER <tela@vecteur.org>
32
*@author        Jean-Charles GRANGER <tela@vecteur.org>
33
//Autres auteurs :
33
//Autres auteurs :
34
*@author        Jean-Pascal MILCENT <jpm@clapas.org>
34
*@author        Jean-Pascal MILCENT <jpm@clapas.org>
35
*@copyright     Tela-Botanica 2000-2005
35
*@copyright     Tela-Botanica 2000-2005
36
*@version       $Revision: 1.1 $ $Date: 2005-11-23 10:22:25 $
36
*@version       $Revision: 1.4 $ $Date: 2005/05/30 09:10:26 $
37
// +------------------------------------------------------------------------------------------------------+
37
// +------------------------------------------------------------------------------------------------------+
38
*/
38
*/
39
 
39
 
40
// +------------------------------------------------------------------------------------------------------+
40
// +------------------------------------------------------------------------------------------------------+
41
// |                                            ENTETE du PROGRAMME                                       |
41
// |                                            ENTETE du PROGRAMME                                       |
42
// +------------------------------------------------------------------------------------------------------+
42
// +------------------------------------------------------------------------------------------------------+
43
/** Inclusion du fichier de configuration de l'application Organisme Carto. */
43
/** Inclusion du fichier de configuration de l'application Organisme Carto. */
44
require_once BB_CHEMIN_APPLI.'bb_organisme_carto/configuration/bboc_config.inc.php';
44
require_once BB_CHEMIN_APPLI.'bb_organisme_carto/configuration/bboc_config.inc.php';
45
 
45
 
46
// Appel du fichier de traduction des textes de l'application Organisme Carto de Biblio Bota
46
// Appel du fichier de traduction des textes de l'application Organisme Carto de Biblio Bota
47
if (file_exists(BBOC_CHEMIN_LANGUES.'bboc_langue_'.BB_URL_I18N.'.inc.php')) {
47
if (file_exists(BBOC_CHEMIN_LANGUES.'bboc_langue_'.BB_URL_I18N.'.inc.php')) {
48
    /** Inclusion du fichier de traduction de l'application Organisme Carto. */
48
    /** Inclusion du fichier de traduction de l'application Organisme Carto. */
49
    include_once BBOC_CHEMIN_LANGUES.'bboc_langue_'.BB_URL_I18N.'.inc.php';
49
    include_once BBOC_CHEMIN_LANGUES.'bboc_langue_'.BB_URL_I18N.'.inc.php';
50
} else {
50
} else {
51
    /** Inclusion du fichier de traduction fr par défaut. */
51
    /** Inclusion du fichier de traduction fr par défaut. */
52
    include_once BBOC_CHEMIN_LANGUES.'bboc_langue_fr.inc.php';
52
    include_once BBOC_CHEMIN_LANGUES.'bboc_langue_fr.inc.php';
53
}
53
}
54
 
54
 
55
/** Inclusion du fichier comportant des fonctions fournissant des informations pour l'application Organisme Carto.*/
55
/** Inclusion du fichier comportant des fonctions fournissant des informations pour l'application Organisme Carto.*/
56
include_once BBOC_CHEMIN_BIBLIO.'bboc_information.fonct.php';
56
include_once BBOC_CHEMIN_BIBLIO.'bboc_information.fonct.php';
57
 
57
 
58
/** Inclusion de la bibliothèque Cartographie. */
58
/** Inclusion de la bibliothèque Cartographie. */
59
require_once BBOC_CHEMIN_BIBLIO_CARTO.'carto_carte.class.php';
59
require_once BBOC_CHEMIN_BIBLIO_CARTO.'carto_carte.class.php';
60
 
60
 
61
// +------------------------------------------------------------------------------------------------------+
61
// +------------------------------------------------------------------------------------------------------+
62
// Initialisation des variables
62
// Initialisation des variables
63
$res = '';
63
$res = '';
64
$res .= '<!-- BiblioBota - Organisme Carto : DEBUT -->'."\n";
64
$res .= '<!-- BiblioBota - Organisme Carto : DEBUT -->'."\n";
65
 
65
 
66
// +------------------------------------------------------------------------------------------------------+
66
// +------------------------------------------------------------------------------------------------------+
67
// |                                            CORPS du PROGRAMME                                        |
67
// |                                            CORPS du PROGRAMME                                        |
68
// +------------------------------------------------------------------------------------------------------+
68
// +------------------------------------------------------------------------------------------------------+
69
 
69
 
70
// +------------------------------------------------------------------------------------------------------+
70
// +------------------------------------------------------------------------------------------------------+
71
// Instanciation du tableau contenant les champs de la table action
71
// Instanciation du tableau contenant les champs de la table action
72
$info_table_action['nom_table_action'] = BB_BDD_NOM_CARTO.'.carto_ACTION';
72
$info_table_action['nom_table_action'] = BB_BDD_NOM_CARTO.'.carto_ACTION';
73
$info_table_action['nom_chp_id_carte'] = 'CA_ID_Carte';
73
$info_table_action['nom_chp_id_carte'] = 'CA_ID_Carte';
74
$info_table_action['nom_chp_id_zg_action'] = 'CA_ID_Zone_geo';
74
$info_table_action['nom_chp_id_zg_action'] = 'CA_ID_Zone_geo';
75
$info_table_action['nom_chp_type_zg'] = 'CA_Type_zone';
75
$info_table_action['nom_chp_type_zg'] = 'CA_Type_zone';
76
$info_table_action['nom_chp_action'] = 'CA_Action';
76
$info_table_action['nom_chp_action'] = 'CA_Action';
77
$info_table_action['nom_chp_id_carte_destination'] = 'CA_ID_Carte_destination';
77
$info_table_action['nom_chp_id_carte_destination'] = 'CA_ID_Carte_destination';
78
 
78
 
79
// +------------------------------------------------------------------------------------------------------+
79
// +------------------------------------------------------------------------------------------------------+
80
$requete_01 =   'SELECT DISTINCT CP_ID_Continent, count(CP_ID_Continent) as nbr '.
80
$requete_01 =   'SELECT DISTINCT CP_ID_Continent, count(CP_ID_Continent) as nbr '.
81
                'FROM '.BB_BDD_NOM.'.biblio_str, '.BB_BDD_NOM_CARTO.'.carto_PAYS '.
81
                'FROM '.BB_BDD_NOM.'.biblio_str, '.BB_BDD_NOM_CARTO.'.carto_PAYS '.
82
                'WHERE B_S_PAYS = CP_ID_Pays '.
82
                'WHERE B_S_PAYS = CP_ID_Pays '.
83
                'AND CP_ID_Continent <> 0 '.
83
                'AND CP_ID_Continent <> 0 '.
84
                'GROUP BY CP_ID_Continent';
84
                'GROUP BY CP_ID_Continent';
85
 
85
 
86
$resultat_01 = mysql_query($requete_01) or die(BOG_afficherErreurSql(__FILE__, __LINE__, mysql_error(), $requete_01));
86
$resultat_01 = mysql_query($requete_01) or die(BOG_afficherErreurSql(__FILE__, __LINE__, mysql_error(), $requete_01));
87
 
87
 
88
$tableau_asso_continent = array();
88
$tableau_asso_continent = array();
89
 
89
 
90
while ($ligne_01 = mysql_fetch_object($resultat_01)) {
90
while ($ligne_01 = mysql_fetch_object($resultat_01)) {
91
    $tableau_asso_continent[$ligne_01->CP_ID_Continent] = $ligne_01->nbr; 
91
    $tableau_asso_continent[$ligne_01->CP_ID_Continent] = $ligne_01->nbr; 
92
}
92
}
93
 
93
 
94
$info_continent['nom_table_zone'] = BB_BDD_NOM_CARTO.'.carto_CONTINENT';
94
$info_continent['nom_table_zone'] = BB_BDD_NOM_CARTO.'.carto_CONTINENT';
95
$info_continent['nom_chp_id_zone'] = 'CC_ID_Continent';
95
$info_continent['nom_chp_id_zone'] = 'CC_ID_Continent';
96
$info_continent['nom_chp_nom_zone'] = 'CC_Intitule_continent';
96
$info_continent['nom_chp_nom_zone'] = 'CC_Intitule_continent';
97
$info_continent['nom_chp_rouge'] = 'CC_Couleur_R';
97
$info_continent['nom_chp_rouge'] = 'CC_Couleur_R';
98
$info_continent['nom_chp_vert'] = 'CC_Couleur_V';
98
$info_continent['nom_chp_vert'] = 'CC_Couleur_V';
99
$info_continent['nom_chp_bleu'] = 'CC_Couleur_B';
99
$info_continent['nom_chp_bleu'] = 'CC_Couleur_B';
100
$info_continent['nom_chp_zone_sup'] = '';
100
$info_continent['nom_chp_zone_sup'] = '';
101
$info_continent['tableau_valeurs_zone'] = $tableau_asso_continent;
101
$info_continent['tableau_valeurs_zone'] = $tableau_asso_continent;
102
 
102
 
103
// +------------------------------------------------------------------------------------------------------+
103
// +------------------------------------------------------------------------------------------------------+
104
$requete_02 =   'SELECT CC_ID_Continent '.
104
$requete_02 =   'SELECT CC_ID_Continent '.
105
                'FROM '.BB_BDD_NOM_CARTO.'.carto_CONTINENT';
105
                'FROM '.BB_BDD_NOM_CARTO.'.carto_CONTINENT';
106
 
106
 
107
$resultat_02 = mysql_query ($requete_02) or die(BOG_afficherErreurSql(__FILE__, __LINE__, mysql_error(), $requete_02));
107
$resultat_02 = mysql_query ($requete_02) or die(BOG_afficherErreurSql(__FILE__, __LINE__, mysql_error(), $requete_02));
108
 
108
 
109
while ($ligne_02 = mysql_fetch_object($resultat_02)) {
109
while ($ligne_02 = mysql_fetch_object($resultat_02)) {
110
    $requete_03 =   'SELECT CP_ID_Pays, count(B_S_PAYS) as nbr '.
110
    $requete_03 =   'SELECT CP_ID_Pays, count(B_S_PAYS) as nbr '.
111
                    'FROM '.BB_BDD_NOM.'.biblio_str, '.BB_BDD_NOM_CARTO.'.carto_PAYS '.
111
                    'FROM '.BB_BDD_NOM.'.biblio_str, '.BB_BDD_NOM_CARTO.'.carto_PAYS '.
112
                    'WHERE B_S_PAYS = CP_ID_Pays '.
112
                    'WHERE B_S_PAYS = CP_ID_Pays '.
113
                    'AND CP_ID_Continent = "'.$ligne_02->CC_ID_Continent.'" '.
113
                    'AND CP_ID_Continent = "'.$ligne_02->CC_ID_Continent.'" '.
114
                    'GROUP BY B_S_PAYS';
114
                    'GROUP BY B_S_PAYS';
115
    $resultat_03 = mysql_query($requete_03) or die(BOG_afficherErreurSql(__FILE__, __LINE__, mysql_error(), $requete_03));
115
    $resultat_03 = mysql_query($requete_03) or die(BOG_afficherErreurSql(__FILE__, __LINE__, mysql_error(), $requete_03));
116
    
116
    
117
    $tableau_asso_pays = array();
117
    $tableau_asso_pays = array();
118
    
118
    
119
    while ($ligne_03 = mysql_fetch_object($resultat_03)) {
119
    while ($ligne_03 = mysql_fetch_object($resultat_03)) {
120
        $tableau_asso_pays[$ligne_03->CP_ID_Pays] = $ligne_03->nbr;
120
        $tableau_asso_pays[$ligne_03->CP_ID_Pays] = $ligne_03->nbr;
121
    }
121
    }
122
    
122
    
123
    $info_pays[$ligne_02->CC_ID_Continent]['nom_table_zone'] = BB_BDD_NOM_CARTO.'.carto_PAYS';
123
    $info_pays[$ligne_02->CC_ID_Continent]['nom_table_zone'] = BB_BDD_NOM_CARTO.'.carto_PAYS';
124
    $info_pays[$ligne_02->CC_ID_Continent]['nom_chp_id_zone'] = 'CP_ID_Pays';
124
    $info_pays[$ligne_02->CC_ID_Continent]['nom_chp_id_zone'] = 'CP_ID_Pays';
125
    $info_pays[$ligne_02->CC_ID_Continent]['nom_chp_nom_zone'] = 'CP_Intitule_pays';
125
    $info_pays[$ligne_02->CC_ID_Continent]['nom_chp_nom_zone'] = 'CP_Intitule_pays';
126
    $info_pays[$ligne_02->CC_ID_Continent]['nom_chp_rouge'] = 'CP_Couleur_R';
126
    $info_pays[$ligne_02->CC_ID_Continent]['nom_chp_rouge'] = 'CP_Couleur_R';
127
    $info_pays[$ligne_02->CC_ID_Continent]['nom_chp_vert'] = 'CP_Couleur_V';
127
    $info_pays[$ligne_02->CC_ID_Continent]['nom_chp_vert'] = 'CP_Couleur_V';
128
    $info_pays[$ligne_02->CC_ID_Continent]['nom_chp_bleu'] = 'CP_Couleur_B';
128
    $info_pays[$ligne_02->CC_ID_Continent]['nom_chp_bleu'] = 'CP_Couleur_B';
129
    $info_pays[$ligne_02->CC_ID_Continent]['nom_chp_zone_sup'] = 'CP_ID_Continent';
129
    $info_pays[$ligne_02->CC_ID_Continent]['nom_chp_zone_sup'] = 'CP_ID_Continent';
130
    $info_pays[$ligne_02->CC_ID_Continent]['tableau_valeurs_zone'] = $tableau_asso_pays;
130
    $info_pays[$ligne_02->CC_ID_Continent]['tableau_valeurs_zone'] = $tableau_asso_pays;
131
}
131
}
132
 
132
 
133
// +------------------------------------------------------------------------------------------------------+
133
// +------------------------------------------------------------------------------------------------------+
134
$requete_04 =   'SELECT CD_ID_Departement, COUNT(CD_ID_Departement) AS nbr '.
134
$requete_04 =   'SELECT CD_ID_Departement, COUNT(CD_ID_Departement) AS nbr '.
135
                'FROM '.BB_BDD_NOM.'.biblio_str, '.BB_BDD_NOM_CARTO.'.carto_DEPARTEMENT '.
135
                'FROM '.BB_BDD_NOM.'.biblio_str, '.BB_BDD_NOM_CARTO.'.carto_DEPARTEMENT '.
136
                'WHERE B_S_PAYS = "fr" '.
136
                'WHERE B_S_PAYS = "fr" '.
137
                'AND CD_ID_Departement = IF (SUBSTRING(B_S_CODEPOSTAL,1,2)<>"97", SUBSTRING(B_S_CODEPOSTAL, 1,2), SUBSTRING(B_S_CODEPOSTAL,1,3)) '.
137
                'AND CD_ID_Departement = IF (SUBSTRING(B_S_CODEPOSTAL,1,2)<>"97", SUBSTRING(B_S_CODEPOSTAL, 1,2), SUBSTRING(B_S_CODEPOSTAL,1,3)) '.
138
                'GROUP BY CD_ID_Departement';
138
                'GROUP BY CD_ID_Departement';
139
$resultat_04 = mysql_query($requete_04) or die(BOG_afficherErreurSql(__FILE__, __LINE__, mysql_error(), $requete_04));
139
$resultat_04 = mysql_query($requete_04) or die(BOG_afficherErreurSql(__FILE__, __LINE__, mysql_error(), $requete_04));
140
 
140
 
141
$tableau_asso_dpt_france = array();
141
$tableau_asso_dpt_france = array();
142
 
142
 
143
while ($ligne_04 = mysql_fetch_object($resultat_04)) {
143
while ($ligne_04 = mysql_fetch_object($resultat_04)) {
144
    $tableau_asso_dpt_france[$ligne_04->CD_ID_Departement] = $ligne_04->nbr; 
144
    $tableau_asso_dpt_france[$ligne_04->CD_ID_Departement] = $ligne_04->nbr; 
145
}
145
}
146
 
146
 
147
$info_dpt_france['nom_table_zone'] = BB_BDD_NOM_CARTO.'.carto_DEPARTEMENT';
147
$info_dpt_france['nom_table_zone'] = BB_BDD_NOM_CARTO.'.carto_DEPARTEMENT';
148
$info_dpt_france['nom_chp_id_zone'] = 'CD_ID_Departement';
148
$info_dpt_france['nom_chp_id_zone'] = 'CD_ID_Departement';
149
$info_dpt_france['nom_chp_nom_zone'] = 'CD_Intitule_departement';
149
$info_dpt_france['nom_chp_nom_zone'] = 'CD_Intitule_departement';
150
$info_dpt_france['nom_chp_rouge'] = 'CD_Couleur_R';
150
$info_dpt_france['nom_chp_rouge'] = 'CD_Couleur_R';
151
$info_dpt_france['nom_chp_vert'] = 'CD_Couleur_V';
151
$info_dpt_france['nom_chp_vert'] = 'CD_Couleur_V';
152
$info_dpt_france['nom_chp_bleu'] = 'CD_Couleur_B';
152
$info_dpt_france['nom_chp_bleu'] = 'CD_Couleur_B';
153
$info_dpt_france['nom_chp_zone_sup'] = 'CD_ID_Pays';
153
$info_dpt_france['nom_chp_zone_sup'] = 'CD_ID_Pays';
154
$info_dpt_france['tableau_valeurs_zone'] = $tableau_asso_dpt_france;
154
$info_dpt_france['tableau_valeurs_zone'] = $tableau_asso_dpt_france;
155
 
155
 
156
// On cree tout d'abords l'arborescence
156
// On cree tout d'abords l'arborescence
157
$monde = new Carto_Carte('continent', '', 'Monde', 'monde_masque5c.png', 'monde5c.png', BBOC_CHEMIN_CARTE, $info_continent, $info_table_action);
157
$monde = new Carto_Carte('continent', '', 'Monde', 'monde_masque5c.png', 'monde5c.png', BBOC_CHEMIN_CARTE, $info_continent, $info_table_action);
158
 
158
 
159
$monde->historique_cartes = isset($GLOBALS['historique_cartes']) ? $GLOBALS['historique_cartes'] : '';
159
$monde->historique_cartes = isset($GLOBALS['historique_cartes']) ? $GLOBALS['historique_cartes'] : '';
160
$monde->image_x = isset($GLOBALS['image_x']) ? $GLOBALS['image_x'] : '';
160
$monde->image_x = isset($GLOBALS['image_x']) ? $GLOBALS['image_x'] : '';
161
$monde->image_y = isset($GLOBALS['image_y']) ? $GLOBALS['image_y'] : '';
161
$monde->image_y = isset($GLOBALS['image_y']) ? $GLOBALS['image_y'] : '';
162
$monde->liste_zone_carte = isset($GLOBALS['liste_zone_carte']) ? $GLOBALS['liste_zone_carte'] : '';
162
$monde->liste_zone_carte = isset($GLOBALS['liste_zone_carte']) ? $GLOBALS['liste_zone_carte'] : '';
163
$monde->url = $GLOBALS['_BIBLIO_']['url']->getURL();
163
$monde->url = $GLOBALS['_BIBLIO_']['url']->getURL();
164
 
164
 
165
foreach ($info_pays as $cle => $valeur) {
165
foreach ($info_pays as $cle => $valeur) {
166
    $requete_05 =   'SELECT CDC_Titre_carte, CDC_ID_Carte, CDC_Carte_fond, CDC_Carte_masque, CDC_ID_Zone_geo_carte '.
166
    $requete_05 =   'SELECT CDC_Titre_carte, CDC_ID_Carte, CDC_Carte_fond, CDC_Carte_masque, CDC_ID_Zone_geo_carte '.
167
                    'FROM '.BB_BDD_NOM_CARTO.'.carto_DESCRIPTION_CARTE, '.BB_BDD_NOM_CARTO.'.carto_ACTION '.
167
                    'FROM '.BB_BDD_NOM_CARTO.'.carto_DESCRIPTION_CARTE, '.BB_BDD_NOM_CARTO.'.carto_ACTION '.
168
                    'WHERE CA_ID_Zone_geo = "'.$cle.'" '.
168
                    'WHERE CA_ID_Zone_geo = "'.$cle.'" '.
169
                    'AND CA_Type_zone = 1 '.
169
                    'AND CA_Type_zone = 1 '.
170
                    'AND CA_ID_Carte_destination = CDC_ID_Carte';
170
                    'AND CA_ID_Carte_destination = CDC_ID_Carte';
171
	$resultat_05 = mysql_query($requete_05) or die(BOG_afficherErreurSql(__FILE__, __LINE__, mysql_error(), $requete_05)); 
171
	$resultat_05 = mysql_query($requete_05) or die(BOG_afficherErreurSql(__FILE__, __LINE__, mysql_error(), $requete_05)); 
172
	$resultat_05_nbre = mysql_num_rows($resultat_05);
172
	$resultat_05_nbre = mysql_num_rows($resultat_05);
173
 
173
 
174
	if ($resultat_05_nbre > 0) {
174
	if ($resultat_05_nbre > 0) {
175
		$ligne_05 = mysql_fetch_object($resultat_05);
175
		$ligne_05 = mysql_fetch_object($resultat_05);
176
		$monde->ajouterFils(	$ligne_05->CDC_ID_Carte, $ligne_05->CDC_ID_Zone_geo_carte, $ligne_05->CDC_Titre_carte, 
176
		$monde->ajouterFils(	$ligne_05->CDC_ID_Carte, $ligne_05->CDC_ID_Zone_geo_carte, $ligne_05->CDC_Titre_carte, 
177
										$ligne_05->CDC_Carte_masque, $ligne_05->CDC_Carte_fond, $valeur, $info_table_action);
177
										$ligne_05->CDC_Carte_masque, $ligne_05->CDC_Carte_fond, $valeur, $info_table_action);
178
	}
178
	}
179
}
179
}
180
 
180
 
181
$monde->fils['europe']->ajouterFils('france', 'fr', 'France' ,'france_masque.png', 'france.png', $info_dpt_france, $info_table_action);
181
$monde->fils['europe']->ajouterFils('france', 'fr', 'France' ,'france_masque.png', 'france.png', $info_dpt_france, $info_table_action);
182
 
182
 
183
// Une fois l'arborescence créée on lance la méthode donnerFormulaireImage() pour récuperer le formulaire de la carte
183
// Une fois l'arborescence créée on lance la méthode donnerFormulaireImage() pour récuperer le formulaire de la carte
184
// (dans $img). S'il n'y a pas de carte à afficher donnerFormulaireImage() renvoi false. On peut alors récupérer
184
// (dans $img). S'il n'y a pas de carte à afficher donnerFormulaireImage() renvoi false. On peut alors récupérer
185
// le niveau ou on en est grâce à $monde->historique (du type continent*namerique*ca).
185
// le niveau ou on en est grâce à $monde->historique (du type continent*namerique*ca).
186
$img = $monde->donnerFormulaireImage();
186
$img = $monde->donnerFormulaireImage();
187
 
187
 
188
// Test d'img
188
// Test d'img
189
if (!$img ) {
189
if (!$img ) {
190
    /** Inclusion du fichier d'affichage des infos sur les organismes d'une zone. */
190
    /** Inclusion du fichier d'affichage des infos sur les organismes d'une zone. */
191
    include_once BBOC_CHEMIN_RACINE.'bboc_organisme_liste.inc.php';
191
    include_once BBOC_CHEMIN_RACINE.'bboc_organisme_liste.inc.php';
192
} else {
192
} else {
193
    // Construction du titre de la carte et de l'historique de navigation dans les cartes
193
    // Construction du titre de la carte et de l'historique de navigation dans les cartes
194
    $historique_carte = new Carto_Historique($monde, '&gt;', 'lien_non_souligne');
194
    $historique_carte = new Carto_Historique($monde, '&gt;', 'lien_non_souligne');
195
    $tab = explode('*',$monde->historique);
195
    $tab = explode('*',$monde->historique);
196
    $id_carte = $tab[(count($tab)-1)];
196
    $id_carte = $tab[(count($tab)-1)];
197
    $requete_06 =   'SELECT CDC_Titre_carte, CDC_Type_zone_carte, CDC_ID_Zone_geo_carte '.
197
    $requete_06 =   'SELECT CDC_Titre_carte, CDC_Type_zone_carte, CDC_ID_Zone_geo_carte '.
198
                    'FROM '.BB_BDD_NOM_CARTO.'.carto_DESCRIPTION_CARTE '.
198
                    'FROM '.BB_BDD_NOM_CARTO.'.carto_DESCRIPTION_CARTE '.
199
                    'WHERE CDC_ID_Carte = "'.$id_carte.'"';
199
                    'WHERE CDC_ID_Carte = "'.$id_carte.'"';
200
    $resultat_06 = mysql_query($requete_06) or die(BOG_afficherErreurSql(__FILE__, __LINE__, mysql_error(), $requete_06));
200
    $resultat_06 = mysql_query($requete_06) or die(BOG_afficherErreurSql(__FILE__, __LINE__, mysql_error(), $requete_06));
201
    $ligne_06 = mysql_fetch_object($resultat_06);
201
    $ligne_06 = mysql_fetch_object($resultat_06);
202
    $structure_nbre = bboc_consulterNbreStructure($id_carte, $ligne_06->CDC_Type_zone_carte, $ligne_06->CDC_ID_Zone_geo_carte);
202
    $structure_nbre = bboc_consulterNbreStructure($id_carte, $ligne_06->CDC_Type_zone_carte, $ligne_06->CDC_ID_Zone_geo_carte);
203
    $titre = '';
203
    $titre = '';
204
    if ($structure_nbre == 0) {
204
    if ($structure_nbre == 0) {
205
        $titre .= $ligne_06->CDC_Titre_carte.' : aucun organisme répertorié';
205
        $titre .= $ligne_06->CDC_Titre_carte.' : aucun organisme répertorié';
206
    } else if ($structure_nbre == 1) {
206
    } else if ($structure_nbre == 1) {
207
        $titre .= $ligne_06->CDC_Titre_carte.' : '.$structure_nbre.' organisme répertorié';
207
        $titre .= $ligne_06->CDC_Titre_carte.' : '.$structure_nbre.' organisme répertorié';
208
    } else {
208
    } else {
209
        $titre .= $ligne_06->CDC_Titre_carte.' : '.$structure_nbre.' organismes répertoriés';
209
        $titre .= $ligne_06->CDC_Titre_carte.' : '.$structure_nbre.' organismes répertoriés';
210
    }
210
    }
211
    
211
    
212
    // Sortie XHTML
212
    // Sortie XHTML
213
    $res .= '<h1 class="titre1_cartographie">'.$titre.'</h1>'."\n";
213
    $res .= '<h1 class="titre1_cartographie">'.$titre.'</h1>'."\n";
214
    $res .= '<p><strong>'.$historique_carte->afficherHistoriqueCarte().'</strong></p>'."\n";
214
    $res .= '<p><strong>'.$historique_carte->afficherHistoriqueCarte().'</strong></p>'."\n";
215
    
215
    
216
    $res .= '<h2 class="titre2_cartographie">Cliquez sur une zone de la carte pour zoomer.</h2>'."\n";
216
    $res .= '<h2 class="titre2_cartographie">Cliquez sur une zone de la carte pour zoomer.</h2>'."\n";
217
    $res .= '<p>La couleur est proportionnelle au nombre d\'organisations.'."\n";
217
    $res .= '<p>La couleur est proportionnelle au nombre d\'organisations.'."\n";
218
    
218
    
219
    $res .= $img;
219
    $res .= $img;
220
    
220
    
221
    $res .= '<h2 class="titre2_cartographie">'.'Avertissement et déni de responsabilité : '.'</h2>'."\n";
221
    $res .= '<h2 class="titre2_cartographie">'.'Avertissement et déni de responsabilité : '.'</h2>'."\n";
222
    $res .= '<p>'.'La représentation et l\'utilisation des frontières, des noms géographiques et autres données employés '."\n".
222
    $res .= '<p>'.'La représentation et l\'utilisation des frontières, des noms géographiques et autres données employés '."\n".
223
            'sur les cartes et utilisés dans les listes, les tableaux, les documents et les bases de données de ce site '."\n".
223
            'sur les cartes et utilisés dans les listes, les tableaux, les documents et les bases de données de ce site '."\n".
224
            'ne sont pas garanties sans erreurs, de même qu\'elles n\'engagent pas la responsabilité de l\'association '."\n".
224
            'ne sont pas garanties sans erreurs, de même qu\'elles n\'engagent pas la responsabilité de l\'association '."\n".
225
            'ni n\'impliquent de reconnaissance officielle de sa part.'.'</p>'."\n";
225
            'ni n\'impliquent de reconnaissance officielle de sa part.'.'</p>'."\n";
226
}
226
}
227
 
227
 
228
// +------------------------------------------------------------------------------------------------------+
228
// +------------------------------------------------------------------------------------------------------+
229
// |                                            PIED du PROGRAMME                                         |
229
// |                                            PIED du PROGRAMME                                         |
230
// +------------------------------------------------------------------------------------------------------+
230
// +------------------------------------------------------------------------------------------------------+
231
$res .= '<!-- BiblioBota - Organisme Carto : FIN -->'."\n";
231
$res .= '<!-- BiblioBota - Organisme Carto : FIN -->'."\n";
232
$sortie = $res;
232
$sortie = $res;
233
 
233
 
234
/* +--Fin du code ----------------------------------------------------------------------------------------+
234
/* +--Fin du code ----------------------------------------------------------------------------------------+
235
*
235
*
236
* $Log: not supported by cvs2svn $
236
* $Log: bb_organisme_carto.php,v $
237
* Revision 1.4  2005/05/30 09:10:26  jpm
237
* Revision 1.4  2005/05/30 09:10:26  jpm
238
* Ajout de class aux titres!
238
* Ajout de class aux titres!
239
*
239
*
240
* Revision 1.3  2005/05/17 10:10:08  jpm
240
* Revision 1.3  2005/05/17 10:10:08  jpm
241
* Correction des bogues avant mise en ligne du site v4.
241
* Correction des bogues avant mise en ligne du site v4.
242
*
242
*
243
* Revision 1.2  2005/04/13 10:12:29  jpm
243
* Revision 1.2  2005/04/13 10:12:29  jpm
244
* Ajout de la constante indiquant la bdd des tables de la carto.
244
* Ajout de la constante indiquant la bdd des tables de la carto.
245
*
245
*
246
* Revision 1.1  2005/03/01 15:19:17  jpm
246
* Revision 1.1  2005/03/01 15:19:17  jpm
247
* Ajout des fichiers principaux de l'application Organisme Carto de Biblio Bota.
247
* Ajout des fichiers principaux de l'application Organisme Carto de Biblio Bota.
248
*
248
*
249
*
249
*
250
* +-- Fin du code ----------------------------------------------------------------------------------------+
250
* +-- Fin du code ----------------------------------------------------------------------------------------+
251
*/
251
*/
252
?>
252
?>