Last active
August 29, 2015 14:04
-
-
Save themeblvd/f26312fb3480ba9f846b to your computer and use it in GitHub Desktop.
In framework 2.5, featured image size options were limited to show/hide. However, framework will still process options onto old content files (if theme has them). To put this all back in place, simply add the options back with the following.
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
<?php | |
/** | |
* In framework 2.5, featured image size options were | |
* limited to show/hide. However, framework will still | |
* process options onto old content files (if theme has them). | |
* To put this all back in place, simply add the options | |
* back with the following. | |
*/ | |
function theme_featured_image_options( $options ) { | |
$items = array('single_thumbs', 'blog_thumbs', 'archive_thumbs'); | |
foreach ( $items as $item ) { | |
$options[$item]['options'] = array( | |
'small' => __( 'Show small featured images', 'themeblvd' ), | |
'full' => __( 'Show full-width featured images', 'themeblvd' ), | |
'hide' => __( 'Hide featured images', 'themeblvd' ) | |
); | |
} | |
return $options; | |
} | |
add_filter( 'themeblvd_formatted_options', 'theme_featured_image_options' ); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment