wordpress/wp-content/themes/basic/themify/themify-metabox/includes/themify-metabox-utils.php
/**
 * Checks if Woocommerce plugin is active and returns the proper value
 *
 * @return bool
 */
Checks if Woocommerce plugin is active and returns the proper value
@return bool
Checks if Woocommerce plugin is active and returns the proper value @return bool
function themify_metabox_is_woocommerce_active() {
	if(function_exists('themify_is_woocommerce_active')){
		return themify_is_woocommerce_active();
	}
	static $is = null;
	if ( $is===null ) {
		$plugin = 'woocommerce/woocommerce.php';
		include_once( ABSPATH . 'wp-admin/includes/plugin.php' );
		return is_plugin_active( $plugin )
			&& is_file( trailingslashit( WP_PLUGIN_DIR ) . $plugin );
	}
	return $is;
}
function themify_metabox_is_woocommerce_active ( ) { if ( function_exists ( 'themify_is_woocommerce_active' ) ) { return themify_is_woocommerce_active ( ) ; } static $ is = null ; if ( $ is === null ) { $ plugin = 'woocommerce/woocommerce.php' ; include_once ( ABSPATH . 'wp-admin/includes/plugin.php' ) ; return is_plugin_active ( $ plugin ) && is_file ( trailingslashit ( WP_PLUGIN_DIR ) . $ plugin ) ; } return $ is ; }
Checks if Woocommerce plugin is active and returns the proper value
 @return bool
Checks if Woocommerce plugin is active and returns the proper value @return bool
// validate if $plugin actually exists, the plugin might be active however not installed.