[wp-hackers] How can I filter on post count for categories?

L'Autre Monde autremonde75 at gmail.com
Thu Jun 4 06:12:05 GMT 2009


The answer is yes and no :)
Yes because this is a great idea to have a separate taxonomy for tickets to 
tag these.
No because I'd like to keep the system as "simple" as possible. So I think 
that keeping the posts together with the tickets it the best way. If I 
introduce a customer taxonomy, you can imagine the impact on the theme and 
also the plugin development. It will be released after windows 42 if I do 
that ;)

----- Original Message ----- 
From: "Joost de Valk" <joost at yoast.com>
To: <wp-hackers at lists.automattic.com>
Sent: Thursday, June 04, 2009 12:33 AM
Subject: Re: [wp-hackers] How can I filter on post count for categories?


> Arent you looking for custom taxonomies? :)
>
> L'Autre Monde wrote:
>> Mike,
>>
>> To be clear, I am currently developping a ticket system based on 
>> Wordpress.
>> So I created a custom type "ticket". I have customized the admin to 
>> include
>> this new type and duplicated the post editor with some restrictions.
>>
>> The idea behind that is that I wanted to keep wordpress built-in features 
>> intact.
>> I didn't want to tweak the post editor. So I added another menu from 
>> scratch
>> with the same functionnalities as the post editor with custom fields.
>>
>> Now that my admin I/F looks ok, I need to be able to bring the tickets 
>> with
>> the posts together on the front end. It works pretty well with some 
>> filtering
>> on the wp_query however I am stuck on this category counter ;)
>>
>> I will try the suggestion from Austin, thanks ;)
>>
>> Cheers,
>>
>> Olivier
>>
>> ----- Original Message ----- From: "Mike Schinkel" 
>> <mikeschinkel at newclarity.net>
>> To: <wp-hackers at lists.automattic.com>
>> Sent: Wednesday, June 03, 2009 7:56 PM
>> Subject: Re: [wp-hackers] How can I filter on post count for categories?
>>
>>
>>> Olivier:
>>>
>>> While I haven't drilled down yet to do this I think custom post types 
>>> could be a really important addition to WP either as a plugin or  better 
>>> yet to core. As there are so many assumptions in WordPress that  assume 
>>> "post" that doing as a plugin will be an uphill battle which is  why it 
>>> would really need to be in core.  If not in core too many other  plugins 
>>> won't support the notion of custom post types.
>>>
>>> I have a plugin I'm using for custom URLs that would fits well with 
>>> custom post types. It's not yet ready to be released because it  doesn't 
>>> yet have an admin console interface and also because it still  has a lot 
>>> of areas where it is not robust but I have been using it  with the More 
>>> Fields plugin which gives kind of a psuedo-custom post  types 
>>> capability.
>>>
>>> Anyway, the reason I email is to ask why not use More Fields because  it 
>>> works albeit not using wp_posts->post_type but instead wp_postmeta-
>>> >option_name="mf_post_type", and also to see how many other people
>>> are interested in a custom post types in core?
>>>
>>> -Mike Schinkel
>>> WordPress Custom Plugins
>>> http://mikeschinkel.com/custom-wordpress-plugins/
>>>
>>>
>>>
>>>
>>> On Jun 3, 2009, at 1:16 PM, L'Autre Monde wrote:
>>>
>>>> Hello,
>>>>
>>>> I am currently writing a plugin which creates a custom post type.  When 
>>>> the category list widget is displayed, the number of posts per 
>>>> categories only includes the posts with a post type of "post". Also, 
>>>> if a category only has the customer post type, it isn't listed as it 
>>>> is seen as an empty one.
>>>>
>>>> I have tried to filter on the get_category and list_cats to modify  the 
>>>> category->count for the category but it doesn't work :(
>>>>
>>>> Any idea for this please? :)
>>>>
>>>> Cheers!
>>>>
>>>> Olivier
>>>> _______________________________________________
>>>> wp-hackers mailing list
>>>> wp-hackers at lists.automattic.com
>>>> http://lists.automattic.com/mailman/listinfo/wp-hackers
>>>
>>> _______________________________________________
>>> wp-hackers mailing list
>>> wp-hackers at lists.automattic.com
>>> http://lists.automattic.com/mailman/listinfo/wp-hackers
>>
>> _______________________________________________
>> wp-hackers mailing list
>> wp-hackers at lists.automattic.com
>> http://lists.automattic.com/mailman/listinfo/wp-hackers
>
> -- 
> *Joost de Valk*
> SEO & Web Development (Magento & WordPress)
> OrangeValley <http://www.orangevalley.nl> & Yoast <http://yoast.com>
> E: joost at orangevalley.nl <mailto:joost at orangevalley.nl> - joost at yoast.com 
> <mailto:joost at yoast.com>
> T: +31624555808 | @yoast <http://twitter.com/yoast> on Twitter
> W: http://yoast.com/
> _______________________________________________
> wp-hackers mailing list
> wp-hackers at lists.automattic.com
> http://lists.automattic.com/mailman/listinfo/wp-hackers 



More information about the wp-hackers mailing list