With the latest release of the choices theme i can't define a "featured image".
So some other plugins, that uses this, faild (e.g. RSS images, ...)
Can't define "Featured Image". So some othe plugins failed
7 posts from 4 voices-
Posted 4 months ago #
-
Hi naranili,
Go into the theme files and open functions-choices.php. Look for:
//remove post thumbnails from pages, posts and various custom post types if(!function_exists('avia_remove_post_thumbnails')) { add_theme_support( 'post-thumbnails' ); add_action('posts_selection', 'avia_remove_post_thumbnails'); add_action('init', 'avia_remove_post_thumbnails'); add_filter('post_updated_messages','avia_remove_post_thumbnails'); function avia_remove_post_thumbnails($msg) { global $post_type; $remove_when = array('post','page','portfolio'); if(is_admin()) { foreach($remove_when as $remove) { if($post_type == $remove || (isset($_GET['post_type']) && $_GET['post_type'] == $remove)) { remove_theme_support( 'post-thumbnails' ); }; } } return $msg; } }and replace it with:
//remove post thumbnails from pages, posts and various custom post types //if(!function_exists('avia_remove_post_thumbnails')) //{ add_theme_support( 'post-thumbnails' ); // // add_action('posts_selection', 'avia_remove_post_thumbnails'); // add_action('init', 'avia_remove_post_thumbnails'); // add_filter('post_updated_messages','avia_remove_post_thumbnails'); // function avia_remove_post_thumbnails($msg) // { // global $post_type; // $remove_when = array('post','page','portfolio'); // // if(is_admin()) // { // foreach($remove_when as $remove) // { // if($post_type == $remove || (isset($_GET['post_type']) && $_GET['post_type'] == $remove)) { remove_theme_support( 'post-thumbnails' ); }; // } // } // // return $msg; // } //}This should be lines around lines 325-348.
You can then set the featured image in the Add Image pop up that appears when adding media to the visual editor.
Regards,
Devin
Posted 4 months ago # -
Doesn't work with WP 3.5
I don'T have a link at the Media-Upload to define a featured media.Posted 4 months ago # -
I think this must be :
//remove post thumbnails from pages, posts and various custom post types if(!function_exists('avia_remove_post_thumbnails')) { add_theme_support( 'post-thumbnails' ); // add_action('posts_selection', 'avia_remove_post_thumbnails'); // add_action('init', 'avia_remove_post_thumbnails'); // add_filter('post_updated_messages','avia_remove_post_thumbnails'); // function avia_remove_post_thumbnails($msg) // { // global $post_type; // $remove_when = apply_filters('avia_remove_post_thumbnails', array('post','page','portfolio')); // // if(is_admin()) // { // foreach($remove_when as $remove) // { // if($post_type == $remove || (isset($_GET['post_type']) && $_GET['post_type'] == $remove)) { remove_theme_support( 'post-thumbnails' ); }; // } // } // // return $msg; // } }Posted 4 months ago # -
Hi,
Has the code you pasted worked as you needed?
Thanks,
Nick
Posted 4 months ago # -
Yes. This code works.
Posted 3 months ago # -
Hey!
Yes, actually following line:
add_theme_support( 'post-thumbnails' );will add the "featured image" option field to the post editor screen.
Regards,
PeterPosted 3 months ago #
Reply
You must log in to post.














