14 if (!defined(
'IN_PEEL')) {
19 if (!function_exists(
'get_user_change_params_form')) {
30 $tpl =
$GLOBALS[
'tplEngine']->createTemplate(
'user_change_params_form.tpl');
36 $tpl->assign(
'verified_account_info', get_verified_account_info());
37 $tpl->assign(
'content_rows_info', (is_user_verified(
$_SESSION[
'session_utilisateur'][
'id_utilisateur'])?
'disabled="disabled"':
''));
39 $tpl->assign(
'content_rows_info',
'');
44 $domain=explode(
'@',
vb(
$frm[
'email']));
45 $email_explain= sprintf(
$GLOBALS[
'STR_EMAIL_BOUNCE_REPLACE'],
vb($domain[1]),
vb(
$frm[
'email_bounce']),
vb(
$frm[
'email']));
47 $email_form=
vb(
$frm[
'email']);
49 $tpl->assign(
'email', $email_form);
50 $tpl->assign(
'email_explain',
vb($email_explain));
52 $tpl->assign(
'civilite_mlle_issel', (
vb(
$frm[
'civilite']) ==
"Mlle"));
53 $tpl->assign(
'civilite_mme_issel', (
vb(
$frm[
'civilite']) ==
"Mme"));
54 $tpl->assign(
'civilite_m_issel', (
vb(
$frm[
'civilite']) ==
"M."));
56 if (empty(
$GLOBALS[
'site_parameters'][
'pseudo_is_not_used'])) {
58 $tpl->assign(
'pseudo_is_optionnal', !empty(
$GLOBALS[
'site_parameters'][
'pseudo_is_optionnal']));
62 $tpl->assign(
'first_name',
vb(
$frm[
'prenom']));
70 $tpl->assign(
'siret_txt',
$GLOBALS[
'STR_COMPANY_IDENTIFICATION'] .
' <span class="etoile">*</span>');
73 $tpl->assign(
'intracom_form',
vb(
$frm[
'intracom_for_billing']));
75 $tpl->assign(
'telephone',
vb(
$frm[
'telephone']));
77 $tpl->assign(
'portable',
vb(
$frm[
'portable']));
82 $tpl->assign(
'activity',
vb(
$frm[
'activity']));
84 if (
vb(
$frm[
'naissance']) !=
"0000-00-00") {
86 $tpl->assign(
'birthday_edit',
true);
94 if (!empty(
$GLOBALS[
'site_parameters'][
'user_fields_enable_code_promo'])) {
95 $tpl->assign(
'promo_code',
vb(
$frm[
'promo_code']));
96 $tpl->assign(
'STR_PROMO_CODE',
$GLOBALS[
'STR_PROMO_CODE']);
100 $tpl->assign(
'STR_PASSWORD_CONFIRMATION',
$GLOBALS[
'STR_PASSWORD_CONFIRMATION']);
102 if (
vb(
$GLOBALS[
'site_parameters'][
'type_affichage_user_favorite_id_categories']) ==
'checkbox') {
103 $tpl->assign(
'id_categories', get_ad_select_options(null,
vb(
$frm[
'id_categories']),
'id',
false,
false,
'checkbox',
'id_categories'));
105 }
elseif (
vb(
$GLOBALS[
'site_parameters'][
'type_affichage_user_favorite_id_categories']) ==
'select') {
109 $tpl->assign(
'id_cat_1', get_ad_select_options(null,
vb(
$frm[
'id_cat_1']),
'id'));
110 $tpl->assign(
'id_cat_2', get_ad_select_options(null,
vb(
$frm[
'id_cat_2']),
'id'));
111 $tpl->assign(
'id_cat_3', get_ad_select_options(null,
vb(
$frm[
'id_cat_3']),
'id'));
114 $tpl->assign(
'STR_ANNOUNCEMENT_INDICATION',
$GLOBALS[
'STR_ANNOUNCEMENT_INDICATION']);
115 $tpl->assign(
'STR_FIRST_CHOICE',
$GLOBALS[
'STR_FIRST_CHOICE']);
116 $tpl->assign(
'STR_SECOND_CHOICE',
$GLOBALS[
'STR_SECOND_CHOICE']);
117 $tpl->assign(
'STR_THIRD_CHOICE',
$GLOBALS[
'STR_THIRD_CHOICE']);
128 $tpl_origin_options = array();
130 while (isset(
$GLOBALS[
'STR_USER_ORIGIN_OPTIONS_' .
$i])) {
131 $tpl_origin_options[] = array(
'value' => $i,
132 'issel' =>
vb(
$frm[
'origin']) == $i,
133 'name' =>
$GLOBALS[
'STR_USER_ORIGIN_OPTIONS_' . $i]
137 $tpl->assign(
'origin_infos', array(
'options' => $tpl_origin_options,
138 'is_origin_other_activated' => in_array(
vb(
$frm[
'origin']),
$GLOBALS[
'origin_other_ids']),
139 'origin_other_ids_for_javascript' =>
'new Array('.implode(
',',
$GLOBALS[
'origin_other_ids']).
')',
140 'origin_other' =>
vb(
$frm[
'origin_other']),
142 'STR_CHOOSE' =>
$GLOBALS[
'STR_CHOOSE']
145 $tpl->assign(
'enable_display_only_user_specific_field', !empty(
$GLOBALS[
'site_parameters'][
'enable_display_only_user_specific_field']));
149 $sqlLng =
"SELECT lang, nom_".$_SESSION[
'session_langue'].
" AS nom_lang
151 WHERE (etat = '1'" . (!empty($_GET[
'langue'])?
" OR lang='" .
word_real_escape_string($_GET[
'langue']) .
"'":
'') .
") AND " .
get_filter_site_cond(
'langues') .
"" . (!empty(
$GLOBALS[
'site_parameters'][
'language_for_contacts'])?
" AND lang IN ('".implode(
"','",
$GLOBALS[
'site_parameters'][
'language_for_contacts']).
"')" :
'' ) .
"
154 $resLng =
query($sqlLng);
155 $language_for_automatic_emails_options = array();
156 $language_for_automatic_emails_selected = null;
158 if (!empty(
$frm[
'lang'])) {
160 $language_for_automatic_emails_options[
vb($lng[
'lang'])] =
vb($lng[
'nom_lang']);
161 if ($lng[
'lang'] ==
$frm[
'lang']) {
162 $language_for_automatic_emails_selected =
vb($lng[
'lang']);
166 if (!empty(
$GLOBALS[
'site_parameters'][
'user_front_office_logo_edit'])) {
168 if (!empty(
$frm[
"logo"])) {
172 $tpl->assign(
'language_for_automatic_emails_options', $language_for_automatic_emails_options);
173 $tpl->assign(
'language_for_automatic_emails_selected', $language_for_automatic_emails_selected);
174 $tpl->assign(
'newsletter_issel', (!isset(
$frm[
'newsletter']) || !empty(
$frm[
'newsletter'])));
175 $tpl->assign(
'commercial_issel', (!isset(
$frm[
'commercial']) ||
$frm[
'commercial']));
177 $tpl->assign(
'id_utilisateur', $_SESSION[
'session_utilisateur'][
'id_utilisateur']);
179 $tpl->assign(
'add_b2b_form_inputs', !empty(
$GLOBALS[
'site_parameters'][
'add_b2b_form_inputs']));
189 $tpl->assign(
'STR_BEFORE_TWO_POINTS',
$GLOBALS[
'STR_BEFORE_TWO_POINTS']);
190 $tpl->assign(
'STR_CHANGE_PARAMS',
$GLOBALS[
'STR_CHANGE_PARAMS']);
196 $tpl->assign(
'STR_STRONG_PSEUDO_NOTIFICATION',
$GLOBALS[
'STR_STRONG_PSEUDO_NOTIFICATION']);
197 $tpl->assign(
'STR_FIRST_NAME',
$GLOBALS[
'STR_FIRST_NAME']);
200 $tpl->assign(
'STR_INTRACOM_FORM',
$GLOBALS[
'STR_INTRACOM_FORM']);
201 $tpl->assign(
'STR_TELEPHONE',
$GLOBALS[
'STR_TELEPHONE']);
204 $tpl->assign(
'STR_NAISSANCE',
$GLOBALS[
'STR_NAISSANCE']);
205 $tpl->assign(
'STR_ERR_BIRTHDAY1',
$GLOBALS[
'STR_ERR_BIRTHDAY1']);
206 $tpl->assign(
'STR_ERR_BIRTHDAY2',
$GLOBALS[
'STR_ERR_BIRTHDAY2']);
209 $tpl->assign(
'STR_USER_ORIGIN',
$GLOBALS[
'STR_USER_ORIGIN']);
210 $tpl->assign(
'STR_COMMERCIAL_AGENT',
$GLOBALS[
'STR_COMMERCIAL_AGENT']);
211 $tpl->assign(
'STR_LANGUAGE_FOR_AUTOMATIC_EMAILS',
$GLOBALS[
'STR_LANGUAGE_FOR_AUTOMATIC_EMAILS']);
212 $tpl->assign(
'STR_NEWSLETTER_YES', (!empty(
$GLOBALS[
'STR_NEWSLETTER_YES'])?
$GLOBALS[
'STR_NEWSLETTER_YES']:
''));
213 $tpl->assign(
'STR_COMMERCIAL_YES', $GLOBALS[
'STR_COMMERCIAL_YES']);
214 $tpl->assign(
'STR_ACTIVITY', $GLOBALS[
'STR_ACTIVITY']);
215 $tpl->assign(
'STR_YOU_ARE', $GLOBALS[
'STR_YOU_ARE']);
216 $tpl->assign(
'STR_BUYERS', $GLOBALS[
'STR_BUYERS']);
217 $tpl->assign(
'STR_IMPORTERS_EXPORTERS', $GLOBALS[
'STR_IMPORTERS_EXPORTERS']);
218 $tpl->assign(
'STR_COMMERCIAL_AGENT', $GLOBALS[
'STR_COMMERCIAL_AGENT']);
219 $tpl->assign(
'STR_PURCHASING_MANAGER', $GLOBALS[
'STR_PURCHASING_MANAGER']);
220 $tpl->assign(
'STR_WORD_SELLERS', $GLOBALS[
'STR_WORD_SELLERS']);
221 $tpl->assign(
'STR_WHOLESALER', $GLOBALS[
'STR_WHOLESALER']);
222 $tpl->assign(
'STR_HALF_WHOLESALER', $GLOBALS[
'STR_HALF_WHOLESALER']);
223 $tpl->assign(
'STR_RETAILERS', $GLOBALS[
'STR_RETAILERS']);
224 $tpl->assign(
'STR_PUNCTUAL', $GLOBALS[
'STR_PUNCTUAL']);
225 $tpl->assign(
'STR_RECURRENT', $GLOBALS[
'STR_RECURRENT']);
231 if (!function_exists(
'get_user_register_form')) {
246 $tpl = $GLOBALS[
'tplEngine']->createTemplate(
'user_register_form.tpl');
248 if(empty($url_account_register)) {
252 $tpl->assign(
'short_register_form', $short_register_form);
254 $tpl->assign(
'add_b2b_form_inputs', !empty($GLOBALS[
'site_parameters'][
'add_b2b_form_inputs']));
255 $tpl->assign(
'action', $url_account_register);
258 if(empty($GLOBALS[
'site_parameters'][
'pseudo_is_not_used'])) {
259 $tpl->assign(
'STR_PSEUDO', $GLOBALS[
'STR_PSEUDO']);
263 $tpl->assign(
'mot_passe',
vb(
$frm[
'mot_passe']));
264 $tpl->assign(
'mot_passe_confirm',
vb(
$frm[
'mot_passe_confirm']));
266 $tpl->assign(
'civilite_mlle_issel', (
vb(
$frm[
'civilite']) ==
"Mlle"));
267 $tpl->assign(
'civilite_mme_issel', (
vb(
$frm[
'civilite']) ==
"Mme"));
268 $tpl->assign(
'civilite_m_issel', (
vb(
$frm[
'civilite']) ==
"M."));
270 $tpl->assign(
'first_name',
vb(
$frm[
'prenom']));
272 $tpl->assign(
'name',
vb(
$frm[
'nom_famille']));
276 $tpl->assign(
'intracom_form',
vb(
$frm[
'intracom_for_billing']));
279 $tpl->assign(
'telephone',
vb(
$frm[
'telephone']));
282 $tpl->assign(
'portable',
vb(
$frm[
'portable']));
295 $tpl->assign(
'activity',
vb(
$frm[
'activity']));
300 $tpl->assign(
'siret_txt', $GLOBALS[
'STR_COMPANY_IDENTIFICATION']);
301 if (!empty($GLOBALS[
'site_parameters'][
'user_fields_enable_code_promo'])) {
302 $tpl->assign(
'promo_code',
vb(
$frm[
'promo_code']));
303 $tpl->assign(
'STR_PROMO_CODE', $GLOBALS[
'STR_PROMO_CODE']);
307 $tpl->assign(
'STR_PASSWORD_CONFIRMATION', $GLOBALS[
'STR_PASSWORD_CONFIRMATION']);
310 if (
vb($GLOBALS[
'site_parameters'][
'type_affichage_user_favorite_id_categories']) ==
'checkbox') {
311 $tpl->assign(
'id_categories', get_ad_select_options(null,
vb(
$frm[
'id_categories']),
'id',
false,
false,
'checkbox',
'id_categories'));
313 }
elseif (
vb($GLOBALS[
'site_parameters'][
'type_affichage_user_favorite_id_categories']) ==
'select') {
317 $tpl->assign(
'id_cat_1', get_ad_select_options(null,
vb(
$frm[
'id_cat_1']),
'id'));
318 $tpl->assign(
'id_cat_2', get_ad_select_options(null,
vb(
$frm[
'id_cat_2']),
'id'));
319 $tpl->assign(
'id_cat_3', get_ad_select_options(null,
vb(
$frm[
'id_cat_3']),
'id'));
321 $tpl->assign(
'STR_WEBSITE', $GLOBALS[
'STR_WEBSITE']);
322 $tpl->assign(
'STR_ANNOUNCEMENT_INDICATION', $GLOBALS[
'STR_ANNOUNCEMENT_INDICATION']);
323 $tpl->assign(
'STR_FIRST_CHOICE', $GLOBALS[
'STR_FIRST_CHOICE']);
324 $tpl->assign(
'STR_SECOND_CHOICE', $GLOBALS[
'STR_SECOND_CHOICE']);
325 $tpl->assign(
'STR_THIRD_CHOICE', $GLOBALS[
'STR_THIRD_CHOICE']);
327 $tpl_origin_options = array();
329 while (isset($GLOBALS[
'STR_USER_ORIGIN_OPTIONS_' . $i])) {
330 $tpl_origin_options[] = array(
'value' => $i,
331 'issel' =>
vb(
$frm[
'origin']) == $i,
332 'name' => $GLOBALS[
'STR_USER_ORIGIN_OPTIONS_' . $i]
336 $tpl->assign(
'origin_infos', array(
'options' => $tpl_origin_options,
337 'is_origin_other_activated' => in_array(
vb(
$frm[
'origin']), $GLOBALS[
'origin_other_ids']),
338 'origin_other_ids_for_javascript' =>
'new Array('.implode(
',', $GLOBALS[
'origin_other_ids']).
')',
339 'origin_other' =>
vb(
$frm[
'origin_other']),
341 'STR_CHOOSE' => $GLOBALS[
'STR_CHOOSE']
344 $tpl->assign(
'enable_display_only_user_specific_field', !empty($GLOBALS[
'site_parameters'][
'enable_display_only_user_specific_field']));
348 $tpl->assign(
'captcha', array(
349 'validation_code_txt' => $GLOBALS[
'STR_VALIDATION_CODE'],
351 'validation_code_copy_txt' => $GLOBALS[
'STR_VALIDATION_CODE_COPY'],
353 'value' =>
vb(
$frm[
'code'])
358 $tpl->assign(
'cgv_issel', !empty(
$frm[
'cgv_confirm']));
359 $tpl->assign(
'STR_CGV_YES', $GLOBALS[
'STR_CGV_YES']);
364 $sqlLng =
"SELECT lang, nom_".$_SESSION[
'session_langue'].
" AS nom_lang
367 " . (!empty($GLOBALS[
'site_parameters'][
'language_for_contacts'])?
" AND lang IN ('".implode(
"','", $GLOBALS[
'site_parameters'][
'language_for_contacts']).
"')" :
'' ) .
"
370 $resLng =
query($sqlLng);
371 $language_for_automatic_emails_options = array();
372 $language_for_automatic_emails_selected = null;
374 $language_for_automatic_emails_options[
vb($lng[
'lang'])] =
vb($lng[
'nom_lang']);
375 if ($lng[
'lang'] == $_SESSION[
'session_langue']) {
376 $language_for_automatic_emails_selected =
vb($lng[
'lang']);
379 if (!empty($GLOBALS[
'site_parameters'][
'user_front_office_logo_edit'])) {
380 $tpl->assign(
'STR_LOGO', $GLOBALS[
'STR_LOGO']);
381 if (!empty(
$frm[
"logo"])) {
385 $tpl->assign(
'language_for_automatic_emails_options', $language_for_automatic_emails_options);
386 $tpl->assign(
'language_for_automatic_emails_selected', $language_for_automatic_emails_selected);
387 $tpl->assign(
'STR_LANGUAGE_FOR_AUTOMATIC_EMAILS', $GLOBALS[
'STR_LANGUAGE_FOR_AUTOMATIC_EMAILS']);
388 $tpl->assign(
'newsletter_issel', (!isset(
$frm[
'newsletter']) || !empty(
$frm[
'newsletter'])));
389 $tpl->assign(
'newsletter_option_selected',
vb(
$frm[
'newsletter_format']));
393 $tpl->assign(
'js_password_control', js_password_control(
'mot_passe'));
394 $tpl->assign(
'STR_CHOOSE', $GLOBALS[
'STR_CHOOSE']);
395 $tpl->assign(
'STR_LEADER', $GLOBALS[
'STR_LEADER']);
396 $tpl->assign(
'STR_MANAGER', $GLOBALS[
'STR_MANAGER']);
397 $tpl->assign(
'STR_EMPLOYEE', $GLOBALS[
'STR_EMPLOYEE']);
399 $tpl->assign(
'STR_FIRST_REGISTER_TITLE', $GLOBALS[
'STR_DEVIS']);
400 $tpl->assign(
'STR_FIRST_REGISTER_TEXT', $GLOBALS[
'STR_MODULE_DEVIS_CONSEIL']);
401 $tpl->assign(
'submit_text', $GLOBALS[
'STR_SEND']);
403 $tpl->assign(
'STR_FIRST_REGISTER_TITLE', $GLOBALS[
'STR_FIRST_REGISTER_TITLE']);
404 $tpl->assign(
'STR_FIRST_REGISTER_TEXT', $GLOBALS[
'STR_FIRST_REGISTER_TEXT']);
405 $tpl->assign(
'STR_OPEN_ACCOUNT', $GLOBALS[
'STR_OPEN_ACCOUNT']);
406 $tpl->assign(
'submit_text', $GLOBALS[
'STR_OPEN_ACCOUNT']);
408 $tpl->assign(
'STR_BEFORE_TWO_POINTS', $GLOBALS[
'STR_BEFORE_TWO_POINTS']);
409 $tpl->assign(
'STR_EMAIL', $GLOBALS[
'STR_EMAIL']);
410 $tpl->assign(
'STR_STRONG_PSEUDO_NOTIFICATION', $GLOBALS[
'STR_STRONG_PSEUDO_NOTIFICATION']);
411 $tpl->assign(
'STR_PASSWORD', $GLOBALS[
'STR_PASSWORD']);
412 $tpl->assign(
'STR_PASSWORD_SECURITY', $GLOBALS[
'STR_PASSWORD_SECURITY']);
413 $tpl->assign(
'STR_STRONG_PASSWORD_NOTIFICATION', $GLOBALS[
'STR_STRONG_PASSWORD_NOTIFICATION']);
414 $tpl->assign(
'STR_GENDER', $GLOBALS[
'STR_GENDER']);
415 $tpl->assign(
'STR_MLLE', $GLOBALS[
'STR_MLLE']);
416 $tpl->assign(
'STR_MME', $GLOBALS[
'STR_MME']);
417 $tpl->assign(
'STR_M', $GLOBALS[
'STR_M']);
418 $tpl->assign(
'STR_FIRST_NAME', $GLOBALS[
'STR_FIRST_NAME']);
419 $tpl->assign(
'STR_NAME', $GLOBALS[
'STR_NAME']);
420 $tpl->assign(
'STR_SOCIETE', $GLOBALS[
'STR_SOCIETE']);
421 $tpl->assign(
'STR_INTRACOM_FORM', $GLOBALS[
'STR_INTRACOM_FORM']);
422 $tpl->assign(
'STR_ZIP', $GLOBALS[
'STR_ZIP']);
423 $tpl->assign(
'STR_TOWN', $GLOBALS[
'STR_TOWN']);
424 $tpl->assign(
'STR_COUNTRY', $GLOBALS[
'STR_COUNTRY']);
425 $tpl->assign(
'STR_TELEPHONE', $GLOBALS[
'STR_TELEPHONE']);
426 $tpl->assign(
'STR_PORTABLE', $GLOBALS[
'STR_PORTABLE']);
427 $tpl->assign(
'STR_FAX', $GLOBALS[
'STR_FAX']);
428 $tpl->assign(
'STR_NAISSANCE', $GLOBALS[
'STR_NAISSANCE']);
429 $tpl->assign(
'STR_MANDATORY', $GLOBALS[
'STR_MANDATORY']);
430 $tpl->assign(
'STR_USER_ORIGIN', $GLOBALS[
'STR_USER_ORIGIN']);
431 $tpl->assign(
'STR_COMMERCIAL_AGENT', $GLOBALS[
'STR_COMMERCIAL_AGENT']);
432 $tpl->assign(
'STR_NEWSLETTER_YES', (!empty($GLOBALS[
'STR_NEWSLETTER_YES'])?$GLOBALS[
'STR_NEWSLETTER_YES']:
''));
433 $tpl->assign(
'STR_COMMERCIAL_YES', $GLOBALS[
'STR_COMMERCIAL_YES']);
434 $tpl->assign(
'STR_ADDRESS', $GLOBALS[
'STR_ADDRESS']);
435 $tpl->assign(
'STR_FONCTION', $GLOBALS[
'STR_FONCTION']);
436 $tpl->assign(
'STR_ACTIVITY', $GLOBALS[
'STR_ACTIVITY']);
437 $tpl->assign(
'STR_YOU_ARE', $GLOBALS[
'STR_YOU_ARE']);
438 $tpl->assign(
'STR_BUYERS', $GLOBALS[
'STR_BUYERS']);
439 $tpl->assign(
'STR_IMPORTERS_EXPORTERS', $GLOBALS[
'STR_IMPORTERS_EXPORTERS']);
440 $tpl->assign(
'STR_COMMERCIAL_AGENT', $GLOBALS[
'STR_COMMERCIAL_AGENT']);
441 $tpl->assign(
'STR_PURCHASING_MANAGER', $GLOBALS[
'STR_PURCHASING_MANAGER']);
442 $tpl->assign(
'STR_WORD_SELLERS', $GLOBALS[
'STR_WORD_SELLERS']);
443 $tpl->assign(
'STR_WHOLESALER', $GLOBALS[
'STR_WHOLESALER']);
444 $tpl->assign(
'STR_HALF_WHOLESALER', $GLOBALS[
'STR_HALF_WHOLESALER']);
445 $tpl->assign(
'STR_RETAILERS', $GLOBALS[
'STR_RETAILERS']);
446 $tpl->assign(
'STR_PUNCTUAL', $GLOBALS[
'STR_PUNCTUAL']);
447 $tpl->assign(
'STR_RECURRENT', $GLOBALS[
'STR_RECURRENT']);
453 if (!function_exists(
'get_user_register_success')) {
460 function get_user_register_success(&
$frm)
464 if (
$frm[
'priv']==
'stop') {
465 $output .=
'<p>' . nl2br($GLOBALS[
'STR_MODULE_PREMIUM_MSG_RETAILER']) .
'</p>';
474 if (!function_exists(
'get_change_password_form')) {
486 $tpl = $GLOBALS[
'tplEngine']->createTemplate(
'change_password_form.tpl');
487 $tpl->assign(
'change_password', $GLOBALS[
'STR_CHANGE_PASSWORD']);
493 $tpl->assign(
'old_password',
vb(
$frm[
'ancien_mot_passe']));
496 $tpl->assign(
'new_password',
vb(
$frm[
'nouveau_mot_passe']));
498 $tpl->assign(
'new_password_confirm',
vb(
$frm[
'nouveau_mot_passe2']));
501 $tpl->assign(
'js_password_control', js_password_control(
'nouveau_mot_passe'));
502 $tpl->assign(
'STR_BEFORE_TWO_POINTS', $GLOBALS[
'STR_BEFORE_TWO_POINTS']);
503 $tpl->assign(
'STR_OLD_PASSWORD', $GLOBALS[
'STR_OLD_PASSWORD']);
504 $tpl->assign(
'STR_NEW_PASSWORD', $GLOBALS[
'STR_NEW_PASSWORD']);
505 $tpl->assign(
'STR_STRONG_PASSWORD_NOTIFICATION', $GLOBALS[
'STR_STRONG_PASSWORD_NOTIFICATION']);
506 $tpl->assign(
'STR_NEW_PASSWORD_CONFIRM', $GLOBALS[
'STR_NEW_PASSWORD_CONFIRM']);
507 $tpl->assign(
'STR_CHANGE', $GLOBALS[
'STR_CHANGE']);
508 $tpl->assign(
'STR_EMPTY_FIELDS', $GLOBALS[
'STR_EMPTY_FIELDS']);
514 if (!function_exists(
'get_recover_password_form')) {
526 $tpl = $GLOBALS[
'tplEngine']->createTemplate(
'recover_password_form.tpl');
527 $tpl->assign(
'get_password', $GLOBALS[
'STR_GET_PASSWORD']);
528 $tpl->assign(
'action', $_SERVER[
'REQUEST_URI']);
529 $tpl->assign(
'STR_SEND', $GLOBALS[
'STR_SEND']);
530 $tpl->assign(
'STR_BEFORE_TWO_POINTS', $GLOBALS[
'STR_BEFORE_TWO_POINTS']);
532 $tpl->assign(
'login_href', get_url(
'membre'));
533 $tpl->assign(
'login_txt', $GLOBALS[
'STR_LOGIN']);
534 $tpl->assign(
'home_href', get_url(
'/'));
535 $tpl->assign(
'home_txt', $GLOBALS[
'STR_HOME']);
536 $tpl->assign(
'js_password_control', js_password_control(
'rec_password_once'));
537 if (
$mode ==
'filing_email') {
538 $tpl->assign(
'email', array(
539 'msg_insert' => $GLOBALS[
'STR_INSERT_EMAIL'],
540 'label' => $GLOBALS[
'STR_EMAIL'] . $GLOBALS[
'STR_BEFORE_TWO_POINTS'],
541 'value' =>
vb(
$frm[
'email']),
545 $tpl->assign(
'pass', array(
548 'msg_insert_new_password' => $GLOBALS[
'STR_INSERT_NEW_PASSWORD'],
549 'STR_NEW_PASSWORD' => $GLOBALS[
'STR_NEW_PASSWORD'],
550 'STR_BEFORE_TWO_POINTS' => $GLOBALS[
'STR_BEFORE_TWO_POINTS'],
551 'password_once' =>
vb(
$frm[
'password_once']),
553 'STR_STRONG_PASSWORD_NOTIFICATION' => $GLOBALS[
'STR_STRONG_PASSWORD_NOTIFICATION'],
554 'STR_NEW_PASSWORD_CONFIRM' => $GLOBALS[
'STR_NEW_PASSWORD_CONFIRM'],
555 'password_twice' =>
vb(
$frm[
'password_twice']),
564 if (!function_exists(
'get_access_account_form')) {
574 function get_access_account_form(&
$frm, &
$form_error_object, $forced_new_client_area_html = null, $skip_title =
false)
577 if(empty($forced_new_client_area_html)){
578 $forced_new_client_area_html =
'' . nl2br($GLOBALS[
'STR_MSG_NEW_CUSTOMER']) .
'<br />';
580 $tpl = $GLOBALS[
'tplEngine']->createTemplate(
'access_account_form.tpl');
582 $tpl->assign(
'acces_account_txt', $GLOBALS[
'STR_ACCES_ACCOUNT']);
584 $tpl->assign(
'acces_account_txt', null);
586 $tpl->assign(
'new_customer', $GLOBALS[
'STR_NEW_CUSTOMER']);
587 $tpl->assign(
'msg_new_customer', $forced_new_client_area_html);
588 $tpl->assign(
'still_customer', $GLOBALS[
'STR_STILL_CUSTOMER']);
589 $tpl->assign(
'msg_still_customer', $GLOBALS[
'STR_MSG_STILL_CUSTOMER']);
590 $tpl->assign(
'pass_perdu_txt', $GLOBALS[
'STR_PASS_PERDU']);
591 $tpl->assign(
'pass_perdu_href', get_url(
'/utilisateurs/oubli_mot_passe.php'));
592 $tpl->assign(
'email_or_pseudo', $GLOBALS[
'STR_EMAIL_OR_PSEUDO'] . $GLOBALS[
'STR_BEFORE_TWO_POINTS']);
595 $tpl->assign(
'STR_PASSWORD', $GLOBALS[
'STR_PASSWORD'] . $GLOBALS[
'STR_BEFORE_TWO_POINTS']);
596 $tpl->assign(
'password',
vb(
$frm[
'mot_passe']));
599 $tpl->assign(
'login_txt', $GLOBALS[
'STR_LOGIN']);
600 if (function_exists(
'get_social_icone')) {
601 $tpl->assign(
'social_icone', get_social_icone());
603 $social = array(
'is_any' =>
false);
605 $social[
'is_any'] =
true;
606 $social[
'facebook'] = get_facebook_connect_btn();
609 $social[
'is_any'] =
true;
610 $social[
'twitter'] = get_sign_in_twitter_btn();
613 $social[
'is_any'] =
true;
614 $social[
'openid'] = get_openid_btn();
616 $tpl->assign(
'social', $social);
622 if (!function_exists(
'get_contact_form')) {
634 $tpl = $GLOBALS[
'tplEngine']->createTemplate(
'contact_form.tpl');
635 $tpl->assign(
'skip_introduction_text', $skip_introduction_text);
636 $tpl->assign(
'short_form', !empty($GLOBALS[
'site_parameters'][
'contact_form_short_mode']));
637 if(!empty($_SERVER[
'HTTPS']) && $_SERVER[
'HTTPS'] !=
'off') {
638 $tpl->assign(
'ssl_image_src', $GLOBALS[
'repertoire_images'] .
'/security.png');
643 if (!empty(
$frm[
'is_ok'])) {
644 $tpl->assign(
'success_msg', $GLOBALS[
'STR_TICKET_OK']);
646 $tpl->assign(
'contact_info', affiche_contenu_html(
"contact_page",
true) . (function_exists(
'get_details_societe')?get_details_societe():
''));
647 $tpl->assign(
'action',
get_current_url(
false).(!empty($GLOBALS[
'main_div_id'])?
'?ctx='.$GLOBALS[
'main_div_id']:
''));
648 $tpl->assign(
'extra_field', get_contact_extra_field());
649 $sujet_options = array(
650 '' => $GLOBALS[
'STR_CONTACT_LB']);
651 for($i=1; isset($GLOBALS[
'STR_CONTACT_SELECT'.$i]); $i++) {
652 if(!empty($GLOBALS[
'STR_CONTACT_SELECT'.$i])) {
653 $sujet_options[$GLOBALS[
'STR_CONTACT_SELECT'.$i]]=$GLOBALS[
'STR_CONTACT_SELECT'.$i];
656 $tpl->assign(
'sujet_options', $sujet_options);
657 $tpl->assign(
'sujet_options_selected',
vb(
$frm[
'sujet']));
660 $tpl->assign(
'commande_id',
vb(
$frm[
'commande_id']));
662 $tpl->assign(
'email_value',
vb(
$frm[
'email']));
667 $tpl->assign(
'societe_value',
vb(
$frm[
'societe']));
669 $tpl->assign(
'first_name_value',
vb(
$frm[
'prenom']));
671 $tpl->assign(
'address_value',
vb(
$frm[
'adresse']));
672 $tpl->assign(
'zip_value',
vb(
$frm[
'code_postal']));
673 $tpl->assign(
'town_value',
vb(
$frm[
'ville']));
674 $tpl->assign(
'country_value',
vb(
$frm[
'pays']));
675 $tpl->assign(
'telephone_value',
vb(
$frm[
'telephone']));
677 $tpl->assign(
'texte_value',
vb(
$frm[
'texte']));
679 $tpl->assign(
'STR_DISPO', $GLOBALS[
'STR_DISPO']);
683 $tpl->assign(
'captcha', array(
684 'validation_code_txt' => $GLOBALS[
'STR_VALIDATION_CODE'],
686 'validation_code_copy_txt' => $GLOBALS[
'STR_VALIDATION_CODE_COPY'],
688 'value' =>
vb(
$frm[
'code'])
691 $tpl->assign(
'align', (!empty($GLOBALS[
'site_parameters'][
'contact_form_align']) ? $GLOBALS[
'site_parameters'][
'contact_form_align'] :
'left'));
694 $tpl->assign(
'STR_SEND', $GLOBALS[
'STR_SEND']);
696 $tpl->assign(
'STR_CONTACT', $GLOBALS[
'STR_CONTACT']);
697 $tpl->assign(
'STR_CONTACT_INTRO', $GLOBALS[
'STR_CONTACT_INTRO']);
698 $tpl->assign(
'STR_CONTACT_SUBJECT', $GLOBALS[
'STR_CONTACT_SUBJECT']);
699 $tpl->assign(
'STR_BEFORE_TWO_POINTS', $GLOBALS[
'STR_BEFORE_TWO_POINTS']);
700 $tpl->assign(
'STR_ORDER_NUMBER', $GLOBALS[
'STR_ORDER_NUMBER']);
701 $tpl->assign(
'STR_REQUIRED_ORDER_NUMBER', $GLOBALS[
'STR_REQUIRED_ORDER_NUMBER']);
702 $tpl->assign(
'STR_EMAIL', $GLOBALS[
'STR_EMAIL']);
703 $tpl->assign(
'STR_NAME', $GLOBALS[
'STR_NAME']);
704 $tpl->assign(
'STR_SOCIETE', $GLOBALS[
'STR_SOCIETE']);
705 $tpl->assign(
'STR_FIRST_NAME', $GLOBALS[
'STR_FIRST_NAME']);
706 $tpl->assign(
'STR_ADDRESS', $GLOBALS[
'STR_ADDRESS']);
707 $tpl->assign(
'STR_ZIP', $GLOBALS[
'STR_ZIP']);
708 $tpl->assign(
'STR_TOWN', $GLOBALS[
'STR_TOWN']);
709 $tpl->assign(
'STR_COUNTRY', $GLOBALS[
'STR_COUNTRY']);
710 $tpl->assign(
'STR_TELEPHONE', $GLOBALS[
'STR_TELEPHONE']);
711 $tpl->assign(
'STR_TEXT', $GLOBALS[
'STR_TEXT']);
712 $tpl->assign(
'STR_DAY_AM', $GLOBALS[
'STR_DAY_AM']);
713 $tpl->assign(
'STR_DAY_PM', $GLOBALS[
'STR_DAY_PM']);
714 $tpl->assign(
'STR_MANDATORY', $GLOBALS[
'STR_MANDATORY']);
720 if (!function_exists(
'get_contact_success')) {
727 function get_contact_success(&
$frm)
730 <h1 property="name" class="page_title">' . $GLOBALS[
'STR_CONTACT'] .
'</h1>
731 <div class="page_content">
734 ' .
vb($GLOBALS[
'site_parameters'][
'contact_form_success_tag']);
739 if (!function_exists(
'get_contact_extra_field')) {
744 function get_contact_extra_field()
750 if (!function_exists(
'js_password_control')) {
756 function js_password_control($field_id)
758 $GLOBALS[
'js_ready_content_array'][] =
'
759 set_password_image_level("' .
filtre_javascript($field_id,
true,
false,
true,
true,
false) .
'","' . $GLOBALS[
'repertoire_images'] .
'","' .
filtre_javascript(
'pwd_level_image',
true,
false,
true,
true,
false) .
'",' . (!empty($GLOBALS[
'site_parameters'][
'bootstrap_enabled'])?
'true':
'false') .
');
764 if (!function_exists(
'get_address_form')) {
771 function get_address_form(
$frm = null)
774 if(empty($_SESSION[
'session_utilisateur'][
'id_utilisateur'])) {
778 <form class="entryform form-inline" method="post" action="'.get_current_url(
false).
'">
781 if (!empty(
$frm[
'id'])) {
783 <input type="hidden" name="id" value="'.vn(
$frm[
'id']).
'">
784 <input type="hidden" name="mode" value="update_address">';
787 <input type="hidden" name="mode" value="insert_address">';
789 if (!empty($GLOBALS[
'site_parameters'][
'mode_transport'])) {
790 $options =
' <option value="" ' .
frmvalide(
vb(
$frm[
'address_type']) ==
"",
' selected="selected"') .
'>' . $GLOBALS[
'STR_INVOICE_ADDRESS'] .
' / ' . $GLOBALS[
'STR_SHIP_ADDRESS'] .
'</option>
791 <option value="bill" ' .
frmvalide(
vb(
$frm[
'address_type']) ==
"bill",
' selected="selected"') .
'>' . $GLOBALS[
'STR_INVOICE_ADDRESS'] .
'</option>
792 <option value="ship" ' .
frmvalide(
vb(
$frm[
'address_type']) ==
"ship",
' selected="selected"') .
'>' . $GLOBALS[
'STR_SHIP_ADDRESS'] .
'</option>
795 $options =
'<option value="bill" ' .
frmvalide(
vb(
$frm[
'address_type']) ==
"bill",
' selected="selected"') .
'>' . $GLOBALS[
'STR_INVOICE_ADDRESS'] .
'</option>';
798 <div class="enregistrement">
799 <span class="enregistrementgauche"><label for="name_adresse">' .$GLOBALS[
'STR_NAME'] .
' ' .
String::strtoupper($GLOBALS[
'STR_ADDRESS']) .
' <span class="etoile">*</span>' . $GLOBALS[
'STR_BEFORE_TWO_POINTS'] .
':</label></span>
800 <span class="enregistrementdroite"><input type="text" class="form-control" id="name_adresse" name="name_adresse" value="'.String::str_form_value(
String::html_entity_decode_if_needed(
vb(
$frm[
'nom']))).
'" required /></span>
802 <div class="enregistrement">
803 <span class="enregistrementgauche"><label>' . $GLOBALS[
'STR_TYPE'] .$GLOBALS[
'STR_BEFORE_TWO_POINTS'] .
':</label></span>
804 <span class="enregistrementdroite">
805 <select name="address_type" class="form-control">
810 <div class="enregistrement">
811 <span class="enregistrementgauche"><label>' . $GLOBALS[
'STR_GENDER'] .$GLOBALS[
'STR_BEFORE_TWO_POINTS'] .
':</label></span>
812 <span class="enregistrementdroite">
813 <input type="radio" name="civilite" value="Mlle" ' .
frmvalide(
vb(
$frm[
'civilite']) ==
"Mlle") .
' /> ' . $GLOBALS[
'STR_MLLE'] .
'
814 <input type="radio" name="civilite" value="Mme" ' .
frmvalide(
vb(
$frm[
'civilite']) ==
"Mme") .
' /> ' . $GLOBALS[
'STR_MME'] .
'
815 <input type="radio" name="civilite" value="M." ' .
frmvalide(
vb(
$frm[
'civilite']) ==
"M.") .
' /> ' . $GLOBALS[
'STR_M'] .
'
818 <div class="enregistrement">
819 <span class="enregistrementgauche"><label for="nom_famille">' . $GLOBALS[
'STR_NAME'] .
' <span class="etoile">*</span>' . $GLOBALS[
'STR_BEFORE_TWO_POINTS'] .
':</label></span>
820 <span class="enregistrementdroite"><input type="text" class="form-control" id="nom_famille" name="nom_famille" value="'.String::str_form_value(
String::html_entity_decode_if_needed(
vb(
$frm[
'nom_famille']))).
'" required /></span>
822 <div class="enregistrement">
823 <span class="enregistrementgauche"><label for="prenom">' . $GLOBALS[
'STR_FIRST_NAME'] .
' <span class="etoile">*</span>' . $GLOBALS[
'STR_BEFORE_TWO_POINTS'] .
':</label></span>
824 <span class="enregistrementdroite"><input type="text" class="form-control" id="prenom" name="prenom" value="'.String::str_form_value(
String::html_entity_decode_if_needed(
vb(
$frm[
'prenom']))).
'" required /><span class="notice"></span>
826 <div class="enregistrement">
827 <span class="enregistrementgauche"><label for="prenom">' . $GLOBALS[
'STR_EMAIL'] .
' <span class="etoile">*</span>' . $GLOBALS[
'STR_BEFORE_TWO_POINTS'] .
':</label></span>
828 <span class="enregistrementdroite"><input type="text" class="form-control" id="email" name="email" value="'.String::str_form_value(
String::html_entity_decode_if_needed(
vb(
$frm[
'email']))).
'" required /><span class="notice"></span>
830 <div class="enregistrement">
831 <span class="enregistrementgauche"><label for="societe">' . $GLOBALS[
'STR_SOCIETE'] . $GLOBALS[
'STR_BEFORE_TWO_POINTS'] .
':</label></span>
832 <span class="enregistrementdroite"><input type="text" class="form-control" id="societe" name="societe" value="'.String::str_form_value(
String::html_entity_decode_if_needed(
vb(
$frm[
'societe']))).
'" /></span>
834 <div class="enregistrement">
835 <span class="enregistrementgauche"><label for="adresse">' . $GLOBALS[
'STR_ADDRESS'] .
' <span class="etoile">*</span>' . $GLOBALS[
'STR_BEFORE_TWO_POINTS'] .
':</label></span>
836 <span class="enregistrementdroite"><input type="text" class="form-control" id="adresse" name="adresse" value="'.String::str_form_value(
String::html_entity_decode_if_needed(
vb(
$frm[
'adresse']))).
'" required /></span>
838 <div class="enregistrement">
839 <span class="enregistrementgauche"><label for="code_postal">' . $GLOBALS[
'STR_ZIP'] .
' <span class="etoile">*</span>' . $GLOBALS[
'STR_BEFORE_TWO_POINTS'] .
':</label></span>
840 <span class="enregistrementdroite"><input type="text" class="form-control" id="code_postal" name="code_postal" value="'.String::str_form_value(
String::html_entity_decode_if_needed(
vb(
$frm[
'code_postal']))).
'" required /></span>
842 <div class="enregistrement">
843 <span class="enregistrementgauche"><label for="ville">' . $GLOBALS[
'STR_TOWN'] .
' <span class="etoile">*</span>' . $GLOBALS[
'STR_BEFORE_TWO_POINTS'] .
':</label></span>
844 <span class="enregistrementdroite"><input type="text" class="form-control" id="ville" name="ville" value="'.String::str_form_value(
String::html_entity_decode_if_needed(
vb(
$frm[
'ville']))).
'" required /></span>
846 <div class="enregistrement">
847 <span class="enregistrementgauche"><label for="pays">' . $GLOBALS[
'STR_COUNTRY'] . $GLOBALS[
'STR_BEFORE_TWO_POINTS'] .
':</label></span>
848 <span class="enregistrementdroite">
849 <select id="pays" name="pays" class="form-control">
854 <div class="enregistrement">
855 <span class="enregistrementgauche"><label for="portable">' . $GLOBALS[
'STR_TELEPHONE'] .
' <span class="etoile">*</span>' . $GLOBALS[
'STR_BEFORE_TWO_POINTS'] .
':</label></span>
856 <span class="enregistrementdroite"><input type="text" class="form-control" id="portable" name="portable" value="'.String::str_form_value(
String::html_entity_decode_if_needed(
vb(
$frm[
'portable']))).
'" required /></span>
858 <p class="center" style="margin-top:10px"><input class="btn btn-primary btn-lg" type="submit" value="' .
String::str_form_value($GLOBALS[
"STR_VALIDATE"]) .
'" /></p>
860 <p><span class="form_mandatory">(*) ' . $GLOBALS[
'STR_MANDATORY'] .
'</span></p>
static strtoupper($string)
Returns string with all alphabetic characters converted to uppercase.
if(!empty($GLOBALS['site_parameters']['order_specific_field_titles'])) if(check_if_module_active('socolissimo')&&!empty($_REQUEST)&&!empty($_REQUEST['PUDOFOID'])&&!empty($_REQUEST['CEEMAIL'])&&!empty($_REQUEST['SIGNATURE'])&&!empty($_REQUEST['ORDERID'])) elseif(!empty($_POST)) elseif(check_if_module_active('socolissimo')&&!empty($_SESSION['session_commande']['is_socolissimo_order'])) foreach(array('bill'=> 1, 'ship'=> 2) as $address_type=> $session_commande_address_id) $frm['societe1']
static textEncode($string, $suppr_endline=false, $encode_only_isolated_amperstands=false)
Méthode de compatibilité avec anciennes versions de PEEL utilisant textEncode au lieu de htmlentities...
get_current_url($with_get=true, $get_short_url=false, $take_away_get_args_array=null)
get_current_url()
get_captcha_inside_form(&$frm)
get_captcha_inside_form()
static html_entity_decode_if_needed($string)
String::html_entity_decode_if_needed()
word_real_escape_string($value)
Applique real_escape_string dans le cas où on n'insère qu'un seul mot, de moins de 30 caractères...
if(!empty($_GET['id'])) if(isset($_POST['form_name'], $_POST['form_subject'], $_POST['form_text'], $_POST['form_lang'])&&empty($_GET['id'])) if(empty($_GET['id'])) $tpl
if(isset($_POST['pays_zone'])) elseif(empty($_SESSION['session_caddie']->zoneId)&&!empty($GLOBALS['site_parameters']['default_delivery_zone_id'])) if(isset($_POST['type'])) elseif(empty($_SESSION['session_caddie']->typeId)&&!empty($GLOBALS['site_parameters']['default_delivery_type_id'])) if(!empty($_POST['code_promo'])) if(!empty($_GET['code_promo'])&&$_GET['code_promo']== 'delete') $form_error_object
get_user_job_options($selected_fonction_name=null)
get_specific_field_infos($frm, $form_error_object=null, $form_usage="user", $step=null)
Permet de définir de nouveaux champs dans le formulaire d'inscription / modification d'utilisateur de...
get_filter_site_cond($table_technical_code, $table_alias=null, $use_strict_rights_if_in_admin=false, $specific_site_id=null, $exclude_public_items=false, $admin_force_multisite_if_allowed=false)
Retourne la condition SQL permettant de filtrer les données pour une table.
query($query, $die_if_error=false, $database_object=null, $silent_if_error=false, $security_sql_filter=true)
The query() function is meant to be called anywhere you want to make a query.
static str_form_value($value, $flags=ENT_COMPAT)
Encode une chaine de caractères pour affichage dans un value="".
get_country_select_options($selected_country_name=null, $selected_country_id=null, $option_value= 'name', $display_inactive_country=false, $allowed_zone_id=null, $preselect_shop_country_if_none_selected=true, $selected_country_lang=null, $allowed_ids=null)
get_country_select_options()
get_uploaded_file_infos($field_name, $file, $delete_url, $logo_width=100, $logo_height=100)
Remplit un tableau d'informations pour le template d'upload HTML.
if(strlen($date2)== '10') if($type== 'users-by-age'&&a_priv('admin_users', true)) elseif($type== 'forums-count'&&a_priv('admin_content', true)) elseif($type== 'forums-categories'&&a_priv('admin_content', true)) elseif($type== 'users-count'&&a_priv('admin_users', true)) elseif($type== 'product-categories'&&a_priv('admin_products', true)) elseif($type== 'users-by-sex'&&a_priv('admin_users', true)) elseif($type== 'users-by-country'&&a_priv('admin_users', true)) elseif($type== 'sales'&&a_priv('admin_sales', true))
fetch_assoc($query_result)
fetch_assoc()
$GLOBALS['page_columns_count']
get_form_token_input($name= 'general', $use_existing_token=true, $return_as_input_form=true)
get_form_token_input()
static substr($string, $start, $length=null)
Returns the portion of string specified by the start and length parameters.
check_if_module_active($module_name, $specific_file_name=null)
Renvoie si un module est présent et activé ou non - Peut être appelé avant ou après le chargement d'u...
static nl2br_if_needed($string)
Fonction de compatibilité avec de vieilles versions de PEEL ou du contenu qui vient d'ailleurs...
if(defined('IN_PEEL_ADMIN')||IN_INSTALLATION) $_SESSION['session_langue']