woo-checkout-field-editor-pro
Last commit date
admin
3 years ago
includes
3 years ago
languages
3 years ago
public
3 years ago
checkout-form-designer.php
3 years ago
readme.txt
3 years ago
checkout-form-designer.php
41 lines
| 1 | <?php |
| 2 | /** |
| 3 | * Plugin Name: Checkout Field Editor for WooCommerce |
| 4 | * Description: Customize WooCommerce checkout fields(Add, Edit, Delete and re-arrange fields). |
| 5 | * Author: ThemeHigh |
| 6 | * Version: 1.7.0 |
| 7 | * Author URI: https://www.themehigh.com |
| 8 | * Plugin URI: https://www.themehigh.com |
| 9 | * Text Domain: woo-checkout-field-editor-pro |
| 10 | * Domain Path: /languages |
| 11 | * WC requires at least: 3.0.0 |
| 12 | * WC tested up to: 6.7 |
| 13 | */ |
| 14 | |
| 15 | if(!defined( 'ABSPATH' )) exit; |
| 16 | |
| 17 | if (!function_exists('is_woocommerce_active')){ |
| 18 | function is_woocommerce_active(){ |
| 19 | $active_plugins = (array) get_option('active_plugins', array()); |
| 20 | if(is_multisite()){ |
| 21 | $active_plugins = array_merge($active_plugins, get_site_option('active_sitewide_plugins', array())); |
| 22 | } |
| 23 | return in_array('woocommerce/woocommerce.php', $active_plugins) || array_key_exists('woocommerce/woocommerce.php', $active_plugins) || class_exists('WooCommerce'); |
| 24 | } |
| 25 | } |
| 26 | |
| 27 | if(is_woocommerce_active()) { |
| 28 | define('THWCFD_VERSION', '1.7.0'); |
| 29 | !defined('THWCFD_BASE_NAME') && define('THWCFD_BASE_NAME', plugin_basename( __FILE__ )); |
| 30 | !defined('THWCFD_PATH') && define('THWCFD_PATH', plugin_dir_path( __FILE__ )); |
| 31 | !defined('THWCFD_URL') && define('THWCFD_URL', plugins_url( '/', __FILE__ )); |
| 32 | |
| 33 | #require THWCFD_PATH . 'classes/class-thwcfd.php'; |
| 34 | require plugin_dir_path( __FILE__ ) . 'includes/class-thwcfd.php'; |
| 35 | |
| 36 | function run_thwcfd() { |
| 37 | $plugin = new THWCFD(); |
| 38 | } |
| 39 | run_thwcfd(); |
| 40 | } |
| 41 |