lerizzle
Member
Posted 1 year ago #
I'm using shortcodes. Based on if a shortcode is in the code I want to use a different template (all for custom post types)
Now I assume that my action hooks 'template_redirect' has passed by the the time add_shortcode runs?
Is there an easy way to trigger a new template only if a shortcdoe is found?
lgedeon
Member
Posted 12 months ago #
@lerizzle have you considered using a custom page template that the user can select instead of using a short-code at all?
It would of course depend a bit on how you are using the short-codes. Perhaps a little more detail would help us find a workable solution.