Combine text with CMS text field for image alt text

As the title says, is it possible to combine text and cms text field for an alt tag on an collaction image?

For example “Sometext + {Collection:ThisField}” in the img alt tag under the html editor.

1 Like

Vote here:

You can’t just ADD a alt tag to a CMS image using custom code,you need to add both image and alt using code. You’ll use a custom code component to declare the image and the alt, and use CMS data for both. Problem is you can’t call a CMS image from a custom code component, so your image would have to be hosted somewhere and entered as a URL in the database.

EDIT I’m wrong, you can totally call an image from the CMS in a custom code box and have its url printed. So juste declare your entire image in the custom code box and define variable for image url and alt text, linking to your CMS data.