[wp-hackers] Time for a wp_post_relationships table?

Otto otto at ottodestruct.com
Tue Aug 3 20:53:53 UTC 2010


On Tue, Aug 3, 2010 at 2:38 PM, Lox <lox.dev at knc.nc> wrote:
> 2010/8/4 Otto <otto at ottodestruct.com>:
> Eg: I have my movies and actors custom post_types. To make the
> relation I _mirrors_ actors (title + short description) to a custom
> taxonomy actors_tax and then apply the right tax term(s) to each
> movie.

I'd just use the post_name (aka the slug) as the term instead.
post_name is at least unique.

> Since WP 3.0 I had to use custom post_type and I needed relations
> between them three times. Why? Because taxonomies are too basic: no
> HTML description, no thumbnail, no ordering. How? Using post meta
> because I didn't have the time to mess up writing a taxonomy mirroring
> system.

Yeah, but that's the point. Taxonomies are not data themselves,
they're really just relationships between your data (which is your
custom posts). The term takes a text format, but it can be anything.

Think of it like tags. A tag can be any text, but the only value in
them is the relationship that the tag defines between different posts
that share that tag.

So all you really need is your term to be minimally descriptive and unique.

-Otto


More information about the wp-hackers mailing list