Is there a way to add alt text to an A/B hero image test in target?

angiep33244241

02-03-2020

Hi all, 

 

I'm currently running an A/B image test and want to know if there is any way to add alt text to the image I'm testing within adobe target? We would usually have alt text added on our backend but since we are testing the image through Target we can't add it like that. 

 

Has anyone else ran into this and if so, how what were the steps you took to add alt text?

 

Thanks!

Accepted Solutions (1)

Accepted Solutions (1)

rajneesh_gautam

03-03-2020

Hi @angiep33244241 

 

You can use custom code to change Alt text:

 

// jQuery
$('img').filter(':first').attr('alt', 'My image')

// Vanilla
document.querySelector('img').setAttribute('alt', 'My image')

from: https://gist.github.com/joyrexus/7307312

 

 

Answers (0)