Hi there, thank you for your suggestion, but I have choose another way, use a custom shortcode so I can put my content where I want. The problem is this shortcode isn’t parsed by the site and I see the plain text
I have followed all the steps to create a custom shortcode:
-
Create the function to execute and save it in a php file that I have put into wp-content folder
-
Include this file in functions.php and register the shortcode with the following lines
include(content_url() . '/custom-shortcodes.php');
add_shortcode( "home_post_shortcode_sc" , "home_post_shortcode" );
I have checked the function name and it’s correct. Since I’m using WpBakery page builder, I have also tried to register this shortcode inside Shortcode mapper and then put it inside page as a page builder element, but without results.
You can see the shortcode in (no) action here: https://www.e-maxsrl.it/shortcode-test/
Is there another way to use custom shortcode within x-theme?
Can you help me find where is the issue? Thank you very much
EDIT: if I put my function directly inside my functions.php, the shortcode works. But I would like to load it externally for some security reason.