https://learn.freecodecamp.org/responsive-web-design/applied-accessibility/improve-accessibility-of-audio-content-with-the-audio-element
The given page does not accept closing audio tag (</audio>
).
The condition “Make sure your audio element has a closing tag.” remains still even if I close the audio tag.
Code:
<body>
<header>
<h1>Real Coding Ninjas</h1>
</header>
<main>
<p>A sound clip of Zersiax's screen reader in action.</p>
<audio controls>
<source src="https://s3.amazonaws.com/freecodecamp/screen-reader.mp3" type="audio/mpeg" />
</audio>
</main>
</body>
Result:
// running test
Make sure your audio element has a closing tag.
// tests completed
Did you use a source element with a src and type attributes, and put it between the open and closing audio tags? Did you include controls in the audio tag?
Hello, @sdriyaz712 I was looking through this challenge and if you add an id attribute then it will not pass, and I posted my code, so you can check it out. If you have questions please tag me, and I will reply.
<body>
<header>
<h1>Real Coding Ninjas</h1>
</header>
<main>
<p>A sound clip of Zersiax's screen reader in action.</p>
<audio controls>
<source src="https://s3.amazonaws.com/freecodecamp/screen-reader.mp3"
type ="audio/mpeg" />
</audio>
</main>
</body>