From 9fb5b3bf10c5f890d9a9967f39a6a38b91abe202 Mon Sep 17 00:00:00 2001 From: Andrea Fercia Date: Sat, 13 Jan 2018 18:52:42 +0000 Subject: [PATCH] Plugins: Fix the plugin details modal in the install plugin search tab after [41356]. Fixes #43082 git-svn-id: https://develop.svn.wordpress.org/trunk@42443 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-admin/js/plugin-install.js | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/wp-admin/js/plugin-install.js b/src/wp-admin/js/plugin-install.js index 80e766b55d..8404b5260a 100644 --- a/src/wp-admin/js/plugin-install.js +++ b/src/wp-admin/js/plugin-install.js @@ -146,8 +146,11 @@ jQuery( document ).ready( function( $ ) { } } - // Open the Plugin details modal. - $( '.thickbox.open-plugin-details-modal' ).on( 'click', function( e ) { + /* + * Open the Plugin details modal. The event is delegated to get also the links + * in the plugins search tab, after the AJAX search rebuilds the HTML. + */ + $( 'body' ).on( 'click', '.thickbox.open-plugin-details-modal', function( e ) { // The `data-title` attribute is used only in the Plugin screens. var title = $( this ).data( 'title' ) ? plugininstallL10n.plugin_information + ' ' + $( this ).data( 'title' ) : plugininstallL10n.plugin_modal_label;