Shared Taxonomies: Using Dynamic Tags to Generate Filtered Archive URLs

  • Solved
  • Posted 2 weeks ago

Hi,

I have several taxonomies and some of them are common across different post types. I would like to create a card that links to the post type archive and applies the filter.

One solution is to create a template for each post type in taxonomie terms -> preview card, similar to this: @site(post_types.profile.archive)?type=@site(post_types.profile.singular)&fil_skills=@term(slug)

But since the design is the same, to avoid creating many templates, isn’t there a way to use dynamic tags and reconstruct the URL?

The parameters I would need to change are “profile” to adapt the first part @site(post_types.profile.archive) and the filter to adapt this part &fil_skills.

Thanks!