Learn Basic CSS by Building a Cafe Menu - Step 1

Tell us what’s happening:
Not quite sure what I did incorrectly. It states to add html element with a lang attribute of en. I’ve tried entering it as : as well and it shows as incorrect. Don’t see what I am doing wrong.

Your code so far

<!DOCTYPE html> 
<html lang="en"</html>

Your browser information:

User Agent is: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/ Safari/537.36

Challenge: Learn Basic CSS by Building a Cafe Menu - Step 1

Link to the challenge:

Remember that all tags must start and end with angled brackets < >

I tried adding a closing > after the first html but it continues to read it as incorrect.

That would be because you have orphaned the lang attribute.

All html attribute must be written inside the respective opening tags.

1 Like

I’m sorry, I’m not quite sure what that means. Wouldn’t it being inside the <> mean it’s inside the tags?

I see what I did wrong actually! Thank you (:

1 Like

So there is a few concepts that you need to recall here.

1- an element like <h1>My Title</h1>
Has 3 parts.
-The opening tag
-The text
-The closing tag

2- an element like <a href=“www.google.com>Search!</a>

Has 4 parts:
-The opening tag
-The attributes within the tag
-The text
-The closing tag

So in your case lang is an attribute so you must place it inside the opening tag.

1 Like

Thank you, the breakdown makes a lot of sense. I realize that the attribute was missing the > to enclose it with the opening tag.

1 Like

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