delete_plugin

delete_plugin

Appears in: , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , ,
Hook Type: action
See hook in action

See hook in core

Displaying hooks found in version: wordpress-6.7

do_action('delete_plugin') is found 1 times:

  • /wp-admin/includes/plugin.php line 980
    		 * @since 4.4.0
    		 *
    		 * @param string $plugin_file Path to the plugin file relative to the plugins directory.
    		 */
    		do_action( 'delete_plugin', $plugin_file );
    
    		$this_plugin_dir = trailingslashit( dirname( $plugins_dir . $plugin_file ) );
    
    		/*
    		 * If plugin is in its own directory, recursively delete the directory.
    		 * Base check on if plugin includes directory separator AND that it's not the root plugin folder.
    

See this hook used in plugins: