manager->get_setting( 'ed_top_bar' )->value(); $top_bar_type = $control->manager->get_setting( 'top_bar_type' )->value(); $control_id = $control->id; if ( $control_id == 'top_bar_type' && $ed_top_bar ) return true; if ( $control_id == 'notification_text' && $ed_top_bar && $top_bar_type == 'top_button_link' ) return true; if ( $control_id == 'notification_label' && $ed_top_bar && $top_bar_type == 'top_button_link' ) return true; if ( $control_id == 'notification_btn_url' && $ed_top_bar && $top_bar_type == 'top_button_link' ) return true; if ( $control_id == 'ed_open_new_target' && $ed_top_bar && $top_bar_type == 'top_button_link' ) return true; if ( $control_id == 'topbar_color' && $ed_top_bar && $top_bar_type == 'top_button_link' ) return true; if ( $control_id == 'topbar_font_color' && $ed_top_bar && $top_bar_type == 'top_button_link' ) return true; if ( $control_id == 'top_bar_newsletter' && $ed_top_bar && $top_bar_type == 'top_newsletter' ) return true; if ( $control_id == 'header_newsletter_note' && $ed_top_bar && $top_bar_type == 'top_newsletter' ) return true; return false; } /** * Active Callback for Banner Slider */ function blossom_floral_pro_banner_ac( $control ){ $banner = $control->manager->get_setting( 'ed_banner_section' )->value(); $slider_type = $control->manager->get_setting( 'slider_type' )->value(); $slider_layout = $control->manager->get_setting( 'slider_layout' )->value(); $control_id = $control->id; if ( $control_id == 'header_image' && ( $banner == 'static_banner' || $banner == 'static_nl_banner' ) ) return true; if ( $control_id == 'header_video' && ( $banner == 'static_banner' || $banner == 'static_nl_banner' ) ) return true; if ( $control_id == 'external_header_video' && ( $banner == 'static_banner' || $banner == 'static_nl_banner' ) ) return true; if ( $control_id == 'banner_title' && $banner == 'static_banner' ) return true; if ( $control_id == 'banner_description' && $banner == 'static_banner' ) return true; if ( $control_id == 'button_one_label' && $banner == 'static_banner' ) return true; if ( $control_id == 'button_one_link' && $banner == 'static_banner' ) return true; if ( $control_id == 'button_two_label' && $banner == 'static_banner' ) return true; if ( $control_id == 'button_two_link' && $banner == 'static_banner' ) return true; if ( $control_id == 'banner_new_tab' && $banner == 'static_banner' ) return true; if ( $control_id == 'banner_new_tab_two' && $banner == 'static_banner' ) return true; if ( $control_id == 'banner_caption_layout' && ( $banner == 'static_banner' || $banner == 'static_nl_banner' ) ) return true; if ( $control_id == 'banner_newsletter' && $banner == 'static_nl_banner' ) return true; if ( $control_id == 'banner_bg_image' && $banner == 'static_nl_banner' ) return true; if ( $control_id == 'slider_type' && $banner == 'slider_banner' ) return true; if ( $control_id == 'include_repetitive_posts' && $banner == 'slider_banner' && ( $slider_type == 'latest_posts' || $slider_type == 'cat' ) ) return true; if ( $control_id == 'slider_auto' && $banner == 'slider_banner' ) return true; if ( $control_id == 'slider_loop' && $banner == 'slider_banner' ) return true; if ( $control_id == 'slider_caption' && $banner == 'slider_banner' ) return true; if ( $control_id == 'slider_readmore' && $banner == 'slider_banner' && ( $slider_layout == 'six' || $slider_layout == 'three' ) ) return true; if ( $control_id == 'slider_cat' && $banner == 'slider_banner' && $slider_type == 'cat' ) return true; if ( $control_id == 'no_of_slides' && $banner == 'slider_banner' && $slider_type == 'latest_posts' ) return true; if ( $control_id == 'slider_pages' && $banner == 'slider_banner' && $slider_type == 'pages' ) return true; if ( $control_id == 'slider_custom' && $banner == 'slider_banner' && $slider_type == 'custom' ) return true; if ( $control_id == 'slider_animation' && $banner == 'slider_banner' ) return true; if ( $control_id == 'slider_speed' && $banner == 'slider_banner' ) return true; if ( $control_id == 'banner_hr' && $banner == 'slider_banner' ) return true; if ( $control_id == 'slider_full_image' && $banner == 'slider_banner' ) return true; if ( $control_id == 'slider_banner_text' && $banner == 'slider_banner' ) return true; return false; } /** * Active Callback for Body Background */ function blossom_floral_pro_body_bg_choice( $control ){ $body_bg = $control->manager->get_setting( 'body_bg' )->value(); $control_id = $control->id; if ( $control_id == 'background_image' && $body_bg == 'image' ) return true; if ( $control_id == 'background_preset' && $body_bg == 'image' ) return true; if ( $control_id == 'background_position' && $body_bg == 'image' ) return true; if ( $control_id == 'background_size' && $body_bg == 'image' ) return true; if ( $control_id == 'background_repeat' && $body_bg == 'image' ) return true; if ( $control_id == 'background_attachment' && $body_bg == 'image' ) return true; if ( $control_id == 'bg_pattern' && $body_bg == 'pattern' ) return true; return false; } /** * Active Callback for before content AD */ function blossom_floral_pro_adbc_ac( $control ){ $ed_code = $control->manager->get_setting( 'ed_bc_post_ad_code' )->value(); $control_id = $control->id; if ( $control_id == 'bc_post_ad_code' && $ed_code == true ) return true; if ( $control_id == 'open_link_diff_tab_bc_post' && $ed_code == false ) return true; if ( $control_id == 'bc_post_ad' && $ed_code == false ) return true; if ( $control_id == 'bc_post_ad_link' && $ed_code == false ) return true; return false; } /** * Active Callback for after content AD */ function blossom_floral_pro_adac_ac( $control ){ $ed_code = $control->manager->get_setting( 'ed_ac_post_ad_code' )->value(); $control_id = $control->id; if ( $control_id == 'ac_post_ad_code' && $ed_code == true ) return true; if ( $control_id == 'open_link_diff_tab_ac_post' && $ed_code == false ) return true; if ( $control_id == 'ac_post_ad' && $ed_code == false ) return true; if ( $control_id == 'ac_post_ad_link' && $ed_code == false ) return true; return false; } /** * Active Callback for social link in contact page */ function blossom_floral_pro_contact_social_ac( $control ){ $ed_social = $control->manager->get_setting( 'ed_contact_social' )->value(); if ( $ed_social == true ) return true; return false; } /** * Active Callback for post/page */ function blossom_floral_pro_post_page_ac( $control ){ $ed_related = $control->manager->get_setting( 'ed_related' )->value(); $ed_comment = $control->manager->get_setting( 'ed_comments' )->value(); $control_id = $control->id; if ( $control_id == 'related_post_title' && $ed_related == true ) return true; if ( $control_id == 'related_taxonomy' && $ed_related == true ) return true; if ( $control_id == 'toggle_comments' && $ed_comment == true ) return true; return false; } /** * Active Callback for pagination */ function blossom_floral_pro_loading_ac( $control ){ $pagination_type = $control->manager->get_setting( 'pagination_type' )->value(); if ( $pagination_type == 'load_more' ) return true; return false; } /** * Active Callback for Shop page description */ function blossom_floral_pro_shop_description_ac( $control ){ $ed_shop_archive_desc = $control->manager->get_setting( 'ed_shop_archive_description' )->value(); $control_id = $control->id; if( $control_id == 'shop_archive_description' && $ed_shop_archive_desc == true && is_woocommerce_activated() ) return true; return false; } if( ! function_exists( 'blossom_floral_pro_shop_sec_ac' ) ) : /** * Active Callback for Shop Section */ function blossom_floral_pro_shop_sec_ac( $control ){ $shop_bg_type = $control->manager->get_setting( 'shop_bg' )->value(); $product_type = $control->manager->get_setting( 'product_type' )->value(); $control_id = $control->id; if( $control_id == 'shop_bg_image' && $shop_bg_type == 'image' ) return true; if( $control_id == 'shop_bg_color' && $shop_bg_type == 'color' ) return true; if( $control_id == 'selected_products' && $product_type == 'custom' ) return true; return false; } endif; if( ! function_exists( 'blossom_floral_pro_popular_section_ac' ) ) : /** * Active Callback for Shop Section */ function blossom_floral_pro_popular_section_ac( $control ){ $pop_post_type = $control->manager->get_setting( 'popular_type' )->value(); $control_id = $control->id; if( $control_id == 'popular_cat' && $pop_post_type == 'category' ) return true; if( $control_id == 'popular_length' && $pop_post_type == 'popular' ) return true; if( $control_id == 'custom_posts_repeater' && $pop_post_type == 'custom' ) return true; return false; } endif; function blossom_floral_pro_colors_ac( $control ){ $child_theme_support = $control->manager->get_setting( 'child_additional_support' )->value(); $control_id = $control->id; if ( $control_id == 'primary_color' && $child_theme_support == 'default' ) return true; if ( $control_id == 'secondary_color' && $child_theme_support == 'default' ) return true; if ( $control_id == 'primary_color_ff' && $child_theme_support == 'floralfashion' ) return true; if ( $control_id == 'secondary_color_ff' && $child_theme_support == 'floralfashion' ) return true; if ( $control_id == 'primary_color_et' && $child_theme_support == 'eleganttravel' ) return true; if ( $control_id == 'secondary_color_et' && $child_theme_support == 'eleganttravel' ) return true; return false; } if( ! function_exists( 'blossom_floral_pro_fonts_ac' ) ) : /** * Active Callback for Shop Section */ function blossom_floral_pro_fonts_ac( $control ){ $child_theme_support = $control->manager->get_setting( 'child_additional_support' )->value(); $control_id = $control->id; if ( $control_id == 'primary_font' && $child_theme_support == 'default' ) return true; if ( $control_id == 'secondary_font' && $child_theme_support == 'default' ) return true; if( $control_id == 'primary_font_ff' && $child_theme_support == 'floralfashion' ) return true; if( $control_id == 'secondary_font_ff' && $child_theme_support == 'floralfashion' ) return true; if( $control_id == 'primary_font_et' && $child_theme_support == 'eleganttravel' ) return true; if( $control_id == 'secondary_font_et' && $child_theme_support == 'eleganttravel' ) return true; return false; } endif; /** * Active Callback for local fonts */ function blossom_floral_pro_ed_localgoogle_fonts(){ $ed_localgoogle_fonts = get_theme_mod( 'ed_localgoogle_fonts' , false ); if( $ed_localgoogle_fonts ) return true; return false; }