Comment out HTML giving strange response

Comment out HTML giving strange response
0

#1

Tell us what’s happening:
The feedback on this code says 2 of 4 answers are correct. It thinks the paragraph text is still visible and missing —> somewhere.
But if I add < before the actual text inside the paragraph and nothing else, then it marks 3 of 4 answers correct, just need a —> somewhere.
Incidentally, the web page screen preview doesn’t remove any of the text unless I type the <!— and —> inside the header or paragraph tags and the system says that is incorrect too. Please help!

Your code so far

<!-—
<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 (iPad; CPU OS 11_4_1 like Mac OS X) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/11.0 Mobile/15E148 Safari/604.1.

Link to the challenge:
https://learn.freecodecamp.org/responsive-web-design/basic-html-and-html5/comment-out-html


#3

I’ve edited your post for readability. When you enter a code block into the forum, precede it with a line of three backticks and follow it with a line of three backticks to make easier to read. See this post to find the backtick on your keyboard. The “preformatted text” tool in the editor (</>) will also add backticks around text.


#4

Thank you! I appreciate the feedback.


#5

After reviewing the code above, it appears the second dash of your opening comment tag is not a normal dash. Make sure your opening comment looks like:

<!--

and not

<!-—

The same problem exists in the second dash of your closing comment.


#6

I see. It’s because it’s a digital keyboard changing the dash without me noticing. I’ll use a regular keyboard. Thank you!


#7

Any other suggestions? It still isn’t working with the right dashes.


#8

What do you have right now?


#9

Please copy/paste your code, but make sure to put 3 backticks on the line before and the line after the code you paste, so it properly displays on the forum.


#10


#11

Which tests are failing? Are you using Chrome or another browser?


#12

Browser is Safari. I can download Chrome.


#13

Chrome works the best with FCC, because FCC uses newer JavaScript features that many browsers have not implemented yet. Let us know what happens when you try the same code with Chrome.


#14

This is in Chrome.


#15

Try deleting the lines with the comment syntax and retyping them. There could have been some hidden characters left over from the strange dash you originally had.


#16

I started from scratch.


#17

Idk man. Can you try on a desktop/laptop? I’m starting to think that your keyboard is throwing in extra invisible characters.


#18

Yeah, I’ll try a pc when I get home. At least I know the code should work. Thanks for all the help!