- //sinon
- $birth = sprintf("%s-%s-%s", substr(Env::v('birth'), 4, 4),
- substr(Env::v('birth'), 2, 2),
- substr(Env::v('birth'), 0, 2));
- XDB::execute("UPDATE auth_user_md5
- SET naissance={?}
- WHERE user_id={?}", $birth,
- S::v('uid'));
- $page->assign('etat_naissance', 'ok');
- return;
- }
-
- $page->assign('etat_naissance', 'query');
- return; // on affiche le formulaire pour naissance
- }
-
- //doit-on faire un update ?
- if (Env::has('modifier') || Env::has('suivant')) {
- require_once dirname(__FILE__) . "/profile/get_{$opened_tab}.inc.php";
- require_once dirname(__FILE__) . "/profile/verif_{$opened_tab}.inc.php";
-
- if($page->nb_errs()) {
- require_once dirname(__FILE__) . "/profile/assign_{$opened_tab}.inc.php";
- $page->assign('onglet', $opened_tab);
- $page->assign('onglet_tpl', "profile/$opened_tab.tpl");
- return;
- }
-
- $date=date("Y-m-j");//nouvelle date de mise a jour
+ $wiz = new PlWizard('Profil', 'core/plwizard.tpl', true);
+ require_once dirname(__FILE__) . '/profile/page.inc.php';
+ $wiz->addPage('ProfileGeneral', 'Général', 'general');
+ $wiz->addPage('ProfileAddress', 'Adresses personnelles', 'adresses');
+ $wiz->addPage('ProfileGroups', 'Groupes X - Binets', 'poly');
+ $wiz->addPage('ProfileDeco', 'Décorations - Medals', 'deco');
+ $wiz->addPage('ProfilePro', 'Informations professionnelles', 'emploi');
+ $wiz->addPage('ProfileSkills', 'Compétences diverses', 'skill');
+ $wiz->addPage('ProfileMentor', 'Mentoring', 'mentor');
+ $wiz->apply($page, 'profile/edit', $opened_tab);