monsterinsights_is_settings_page

The Google Analytics for WordPress by MonsterInsights monsterinsights is settings page function.

Description

monsterinsights_is_settings_page(); 

Usage

  1. if ( !function_exists( 'monsterinsights_is_settings_page' ) ) { 
  2. require_once ABSPATH . PLUGINDIR . 'google-analytics-for-wordpress-by-monsterinsights/includes/admin/pages/settings.php'; 
  3.  
  4.  
  5. // NOTICE! Understand what this does before running. 
  6. $result = monsterinsights_is_settings_page(); 
  7.  

Defined (1)

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

/includes/admin/pages/settings.php  
  1. function monsterinsights_is_settings_page() { 
  2. $current_screen = get_current_screen(); 
  3. global $admin_page_hooks; 
  4.  
  5. if ( ! is_object( $current_screen ) || empty( $current_screen->id ) || empty( $admin_page_hooks ) ) { 
  6. return false; 
  7.  
  8. $settings_page = false; 
  9. if ( ! empty( $admin_page_hooks['monsterinsights_dashboard'] ) && $current_screen->id === $admin_page_hooks['monsterinsights_dashboard'] . '_page_monsterinsights_settings' ) { 
  10. $settings_page = true; 
  11.  
  12. if ( $current_screen->id === 'toplevel_page_monsterinsights_settings' ) { 
  13. $settings_page = true; 
  14.  
  15. return $settings_page;