Is there a way to change the default settings for an image caption in the avia builder? I want the following settings to be in place every time a photo is put into a post:
Image caption: Yes
Caption Custom Font Size: default
Caption Appearance: Only display on hover
Caption Overlay Opacity: 0.4
Caption Overlay Background Colour: #2c353d
Caption Font Colour: #ffffff
Hey ChristineGerman,
Thank you for using Enfold.
Yes, this is possible. Please add this filter in the functions.php file.
add_filter('avf_template_builder_shortcode_elements', 'avf_template_builder_shortcode_elements_mod', 10, 9999);
function avf_template_builder_shortcode_elements_mod($elements) {
$counter = 0;
foreach($elements as $element)
{
// enable image caption by default
if($element['id'] == 'caption') {
$elements[$counter]['std'] = 'yes';
}
$counter++;
}
return $elements;
}
Best regards,
Ismael
I do have a child theme setup…Can I add that somehow as a shortcode .php file?
I tried adding it to the functions.php file and it hasn’t changed anything
Hi ChristineGerman,
Can you give us temporary admin access to your website in the private content box below, so that we can have a closer look?
Best regards,
Victoria