parent_file) && 'plugins.php' === $screen->parent_file && 'update' === $screen->id) { return; } if ('true' === get_user_meta(get_current_user_id(), '_hello_elementor_install_notice', true)) { return; } $plugin = 'elementor/elementor.php'; $installed_plugins = get_plugins(); $is_elementor_installed = isset($installed_plugins[$plugin]); if ($is_elementor_installed) { if (!current_user_can('activate_plugins')) { return; } $message = __('AM Programación incluye el plugin Elementor. Actívalo para que funcione correctamente.', 'amprogramacion'); $button_text = __('Activar Elementor', 'amprogramacion'); $button_link = wp_nonce_url('plugins.php?action=activate&plugin=' . $plugin . '&plugin_status=all&paged=1&s', 'activate-plugin_' . $plugin); } else { if (!current_user_can('install_plugins')) { return; } $message = __('AM Programación incluye el plugin Elementor. Instálalo para que funcione correctamente.', 'amprogramacion'); $button_text = __('Instalar Elementor', 'amprogramacion'); $button_link = wp_nonce_url(self_admin_url('update.php?action=install-plugin&plugin=elementor'), 'install-plugin_elementor'); } ?>