Commenting allows you to leave messages without affecting the browser display. It also allows you to make code inactive. A comment in HTML starts with <!--
, contains any number of lines of text, and ends with -->
. For example, the comment <!-- TODO: Remove h1 -->
contains the text TODO: Remove h1
.
Add a comment above the p
element with this text:
TODO: Add link to cat photos
<html>
<body>
<h1>CatPhotoApp</h1>
<h2>Cat Photos</h2>
<!-- User Editable Region -->
<p>See more cat photos in our gallery.
<!-- TODO: add link to cat photos -->
</p>
<!-- User Editable Region -->
</body>
</html>
Your browser information:
User Agent is: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/111.0.0.0 Safari/537.36
Challenge: Learn HTML by Building a Cat Photo App - Step 4
Link to the challenge: