Submit problem in HTML CSS

Tell us what’s happening:
I am giving meta tag but not getting pass.

  **Your code so far**
<!DOCTYPE html>
  <meta charset="utf-8">
  <title>Colored Markers</title>
  **Your browser information:**

User Agent is: Mozilla/5.0 (X11; Linux x86_64; rv:101.0) Gecko/20100101 Firefox/101.0

Challenge: Step 4

Link to the challenge:

This tag is left unclosed. This is a self-closing tag, close it and you’ll pass the challenge.
Always remember to close every tags even if they aren’t self-closing.

Also tried that. Not working.

    <meta charset="utf-8"/>
    <title>Colored Markers</title>
1 Like

Welcome to the Forums :wave:

Your code passes for me try your code in a different browser or in an incognito window.

When working with a self-closing tag, you failed to close the tag. I said “close the tag” but you didn’t do that.
This is an example of an element with an opening and closing tag:


You can see there’s a “/“ backslash in the closing tag.

To close a self-closing tag all you need is include that backslash in the tag without including a closing tag for example:

<tag attribute=“value” />

Now this :arrow_up: is a self-closing tag.

The backslash isn’t always needed for a self-closing tag.

Edit: I also edited the post of @srpallab it looks like he did use a backslash.

In my browser I tried his solution without a backslash and it failed and when I added the backslash it passed so I figured it was a requirement to pass the challenge. I guess there’s a bug somewhere.

The code does pass for me, not sure whether its a prob with my browser now.
Backslash might work for the current problem(maybe), a backslash isn’t always required for self-closing tags, there might be a problem with the tests or the browser.

Yeah this might be the case.

@srpallab try this approach or if you have adBlockers extensions in your browser I strongly advice you disable the adBlockers for freeCodeCamp as they often interfere with the tests.

Hopefully you’ve been able to pass the challenge.

Happy Coding :+1:!

capitalize your “UTF-8”

and use a forward slash/ to close the self closing tag

<meta charset="UTF-8" />

This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.