# Image title and alt tags not displaying

**URL:** https://meta.discourse.org/t/image-title-and-alt-tags-not-displaying/38918
**Category:** Support
**Created:** [2월 2, 2016, 7:59오후 UTC](https://meta.discourse.org/t/image-title-and-alt-tags-not-displaying/38918 "2016-02-02T19:59:24Z")
**Posts on this page:** 12
**Page:** 1

<div class="post-metadata">

### Author: ![pfaffman](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/pfaffman/32/120154_2.png) [@pfaffman](https://meta.discourse.org/u/pfaffman)
#### Post date: [2월 2, 2016, 7:59오후 UTC](https://meta.discourse.org/t/image-title-and-alt-tags-not-displaying/38918/1 "2016-02-02T19:59:24Z")

</div>

I’m in academia and there’s a huge push about accessibility since Harvard and MIT got ADA suits because MOOCs weren’t screen-reader compliant. I’m trying to be a good citizen and include alt tags, but it seems that they are not showing up. They’re in the HTML, though, so I guess screen readers will see them. It makes it hard for me to check, though. I guess this is a simple CSS fix?

I can’t see alt or title tags on this image:

![this is an alt tag](https://global.discourse-cdn.com/meta/original/3X/4/f/4faf3120c821aa8e239fe74c8568ca4afaca6433.png "This is the picture title")

On a related note, it would be nice if the `<img ...>` tags that get created on an upload included something like `alt="image description"` so that people who don’t know to add that get a little bit of help.

---

<div class="post-metadata">

### Author: ![codinghorror](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/codinghorror/32/110067_2.png) [@codinghorror](https://meta.discourse.org/u/codinghorror)
#### Post date: [2월 2, 2016, 8:09오후 UTC](https://meta.discourse.org/t/image-title-and-alt-tags-not-displaying/38918/2 "2016-02-02T20:09:58Z")

</div>

Er.. what? Look at the browser DOM.

 ![](https://global.discourse-cdn.com/meta/original/3X/e/1/e109817776c3b08fbc0dbfaf498a6e04d81855bc.png)

```plaintext
<img src="https://global.discourse-cdn.com/meta/original/3X/4/f/4faf3120c821aa8e239fe74c8568ca4afaca6433.png" 
width="206" height="44" 
alt="this is an alt tag" 
title="This is the picture title">

```

In Markdown you do it this way

`![Image text goes here](http://commonmark.org/help/images/favicon.png)`

Feel free to send links to [our Markdown help page](http://commonmark.org/help), and the 10 minute interactive tutorial is on a big giant button there.

---

<div class="post-metadata">

### Author: ![pfaffman](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/pfaffman/32/120154_2.png) [@pfaffman](https://meta.discourse.org/u/pfaffman)
#### Post date: [2월 2, 2016, 8:54오후 UTC](https://meta.discourse.org/t/image-title-and-alt-tags-not-displaying/38918/3 "2016-02-02T20:54:45Z")

</div>

Well, I see it now. It didn’t make sense that this could be a problem, but I swear that those weren’t showing up when I posted this.

---

<div class="post-metadata">

### Author: ![codinghorror](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/codinghorror/32/110067_2.png) [@codinghorror](https://meta.discourse.org/u/codinghorror)
#### Post date: [2월 2, 2016, 8:59오후 UTC](https://meta.discourse.org/t/image-title-and-alt-tags-not-displaying/38918/4 "2016-02-02T20:59:01Z")

</div>

Well, there is a slight difference between a reply inserted dynamically in the page in _your_ browser when the reply is composed, and what is rendered to everyone else who reads it (or if you re-enter the topic, or refresh the page etc).

---

<div class="post-metadata">

### Author: ![dictoon](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/dictoon/32/47968_2.png) [@dictoon](https://meta.discourse.org/u/dictoon)
#### Post date: [12월 2, 2018, 12:40오후 UTC](https://meta.discourse.org/t/image-title-and-alt-tags-not-displaying/38918/5 "2018-12-02T12:40:34Z")

</div>

The Markdown fragment

```
![SPPM with RT Direct Lighting](upload://x1828bKPKA0BZDckEtlgeNFwad0.jpeg)

```

does correctly produce an `<img>` tag with an `alt` attribute, however it would be nice if that image title or description would be shown when hovering over the image or clicking on it. Currently it’s not shown anywhere:

 ![This title is not shown anywhere](https://global.discourse-cdn.com/meta/original/3X/a/0/a08cbe9d0a1cd3b8f959ce8daad86891a609f0d7.png)

(In fact the title I’ve set on this image is not shown anywhere.)

This is with Discourse v2.2.0.beta1 +22.

---

<div class="post-metadata">

### Author: ![D8vid](https://avatars.discourse-cdn.com/v4/letter/d/b38774/32.png) [@D8vid](https://meta.discourse.org/u/D8vid)
#### Post date: [6월 7, 2019, 11:37오전 UTC](https://meta.discourse.org/t/image-title-and-alt-tags-not-displaying/38918/6 "2019-06-07T11:37:37Z")

</div>

> [@dictoon](#):
>
> it would be nice if that image title or description would be shown when hovering over the image or clicking on it. Currently it’s not shown anywhere

I liked this reply and tried to find the github issue form, so, um, small **bump**.

---

<div class="post-metadata">

### Author: ![codinghorror](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/codinghorror/32/110067_2.png) [@codinghorror](https://meta.discourse.org/u/codinghorror)
#### Post date: [6월 8, 2019, 12:59오전 UTC](https://meta.discourse.org/t/image-title-and-alt-tags-not-displaying/38918/7 "2019-06-08T00:59:50Z")

</div>

What is being advocated here for is to duplicate the `alt=` and `title=` elements on the `<img>` tag but I remember reading that this is not recommended a bunch of places. For example

> **[HTML Standard](https://html.spec.whatwg.org/multipage/dom.html)**

> Relying on the title attribute is currently discouraged as many user agents do not expose the attribute in an accessible manner as required by this specification (e.g. requiring a pointing device such as a mouse to cause a tooltip to appear, which excludes keyboard-only users and touch-only users, such as anyone with a modern phone or tablet).

`alt` is the important attribute, `title` is kinda.. honestly irrelevant in today’s mostly-smartphone world?

---

<div class="post-metadata">

### Author: ![D8vid](https://avatars.discourse-cdn.com/v4/letter/d/b38774/32.png) [@D8vid](https://meta.discourse.org/u/D8vid)
#### Post date: [6월 9, 2019, 1:11오전 UTC](https://meta.discourse.org/t/image-title-and-alt-tags-not-displaying/38918/8 "2019-06-09T01:11:20Z")

</div>

I think the issue is more about which info lightbox uses to caption an image (the caption bar which appears on mouseover/touchscreen-press, and always visible in the gallery viewer).

The lightbox caption bar currently appears to use info from a title attribute in a.class=lightbox, where that title attribute holds the image’s filename, plus image resolution & filesize (the image filename appears again in the mouseover tooltip, where it seems lightbox is generating this tooltip using CSS, as the img tag has no title attribute).

Preferred would be for lightbox to use the img alt data from markdown in the caption bar, i.e. from `[alt text]($img_url)`, with perhaps the complete filename/resolution/filesize in the mouseover tooltip (info which is potentiallly useful for a desktop user, not so much for a touch-device user).

---

<div class="post-metadata">

### Author: ![D8vid](https://avatars.discourse-cdn.com/v4/letter/d/b38774/32.png) [@D8vid](https://meta.discourse.org/u/D8vid)
#### Post date: [6월 9, 2019, 1:35오전 UTC](https://meta.discourse.org/t/image-title-and-alt-tags-not-displaying/38918/9 "2019-06-09T01:35:28Z")

</div>

Err, I see now looking more closely at the [RAW](https://meta.discourse.org/raw/38918), the HTML source, the ‘related note’, and follow-ups, how this ambiguously titled topic ended up conflating a feature change request with a non-issue. oops!

---

<div class="post-metadata">

### Author: ![ad-si](https://avatars.discourse-cdn.com/v4/letter/a/e68b1a/32.png) [@ad-si](https://meta.discourse.org/u/ad-si)
#### Post date: [10월 9, 2019, 3:26오후 UTC](https://meta.discourse.org/t/image-title-and-alt-tags-not-displaying/38918/10 "2019-10-09T15:26:31Z")

</div>

라이트박스 오버레이를 개선하는 아이디어에 대해 정식 기능 요청을 등록했습니다: [Display an Image's alt or title attribute in ligthbox overlay](https://meta.discourse.org/t/display-an-images-alt-or-title-attribute-in-ligthbox-overlay/130579)

---

<div class="post-metadata">

### Author: ![system](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/system/32/443519_2.png) [@system](https://meta.discourse.org/u/system)
#### Post date: [6월 11, 2023, 5:22오전 UTC](https://meta.discourse.org/t/image-title-and-alt-tags-not-displaying/38918/11 "2023-06-11T05:22:44Z")

</div>



---

<div class="post-metadata">

### Author: ![JammyDodger](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/jammydodger/32/254611_2.png) [@JammyDodger](https://meta.discourse.org/u/JammyDodger)
#### Post date: [6월 11, 2023, 5:29오전 UTC](https://meta.discourse.org/t/image-title-and-alt-tags-not-displaying/38918/12 "2023-06-11T05:29:25Z")

</div>


