I need help on how to comment out so it is not visible on the page

Tell us what’s happening:

Your code so far


<h1>!fantastic>
<h2><!---->
<p><!indeed-->
<h1>Hello World</h1>

<h2>CatPhotoApp</h2>

<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>
-->

Your browser information:

User Agent is: Mozilla/5.0 (Linux; Android 7.0; Infinix X559C) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/85.0.4183.101 Mobile Safari/537.36.

Challenge: Comment out HTML

Link to the challenge:

This is how you comment out an element:

<!-- <li>i am a list</li> -->

You can do the same for your h1 and p element.

2 Likes

I had tried this method several time it does’nt work. Pls what I need is solution on : Your h1 element should be commented out so that it is not visible on the page

Hey @Ollyreal,
It looks like you have changed the template code a little too much, Try to press the Reset My Code button, then try again commenting the h1 element.

In HTML, to comment something, they use <!-- to open the comment and --> to close it. Here’s an example:
<!-- Anything in between these 2 will be commented -->

Tell us what’s happening:

Your code so far


<!-- <h1>i am a list</h1> -->
<!--<h2>i am a list</h2>-->
<!-- <p>i love her</p> -->
<h1>Hello World</h1>

<h2>CatPhotoApp</h2>

<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>
-->

Your browser information:

User Agent is: Mozilla/5.0 (Linux; Android 7.0; Infinix X559C) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/85.0.4183.101 Mobile Safari/537.36.

Challenge: Comment out HTML

Link to the challenge:

I moved your post over here.

Your task is to take the existing h1 and wrap comment tags around it.

You need to delete this part

For your h1 place an opening comment tag in front <!-- and a closing comment tag at the end of the h1 -->

Then do the same for the p tag.

Hope that makes sense

So basically do what you did here

but instead of creating a whole new tag you need to just apply that comment tag to the h1 and p tags.