[wp-hackers] Best approach

Diana K. Cury dianakac at gmail.com
Wed Sep 28 02:43:08 UTC 2011


Thanks for your reply,

I still can't find a way to populate the taxonomies assigning the parent, I 
thinks there´s no way to do so.





----- Original Message ----- 
From: "Jeremy Clarke" <jer at simianuprising.com>
To: <wp-hackers at lists.automattic.com>
Sent: Tuesday, September 27, 2011 12:06 PM
Subject: Re: [wp-hackers] Best approach


On Mon, Sep 19, 2011 at 2:34 PM, Diana K. Cury <dianakac at gmail.com> wrote:

>
> I'm think taxonomies should do, but is ok to add soo much items like
> cities? Is there limit?!
>
>
There's no technical limit but there are usability issues that come up with
hierarchical (category-style) taxonomies if you have too many terms in them.
Specifically the category selection box is really intended for 2-100 or so
terms, more than that and it is no longer a good interface to deal with such
a long list. If the terms are actually in a complex hierarchy more than 2
levels deep it gets even worse because it's almost impossible to visualize
the hierarchy in that tiny box. I've also found (in having categories hold
world regions then countries inside them) that trying to display complex
taxonomy hierarchies on the frontend can be a big hassle and definitely
requires reworking the standard taxonomy display functions because e.g. you
don't want a list of all terms sorted alphabetically if some of them are
cities and some of them are countries, you want to show the hierarchy
somehow.

That said, any situation where you want to functionally relate
countries/states/cities together is going to be very complicated, so putting
the work into a hierarchical taxonomy solution is probably your best bet.


> I found quite easy to populate the terms using insert_terms, but there is
> someway to insert taxonomies within a prent one?!
>
>
When you insert terms you can add the 'parent' field with the term_id of the
parent you want to set. Look at the function to see how that's possible, I
may have the detail wrong but that's the essence.

-- 
Jeremy Clarke • jeremyclarke.org
Code and Design • globalvoicesonline.org
_______________________________________________
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