Line 17... |
Line 17... |
17 |
// | |
|
17 |
// | |
|
18 |
// | You should have received a copy of the GNU Lesser General Public |
|
18 |
// | You should have received a copy of the GNU Lesser General Public |
|
19 |
// | License along with this library; if not, write to the Free Software |
|
19 |
// | License along with this library; if not, write to the Free Software |
|
20 |
// | Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA |
|
20 |
// | Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA |
|
21 |
// +------------------------------------------------------------------------------------------------------+
|
21 |
// +------------------------------------------------------------------------------------------------------+
|
22 |
// CVS : $Id: bazar.fonct.rss.php,v 1.97 2007-10-24 08:56:27 alexandre_tb Exp $
|
22 |
// CVS : $Id: bazar.fonct.rss.php,v 1.98 2007-10-24 13:27:45 alexandre_tb Exp $
|
23 |
/**
|
23 |
/**
|
24 |
*
|
24 |
*
|
25 |
*@package bazar
|
25 |
*@package bazar
|
26 |
//Auteur original :
|
26 |
//Auteur original :
|
27 |
*@author Alexandre GRANIER <alexandre@tela-botanica.org>
|
27 |
*@author Alexandre GRANIER <alexandre@tela-botanica.org>
|
28 |
*@author Florian Schmitt <florian@ecole-et-nature.org>
|
28 |
*@author Florian Schmitt <florian@ecole-et-nature.org>
|
29 |
//Autres auteurs :
|
29 |
//Autres auteurs :
|
30 |
*@copyright Tela-Botanica 2000-2006
|
30 |
*@copyright Tela-Botanica 2000-2006
|
31 |
*@version $Revision: 1.97 $
|
31 |
*@version $Revision: 1.98 $
|
32 |
// +------------------------------------------------------------------------------------------------------+
|
32 |
// +------------------------------------------------------------------------------------------------------+
|
33 |
*/
|
33 |
*/
|
Line 34... |
Line 34... |
34 |
|
34 |
|
35 |
// +------------------------------------------------------------------------------------------------------+
|
35 |
// +------------------------------------------------------------------------------------------------------+
|
Line 161... |
Line 161... |
161 |
$resultat = $GLOBALS['_BAZAR_']['db']->query($requete) ;
|
161 |
$resultat = $GLOBALS['_BAZAR_']['db']->query($requete) ;
|
162 |
}
|
162 |
}
|
163 |
}
|
163 |
}
|
164 |
}
|
164 |
}
|
165 |
$requete = 'SELECT *,bn_label_nature FROM bazar_fiche,bazar_nature WHERE bf_ce_nature=bn_id_nature and bf_id_fiche='.$GLOBALS['_BAZAR_']['id_fiche'];
|
165 |
$requete = 'SELECT *,bn_label_nature FROM bazar_fiche,bazar_nature WHERE bf_ce_nature=bn_id_nature and bf_id_fiche='.$GLOBALS['_BAZAR_']['id_fiche'];
|
166 |
|
- |
|
- |
|
166 |
if (isset($GLOBALS['_BAZAR_']['langue'])) $requete .= ' and bn_ce_i18n like "'.$GLOBALS['_BAZAR_']['langue'].'"';
|
167 |
$resultat = $GLOBALS['_BAZAR_']['db']->query($requete) ;
|
167 |
$resultat = $GLOBALS['_BAZAR_']['db']->query($requete) ;
|
168 |
(DB::isError($resultat)) ? die(BOG_afficherErreurSql(__FILE__, __LINE__, $resultat->getMessage(), $requete))
|
168 |
(DB::isError($resultat)) ? die (BOG_afficherErreurSql(__FILE__, __LINE__, $resultat->getMessage(), $requete))
|
169 |
: '';
|
169 |
: '';
|
Line 170... |
Line 170... |
170 |
|
170 |
|
171 |
$ligne = $resultat->fetchRow(DB_FETCHMODE_ASSOC) ;
|
171 |
$ligne = $resultat->fetchRow(DB_FETCHMODE_ASSOC) ;
|
172 |
if (!isset($GLOBALS['_BAZAR_']['typeannonce'])) $GLOBALS['_BAZAR_']['typeannonce'] = $ligne['bf_ce_nature'];
|
172 |
if (!isset($GLOBALS['_BAZAR_']['typeannonce'])) $GLOBALS['_BAZAR_']['typeannonce'] = $ligne['bf_ce_nature'];
|
Line 176... |
Line 176... |
176 |
|
176 |
|
177 |
// Si on vient de l applette calendrier, $GLOBALS['_BAZAR_']['id_typeannonce'] est vide ...
|
177 |
// Si on vient de l applette calendrier, $GLOBALS['_BAZAR_']['id_typeannonce'] est vide ...
|
178 |
// mais on dispose de la constante BAZ_NUM_ANNONCE_CALENDRIER
|
178 |
// mais on dispose de la constante BAZ_NUM_ANNONCE_CALENDRIER
|
Line 179... |
Line 179... |
179 |
if (!isset($GLOBALS['_BAZAR_']['id_typeannonce']) && defined('BAZ_NUM_ANNONCE_CALENDRIER')) $GLOBALS['_BAZAR_']['id_typeannonce'] = BAZ_NUM_ANNONCE_CALENDRIER;
|
179 |
if (!isset($GLOBALS['_BAZAR_']['id_typeannonce']) && defined('BAZ_NUM_ANNONCE_CALENDRIER')) $GLOBALS['_BAZAR_']['id_typeannonce'] = BAZ_NUM_ANNONCE_CALENDRIER;
|
180 |
|
180 |
|
181 |
$requete='SELECT bn_id_nature, bn_template, bn_commentaire, bn_label_class,bn_label_nature FROM bazar_nature ';
|
- |
|
- |
|
181 |
$requete='SELECT bn_id_nature, bn_template, bn_commentaire, bn_label_class,bn_label_nature FROM bazar_nature where 1';
|
182 |
if ($GLOBALS['_BAZAR_']['id_typeannonce'] != 'toutes') $requete .= 'WHERE bn_id_nature in ('.$GLOBALS['_BAZAR_']['id_typeannonce'].')';
|
182 |
if ($GLOBALS['_BAZAR_']['id_typeannonce'] != 'toutes') $requete .= ' and bn_id_nature in ('.$GLOBALS['_BAZAR_']['id_typeannonce'].')';
|
183 |
|
183 |
if (isset($GLOBALS['_BAZAR_']['langue'])) $requete .= ' and bn_ce_i18n like "'.$GLOBALS['_BAZAR_']['langue'].'"';
|
184 |
$resultat = $GLOBALS['_BAZAR_']['db']->query($requete) ;
|
184 |
$resultat = $GLOBALS['_BAZAR_']['db']->query($requete) ;
|
185 |
if (DB::isError($resultat)) {
|
185 |
if (DB::isError($resultat)) {
|
186 |
return ($resultat->getMessage().$resultat->getDebugInfo()) ;
|
186 |
return ($resultat->getMessage().$resultat->getDebugInfo()) ;
|
Line 1239... |
Line 1239... |
1239 |
}
|
1239 |
}
|
Line 1240... |
Line 1240... |
1240 |
|
1240 |
|
1241 |
/* +--Fin du code ----------------------------------------------------------------------------------------+
|
1241 |
/* +--Fin du code ----------------------------------------------------------------------------------------+
|
1242 |
*
|
1242 |
*
|
- |
|
1243 |
* $Log: not supported by cvs2svn $
|
- |
|
1244 |
* Revision 1.97 2007-10-24 08:56:27 alexandre_tb
|
- |
|
1245 |
* bug d'affichage multiple lorsqu'il y a +sieurs langues
|
1243 |
* $Log: not supported by cvs2svn $
|
1246 |
*
|
1244 |
* Revision 1.96 2007-10-22 10:09:21 florian
|
1247 |
* Revision 1.96 2007-10-22 10:09:21 florian
|
1245 |
* correction template
|
1248 |
* correction template
|
1246 |
*
|
1249 |
*
|
1247 |
* Revision 1.95 2007-10-22 09:22:02 alexandre_tb
|
1250 |
* Revision 1.95 2007-10-22 09:22:02 alexandre_tb
|