woocommerce
Last commit date
assets
7 years ago
i18n
7 years ago
includes
4 years ago
sample-data
7 years ago
templates
7 years ago
license.txt
7 years ago
readme.txt
4 years ago
uninstall.php
7 years ago
woocommerce.php
4 years ago
woocommerce.php
43 lines
| 1 | <?php |
| 2 | /** |
| 3 | * Plugin Name: WooCommerce |
| 4 | * Plugin URI: https://woocommerce.com/ |
| 5 | * Description: An eCommerce toolkit that helps you sell anything. Beautifully. |
| 6 | * Version: 3.5.10 |
| 7 | * Author: Automattic |
| 8 | * Author URI: https://woocommerce.com |
| 9 | * Text Domain: woocommerce |
| 10 | * Domain Path: /i18n/languages/ |
| 11 | * |
| 12 | * @package WooCommerce |
| 13 | */ |
| 14 | |
| 15 | if ( ! defined( 'ABSPATH' ) ) { |
| 16 | exit; // Exit if accessed directly. |
| 17 | } |
| 18 | |
| 19 | // Define WC_PLUGIN_FILE. |
| 20 | if ( ! defined( 'WC_PLUGIN_FILE' ) ) { |
| 21 | define( 'WC_PLUGIN_FILE', __FILE__ ); |
| 22 | } |
| 23 | |
| 24 | // Include the main WooCommerce class. |
| 25 | if ( ! class_exists( 'WooCommerce' ) ) { |
| 26 | include_once dirname( __FILE__ ) . '/includes/class-woocommerce.php'; |
| 27 | } |
| 28 | |
| 29 | /** |
| 30 | * Main instance of WooCommerce. |
| 31 | * |
| 32 | * Returns the main instance of WC to prevent the need to use globals. |
| 33 | * |
| 34 | * @since 2.1 |
| 35 | * @return WooCommerce |
| 36 | */ |
| 37 | function wc() { |
| 38 | return WooCommerce::instance(); |
| 39 | } |
| 40 | |
| 41 | // Global for backwards compatibility. |
| 42 | $GLOBALS['woocommerce'] = wc(); |
| 43 |