st_woo_ai_rel_products_constant(); $this->st_woo_ai_rel_products_core(); } public function st_woo_ai_rel_products_constant() { global $wp_version; define('ST_WOO_AI_REL_PRODUCTS_WP_VERSION', $wp_version); define('ST_WOO_AI_REL_PRODUCTS_BASE_PATH', dirname(__FILE__)); define('ST_WOO_AI_REL_PRODUCTS_URL_PATH', plugin_dir_url(__FILE__)); define('ST_WOO_AI_REL_PRODUCTS_PLUGIN_BASE_PATH', plugin_basename(__FILE__)); define('ST_WOO_AI_REL_PRODUCTS_PLUGIN_FILE_PATH', (__FILE__)); } public function deactivate_plugin($plugin) { if ($plugin === 'ai-related-product-pro/ai-related-products.php') { deactivate_plugins('ai-related-products/ai-related-products.php'); } } public function st_woo_ai_rel_products_core() { include_once ST_WOO_AI_REL_PRODUCTS_BASE_PATH . '/include/core.php'; } } } if (!function_exists('ST_Woo_Ai_Rel_Products')) { function ST_Woo_Ai_Rel_Products() { return ST_WOO_AI_REL_PRODUCTS::get_instance(); } } if (!function_exists('st_woo_ai_rel_products_admin_install_woo_notice')) { function st_woo_ai_rel_products_admin_install_woo_notice() { $class = 'notice notice-warning'; $message = __('WooCommerce Smart Related Products Plugin is a supportive addon for WooCommerce. Please install and activate the WooCommerce plugin.', 'ai-related-products'); $label = __('Install WooCommerce', 'ai-related-products'); $url = admin_url('plugin-install.php?s=woocommerce&tab=search&type=term'); printf('
%2$s %4$s