Skip Navigation

[Assigned] Many 2 Many with Taxonomy

This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.

No supporters are available to work today on Toolset forum. Feel free to create tickets and we will handle it as soon as we are online. Thank you for your understanding.

Sun Mon Tue Wed Thu Fri Sat
- 10:00 – 13:00 10:00 – 13:00 10:00 – 13:00 10:00 – 13:00 10:00 – 13:00 -
- 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 -

Supporter timezone: Asia/Kolkata (GMT+05:30)

This topic contains 7 replies, has 3 voices.

Last updated by Griffin 1 day, 21 hours ago.

Assisted by: Minesh.

Author
Posts
#2762856

Tell us what you are trying to do?
I have a content type called Song
I also have another content type called Person (they are for credits, ie. musician)
I have a taxonomy called Instruments

I want to have a m2m relationship between song and person (that's easy), but instead of extra fields, would like to use the instruments taxonomy so I use a consistent and reusable data source.

Is there any documentation that you are following?
No
Is there a similar example that we can see?

What is the link to your site?

#2763156

Minesh
Supporter

Languages: English (English )

Timezone: Asia/Kolkata (GMT+05:30)

Hello. Thank you for contacting the Toolset support.

You can either add taxonomy to post types that you include in many-to-many post relationship.

The intermediary post type that will seat between your two many to many post type and you can not add taxonomy to intermediary post type. You can add only custom fields.

For instance you have post type X and post type Y, then you can assign taxonomy to both post type X and post type Y but when you create many-to-many post relationship it will offer you intermediary post type generated automatically lets say (manytomanyxy post type) that will seat between post type X and post type Y and you can not assign taxonomy to this intermediary post type.

#2763359

I understand that, but the point was to not have to, for example, write Guitar everytime. Also, if I wanted to see all the guitar player credits that's not possible. Taxonomy solves that if it could be linked in the M2M Intermediate post. Since you can't do that, I'll try something else. Drupal, did that BTW, so I know it's possible.

#2763492

Christopher Amirian
Supporter

Languages: English (English )

Hi,

This is Christopher. I'm here to inform you that Minesh will not be available today. He will answer the question tomorrow.

Most probably he will say that it is not possible with Toolset as it is what I also understand.

I appreciate your patience.

#2765288

Minesh
Supporter

Languages: English (English )

Timezone: Asia/Kolkata (GMT+05:30)

As per the Toolset many to many post relationship you can add custom fields to intermediary post type that seats between the two post types of many to many post relationship hence its not possible to hook in taxonomy by to intermediary post type, only the custom fields are allowed. You can say its limitation by design of many to many post relationship.

#2765298

Okay, I'll try to work around it, but taking the example of A song has many credits (people), and credits are on many songs, can you think of anyway to use the custom field in the intermediate post to link them (i.e. look up all Joe Green credits?) That's mainly what I'm looking for.

#2765925

Minesh
Supporter

Languages: English (English )

Timezone: Asia/Kolkata (GMT+05:30)

Here is a sandbox site and you can auto-login to it using the following link:
- hidden link

Can you please create your post types, many-to-many relationship with intermediary post by adding custom field and add few posts and connect them in relationship and tell me on what post/page you want to display what and then I will be able to guide you in the right direction.

#2767262

Okay, that is there, I added some data. Also, I can never add a person more than once on a track with the instrument even with it set to multiple.

Basically, every song can have multiple musicians (people), and they can play on multiple instruments per track (which it won't let me do now). I would like to click on a person and find what tracks etc. they play on and what instrument, and from a data point, not have to type in instruments all the time, but that's a lesser problem.