=' ) ) { add_action( 'admin_notices', [ $this, 'admin_notice_for_minimum_elementor_version' ] ); return; } // Minimum PHP Version Check if ( version_compare( PHP_VERSION, self::MINIMUM_PHP_VERSION, '<' ) ) { add_action( 'admin_notices', [ $this, 'admin_notice_for_minimum_php_version' ] ); return; } // Include File $this->include_files(); } /*--------------------------------- * Notice For Minimum PHP Version *---------------------------------*/ public function admin_notice_for_minimum_php_version() { if ( isset( $_GET['activate'] ) ) unset( $_GET['activate'] ); $message = sprintf( esc_html__( '"%1$s" requires version %2$s or greater.', 'skb_cife' ), '' . esc_html__( 'PHP', 'skb_cife' ) . '', self::MINIMUM_PHP_VERSION ); printf( '

%1$s

', $message ); } /*-------------------------------------------- * Notice For Elementor Install / Activation *--------------------------------------------*/ public function admin_notice_for_missing_elementor() { $elementor = 'elementor/elementor.php'; /* @function skb_cife_is_plugins_active form helper function file */ if( skb_cife_is_plugins_active( $elementor ) ) { if( ! current_user_can( 'activate_plugins' ) ) { return; } $activation_url = wp_nonce_url( 'plugins.php?action=activate&plugin=' . $elementor . '&plugin_status=all&paged=1&s', 'activate-plugin_' . $elementor ); $message = '

' . __( 'Skyboot - Custom Icons for Elementor are not working because you need to activate the Elementor plugin.', 'skb_cife' ) . '

'; $message .= '

' . sprintf( '%s', $activation_url, __( 'Activate Elementor Now', 'skb_cife' ) ) . '

'; } else { if ( ! current_user_can( 'install_plugins' ) ) { return; } $install_url = wp_nonce_url( self_admin_url( 'update.php?action=install-plugin&plugin=elementor' ), 'install-plugin_elementor' ); $message = '

' . __( 'Skyboot - Custom Icons for Elementor are not working because you need to install the Elementor plugin', 'skb_cife' ) . '

'; $message .= '

' . sprintf( '%s', $install_url, __( 'Install Elementor Now', 'skb_cife' ) ) . '

'; } echo '

' . $message . '

'; } /*--------------------------------- * Notice For Minimum Elementor Version *---------------------------------*/ public function admin_notice_for_minimum_elementor_version() { if ( isset( $_GET['activate'] ) ) unset( $_GET['activate'] ); $message = sprintf( esc_html__( '"%1$s" requires version %2$s or greater.', 'skb_cife' ), '' . esc_html__( 'Elementor', 'skb_cife' ) . '', self::MINIMUM_ELEMENTOR_VERSION ); printf( '

%1$s

', $message ); } /*--------------- * Include File * --------------*/ public function include_files() { // Admin Init file if( is_admin() ){ require( SKB_CIFE_PL_PATH.'settings-api/settings-api-init.php' ); } // script manager file if ( !file_exists('class-scripts-manager.php') ){ require( SKB_CIFE_PL_PATH . 'classes/class-scripts-manager.php' ); } // Ico moon Brands icons if ( skb_cife_get_option( 'brands_icon', 'skb_cife_manage_icon', 'off') === 'on' && !file_exists('class-brands-icon.php') ){ require( SKB_CIFE_PL_PATH . 'classes/icons/class-brands-icon.php' ); } // devicons Icon if ( skb_cife_get_option( 'devicons_icon', 'skb_cife_manage_icon', 'off') === 'on' && !file_exists('class-devicons-icon.php') ){ require( SKB_CIFE_PL_PATH . 'classes/icons/class-devicons-icon.php' ); } // Elegant icon if ( skb_cife_get_option( 'elegant_icon', 'skb_cife_manage_icon', 'on') === 'on' && !file_exists('class-elegant-icon.php') ){ require( SKB_CIFE_PL_PATH . 'classes/icons/class-elegant-icon.php' ); } // Elusive icons if ( skb_cife_get_option( 'elusive_icon', 'skb_cife_manage_icon', 'off') === 'on' && !file_exists('class-elusive-icon.php') ){ require( SKB_CIFE_PL_PATH . 'classes/icons/class-elusive-icon.php' ); } // Ico Font if ( skb_cife_get_option( 'icofont_icon', 'skb_cife_manage_icon', 'off') === 'on' && !file_exists('class-icofont-icon.php') ){ require( SKB_CIFE_PL_PATH . 'classes/icons/class-icofont-icon.php' ); } // Icomoon Icon if ( skb_cife_get_option( 'icomoon_icon', 'skb_cife_manage_icon', 'off') === 'on' && !file_exists('class-icomoon-icon.php') ){ require( SKB_CIFE_PL_PATH . 'classes/icons/class-icomoon-icon.php' ); } // Iconic icons if ( skb_cife_get_option( 'iconic_icon', 'skb_cife_manage_icon', 'off') === 'on' && !file_exists('class-iconic-icon.php') ){ require( SKB_CIFE_PL_PATH . 'classes/icons/class-iconic-icon.php' ); } // Ion icon if ( skb_cife_get_option( 'ion_icon', 'skb_cife_manage_icon', 'off') === 'on' && !file_exists('class-ion-icon.php') ){ require( SKB_CIFE_PL_PATH . 'classes/icons/class-ion-icon.php' ); } // linearicons if ( skb_cife_get_option( 'linearicons_icon', 'skb_cife_manage_icon', 'on') === 'on' && !file_exists('class-linearicons-icon.php') ){ require( SKB_CIFE_PL_PATH . 'classes/icons/class-linearicons-icon.php' ); } // Line Awesome Icon if ( skb_cife_get_option( 'lineawesome_icon', 'skb_cife_manage_icon', 'off') === 'on' && !file_exists('class-lineawesome-icon.php') ){ require( SKB_CIFE_PL_PATH . 'classes/icons/class-lineawesome-icon.php' ); } // Line icon if ( skb_cife_get_option( 'line_icon', 'skb_cife_manage_icon', 'off') === 'on' && !file_exists('class-line-icon.php') ){ require( SKB_CIFE_PL_PATH . 'classes/icons/class-line-icon.php' ); } // Material Design Icon if ( skb_cife_get_option( 'materialdesign_icon', 'skb_cife_manage_icon', 'off') === 'on' && !file_exists('class-materialdesign-icon.php') ){ require( SKB_CIFE_PL_PATH . 'classes/icons/class-materialdesign-icon.php' ); } // Open Iconic icons if ( skb_cife_get_option( 'open_iconic_icon', 'skb_cife_manage_icon', 'off') === 'on' && !file_exists('class-open-iconic-icon.php') ){ require( SKB_CIFE_PL_PATH . 'classes/icons/class-open-iconic-icon.php' ); } // simpleline icon if ( skb_cife_get_option( 'simpleline_icon', 'skb_cife_manage_icon', 'off') === 'on' && !file_exists('class-simpleline-icon.php') ){ require( SKB_CIFE_PL_PATH . 'classes/icons/class-simpleline-icon.php' ); } // themify icon if ( skb_cife_get_option( 'themify_icon', 'skb_cife_manage_icon', 'on') === 'on' && !file_exists('class-themify-icon.php') ){ require( SKB_CIFE_PL_PATH . 'classes/icons/class-themify-icon.php' ); } } }