[wp-trac] [WordPress Trac] #43647: Add "title" attribute to YouTube embeds

WordPress Trac noreply at wordpress.org
Tue Mar 27 17:14:19 UTC 2018


#43647: Add "title" attribute to YouTube embeds
---------------------------+-----------------------------
 Reporter:  thatdevgirl    |      Owner:
     Type:  enhancement    |     Status:  new
 Priority:  normal         |  Milestone:  Awaiting Review
Component:  Embeds         |    Version:  trunk
 Severity:  normal         |   Keywords:
  Focuses:  accessibility  |
---------------------------+-----------------------------
 '''Issue'''

 When embedding a YouTube video on a page, the `iframe` code to embed the
 video does not include a `title` tag.  The lack of title tag is an
 accessibility issue because screen readers use the title tag to get
 information about embedded content.

 This is specific to WCAG guideline 4.1.2, which is a level A guideline:
 https://www.w3.org/TR/UNDERSTANDING-WCAG20/ensure-compat-rsv.html

 '''Steps to reproduce'''

 You can use either the classic editor or Gutenberg to reproduce this
 issue.

 1. Create a new page.
 2. Paste the URL of a YouTube video into the editor. You will see a
 preview of the embedded video.
 3. Publish the page.
 4. View the page and inspect the `iframe` containing the video. Note the
 lack of `title` tag in the `iframe`.

 '''Possible fixes'''

 1. The code that creates the iframe for a YouTube video also includes a
 `title` tag with the title of the video. (This is the case with Vimeo
 video embeds.)

 2. Some alternate way is provided to the content editor in WordPress to
 add their own title.

--
Ticket URL: <https://core.trac.wordpress.org/ticket/43647>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list