Subversion Repositories Applications.bazar

Rev

Rev 140 | Rev 144 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 140 Rev 142
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.php,v 1.51 2006-07-18 14:17:32 alexandre_tb Exp $
22
// CVS : $Id: bazar.fonct.php,v 1.52 2006-07-25 13:05:00 alexandre_tb Exp $
23
/**
23
/**
24
*
24
*
25
* Fonctions du module bazar
25
* Fonctions du module bazar
26
* 
26
* 
27
*
27
*
Line 29... Line 29...
29
//Auteur original :
29
//Auteur original :
30
*@author        Alexandre Granier <alexandre@tela-botanica.org>
30
*@author        Alexandre Granier <alexandre@tela-botanica.org>
31
*@author        Florian Schmitt <florian@ecole-et-nature.org>
31
*@author        Florian Schmitt <florian@ecole-et-nature.org>
32
//Autres auteurs :
32
//Autres auteurs :
33
*@copyright     Tela-Botanica 2000-2004
33
*@copyright     Tela-Botanica 2000-2004
34
*@version       $Revision: 1.51 $ $Date: 2006-07-18 14:17:32 $
34
*@version       $Revision: 1.52 $ $Date: 2006-07-25 13:05:00 $
35
// +------------------------------------------------------------------------------------------------------+
35
// +------------------------------------------------------------------------------------------------------+
36
*/
36
*/
Line 37... Line 37...
37
 
37
 
38
// +------------------------------------------------------------------------------------------------------+
38
// +------------------------------------------------------------------------------------------------------+
Line 841... Line 841...
841
	}
841
	}
842
	//verification de l'existence de la fiche
842
	//verification de l'existence de la fiche
843
	$requete = 'SELECT bf_id_fiche FROM bazar_fiche WHERE bf_id_fiche='.$idfiche;
843
	$requete = 'SELECT bf_id_fiche FROM bazar_fiche WHERE bf_id_fiche='.$idfiche;
844
	$resultat = $GLOBALS['_BAZAR_']['db']->query($requete) ;
844
	$resultat = $GLOBALS['_BAZAR_']['db']->query($requete) ;
845
        if (DB::isError($resultat)) {
845
        if (DB::isError($resultat)) {
846
            die ($resultat->getMessage().$resultat->getDebugInfo()) ;
846
            echo ($resultat->getMessage().$resultat->getDebugInfo()) ;
847
        }
847
        }
848
	if ($resultat->numRows()==0) {
848
	if ($resultat->numRows()==0) {
849
		//creation d'une fiche temporaire avec l'image
849
		//creation d'une fiche temporaire avec l'image
850
	$requete = 'INSERT INTO bazar_fiche SET bf_id_fiche='.$idfiche.', bf_ce_nature='.$GLOBALS['_BAZAR_']['id_typeannonce'].', bf_ce_utilisateur='.$GLOBALS['id_user'].', bf_date_creation_fiche=NOW(), bf_url_image="'.$_FILES['image']['name'].'", '.
850
	$requete = 'INSERT INTO bazar_fiche SET bf_id_fiche='.$idfiche.', bf_ce_nature='.$GLOBALS['_BAZAR_']['id_typeannonce'].', bf_ce_utilisateur='.$GLOBALS['id_user'].', bf_date_creation_fiche=NOW(), bf_url_image="'.$_FILES['image']['name'].'", '.
851
		   'bf_titre="annonce temporaire"';
851
		   'bf_titre="annonce temporaire"';
Line 1219... Line 1219...
1219
}
1219
}
Line 1220... Line 1220...
1220
 
1220
 
1221
/* +--Fin du code ----------------------------------------------------------------------------------------+
1221
/* +--Fin du code ----------------------------------------------------------------------------------------+
1222
*
1222
*
-
 
1223
* $Log: not supported by cvs2svn $
-
 
1224
* Revision 1.51  2006/07/18 14:17:32  alexandre_tb
-
 
1225
* Ajout d'un formulaire d identification
1223
* $Log: not supported by cvs2svn $
1226
*
1224
* Revision 1.50  2006/06/21 08:37:59  alexandre_tb
1227
* Revision 1.50  2006/06/21 08:37:59  alexandre_tb
1225
* Correction de bug, d'un appel constant (....) qui ne fonctionnais plus.
1228
* Correction de bug, d'un appel constant (....) qui ne fonctionnais plus.
1226
*
1229
*
1227
* Revision 1.49  2006/06/02 09:29:07  florian
1230
* Revision 1.49  2006/06/02 09:29:07  florian