Legacy shortcode for content modal

Hey team

I know you love using global blocks, but sometimes they don’t work. I ran into one of those situations and wanted to know how I can create a content modal with shortcodes.

The other option would be to create a button that links to an offscreen content modal global block. However, I need to know that I can call that global block to any page or post as the button will appear within posts that are created by the calendar, meaning there would be many dynamic urls (based on dates).

Any help is appreciated.

Hello @KMCHTX,

Thanks for writing in! Please be inform that Content Area Modal element is part of the v2 elements. It does not have a shortcode. Only those classic elements have their own shortcodes. The v2 elements such as the content area modal relies on the post meta added to the editor. Therefore, what you have in mind is not possible.

By the way, a global block needs to be added to the page first before its contents can be displayed. There is no such feature wherein a content area modal or a toggle button will load up a global block into the page without even adding the global block into the page. The global block must be at least added in the content area modal element.

Best Regards.

1 Like

Thanks for clarifying on it’s function. Cheers

You are welcome @KMCHTX

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.