Пример #1
0
/**
 * Returns an array with the post types managed by Themify,
 * where the Themify Custom Panel is initialized.
 * Filterable using themify_post_types
 * @param Array $types additional post types
 * @return Array
 * @since 1.1.5
 */
function themify_post_types($types = array())
{
    $defaults = array_merge(array('post', 'page'), themify_specific_post_types(), $types);
    return array_unique(apply_filters('themify_post_types', $defaults));
}
Пример #2
0
/**
 * Sets the WP Featured Image size selected for Query Category pages
 * @since 1.1.5 
 */
function themify_feature_size_page()
{
    global $feature_size_page, $feature_size_cpt, $feature_size_query_page, $post;
    $feature_size_query_page = $post;
    /** Get size for WP Featured Image @var String $feature_size_page*/
    $feature_size_page = themify_get('feature_size_page');
    $types = themify_specific_post_types();
    foreach ($types as $type) {
        $fs_cpt = themify_get('feature_size_' . $type);
        if (isset($fs_cpt)) {
            $feature_size_cpt = $fs_cpt;
        }
    }
}