• hi guys,

    I work on a new project and in this project I have 3 custom post types:
    book
    translator automatically
    editor
    until now everything is easy.

    now it’s more complicated, a book is edited by an editor and translated by a translator so when I add a new book I would like to select translator and editor in a custom taxonomy (taxo-translator and taxo-editor).

    these 2 custom taxonomies are filled when I add a new translator (custom post type) and a new editor (custom post type)… actually it’s what I want to do… but is it possible and how to do that?

    an action hook after the creation of the custom post type ? how to get name and id?

    I’m not sure if I can do it easily with WP…

    Jimmy

Viewing 1 replies (of 1 total)
  • Hey…
    I’m actually doing this on one site!

    I’ve created custom taxonomies and then use wp_insert_term() when I save the page data (custom posttype).
    Not sure but I think you have to do this before you add the customfield data to the DB… At least I can’t get it to work inside the if-statement where you do add_post_meta.

    I do have a question though, if any one is reading this.

    If I’v addad e term with wp_insert_term, how can I uppdate this term in the code (not using admin panel) ?? I’m aware of the wp_update_term, but can’t get to grips of how I change the name, because in the args you can only put “alias_of”, desc, slug & parent!

    Anyone got suggestion….??

Viewing 1 replies (of 1 total)
  • The topic ‘automatic taxonomy update after add a new custom post type’ is closed to new replies.