//Autres auteurs : *@author Jean-Pascal MILCENT *@copyright Tela-Botanica 2000-2004 *@version $Revision: 1.1 $ $Date: 2005-11-23 10:22:25 $ // +------------------------------------------------------------------------------------------------------+ */ // +------------------------------------------------------------------------------------------------------+ // | ENTETE du PROGRAMME | // +------------------------------------------------------------------------------------------------------+ // +------------------------------------------------------------------------------------------------------+ // | CORPS du PROGRAMME | // +------------------------------------------------------------------------------------------------------+ if ($var_biblio['open_proposer_str'] == 1) { // Si Open Moderation est ouvert, alors proposer la modification des données $the_url_edit = BB_URL_COURANTE_ADMIN.'&action=edit&ensemble=str&ref='.$tableau['str']; $sortie .= '

'."\n"; $sortie .= ''."\n". ''.'Modifier la fiche structure'.''."\n". ''."\n"; $sortie .= ''.'Corriger la fiche...'.''."\n"; $sortie .= '

'."\n"; } $query = 'SELECT * '. 'FROM '.$tbl['str'].', '.$tbl['pays'].', '.$tbl['typestr'].' '. 'WHERE ('.$tbl['str'].'.B_S_IDSTR = '.$tableau['str'].') '. 'AND ('.$tbl['str'].'.B_S_TYPESTR = '.$tbl['typestr'].'.B_TYPSTR_ID) '. 'AND ('.$tbl['str'].'.B_S_PAYS = '.$tbl['pays'].'.GC_ID) '. 'AND ('.$tbl['pays'].'.GC_LOCALE = "'.$GLOBALS['_GEN_commun']['i18n'].'")'; $do_query = mysql_query($query) or die('Erreur de requête (choix de structure) : '.$query); $nb = mysql_num_rows($do_query); if ($nb == 0) { $sortie .= '

'. 'Erreur ! :

aucune structure ne correspond à l\'identifiant str='.$tableau['str'].'.'. '

'."\n"; } else if ($nb > 1) { $sortie .= '

'. 'Erreur ! :

le moteur bbc_information a trouvé plusieurs données pour l\'identifiant str='.$tableau['str'].'.'. '

'."\n"; } else { $row = mysql_fetch_object($do_query); $get_nom = $row->B_S_NOM; $get_sigle = $row->B_S_SIGLE; $get_service = $row->B_S_SERVICE; $get_typestr = $row->B_TYPSTR_LABEL; $get_numtypestr = $row->B_S_TYPESTR; $get_datecreation = $row->B_S_DATECREATION; $get_nbrperso = $row->B_S_NBRPERSO; $get_vocactiv = $row->B_S_VOCACTIV; $get_adresse1 = $row->B_S_ADRESSE1; $get_adresse2 = $row->B_S_ADRESSE2; $get_cp = $row->B_S_CODEPOSTAL; $get_ville = $row->B_S_VILLE; $get_pays = $row->GC_NAME; $get_tel = $row->B_S_TEL; $get_fax = $row->B_S_FAX; $get_mail = $row->B_S_MAIL; $get_image = $row->B_S_IMAGE; $get_comment = $row->B_S_COMMENT; $get_majfiche = $row->B_S_MAJFICHE; mysql_free_result($do_query); // Titre de la structure $sortie .= '

'; $sortie .= $get_nom; if ($get_sigle != '') { $sortie .= ' ('.$get_sigle.')'; } $sortie .= '

'."\n"; // Type de structure et vocation $sortie .= '

'.'Type de structure, vocation'.'

'."\n"; $sortie .= '

'."\n"; if ($get_typestr != '') { $sortie .= ''.'Type de structure :'.' '.$get_typestr.''."\n"; } if ($get_vocactiv != '') { if ($get_typestr != '') { $sortie .= '
'."\n"; } $sortie .= ''.'Vocation / Activité :'.' '.$get_vocactiv.''."\n"; } $sortie .= '

'."\n"; // Bloc d'adresse $sortie .= '

'.'Adresse'.'

'."\n"; $sortie .= '

'."\n"; if ($get_service != '') { $sortie .= $get_service."\n"; } if ($get_adresse1 != '') { if ($get_service != '') { $sortie .= '
'."\n"; } $sortie .= $get_adresse1."\n"; } if ($get_adresse2 != '') { if (($get_service != '') || ($get_adresse1 != '')) { $sortie .= '
'."\n"; } $sortie .= $get_adresse2."\n"; } if ($get_cp != '') { if (($get_service != '') || ($get_adresse1 != '') || ($get_adresse2 != '')) { $sortie .= '
'."\n"; } $sortie .= $get_cp."\n"; } if ($get_ville != '') { $sortie .= ' '.$get_ville."\n"; } if ($get_pays != '') { if (($get_service != '') || ($get_adresse1 != '') || ($get_ville != '') || ($get_cp != '')) { $sortie .= '
'."\n"; } $sortie .= $get_pays."\n"; } // Bloc contact $sortie .= '

'."\n"; if ($get_tel != '') { $sortie .= ''.'Téléphone :'.' '.$get_tel.''."\n"; } if ($get_fax != '') { if ($get_tel != '') { $sortie .= '
'."\n"; } $sortie .= ''.'Fax :'.' '.$get_fax.''."\n"; } if ($get_mail != '') { if (($get_fax != '') || ($get_tel != '')) { $sortie .= '
'."\n"; } $sortie .= ''.'Courriel :'.' '. ' '. ''.$get_mail.''. ''."\n"; } // Logo ou image de la structure if ($get_image != '') { $sortie .= ''; } $sortie .= '

'."\n"; // Bloc info supplémentaires if ($get_nbrperso > 0 OR $get_datecreation > 0 OR $get_comment != '') { $sortie .= '

'.'Informations supplémentaires'.'

'."\n"; $sortie .= '

'."\n"; // Calcul de la date de création if ($get_datecreation > 0) { $sortie .= ''.'Date de création :'.' '. ''.FormateDateYYYYMMJJ($get_datecreation).''."\n"; } // Nbre de salariés ou de membres if ($get_nbrperso > 0) { if ($get_datecreation > 0) { $sortie .= '
'."\n"; } if ($get_numtypestr == 3) { $sticker = 'salariés'; } else { $sticker = 'membres'; } $sortie .= ''.'Nombre de '.$sticker.' :'.' '. ''.$get_nbrperso.''."\n"; } // Info - commentaires if ($get_comment != '') { if (($get_datecreation > 0) || ($get_nbrperso > 0)) { $sortie .= '
'."\n"; } $sortie .= ''.'Informations complémentaires :'.' '. ''.$get_comment.''."\n"; } $sortie .= '

'."\n"; } // A partir d'ici on affiche les liens de la structure $sortie .= '

'.'Liens web'.'

'."\n"; $sortie .= '

'."\n"; $query_lk = 'SELECT '.$tbl['link'].'.* '. 'FROM '.$tbl['link'].' '. 'WHERE '.$tbl['link'].'.B_L_LKSTR = '.$tableau['str'].' '. 'AND B_L_CACHER = 0 '. 'ORDER BY B_L_TITRE'; $do_query_lk = mysql_query($query_lk) or die('Erreur de requête (liens web) : '.$query_lk); $nb_lk = mysql_num_rows($do_query_lk); if ($nb_lk == 0) { $sortie .= 'Pas de lien web référencé.'; } else { $o = 1; while ($row = mysql_fetch_object($do_query_lk)) { $idlink = $row->B_L_IDLINK; $titrelink = $row->B_L_TITRE; $urllink = $row->B_L_URL; $resumlink = $row->B_L_RESUMCLE; $comlink = $row->B_L_COMMENT; $datelink = $row->B_L_MAJFICHE; $get_part = $row->B_L_PARTENAIRE; $get_ref = $row->B_L_REFERENCE; $sortie .= ''.'Lien Web'.' '."\n"; $sortie .= ''; if ($titrelink != '') { $sortie .= $titrelink; } else { $sortie .= $urllink; } $sortie .= ''."\n"; if ($resumlink != '') { $sortie .= ' - '.$resumlink; } if ($comlink != '') { $sortie .= ' - '.$comlink; } // if ($datelink > 0) $sortie .= " [".date('d/m/Y',$datelink)."]"; if (($nb_lk - $o) > 0) { $sortie .= '
'."\n"; } if ($get_ref == 1) { $sortie .= ' '.'Site Référence'.' '."\n"; } if ($get_part == 1) { $sortie .= ' '.'Site Partenaire de Tela Botanica'.' '."\n"; } $o++; } } $sortie .= '

'."\n"; mysql_free_result($do_query_lk); // Là on affiche les Voir Aussi Structures ... si y'en a $UnVoirAussi = new VoirAussi($tableau['str'],$tbl['str']); if ($UnVoirAussi->NbVA > 0) { $liste_va = $UnVoirAussi->ListerVoirAussi(); $sortie .= '

'.'Voir Aussi'.'

'."\n"; for ($i = 0; $i == (($UnVoirAussi->NbVA) - 1); $i++) { $sortie .= ''.$liste_va[$i]['icon_alt'].' '; $sortie .= ''.$liste_va[$i]['texte'].''; if ($liste_va[$i]['desc'] != '') { $sortie .= ' - '.''.$liste_va[$i]['desc'].''; } if (($i != 0) && ($i < ($UnVoirAussi->NbVA))) { $sortie .= '
'."\n"; } } $sortie .= '
'."\n"; } // Affichage des méta données $sortie .= '

'. 'Dernière mise à jour de la fiche : '.date('d/m/Y',$get_majfiche).' - fiche '.$tableau['str']. '

'."\n\n"; } /* +--Fin du code ----------------------------------------------------------------------------------------+ * * $Log: not supported by cvs2svn $ * Revision 1.2 2005/05/17 10:10:08 jpm * Correction des bogues avant mise en ligne du site v4. * * Revision 1.1 2004/09/16 12:06:31 jpm * Décomposition du fichier information en plusieurs fichiers. * * * +-- Fin du code ----------------------------------------------------------------------------------------+ */ ?>