monsterinsights_settings_compatibility

Compatibility Tracking Settings.

Description

apply_filters( 'monsterinsights_settings_compatibility', (callback) $array ); 

Parameters (1)

0. $array — Optional. (callback) => array( 'subdomain_tracking' => array( 'id' => 'subdomain_tracking', 'name' => __( 'Domain to track as:', 'google-analytics-for-wordpress' ), 'desc' => sprintf( esc_html__( 'This allows you to %1$sset the domain%2$s that\'s used for tracking. Only is used if set to a value, else defaults to automatic determination. It is very rare that you would need to use this setting.', 'google-analytics-for-wordpress' ), '' , '' ), 'type' => 'text', ), 'custom_code' => array( 'id' => 'custom_code', 'name' => __( 'Custom code', 'google-analytics-for-wordpress' ), 'desc' => sprintf( esc_html__( 'Not for the average user: this allows you to add a line of code, to be added before the %1$s call.', 'google-analytics-for-wordpress' ), '_trackPageview' ), 'type' => 'unfiltered_textarea', ), 'debug_mode' => array( 'id' => 'debug_mode', 'name' => __( 'Enable Debug Mode', 'google-analytics-for-wordpress' ), 'desc' => __( 'Turns on debugging in JS events tracking, logging of eCommerce requests and enables debug settings.', 'google-analytics-for-wordpress'), 'type' => 'checkbox', ), )
The array.

Usage

To run the hook, copy the example below.
  1. $array = apply_filters( 'monsterinsights_settings_compatibility', $array ); 
  2.  
  3. if ( !empty( $array ) ) { 
  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_compatibility callback 
  2. function filter_monsterinsights_settings_compatibility( $array ) { 
  3. // make filter magic happen here... 
  4. return $array
  5. }; 
  6.  
  7. // add the filter 
  8. add_filter( 'monsterinsights_settings_compatibility', 'filter_monsterinsights_settings_compatibility', 10, 1 ); 
To remove a hook callback, use the example below.
  1. // remove the filter 
  2. remove_filter( 'monsterinsights_settings_compatibility', 'filter_monsterinsights_settings_compatibility', 10, 1 ); 

Defined (1)

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

/includes/admin/settings/register-settings.php  
  1. 'compatibility' => apply_filters('monsterinsights_settings_compatibility',