tribe_community_tickets_get_woocommerce_info_array()

Get the array of plugin information used by Common’s Dependency and elsewhere in this plugin.


Return

(array)


Top ↑

Source

File: events-community-tickets.php

function tribe_community_tickets_get_woocommerce_info_array() {
	/**
	 * Setting the path helps Tribe__Admin__Notice__Plugin_Download
	 *
	 * First check if already defined (i.e. if Woo is active).
	 * If not active, check if plugin file exists. If it does, we've confirmed it's there.
	 * If Woo files don't exist where expected, just send it anyway since Woo isn't active (based on define not being set).
	 */
	if ( defined( 'WC_PLUGIN_FILE' ) ) {
		$path = WC_PLUGIN_FILE;
	} else {
		$path = trailingslashit( dirname( plugin_dir_path( __FILE__ ) ) ) . 'woocommerce/woocommerce.php';
	}

	return [
		'short_name'   => 'WooCommerce',
		'class'        => 'WooCommerce',
		'path'         => $path,
		'thickbox_url' => 'plugin-install.php?tab=plugin-information&plugin=woocommerce&TB_iframe=true',
	];
}

Top ↑

Changelog

Changelog
Version Description
4.7.1 Introduced.