Hey everyone. I am completely new to coding and have hit a snag. I am being asked in the curriculum to nest an image within an “a” element.
The instructions are as follows:
Place the existing image element within an a
( anchor ) element.
Once you’ve done this, hover over your image with your cursor. Your cursor’s normal pointer should become the link clicking pointer. The photo is now a link.
I am doing this exactly, but doesn’t seem to be letting me go to the next assignment. The error message that I am getting is saying that each “a” element should have a closing tag. I have also seen previous solutions that apparently worked for others, but I tried them to no avail. Help would be greatly appreciated. Thanks.
<h2>CatPhotoApp</h2>
<main>
<p>Click here to view more <a href="#">cat photos</a>.</p>
<a href="#">
<img src="https://bit.ly/fcc-relaxing-cat" alt="A cute orange cat lying on its back.">
<a/>
<p>Kitty ipsum dolor sit amet, shed everywhere shed everywhere stretching attack your ankles chase the red dot, hairball run catnip eat the grass sniff.</p>
<p>Purr jump eat the grass rip the couch scratched sunbathe, shed everywhere rip the couch sleep in the sink fluffy fur catnip scratched.</p>
</main>