コード例 #1
0
ファイル: essb-options.php プロジェクト: ajay786singh/emc
 public static function get_instance()
 {
     if (null == self::$instance) {
         self::$instance = new self();
     }
     return self::$instance;
 }
コード例 #2
0
ファイル: essb-js-builder.php プロジェクト: ajay786singh/emc
 function __construct()
 {
     $this->js_builder = array();
     $this->js_lazyload = array();
     $this->js_socialscripts = array();
     $essb_options = EasySocialShareButtons_Options::get_instance();
     $this->options = $essb_options->options;
     add_action('wp_footer', array($this, 'generate_custom_js'), 12);
 }
コード例 #3
0
 function __construct()
 {
     $essb_options = EasySocialShareButtons_Options::get_instance();
     $this->options = $essb_options->options;
     $this->loadDefaultFromOptions();
     if ($this->sso_active) {
         add_filter('language_attributes', array($this, 'insertLanguageAttributes'));
         add_action('wp_head', array($this, 'outputMeta'));
     }
 }
コード例 #4
0
 function __construct()
 {
     // initialize options
     $essb_options = EasySocialShareButtons_Options::get_instance();
     $this->options = $essb_options->options;
     $this->active = ESSBOptionsHelper::optionsBoolValue($this->options, 'native_privacy_active');
     if (ESSB_DEMO_MODE) {
         $is_active_option = isset($_REQUEST['native-privacy']) ? $_REQUEST['native-privacy'] : '';
         if ($is_active_option == 'true') {
             $this->active = true;
         }
     }
     if ($this->active) {
         $this->get_state();
         add_action('wp_enqueue_scripts', array($this, 'registerCSS'), 10);
     }
 }
コード例 #5
0
 function __construct()
 {
     $essb_options = EasySocialShareButtons_Options::get_instance();
     $this->options = $essb_options->options;
     $is_active = ESSBOptionsHelper::optionsBoolValue($this->options, 'afterclose_active');
     $is_active_option = "";
     if (ESSB_DEMO_MODE) {
         $is_active_option = isset($_REQUEST['aftershare']) ? $_REQUEST['aftershare'] : '';
         if ($is_active_option != '') {
             $is_active = true;
         }
     }
     if ($is_active) {
         $this->load_js_async = ESSBOptionsHelper::optionsBoolValue($this->options, 'load_js_async');
         $this->load($is_active_option);
     }
 }
コード例 #6
0
 public function get_post_types()
 {
     $types_to_track = array();
     $pts = get_post_types(array('public' => true, 'show_ui' => true, '_builtin' => true));
     $cpts = get_post_types(array('public' => true, 'show_ui' => true, '_builtin' => false));
     $essb_options = EasySocialShareButtons_Options::get_instance();
     $options = $essb_options->options;
     if (is_array($options)) {
         if (!isset($options['esml_monitor_types'])) {
             $options['esml_monitor_types'] = array();
         }
     }
     if (is_array($options) && isset($options['esml_monitor_types']) && is_array($options['esml_monitor_types'])) {
         global $wp_post_types;
         // classical post type listing
         foreach ($pts as $pt) {
             $selected = in_array($pt, $options['esml_monitor_types']) ? '1' : '0';
             if ($selected == '1') {
                 $types_to_track[] = $pt;
             }
         }
         // custom post types listing
         if (is_array($cpts) && !empty($cpts)) {
             foreach ($cpts as $cpt) {
                 $selected = in_array($cpt, $options['esml_monitor_types']) ? '1' : '0';
                 if ($selected == '1') {
                     $types_to_track[] = $cpt;
                 }
                 $selected = in_array($cpt, $options['esml_monitor_types']) ? 'checked="checked"' : '';
             }
         }
     }
     return $types_to_track;
 }
コード例 #7
0
 function color_customizer_compiler()
 {
     $essb_options = EasySocialShareButtons_Options::get_instance();
     $options = $essb_options->options;
     // activate_fanscounter_customizer
     $activate_fanscounter_customizer = isset($options['activate_fanscounter_customizer']) ? $options['activate_fanscounter_customizer'] : 'false';
     if ($activate_fanscounter_customizer != 'true') {
         return "";
     }
     $output = "";
     if ($activate_fanscounter_customizer == 'true') {
         $css_builder = array();
         foreach ($this->essb_supported_items as $network) {
             $color = isset($options['fanscustomizer_' . $network . '_color']) ? $options['fanscustomizer_' . $network . '_color'] : '';
             if ($color != '') {
                 $css_builder[] = '.essb-fans.colored li a i.essb-fans-icon2-' . $network . ',.essb-fans.colored li a i.essb-fans-icon-' . $network . ',.essb-fans.metro li.essb-fans-' . $network . ' a,.essb-fans.flat li.essb-fans-' . $network . ' a,.essb-fans.tiny li.essb-fans-' . $network . ' a{background-color: ' . $color . ' !important;}';
             }
         }
         if (count($css_builder) > 0) {
             wp_deregister_style('essb-fans-count-style');
             // wp_register_style ( 'essb-fans-count-style', ESSB_PLUGIN_URL
             // . '/assets/css/essb-fanscount.min.css', array (),
             // $this->version . "" . $this->module_version );
             $output .= '<link rel=\'stylesheet\' id=\'essb-fans-count-style-css\'  href=\'' . ESSB_PLUGIN_URL . '/assets/css/essb-fanscount.min.css\' type=\'text/css\' media=\'all\' />';
             $output .= '<style type="text/css">';
             foreach ($css_builder as $css) {
                 $output .= $css;
             }
             $output .= '</style>';
         }
     }
     return $output;
 }
コード例 #8
0
ファイル: essb-vk.php プロジェクト: ajay786singh/emc
<?php

$essb_options = EasySocialShareButtons_Options::get_instance();
if (function_exists('vc_map')) {
    function essb_vk_checkbox_network_selection()
    {
        global $essb_options;
        $y = $n = '';
        $options = $essb_options->options;
        $result = array();
        if (is_array($options)) {
            foreach ($options['networks'] as $k => $v) {
                $is_checked = "";
                $network_name = isset($v[1]) ? $v[1] : $k;
                $result[$network_name . '&nbsp;&nbsp;'] = $k;
            }
            return $result;
        }
    }
    $param_obj = array(array("type" => 'checkbox', "heading" => __("Social Networks", ESSB_TEXT_DOMAIN), "param_name" => "buttons", "value" => essb_vk_checkbox_network_selection()), array("type" => "dropdown", "heading" => __("Counters", ESSB_TEXT_DOMAIN), "param_name" => "counters", "value" => array(__("Yes", ESSB_TEXT_DOMAIN) => "1", __("No", ESSB_TEXT_DOMAIN) => "0")), array("type" => "dropdown", "heading" => __("Counter Position", ESSB_TEXT_DOMAIN), "param_name" => "counter_pos", "value" => array(__("Left", ESSB_TEXT_DOMAIN) => "left", __("Right", ESSB_TEXT_DOMAIN) => "right", __("Hidden", ESSB_TEXT_DOMAIN) => "none", __("Inside", ESSB_TEXT_DOMAIN) => "inside", __("Inside With Network Names", ESSB_TEXT_DOMAIN) => "insidename", __("Left Modern", ESSB_TEXT_DOMAIN) => "leftm", __("Right Modern", ESSB_TEXT_DOMAIN) => "rightm", __("Top", ESSB_TEXT_DOMAIN) => "top", __("Top Mini", ESSB_TEXT_DOMAIN) => "topm")), array("type" => "dropdown", "heading" => __("Total Counter Position", ESSB_TEXT_DOMAIN), "param_name" => "total_counter_pos", "value" => array(__("Left", ESSB_TEXT_DOMAIN) => "left", __("Right", ESSB_TEXT_DOMAIN) => "right", __("Right Big Numbers", ESSB_TEXT_DOMAIN) => "rightbig", __("Left Big Numbers", ESSB_TEXT_DOMAIN) => "leftbig", __("Hidden", ESSB_TEXT_DOMAIN) => "none")), array("type" => 'dropdown', "heading" => __("Hide Network Names", ESSB_TEXT_DOMAIN), "param_name" => "hide_names", "value" => array(__("No", ESSB_TEXT_DOMAIN) => "no", __("Yes and display them on hover", ESSB_TEXT_DOMAIN) => "yes", __("Yes and do not display them on hover (always hidden)", ESSB_TEXT_DOMAIN) => "force")), array("type" => 'textfield', "heading" => __("Custom Share URL", ESSB_TEXT_DOMAIN), "param_name" => "url"), array("type" => 'textfield', "heading" => __("Custom Share Message", ESSB_TEXT_DOMAIN), "param_name" => "text"), array("type" => 'textfield', "heading" => __("Custom Share Image", ESSB_TEXT_DOMAIN), "param_name" => "image"), array("type" => 'textfield', "heading" => __("Custom Share Description", ESSB_TEXT_DOMAIN), "param_name" => "description"), array("type" => 'checkbox', "heading" => __("Full width buttons", ESSB_TEXT_DOMAIN), "param_name" => "fullwidth", "value" => array(__("Yes", ESSB_TEXT_DOMAIN) => "yes")), array("type" => 'textfield', "heading" => __("Full width share buttons width (number)", ESSB_TEXT_DOMAIN), "param_name" => "fullwidth_fix"), array("type" => 'checkbox', "heading" => __("Fixed width buttons", ESSB_TEXT_DOMAIN), "param_name" => "fixedwidth", "value" => array(__("Yes", ESSB_TEXT_DOMAIN) => "yes")), array("type" => 'textfield', "heading" => __("Fixed width share buttons width (number in px without px in value)", ESSB_TEXT_DOMAIN), "param_name" => "fixedwidth_px"), array("type" => 'checkbox', "heading" => __("Display as sidebar", ESSB_TEXT_DOMAIN), "param_name" => "sidebar", "value" => array(__("Yes", ESSB_TEXT_DOMAIN) => "yes")), array("type" => "dropdown", "heading" => __("Sidebar position", ESSB_TEXT_DOMAIN), "param_name" => "sidebar_pos", "value" => array(__("Left", ESSB_TEXT_DOMAIN) => "left", __("Right", ESSB_TEXT_DOMAIN) => "right", __("Bottom", ESSB_TEXT_DOMAIN) => "bottom", __("Top", ESSB_TEXT_DOMAIN) => "top")), array("type" => 'checkbox', "heading" => __("Display as popup", ESSB_TEXT_DOMAIN), "param_name" => "popup", "value" => array(__("Yes", ESSB_TEXT_DOMAIN) => "yes")), array("type" => 'textfield', "heading" => __("Popup display after (sec)", ESSB_TEXT_DOMAIN), "param_name" => "popafter"), array("type" => 'checkbox', "heading" => __("Display as float bar", ESSB_TEXT_DOMAIN), "param_name" => "float", "value" => array(__("Yes", ESSB_TEXT_DOMAIN) => "yes")), array("type" => "dropdown", "heading" => __("Template", ESSB_TEXT_DOMAIN), "param_name" => "template", "value" => array(__("Default from settings", ESSB_TEXT_DOMAIN) => "", __("Default", ESSB_TEXT_DOMAIN) => "default", __("Metro", ESSB_TEXT_DOMAIN) => "metro", __("Modern", ESSB_TEXT_DOMAIN) => "modern", __("Round", ESSB_TEXT_DOMAIN) => "round", __("Big", ESSB_TEXT_DOMAIN) => "big", __("Big (Retina)", ESSB_TEXT_DOMAIN) => "big-retina", __("Metro (Retina)", ESSB_TEXT_DOMAIN) => "metro-retina", __("Light (Retina)", ESSB_TEXT_DOMAIN) => "light-retina", __("Flat (Retina)", ESSB_TEXT_DOMAIN) => "flat-retina", __("Tiny (Retina)", ESSB_TEXT_DOMAIN) => "tiny-retina", __("Round (Retina)", ESSB_TEXT_DOMAIN) => "round-retina", __("Modern (Retina)", ESSB_TEXT_DOMAIN) => "modern-retina")));
    $options = $essb_options->options;
    if (is_array($options)) {
        foreach ($options['networks'] as $k => $v) {
            $network_name = isset($v[1]) ? $v[1] : $k;
            $single_option = array("type" => "textfield", "heading" => $network_name . " custom button text", "param_name" => $k . "_text");
            $param_obj[] = $single_option;
        }
    }
    vc_map(array("name" => __("Easy Social Share Buttons", ESSB_TEXT_DOMAIN), "base" => "easy-social-share", "icon" => 'easy-social-share', "category" => __('Easy Social Share Buttons', ESSB_TEXT_DOMAIN), "description" => __("Display Social Share Buttons", ESSB_TEXT_DOMAIN), "params" => $param_obj));
}
if (function_exists('vc_map')) {
コード例 #9
0
ファイル: essb.php プロジェクト: ajay786singh/emc
 public function __construct()
 {
     global $essb_stats;
     $this->stats = $essb_stats;
     $essb_options = EasySocialShareButtons_Options::get_instance();
     $this->options = $essb_options->options;
     // @since 1.3.9.8 - new Social Share Optimization Engine
     EasySocialShareButtons_SocialShareOptimization::get_instance();
     // @since 2.0 After Share Close User Actions
     ESSBAfterCloseShare::instance();
     $this->essb_css_builder = new ESSB_CSS_Builder();
     $this->essb_js_builder = ESSB_JS_Buider::get_instance();
     $option = $this->options;
     $this->social_privacy = ESSB_Social_Privacy::get_instance();
     $remove_ver_resource = ESSBOptionsHelper::optionsBoolValue($option, 'remove_ver_resource');
     //isset($option['remove_ver_resource']) ? $option['remove_ver_resource'] : 'false';
     if ($remove_ver_resource) {
         $this->version = '';
     }
     $new_priority = isset($option['priority_of_buttons']) ? $option['priority_of_buttons'] : '';
     if (trim($new_priority) != '') {
         $new_priority = trim($new_priority);
         $new_priority = intval($new_priority);
         if ($new_priority != 0) {
             $this->custom_priority = $new_priority;
             $this->custom_priority_active = true;
         }
     }
     // @since 1.3.9.8 - GA tracking mode
     $this->ga_tracking = ESSBOptionsHelper::optionsBoolValue($option, 'activate_ga_tracking');
     //$activate_ga_tracking = isset($option['activate_ga_tracking']) ? $option['activate_ga_tracking'] : '';
     if ($this->ga_tracking == 'true') {
         //$this->ga_tracking = true;
         //$ga_tracking_mode = isset($option['ga_tracking_mode']) ? $option['ga_tracking_mode'] : '';
         $ga_tracking_mode = ESSBOptionsHelper::optionsValue($option, 'ga_tracking_mode');
         $this->essb_js_builder->include_ga_tracking_code($ga_tracking_mode);
     }
     $this->mobile_options_active = ESSBOptionsHelper::optionsBoolValue($option, 'activate_opt_by_mp');
     //$activate_opt_by_mp = isset($option['activate_opt_by_mp']) ? $option['activate_opt_by_mp'] : 'false';
     //if ($activate_opt_by_mp == 'true') {
     //	$this->mobile_options_active = true;
     //}
     $module_off_lv = isset($option['module_off_lv']) ? $option['module_off_lv'] : 'false';
     if ($module_off_lv != 'true') {
         $this->love = ESSB_LoveYou::get_instance();
     }
     $this->avoid_next_page = ESSBOptionsHelper::optionsBoolValue($option, 'avoid_nextpage');
     //$avoid_nextpage = isset($option['avoid_nextpage']) ? $option['avoid_nextpage'] : 'false';
     //if ($avoid_nextpage == "true") { $this->avoid_next_page = true; }
     // @since 1.3.9.5 - we can have specific post type options
     $this->options_by_pt_active = ESSBOptionsHelper::optionsBoolValue($option, 'activate_opt_by_pt');
     //$activate_opt_by_pt = isset($option['activate_opt_by_pt']) ? $option['activate_opt_by_pt'] : 'false';
     //if ($activate_opt_by_pt == "true") {
     //	$this->options_by_pt_active = true;
     //}
     // @since 1.3.9.5 - we can have specific post type options
     //$activate_opt_by_bp = isset($option['activate_opt_by_bp']) ? $option['activate_opt_by_bp'] : 'false';
     $this->options_by_bp_active = ESSBOptionsHelper::optionsBoolValue($option, 'activate_opt_by_bp');
     //if ($activate_opt_by_bp == "true") {
     //	$this->options_by_bp_active = true;
     //}
     $this->load_js_async = ESSBOptionsHelper::optionsBoolValue($option, 'load_js_async');
     //$load_js_async = isset($option['load_js_async']) ? $option['load_js_async'] : 'false';
     //$this->load_js_async = ($load_js_async == "true") ? true: false;
     $this->load_js_defer = ESSBOptionsHelper::optionsBoolValue($option, 'load_js_defer');
     //$load_js_defer = isset($option['load_js_defer']) ? $option['load_js_defer'] : 'false';
     //load_js_async = ($load_js_defer == "true") ? true: false;
     if ($this->load_js_defer) {
         $this->load_js_async = true;
     }
     $this->essb_js_builder->load_async = $this->load_js_async;
     $this->essb_js_builder->load_defer = $this->load_js_defer;
     add_action('wp_enqueue_scripts', array($this, 'register_front_assets'), 1);
     $this->skinned_social = ESSBOptionsHelper::optionsBoolValue($option, 'skin_native');
     //$skin_native = isset($option['skin_native']) ? $option['skin_native'] : 'false';
     //$skin_native_skin = isset($option['skin_native_skin']) ? $option['skin_native_skin'] : '';
     if ($this->skinned_social) {
         //$this->skinned_social = true;
         $this->skinned_social_selected_skin = ESSBOptionsHelper::optionsBoolValue($option, 'skin_native_skin');
     }
     if ($this->custom_priority_active) {
         add_action('the_content', array($this, 'print_share_links'), $this->custom_priority, 1);
     } else {
         add_action('the_content', array($this, 'print_share_links'), 10, 1);
     }
     $is_excerpt_active = isset($option['display_excerpt']) ? $option['display_excerpt'] : 'false';
     $apply_clean_buttons = isset($option['apply_clean_buttons']) ? $option['apply_clean_buttons'] : 'false';
     $apply_clean_buttons_method = ESSBOptionsHelper::optionsValue($option, 'apply_clean_buttons_method');
     if ($apply_clean_buttons == "true") {
         $apply_clean_buttons_method = ESSBOptionsHelper::optionsValue($option, 'apply_clean_buttons_method');
         if ($apply_clean_buttons_method != 'action') {
             add_filter('get_the_excerpt', array($this, 'remove_buttons_excerpts_method2'), -999);
         } else {
             add_filter('get_the_excerpt', array($this, 'remove_buttons_excerpts'));
         }
         //add_filter( 'the_excerpt', array( $this, 'remove_buttons_excerpts'), -999);
     }
     // @since 1.1.9
     if ($is_excerpt_active == "true") {
         if ($this->custom_priority_active) {
             add_action('the_excerpt', array($this, 'print_share_links_excerpt'), $this->custom_priority, 1);
         } else {
             add_action('the_excerpt', array($this, 'print_share_links_excerpt'), 10, 1);
         }
     }
     add_shortcode('essb', array($this, 'handle_essb_shortcode'));
     add_shortcode('easy-share', array($this, 'handle_essb_shortcode'));
     add_shortcode('easy-social-share-buttons', array($this, 'handle_essb_shortcode'));
     // @since 1.3.9.2
     add_shortcode('easy-social-like', array($this, 'handle_essb_like_buttons_shortcode'));
     add_shortcode('easy-social-like-simple', array($this, 'handle_essb_like_buttons_shortcode'));
     add_shortcode('easy-social-share', array($this, 'handle_essb_shortcode_vk'));
     // @since 1.3.9.3
     add_shortcode('easy-total-shares', array($this, 'handle_essb_total_shortcode'));
     $included_fb_api = isset($option['facebook_like_button_api']) ? $option['facebook_like_button_api'] : '';
     $facebook_advanced_sharing = isset($option['facebookadvanced']) ? $option['facebookadvanced'] : 'false';
     $facebook_like_button = isset($option['facebook_like_button']) ? $option['facebook_like_button'] : 'false';
     if ($included_fb_api != 'true' && $facebook_like_button == 'true') {
         if ($this->social_privacy->is_activated('facebook')) {
             $this->essb_js_builder->include_fb_script();
             $this->fb_api_loaded = true;
         }
     }
     $plusbutton = isset($option['googleplus']) ? $option['googleplus'] : 'false';
     if ($plusbutton == 'true') {
         //add_action ( 'wp_footer', array ($this, 'init_gplus_script' ) );
         if ($this->social_privacy->is_activated('google')) {
             $this->essb_js_builder->include_gplus_script();
             $this->gplus_loaded = true;
         }
     }
     // @since 1.0.4
     $include_vk_api = isset($option['vklike']) ? $option['vklike'] : '';
     if ($include_vk_api == 'true') {
         //add_action ( 'wp_footer', array ($this, 'init_vk_script' ) );
         if ($this->social_privacy->is_activated('vk')) {
             $this->vk_application_id = isset($option['vklikeappid']) ? $option['vklikeappid'] : '';
             //include_vk_script
             add_action('wp_head', array($this, 'include_vk_script'));
         }
     }
     // @since 1.0.7 fix for mobile devices don't to pop network names
     $hidden_network_names = isset($option['hide_social_name']) && $option['hide_social_name'] == 1 ? true : false;
     // @since 1.3.9.2
     $always_hide_names_mobile = isset($option['always_hide_names_mobile']) ? $option['always_hide_names_mobile'] : 'false';
     if ($always_hide_names_mobile == 'true' && $this->isMobile()) {
         $hidden_network_names = true;
     }
     if ($hidden_network_names && $this->isMobile()) {
         $this->essb_css_builder->fix_css_mobile_hidden_network_names();
     }
     if ($hidden_network_names && !$this->isMobile()) {
         $force_hide = isset($option['force_hide_social_name']) ? $option['force_hide_social_name'] : 'false';
         if ($force_hide == 'true') {
             $this->essb_css_builder->fix_css_mobile_hidden_network_names();
             $this->always_hidden_names = true;
         }
     }
     $hidden_buttons_on_lowres_mobile = isset($option['force_hide_buttons_on_mobile']) ? $option['force_hide_buttons_on_mobile'] : 'false';
     if ($hidden_buttons_on_lowres_mobile == 'true' && $this->isMobile()) {
         $this->essb_css_builder->fix_css_mobile_hidden_buttons();
     }
     $force_hide_icons = isset($option['force_hide_icons']) ? $option['force_hide_icons'] : 'false';
     if ($force_hide_icons == 'true') {
         $this->essb_css_builder->fix_css_hide_icons();
     }
     // @since 1.3.9.3
     $force_hide_buttons_on_all_mobile = isset($option['force_hide_buttons_on_all_mobile']) ? $option['force_hide_buttons_on_all_mobile'] : 'false';
     if ($force_hide_buttons_on_all_mobile == "true") {
         $this->deactive_content_filters();
     }
     // @since 1.1
     //add_action ( 'wp_ajax_nopriv_essb_action', array ($this, 'send_email' ) );
     //add_action ( 'wp_ajax_essb_action', array ($this, 'send_email' ) );
     // @since 1.3.1
     add_action('wp_ajax_nopriv_essb_counts', array($this, 'get_share_counts'));
     add_action('wp_ajax_essb_counts', array($this, 'get_share_counts'));
     add_action('wp_ajax_nopriv_essb_self_postcount', array($this, 'essb_self_updatepost_count'));
     add_action('wp_ajax_essb_self_postcount', array($this, 'essb_self_updatepost_count'));
     if (ESSB_SELF_ENABLED) {
         //add_action ( 'wp_ajax_nopriv_essb_self_counts', array ($this, 'get_self_share_counts' ) );
         //add_action ( 'wp_ajax_essb_self_counts', array ($this, 'get_self_share_counts' ) );
         //add_action ( 'wp_ajax_nopriv_essb_self_docount', array ($this, 'essb_self_docount' ) );
         //add_action ( 'wp_ajax_essb_self_docount', array ($this, 'essb_self_docount' ) );
         //$activate_self_hosted_counters = isset ( $option ['activate_self_hosted_counters'] ) ? $option ['activate_self_hosted_counters'] : 'false';
         //if ($activate_self_hosted_counters == 'true') {
         //	add_action ( 'wp_footer', array ($this, 'essb_self_docount_code' ) );
         $this->using_self_counters = true;
         //}
     }
     //$sidebar_draw_in_footer = isset ( $option ['sidebar_draw_in_footer'] ) ? $option ['sidebar_draw_in_footer'] : 'false';
     // since 1.3.9.9
     $sidebar_draw_in_footer = 'true';
     if ($sidebar_draw_in_footer == 'true') {
         add_action('wp_footer', array($this, 'display_sidebar_in_footer'));
     }
     $woocommerce_share = isset($option['woocommece_share']) ? $option['woocommece_share'] : 'false';
     if ($woocommerce_share == "true") {
         add_action('woocommerce_share', array($this, 'handle_woocommerce_share'));
     }
     $wpec_before_desc = isset($option['wpec_before_desc']) ? $option['wpec_before_desc'] : 'false';
     $wpec_after_desc = isset($option['wpec_after_desc']) ? $option['wpec_after_desc'] : 'false';
     $wpec_theme_footer = isset($option['wpec_theme_footer']) ? $option['wpec_theme_footer'] : 'false';
     if ($wpec_before_desc == "true") {
         add_action('wpsc_product_before_description', array($this, 'handle_wpecommerce_share'));
     }
     if ($wpec_after_desc == "true") {
         add_action('wpsc_product_addons', array($this, 'handle_wpecommerce_share'));
     }
     if ($wpec_theme_footer == "true") {
         add_action('wpsc_theme_footer', array($this, 'handle_wpecommerce_share'));
     }
     // @since 1.3.9.8 JigoShop
     $jigoshop_top = isset($option['jigoshop_top']) ? $option['jigoshop_top'] : 'false';
     $jigoshop_bottom = isset($option['jigoshop_bottom']) ? $option['jigoshop_bottom'] : 'false';
     if ($jigoshop_top == 'true') {
         add_action('jigoshop_before_single_product_summary', array($this, 'handle_jigoshop_share'));
     }
     if ($jigoshop_bottom == 'true') {
         add_action('jigoshop_after_main_content', array($this, 'handle_jigoshop_share'));
     }
     // @since 1.2.6
     $bbpress_forum = isset($option['bbpress_forum']) ? $option['bbpress_forum'] : 'false';
     $bbpress_topic = isset($option['bbpress_topic']) ? $option['bbpress_topic'] : 'false';
     $buddypress_group = isset($option['buddypress_group']) ? $option['buddypress_group'] : 'false';
     $buddypress_activity = isset($option['buddypress_activity']) ? $option['buddypress_activity'] : 'false';
     $display_where = isset($option['display_where']) ? $option['display_where'] : '';
     if ($bbpress_topic == 'true') {
         if ('top' == $display_where || 'both' == $display_where || 'float' == $display_where || 'sidebar' == $display_where || 'likeshare' == $display_where || 'sharelike' == $display_where) {
             add_action('bbp_template_before_replies_loop', array($this, 'bbp_show_before_replies'));
         }
         if ('bottom' == $display_where || 'both' == $display_where || 'popup' == $display_where || 'likeshare' == $display_where || 'sharelike' == $display_where) {
             add_action('bbp_template_after_replies_loop', array($this, 'bbp_show_after_replies'));
         }
     }
     if ($bbpress_forum == "true") {
         if ('top' == $display_where || 'both' == $display_where || 'float' == $display_where || 'sidebar' == $display_where || 'likeshare' == $display_where || 'sharelike' == $display_where) {
             add_action('bbp_template_before_topics_loop', array($this, 'bbp_show_before_topics'));
         }
         if ('bottom' == $display_where || 'both' == $display_where || 'popup' == $display_where || 'likeshare' == $display_where || 'sharelike' == $display_where) {
             add_action('bbp_template_after_topics_loop', array($this, 'bbp_show_after_topics'));
         }
     }
     if ($buddypress_group == 'true') {
         add_action('bp_before_group_home_content', array($this, 'buddy_social_button_group_filter'));
     }
     if ($buddypress_activity == 'true') {
         add_action('bp_activity_entry_meta', array($this, 'buddy_social_button_activity_filter'), 999);
     }
     // @since 2.0 myCred Integration
     $this->mycred_active = ESSBOptionsHelper::optionsBoolValue($option, 'mycred_activate');
     if ($this->mycred_active) {
         $this->mycred_group = ESSBOptionsHelper::optionsValue($option, 'mycred_group');
         $this->mycred_points = ESSBOptionsHelper::optionsValue($option, 'mycred_points');
     }
     // @since 1.2.7
     /*$opengraph_tags = isset ( $option ['opengraph_tags'] ) ? $option ['opengraph_tags'] : 'false';
     		
     		if ($opengraph_tags == 'true') {
     			// @since 1.3.9.8
     			$opengraph = ESSB_OpenGraph::get_instance();
     			// @since 1.3.7.3
     			$opengraph->fbadmins = isset ( $option ['opengraph_tags_fbadmins'] ) ? $option ['opengraph_tags_fbadmins'] : '';
     			$opengraph->fbpage = isset ( $option ['opengraph_tags_fbpage'] ) ? $option ['opengraph_tags_fbpage'] : '';
     			$opengraph->fbapp = isset ( $option ['opengraph_tags_fbapp'] ) ? $option ['opengraph_tags_fbapp'] : '';
     			$opengraph->default_image = isset ( $option ['sso_default_image'] ) ? $option ['sso_default_image'] : '';
     			
     			$opengraph->activate_opengraph_metatags ();
     		}
     		
     		// @since 1.3.6
     		$twitter_card_active = isset ( $option ['twitter_card'] ) ? $option ['twitter_card'] : 'false';
     		
     		if ($twitter_card_active == "true") {
     			// @since 1.3.9.8 moved to singleton pattern
     			$twitter_cards = ESSB_TwitterCards::get_instance();
     			$twitter_cards->card_type = isset ( $option ['twitter_card_type'] ) ? $option ['twitter_card_type'] : '';
     			$twitter_cards->twitter_user = isset ( $option ['twitter_card_user'] ) ? $option ['twitter_card_user'] : '';
     			$twitter_cards->default_image = isset ( $option ['sso_default_image'] ) ? $option ['sso_default_image'] : '';
     			
     			$twitter_cards->activate_twittercards_metatags ();
     		}
     		*/
     // @since 1.3.9.5
     $this->essb_css_builder->insert_total_shares_text();
     $this->essb_css_builder->handle_postfloat_custom_css();
     $this->essb_css_builder->customizer_compile_css($this->skinned_social);
     $encode_url_nonlatin = isset($option['encode_url_nonlatin']) ? $option['encode_url_nonlatin'] : 'false';
     if ($encode_url_nonlatin == "true") {
         add_action('template_redirect', array($this, 'essb_sharing_process_requests'), 9);
     }
 }