# Alt-text for images when using @Html.ImageFor

**URL:** <https://forum.litium.com/t/alt-text-for-images-when-using-html-imagefor/1594>\
**Category:** Questions\
**Tags:** litium-7\
**Created:** [August 19, 2020, 12:17pm UTC](https://forum.litium.com/t/alt-text-for-images-when-using-html-imagefor/1594 "2020-08-19T12:17:51Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![leifbystrom](https://avatars.discourse-cdn.com/v4/letter/l/3ab097/32.png) [@leifbystrom](https://forum.litium.com/u/leifbystrom)\
**Post date:** [August 19, 2020, 12:17pm UTC](https://forum.litium.com/t/alt-text-for-images-when-using-html-imagefor/1594/1 "2020-08-19T12:17:51Z")

</div>

When using @Html.ImageFor to display images for the product images, it should get the alt-text from the ImageModel.Alt if it’s set, but its null on all of the images i fetch from the product.  
Is there a mapping to a specific field/fieldname or anything like that I could use to get the Alt-text mapped and set on the images?

Litium version: 7.2.3

---

<div class="post-metadata">

**Author:** ![steve.redstorm](https://yyz2.discourse-cdn.com/flex030/user_avatar/forum.litium.com/steve.redstorm/32/14_2.png) [@steve.redstorm](https://forum.litium.com/u/steve.redstorm)\
**Post date:** [August 19, 2020, 12:24pm UTC](https://forum.litium.com/t/alt-text-for-images-when-using-html-imagefor/1594/2 "2020-08-19T12:24:44Z")

</div>

You can check this query:

> [@Alt text is not mapped](https://forum.litium.com/t/alt-text-is-not-mapped/1441):
>
> I have a ImageProperty in a pagetype. And it looks like this in the CMS But the ALT text is not mapped to the image model by the automapper. [image] [image] Why is the alt text not mapped? Something im missing? Litium version: 6.2.3

---

<div class="post-metadata">

**Author:** ![system](https://canada1.discourse-cdn.com/flex030/uploads/litium/original/1X/12eddac3b8b661de1db86af10ac8151b571e6fb9.png) [@system](https://forum.litium.com/u/system)\
**Post date:** [September 16, 2020, 12:24pm UTC](https://forum.litium.com/t/alt-text-for-images-when-using-html-imagefor/1594/3 "2020-09-16T12:24:57Z")

</div>

Closed on September 16, 2020, 12:24pm UTC

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
