Make WordPress Core

Opened 7 years ago

Closed 7 years ago

#43647 closed enhancement (duplicate)

Add "title" attribute to YouTube embeds

Reported by: thatdevgirl's profile thatdevgirl Owned by:
Milestone: Priority: normal
Severity: normal Version:
Component: Embeds Keywords:
Focuses: accessibility Cc:

Description

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.)
  1. Some alternate way is provided to the content editor in WordPress to add their own title.

Change History (1)

#1 @ocean90
7 years ago

  • Milestone Awaiting Review deleted
  • Resolution set to duplicate
  • Status changed from new to closed
  • Version trunk deleted

Hello @thatdevgirl, welcome to WordPress Trac!

Thanks for your report, this issue is already being tracked in #40245.

Note: See TracTickets for help on using tickets.