/** * Plugin compatibility checker * * Here current theme is checked for compatibility with WP PRODUCT ADDER. * * @version 1.1.2 * @package ecommerce-product-catalog/functions * @author Norbert Dreszer */ function al_product_adder_admin_notices_styles() { if (current_user_can('activate_plugins')) { if (!is_advanced_mode_forced()) { $template = get_option('template'); $integration_type = get_integration_type(); if (!empty($_GET['hide_al_product_adder_support_check'])) { update_option('product_adder_theme_support_check', $template); return; } if (get_option('product_adder_theme_support_check') !== $template && current_user_can('delete_others_products')) { product_adder_theme_check_notice(); } } if (is_ic_catalog_admin_page()) { $product_count = ic_products_count(); if ($product_count > 5) { if (false === get_transient('implecode_hide_plugin_review_info')) { implecode_plugin_review_notice(); set_transient('implecode_hide_plugin_translation_info', 1, WEEK_IN_SECONDS); } else { if (false === get_transient('implecode_hide_plugin_translation_info') && !is_english_catalog_active()) { implecode_plugin_translation_notice(); } } } else { if (false === get_transient('implecode_hide_plugin_review_info')) { set_transient('implecode_hide_plugin_review_info', 1, WEEK_IN_SECONDS); } } } } }
function is_ic_new_product_screen() { $screen = get_current_screen(); if (is_ic_catalog_admin_page() && $screen->action == 'add') { return true; } return false; }
function change_thumbnail_html($content) { if (is_ic_catalog_admin_page()) { add_filter('admin_post_thumbnail_html', 'modify_add_product_image_label'); } }