Point out the WCAG error or errors in this snippet of code: "<img src="chart.png">"
- User
Point out the WCAG error or errors in this snippet of code: ""
- Assistant
The snippet of code you provided contains an image element without an
altattribute. According to the Web Content Accessibility Guidelines (WCAG), all non-text content (like images) should have a text alternative that serves the equivalent purpose. This is important for users who rely on screen readers to understand the content of a web page.Here is the WCAG error in the provided code:
html<img src="chart.png">To correct this error and make the image accessible, you should add an
altattribute that describes the image. For example, if the image is a chart showing sales data for the year, you could use:html
Other models, same or similar prompt
Responses were produced in different, uncontrolled contexts (system prompts, settings, prior turns). This is not a benchmark.