changed all instances of fipf to cipf

This commit is contained in:
asus
2024-03-07 22:32:50 +01:00
parent f870f77a2c
commit be79310404
18 changed files with 170 additions and 92 deletions

View File

@@ -45,13 +45,13 @@ function handle_prof_is_activ_CIPF($author_id) {
*/
$redirection_prof_inactiv = home_url() . '/' . $slug_wait_activation;
wp_redirect($redirection_prof_inactiv);
wp_redirect($redirection_prof_inactiv, 301);
exit;
}
/*
* check meta field 'fipf_payement_status'
* check meta field 'cipf_payement_status'
* if field value is 'success'
* - hide block 'failure'
* - and update field to '', so it will not show next time
@@ -62,9 +62,9 @@ function handle_prof_is_activ_CIPF($author_id) {
* if field value is ''
* - hide both 'success' and 'failure' blocs
*
* .fipf_prof_paiement_message -> on row, added display none in page css
* #fipf_prof_paiement_reussi -> on row
* #fipf_prof_paiement_echoue -> on row
* .cipf_prof_paiement_message -> on row, added display none in page css
* #cipf_prof_paiement_reussi -> on row
* #cipf_prof_paiement_echoue -> on row
*
*/
function show_prof_paiement_messages_CIPF($user_id) {
@@ -80,22 +80,22 @@ function show_prof_paiement_messages_CIPF($user_id) {
if ($is_activ === 'Inactif')
return;
$fipf_prof_payement = new PLGNTLS_class();
$cipf_prof_payement = new PLGNTLS_class();
$payement_status2 = get_user_meta($user_id, 'fipf_payement_status');
$payement_status = get_user_meta($user_id, 'fipf_payement_status', true);
$payement_status2 = get_user_meta($user_id, 'cipf_payement_status');
$payement_status = get_user_meta($user_id, 'cipf_payement_status', true);
if ($payement_status === 'success') {
$fipf_prof_payement->add_to_front(array(
array( 'css' => '#fipf_prof_paiement_reussi {display: block;}' )
$cipf_prof_payement->add_to_front(array(
array( 'css' => '#cipf_prof_paiement_reussi {display: block;}' )
));
}
else if ($payement_status === 'started') {
$fipf_prof_payement->add_to_front(array(
array( 'css' => '#fipf_prof_paiement_echoue {display: block;}' )
$cipf_prof_payement->add_to_front(array(
array( 'css' => '#cipf_prof_paiement_echoue {display: block;}' )
));
}
update_user_meta($user_id, 'fipf_payement_status', '');
update_user_meta($user_id, 'cipf_payement_status', '');
}