0
votes

I've created a simple custom post type for adding Teams. In the post type teams i've added a couple of teams.

To show those teams in the menu i've created a page called teams. In the menu the parent page is the page teams, where i've added the custom post type teams, example

  • Teams (page post type) -- team 1 (custom post type teams) -- team 2 (custom post type teams)

This works perfectly for the menu. But there seems to be a conflict in the breakcrumbs.

When visiting the custom post type page team 2, the breadcrumb is as following:

home / teams / team2.

The problem is when i click on teams it goes to the archive page, but i want i to go to the normal teams page. I think this is a conflict with the same name for the page teams and the custom post type teams.

I've tried to disable the option has_archive, but then the following breadcrumb is created:

home / team2

And this is not how i want it. Does anyone has a solution for this?

2

2 Answers

0
votes

Create a taxonomy-{taxonomy1-slug}.php and taxonomy-{taxonomy2-slug}.php page for saperate templates.

0
votes

I've solved this.

Page name is teams and ctp is teams. After adding this to the settings for ctp:

'has_archive' => 'teams/' (added the slash)

The conflict has been solved.