can the plugin work in custom post ??
]]>permalink: /%category%/%postname%/
]]>Sorry broken and yes I have premalinks, only 1 /%postname%/ so I guess I am out off luck with this plugins
]]>This plug-in appears to stop functioning on upgrade to 3.1.2, though it was working perfectly with 3.1 (not sure about 3.1.1). Posts belong to child categories start to appear again on the category listing after the upgrade, as if the plug-in was not installed.
]]>I’ve been wondering if there’s any way to use this awesome plugin to show just posts from one category on my Home page.
I’ve been using this workaround to show them, but it shows child categories too.
function exclude_category($query) {
if ( $query->is_home ) {
$query->set('cat', '7');
}
return $query;
}
add_filter('pre_get_posts', 'exclude_category');
and here’s the original ‘Post category only’ plugin:
class post_category_only {
static function load() {
add_action('pre_get_posts', array('post_category_only', 'pre_get_posts'));
}
static function pre_get_posts($argument) {
if($argument->is_category) {
$category = get_category_by_path($argument->query['category_name']);
if($category) {
$argument->query_vars['category__in'] = $category->cat_ID;
}
}
}
}
post_category_only::load();
Thanks for help!
]]>totally needed this … wordpress 3.1 busted some things up and a function I had that excluded child category posts from appearing in the parent category posts stopped working.
Simple and clean plugin that brings a valuable functionality to wordpress. thanks again!!
]]>