fixed redirection preventing to edit in divi builder mode
This commit is contained in:
@@ -45,6 +45,10 @@ function payment_page_redirects_CIPF() {
|
|||||||
$slug_paypal_page = PLGNTLS_class::SLUG_PAYPAL_PAGE;
|
$slug_paypal_page = PLGNTLS_class::SLUG_PAYPAL_PAGE;
|
||||||
$role_prof = PLGNTLS_class::ROLE_PROF;
|
$role_prof = PLGNTLS_class::ROLE_PROF;
|
||||||
|
|
||||||
|
// don't redirect if it is the divi builder mode
|
||||||
|
if (et_fb_is_enabled) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
// check the slug
|
// check the slug
|
||||||
if (!is_page($slug_paypal_page)) {
|
if (!is_page($slug_paypal_page)) {
|
||||||
return;
|
return;
|
||||||
|
|||||||
@@ -18,6 +18,9 @@ if (!defined('ABSPATH')) {
|
|||||||
function prof_after_form_CIPF($form_id, $post_array, $form_type) {
|
function prof_after_form_CIPF($form_id, $post_array, $form_type) {
|
||||||
PLGNTLS_class::debug_infos();
|
PLGNTLS_class::debug_infos();
|
||||||
$acf_account_state = PLGNTLS_class::ACF_ACCOUNT_STATE;
|
$acf_account_state = PLGNTLS_class::ACF_ACCOUNT_STATE;
|
||||||
|
error_log('form_id: '.json_encode($form_id));
|
||||||
|
error_log('post_array: '.json_encode($post_array));
|
||||||
|
error_log('form_type: '.json_encode($form_type));
|
||||||
|
|
||||||
//$user_id = get_current_user_id();
|
//$user_id = get_current_user_id();
|
||||||
$user_id = $post_array['ID'];
|
$user_id = $post_array['ID'];
|
||||||
@@ -69,6 +72,10 @@ function prof_form_restrictions_CIPF(){
|
|||||||
$slug_renew_card = PLGNTLS_class::SLUG_RENEW_CARD;
|
$slug_renew_card = PLGNTLS_class::SLUG_RENEW_CARD;
|
||||||
$role_prof = PLGNTLS_class::ROLE_PROF;
|
$role_prof = PLGNTLS_class::ROLE_PROF;
|
||||||
|
|
||||||
|
// don't redirect if it is the divi builder mode
|
||||||
|
if (et_fb_is_enabled) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
if (!is_page($slug_renew_card)) {
|
if (!is_page($slug_renew_card)) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -59,6 +59,10 @@ function prof_profil_redirects_CIPF() {
|
|||||||
// is an author page
|
// is an author page
|
||||||
if (!is_author())
|
if (!is_author())
|
||||||
return;
|
return;
|
||||||
|
// don't redirect if it is the divi builder mode
|
||||||
|
if (et_fb_is_enabled) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user