Adding Global Blocks to every Post after content, before Footer

Can someone please help me how to Add a Global Block to every Post after content, but before Footer?

Thank you!

Hello There,

Thanks for writing in! Because what you are trying to accomplish requires a template customization, we would highly to suggest that you use a child theme. This allows you to make code changes that won’t be overwritten when an X update is released.

After the child theme is set up, please add the following code in your child theme’s functions.php file

function add_global_blocks_single_post(){
  echo do_shortcode('[cs_gb id=123]');
}
add_action('x_after_the_content_end', 'add_global_blocks_single_post');

And just make sure that you have replace [cs_gb id=123] with the correct global block shortcode.

Hope this helps. Please let us know how it goes.

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