JavaScript Treehouse Club - MASH MASH - HTML Thinking With Your Head

Just doing MASH the game. I duplicate her work and it says doctype has to be above the <head>??

I'm just starting the MASH game. HTML part first. Her example shows the head above doctype. When I do the worksheet checker says the head has to be within the doctype. Not above as shown. Still when I out the head on top I couldn't get it to work

index.html
<head>
  <!DOCTYPE> 
  <meta charset="utf-8">
  <title>Futuristic MASH</title>
  <h1>Futuristic MASH</h1>
  <link href="style.css" rel="stylesheet">
  <p> Directions to play the game: </p>
</head>

2 Answers

Milan Pankhania
Milan Pankhania
3,734 Points

Doctype should always go first and shouldn't be in the <head> tag. This is how a standard page is marked up:

<!DOCTYPE html>
<html>
    <head>

    </head>
    <body>

    </body>
</html>

The h1 tag and p tag shouldn't be in the <head> either, does this help?

Edit: The question is asking you to delete elements that don't belong in the <head>, so the answer would be:

<head>
  <meta charset="utf-8">
  <title>Futuristic MASH</title>
  <link href="style.css" rel="stylesheet">
</head>
KRIS NIKOLAISEN
PRO
KRIS NIKOLAISEN
Pro Student 47,362 Points

The instructions are to DELETE everything that doesn't belong. Consider the bummer message as information on what to delete.

Ahh geesh thanks! That helps a lot. Duh.