Fires if the cover image was successfully deleted.


do_action( '<component>_cover_image_deleted', (int) $int_cover_image_data_item_id ); 

The dynamic portion(s) of the hook will be xprofile in case of a user's cover image, groups in case of a group's cover image. For instance: Use add_action( xprofile_cover_image_deleted ) to run your specific code once the user has deleted his cover image.

Parameters (1)

0. $int_cover_image_data_item_id (int) => (int) $cover_image_data['item_id']
Inform about the item id the cover image was deleted for.


To run the hook, copy the example below.
  1. // run the action 
  2. do_action( '{$component}_cover_image_deleted', $int_cover_image_data_item_id ); 
The following example is for adding a hook callback.
  1. // define the <component>_cover_image_deleted callback 
  2. function action_component_cover_image_deleted( $int_cover_image_data_item_id ) { 
  3. // make action magic happen here... 
  4. }; 
  6. // add the action 
  7. add_action( "{$component}_cover_image_deleted", 'action_component_cover_image_deleted', 10, 1 ); 
To remove a hook callback, use the example below.
  1. // remove the action 
  2. remove_action( "{$component}_cover_image_deleted", 'action_component_cover_image_deleted', 10, 1 ); 

Defined (1)

The action is defined in the following location(s).

  1. do_action( "{$component}_cover_image_deleted", (int) $cover_image_data['item_id'] );