advantage_thumbnail_array

The Advantage advantage thumbnail array function.

Description

advantage_thumbnail_array(); 

Usage

  1. if ( !function_exists( 'advantage_thumbnail_array' ) ) { 
  2. require_once '/inc/lib-general.php'; 
  3.  
  4.  
  5. // NOTICE! Understand what this does before running. 
  6. $result = advantage_thumbnail_array(); 
  7.  

Defined (1)

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

/inc/lib-general.php  
  1. function advantage_thumbnail_array() { 
  2. $sizes = array ( 
  3. array( 'key' => '',  
  4. 'name' => __( 'Thumbnail', 'advantage' ) ),  
  5. array( 'key' => 'medium',  
  6. 'name' => __( 'Medium', 'advantage' ) ),  
  7. array( 'key' => 'large',  
  8. 'name' => __( 'Large', 'advantage' ) ),  
  9. array( 'key' => 'full',  
  10. 'name' => __( 'Full', 'advantage' ) ),  
  11. array( 'key' => 'custom',  
  12. 'name' => __( 'Custom', 'advantage' ) ),  
  13. array( 'key' => 'none',  
  14. 'name' => __( 'None', 'advantage' ) ),  
  15. ); 
  16. global $_wp_additional_image_sizes; 
  17.  
  18. if ( isset( $_wp_additional_image_sizes ) ) 
  19. foreach( $_wp_additional_image_sizes as $name => $item)  
  20. $sizes[] = array( 'key' => $name, 'name' => $name ); 
  21. return apply_filters( 'advantage_thumbnail_array', $sizes );