Quantcast
Channel: Topic Tag: action | WordPress.org
Viewing all articles
Browse latest Browse all 889

Bug Report and Solutions

$
0
0

WordPress Core 5.3.2
WP Smartcrop 2.0.5

Hi! I found that there is an action filter ‘wp_enqueue_media’ is being added in wp-smartcrop.php but it will not be fired because wp_enqueue_media(); is never runs.

I test by deactivating all plugins and found. It works while working with some plugins because those plugins run wp_enqueue_media(); somewhere.

So, to solve this problem, the following action filter is needed:

add_action( ‘admin_enqueue_scripts’, array( $this, ‘admin_enqueue_scripts’ ) );
function admin_enqueue_scripts() {
wp_enqueue_media();
}

Before it is being updated, anyone meet the same problem could add the above filter to your functions.php by changing it to non-plugin format. (without using array and “this”)


Viewing all articles
Browse latest Browse all 889

Trending Articles