On this answer: https://kriesi.at/support/topic/shortcode-in-excerpt-new-version-enfold/#post-982080 the Enfold team had solved my question:
On the other hand I just installed Enfold Child Theme not to have to re-enter each time this line of code.
Where should I position it, because the folder: config-templatebuilder / avia-shortcodes / portfolio / portfolio.php does not exist in the Child Theme?
Hi
Where should I position it, because the folder: config-templatebuilder / avia-shortcodes / portfolio / portfolio.php does not exist in the Child Theme?
You have to build this folder structure in your child theme folder as well and then it should work smoothly.
Best
Michael
Hi kohlidays_kohsamui ,
You can find the instructions here: https://kriesi.at/documentation/enfold/intro-to-layout-builder/#add-elements-to-alb
First you’ll need to add this code on your child theme’s functions.php:
add_filter('avia_load_shortcodes', 'avia_include_shortcode_template', 15, 1);
function avia_include_shortcode_template($paths)
{
$template_url = get_stylesheet_directory();
array_unshift($paths, $template_url.'/shortcodes/');
return $paths;
}
then in your parent theme (Enfold) copy portfolio.php located in config-templatebuilder / avia-shortcodes / portfolio folder
then go to your child theme folder create a new folder and name it shortcodes then paste the portfolio.php you have copied and tweak it from there.
Best regards,
Nikko
Thanks a lot Nikko. It’s working.
Best regards to all the Team.
Hi kohlidays_kohsamui,
Glad that we could help :)
Thanks for using Enfold and have a great day!
Best regards,
Nikko