Tell us what’s happening:
I dont know how to use the alt tag after an img tag
Your code so far
<html>
<body>
<main>
<h1>CatPhotoApp</h1>
<h2>Cat Photos</h2>
<!-- TODO: Add link to cat photos -->
<p>Everyone loves cute cats online!</p>
<!-- User Editable Region -->
<img src="https://cdn.freecodecamp.org/curriculum/cat-photo-app/relaxing-cat.jpg" "alt="A cute orange cat lying on its back/>
<!-- User Editable Region -->
</main>
</body>
</html>
Your browser information:
User Agent is: Mozilla/5.0 (Linux; Android 10; K) AppleWebKit/537.36 (KHTML, like Gecko) SamsungBrowser/29.0 Chrome/136.0.0.0 Mobile Safari/537.36
Challenge Information:
Learn HTML by Building a Cat Photo App - Step 9
ILM
March 5, 2026, 11:54am
2
see here how you have the attribute name, src, and then the = and then the value of attribute in quotes
try to use the quotes in the same way, do not put it before the attribute name
dhess
March 5, 2026, 1:33pm
3
Just to clarify, alt is an attribute that goes inside the img tag. alt is not a separate HTML element.
`hope this helps <img src=“https://cdn.freecodecamp.org/curriculum/cat-photo-app/relaxing-cat.jpg ” "alt="A cute orange cat lying on its back/>
you need to take out and inverted commas away from the alt no need for this it is just alt=”lying” or whatever put the inverted commas one at one and end one at the other only thanks Ian. happy coding.
system
Closed
April 3, 2026, 10:05pm
5
This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.