cancel
Showing results for 
Search instead for 
Did you mean: 

Adding "alt" tags for the product images in magento2

Adding "alt" tags for the product images in magento2

Hi All,

We are having lot of w3 validation errors in my website and all are related to the images alt tags as below:

Error: An img element must have an alt attribute, except under certain conditions. 

Is there any way to add alt tags for the images to solve these w3 validation errors.
We are using Magento Version: 2.1.2

Anyone have a solution for this..Please suggest me..

Thanks,
siva.

5 REPLIES

Re: Adding "alt" tags for the product images in magento2

Hi @soho_rize,

 

Are you talking about the alt text?

 

Área de trabajo 1_005.png

 

 

--
If you've found one of my answers useful, please give "Kudos" or "Accept as Solution"

Re: Adding "alt" tags for the product images in magento2

Hi Damian,

Yes..you are right..I am asking the same..
We have tried to add the alt text but it was not getting for my images.

Can you suggest any thing we need to do in product configuration(creating/editing) to get "Alt" attributes for product images.

Thanks,
Siva.

Re: Adding "alt" tags for the product images in magento2

@soho_rize,

 

I've made a new test and the alt text works right.

 

Edition:

 

Área de trabajo 1_001.png

 

Category View:

 

Área de trabajo 1_002.png

 

Product View:

 

Área de trabajo 1_003.png

 

 

Is this what you are looking for?

 

 

--
If you've found one of my answers useful, please give "Kudos" or "Accept as Solution"

Re: Adding "alt" tags for the product images in magento2

I am looking for this kind of thing in magento 1.9

 

Please suggest me, how can i do that, 

so that i can fetch the same alt text for the respective product image.

 

 

Re: Adding "alt" tags for the product images in magento2

In my instance of Magento (2.1.3), adding the alt text the way you described creates a caption and not alt text.

 

This is what it's adding to the code:

"caption":"Organic Bergamot Essential Oil, 5 ml"