Site icon Hip-Hop Website Design and Development

Dynamic template page calling shared taxonomies CPT or Plugin post type : how to clone taxonomy for plugin + set up dynamic shortcode

I’m building a website pro-bono for a friend searcher and making a template for 280 pages which will have the same structure as we want to be able to modify it in 1 place.

I do this with elementor template builder. In this template, I query several blocs of grid contents from different post types and it will display them depending on a common category.

For CPT, it’s easy. I shared the native post category with ACF into the Page Type + into all my CPT, then I query dynamically the id into the post grids with Crocoblocks plugin.

The logic is id of the page = id of the posts/custom posts

But, I have a pdf flipbook plugin Dearflip which has already a shortcode to display a nice grid and I don’t want to loose its functions like opening the flipbook in a modal.
It’s a CPT with posts and categories.

I don’t code myself, so I’d be happy if you can help me.

1/ I need dflip_category from this plugin to share the same post category terms like the others CPT so my page category checked can show the right contents dynamically.

2/ I need to find a way to put the shortcode in the template with a dynamic id coming from the page category as it will be the same id. So I’m looking for a way to inject the page id dynamically into the shortcode.

The shortcode grid is like this [dflip books="slug"] and I’d like something like this [dflip books="{insert_page_category_slug}"] [/dflip]

Any help with the correct code would be awesome! I’ve been searching everywhere how to do it. It’s out of my league.

Dearflip plugin CPT name : dflip taxonomy: dflip_category
my Page (ACF) taxonomy : cat_id

Thanks in advance if anyone can help.