Hello @rui9075918
Thank you very much for using our plugin.
The selector for the images previews is:
#fbuilder .cff-file-field .files-list img
So, If you want to increase the size of image previou and border, you can enter the style definition below through the “Customize Form Design” attribute in the “Form Settings” tab:
#fbuilder .cff-file-field .files-list img{
width:300px !important;
border: 2px solid blue !important;
}
Best regards.
Thanks for the quick response. It already helps me a lot. But I would like to know if changing a number field, or another, could manipulate the dimensions of the image. Thanks again.
Hello @rui9075918
If you know the images selector, you can vary their appearance at the runtime by coding.
For example, assuming you have the number field fieldname123, you can insert a calculated field in the form and enter the equation:
(function(){
var css = {};
if(fieldname123 < 10) {
css['borderColor'] = 'red';
css['width'] = '100px';
} else {
css['borderColor'] = 'green';
css['width'] = '200px';
}
jQuery('#fbuilder .cff-file-field .files-list img').each(function(){jQuery(this).css(css);});
})()
The previous equation varies the images sizes and borders colors at the runtime based on the value of the fieldname123 field.
Best regards.
Thanks so much for your help. Congratulations on the quick and effective way you answered the questions I asked.