monsterinsights_settings_engagement

Engagement Settings.

Description

apply_filters( 'monsterinsights_settings_engagement', (callback) $var ); 

Parameters (1)

0. $var — Optional. (callback) => array( 'ignore_users' => array( 'id' => 'ignore_users', 'name' => __( 'Ignore these user roles from tracking:', 'google-analytics-for-wordpress' ), 'desc' => __( 'Users that have at least one of these roles will not be tracked into Google Analytics.', 'google-analytics-for-wordpress' ), 'type' => 'select', 'options' => monsterinsights_get_roles(), 'select2' => true, 'multiple' => true, 'allowclear' => true, ), 'events_mode' => array( 'id' => 'events_mode', 'name' => __( 'Track outbound clicks and download links?', 'google-analytics-for-wordpress' ), 'desc' => __( 'We recommend tracking clicks and downloads, so you know where users are exiting your site, and what downloads they are interacting with. ', 'google-analytics-for-wordpress', 'google-analytics-for-wordpress' ), 'type' => 'radio', 'std' => 'js', 'options' => array( 'none' => __( 'No', 'google-analytics-for-wordpress' ), 'php' => __( 'Yes, using PHP (deprecated)', 'google-analytics-for-wordpress' ), 'js' => __( 'Using Javascript (recommended)', 'google-analytics-for-wordpress' ), ), ), )
The array.

Usage

To run the hook, copy the example below.
  1. $var = apply_filters( 'monsterinsights_settings_engagement', $var ); 
  2.  
  3. if ( !empty( $var ) ) { 
  4.  
  5. // everything has led up to this point... 
  6.  
  7.  
The following example is for adding a hook callback.
  1. // define the monsterinsights_settings_engagement callback 
  2. function filter_monsterinsights_settings_engagement( $var ) { 
  3. // make filter magic happen here... 
  4. return $var
  5. }; 
  6.  
  7. // add the filter 
  8. add_filter( 'monsterinsights_settings_engagement', 'filter_monsterinsights_settings_engagement', 10, 1 ); 
To remove a hook callback, use the example below.
  1. // remove the filter 
  2. remove_filter( 'monsterinsights_settings_engagement', 'filter_monsterinsights_settings_engagement', 10, 1 ); 

Defined (1)

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

/includes/admin/settings/register-settings.php  
  1. 'engagement' => apply_filters( 'monsterinsights_settings_engagement',