jetpack_social_menu_get_type

Return the type of menu the theme is using.

Description

(null|string) jetpack_social_menu_get_type(); 

Returns (null|string)

$menu_type


Usage

  1. if ( !function_exists( 'jetpack_social_menu_get_type' ) ) { 
  2. require_once '/modules/theme-tools/social-menu.php'; 
  3.  
  4.  
  5. // NOTICE! Understand what this does before running. 
  6. $result = jetpack_social_menu_get_type(); 
  7.  

Defined (1)

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

/modules/theme-tools/social-menu.php  
  1. function jetpack_social_menu_get_type() { 
  2. $options = get_theme_support( 'jetpack-social-menu' ); 
  3.  
  4. if ( empty( $options ) ) { 
  5. $menu_type = null; 
  6. } else { 
  7. $menu_type = ( in_array( $options[0], array( 'genericons', 'svg' ) ) ) ? $options[0] : 'genericons'; 
  8.  
  9. return $menu_type;