Created
November 8, 2012 18:41
-
-
Save WebEndevSnippets/4040667 to your computer and use it in GitHub Desktop.
WordPress: Display Custom Image Sizes in Media Gallery
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
add_filter( 'image_size_names_choose', 'we_custom_image_sizes_choose' ); | |
/** | |
* Display custom image sizes in Media Gallery | |
* | |
*/ | |
function we_custom_image_sizes_choose( $sizes ) { | |
$custom_sizes = array( | |
'slider-1140' => 'Wide', | |
); | |
return array_merge( $sizes, $custom_sizes ); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment