Subversion Repositories Applications.papyrus

Rev

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

Rev 741 Rev 760
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: inscription.fonct.php,v 1.10 2006-02-28 14:02:20 alexandre_tb Exp $
22
// CVS : $Id: inscription.fonct.php,v 1.11 2006-03-02 16:57:31 alexandre_tb Exp $
23
// CVS : $Id: inscription.fonct.php,v 1.10 2006-02-28 14:02:20 alexandre_tb Exp $
23
// CVS : $Id: inscription.fonct.php,v 1.11 2006-03-02 16:57:31 alexandre_tb Exp $
24
/**
24
/**
25
* Fonctions du module inscription
25
* Fonctions du module inscription
26
*
26
*
27
* Fonctions du module inscription
27
* Fonctions du module inscription
28
*
28
*
Line 30... Line 30...
30
//Auteur original :
30
//Auteur original :
31
*@author        Alexandre Granier <alexandre@tela-botanica.org>
31
*@author        Alexandre Granier <alexandre@tela-botanica.org>
32
//Autres auteurs :
32
//Autres auteurs :
33
*@author        Aucun
33
*@author        Aucun
34
*@copyright     Tela-Botanica 2000-2004
34
*@copyright     Tela-Botanica 2000-2004
35
*@version       $Revision: 1.10 $ $Date: 2006-02-28 14:02:20 $
35
*@version       $Revision: 1.11 $ $Date: 2006-03-02 16:57:31 $
36
*@version       $Revision: 1.10 $ $Date: 2006-02-28 14:02:20 $
36
*@version       $Revision: 1.11 $ $Date: 2006-03-02 16:57:31 $
37
// +------------------------------------------------------------------------------------------------------+
37
// +------------------------------------------------------------------------------------------------------+
38
*/
38
*/
Line 39... Line 39...
39
 
39
 
40
// +------------------------------------------------------------------------------------------------------+
40
// +------------------------------------------------------------------------------------------------------+
Line 208... Line 208...
208
    $req = INS_CHAMPS_NOM.'="'.addslashes($valeur['nom']).'", ';
208
    $req = INS_CHAMPS_NOM.'="'.addslashes($valeur['nom']).'", ';
209
    // Initialisation de variable pour éviter des notices
209
    // Initialisation de variable pour éviter des notices
210
    foreach (array ('adresse_1', 'adresse_2', 'ville', 'telephone', 'fax', 'site') as $val) {
210
    foreach (array ('adresse_1', 'adresse_2', 'ville', 'telephone', 'fax', 'site') as $val) {
211
    	if (!isset ($valeur[$val])) $valeur[$val] = '' ;   	
211
    	if (!isset ($valeur[$val])) $valeur[$val] = '' ;   	
212
    }
212
    }
213
    if (isset($valeur['prenom'])) {
-
 
-
 
213
 
214
    	$req .= INS_CHAMPS_PRENOM.'="'.$valeur['prenom'].'", ';
214
    $req .= INS_CHAMPS_NOM_WIKINI.'="'.$valeur['nom_wiki'].'", '  ;
215
    	if (INS_UTILISE_WIKINI) $req .= INS_CHAMPS_NOM_WIKINI.'="'.genere_nom_wiki($valeur['prenom'],$valeur['nom']).'", ' ;
-
 
216
    } elseif (INS_UTILISE_WIKINI) {
-
 
217
    	$req .= INS_CHAMPS_NOM_WIKINI.'="'.genere_nom_wiki('Structure',$valeur['nom']).'", ' ;
-
 
218
    }
-
 
219
    $req .= INS_CHAMPS_MAIL.'="'.addslashes($valeur['email']).'", ' ;
215
    $req .= INS_CHAMPS_MAIL.'="'.addslashes($valeur['email']).'", ' ;
220
    $req .= INS_CHAMPS_PASSE.'="'.md5($valeur['mot_de_passe']).'", '.
216
    $req .= INS_CHAMPS_PASSE.'="'.md5($valeur['mot_de_passe']).'", '.
221
            INS_CHAMPS_PAYS.'="'.addslashes($valeur['pays']).'", '.
217
            INS_CHAMPS_PAYS.'="'.addslashes($valeur['pays']).'", '.
222
            INS_CHAMPS_ADRESSE_1.'="'.addslashes($valeur['adresse_1']).'", '.
218
            INS_CHAMPS_ADRESSE_1.'="'.addslashes($valeur['adresse_1']).'", '.
223
            INS_CHAMPS_ADRESSE_2.'="'.addslashes($valeur['adresse_2']).'", '.
219
            INS_CHAMPS_ADRESSE_2.'="'.addslashes($valeur['adresse_2']).'", '.
Line 289... Line 285...
289
    $valeurs_par_defaut['ville'] = $ligne[INS_CHAMPS_VILLE] ;
285
    $valeurs_par_defaut['ville'] = $ligne[INS_CHAMPS_VILLE] ;
290
    $valeurs_par_defaut['adresse_1'] = $ligne[INS_CHAMPS_ADRESSE_1] ;
286
    $valeurs_par_defaut['adresse_1'] = $ligne[INS_CHAMPS_ADRESSE_1] ;
291
    $valeurs_par_defaut['adresse_2'] = $ligne[INS_CHAMPS_ADRESSE_2] ;
287
    $valeurs_par_defaut['adresse_2'] = $ligne[INS_CHAMPS_ADRESSE_2] ;
292
    $valeurs_par_defaut['telephone'] = $ligne[INS_CHAMPS_TELEPHONE] ;
288
    $valeurs_par_defaut['telephone'] = $ligne[INS_CHAMPS_TELEPHONE] ;
293
    $valeurs_par_defaut['fax'] = $ligne[INS_CHAMPS_FAX] ;
289
    $valeurs_par_defaut['fax'] = $ligne[INS_CHAMPS_FAX] ;
-
 
290
    if (INS_CHAMPS_STRUCTURE != '') {
294
    if (INS_CHAMPS_STRUCTURE != '') $valeurs_par_defaut['structure'] = $ligne[INS_CHAMPS_STRUCTURE] ;
291
    	$valeurs_par_defaut['structure'] = $ligne[INS_CHAMPS_STRUCTURE] ;
-
 
292
    	$valeurs_par_defaut['type_structure'] = $ligne['a_type_structure'];	
-
 
293
    }
295
    $valeurs_par_defaut['site'] = $ligne[INS_CHAMPS_SITE_INTERNET] ;
294
    $valeurs_par_defaut['site'] = $ligne[INS_CHAMPS_SITE_INTERNET] ;
296
    $valeurs_par_defaut['lettre'] = $ligne[INS_CHAMPS_LETTRE] ;
295
    $valeurs_par_defaut['lettre'] = $ligne[INS_CHAMPS_LETTRE] ;
297
    $valeurs_par_defaut['visible'] = $ligne[INS_CHAMPS_VISIBLE] ;
296
    $valeurs_par_defaut['visible'] = $ligne[INS_CHAMPS_VISIBLE] ;
298
    $valeurs_par_defaut['sigle_structure'] = $ligne[INS_CHAMPS_SIGLE_STRUCTURE] ;
297
    $valeurs_par_defaut['sigle_structure'] = $ligne[INS_CHAMPS_SIGLE_STRUCTURE] ;
299
    if (INS_CHAMPS_NUM_AGREMENT != '') $valeurs_par_defaut['num_agrement'] = $ligne[INS_CHAMPS_NUM_AGREMENT] ;
298
    if (INS_CHAMPS_NUM_AGREMENT != '') $valeurs_par_defaut['num_agrement'] = $ligne[INS_CHAMPS_NUM_AGREMENT] ;
Line 323... Line 322...
323
    } else {
322
    } else {
324
    	$res = '<h1>'.INS_FICHE_PERSONNELLE.'</h1>'."\n" ;
323
    	$res = '<h1>'.INS_FICHE_PERSONNELLE.'</h1>'."\n" ;
325
    	$res .= '<h2>'.$ligne[INS_CHAMPS_PRENOM].' '.$ligne[INS_CHAMPS_NOM].'</h2>'."\n";
324
    	$res .= '<h2>'.$ligne[INS_CHAMPS_PRENOM].' '.$ligne[INS_CHAMPS_NOM].'</h2>'."\n";
326
    	$res .= '<dl class="affiche_infos">'."\n";
325
    	$res .= '<dl class="affiche_infos">'."\n";
327
    }
326
    }
-
 
327
    
328
    $res .= ligne_inscription(INS_ADRESSE_1, $ligne[INS_CHAMPS_ADRESSE_1]) ;
328
    $res .= ligne_inscription(INS_ADRESSE_1, $ligne[INS_CHAMPS_ADRESSE_1]) ;
329
    $res .= ligne_inscription(INS_ADRESSE_2, $ligne[INS_CHAMPS_ADRESSE_2]) ;
329
    $res .= ligne_inscription(INS_ADRESSE_2, $ligne[INS_CHAMPS_ADRESSE_2]) ;
330
    $res .= ligne_inscription(INS_CODE_POSTAL, $ligne[INS_CHAMPS_CODE_POSTAL]) ;
330
    $res .= ligne_inscription(INS_CODE_POSTAL, $ligne[INS_CHAMPS_CODE_POSTAL]) ;
331
    $res .= ligne_inscription(INS_VILLE, $ligne[INS_CHAMPS_VILLE]) ;
331
    $res .= ligne_inscription(INS_VILLE, $ligne[INS_CHAMPS_VILLE]) ;
332
    $pays = new ListeDePays($GLOBALS['ins_db']) ;
332
    $pays = new ListeDePays($GLOBALS['ins_db']) ;
Line 642... Line 642...
642
}
642
}
Line 643... Line 643...
643
 
643
 
644
/* +--Fin du code ----------------------------------------------------------------------------------------+
644
/* +--Fin du code ----------------------------------------------------------------------------------------+
645
*
645
*
-
 
646
* $Log: not supported by cvs2svn $
-
 
647
* Revision 1.10  2006/02/28 14:02:20  alexandre_tb
-
 
648
* suppression des insertion dans les tables du bazar
646
* $Log: not supported by cvs2svn $
649
*
647
* Revision 1.9  2006/02/14 10:19:10  alexandre_tb
650
* Revision 1.9  2006/02/14 10:19:10  alexandre_tb
648
* Mise en place des templates
651
* Mise en place des templates
649
* CREATE TABLE `inscription_template` (
652
* CREATE TABLE `inscription_template` (
650
*   `it_id_template` smallint(5) unsigned NOT NULL default '0',
653
*   `it_id_template` smallint(5) unsigned NOT NULL default '0',