This forum is now read-only. Please use our new forums! Go to forums

0 points
Submitted by Quentin Eck
about 9 years

15/21 What the what is wrong with this code.

<!DOCTYPE html>
<head>

<style> 
body { 
background: url("https://codecademy-content.s3.amazonaws.com/courses/web-beginner-en-3pc6w/images/splash.jpg");
background-size: cover;
background-position: center center;
background-repeat: no-repeat;
background-attachment: fixed;
text-align: center;
background: black;
color : white;
font-family: Helvetica;
} 
body {
    text-align: center;
}
</style>
</head>http://www.codecademy.com/

<body>
body { text-align: center;}   
<body>Quentin</body>.
<body>Hi! I am learning how to make my very own web page! I  really like blueberry muffins and long walks on the beach.</body>
<input type="email">
placeholder="Email"
</body>

<img src=”http://codecademy-content.s3.amazonaws.com/courses/web-beginner-en-3pc6w/images/avatar.jpg“ url(“https://codecademy-content.s3.amazonaws.com/courese/web-beginner-en-3pc6w/images/splash.jpg“);

What is wrong???????????????????????????????????????????????

Answer 54d8e9af51b8871867009fed

0 votes

Permalink

Hi Quentin,

You have a few things to fix there before we can clearly see what is going on.

You only need one body selector in your <style> ... </style> section. That means only one of these:

body { ...

You currently have two of those in your style section and another in your <body>. Gather all of those into one.

Next, you should only have one <body> ... </body>. You currently have three. All of your HTML code must be between those two tags.

Sort those out and then let’s see where that leaves us.

points
Submitted by Judy
about 9 years

Answer 54e0b7e951b887634c0064bb

0 votes

Permalink

Well, I did the thing’s you recommend, but it still says “Set the body’s background size to cover.

points
Submitted by Quentin Eck
about 9 years

1 comments

Judy about 9 years

Please show us your updated code.

Answer 551756a2937676945e00263f

0 votes

Permalink

Hi Quentin,

Thanks for posting your updated code. There are a few things that you need to look at.

background: black; – that line is making your background black instead of showing splash.jpg.

This next bit of CSS code is just dangling after the end of the body { ... } selector:

    text-align: center;
}

If you want your body text to have that styling applied they you should put that inside of the body { … }. I notice that you have the line in there already so you can just delete this code.

Next, you have http://www.codecademy.com/ between your head and body elements. You should have nothing between those two elements. I’m not sure what you had planned for that URL. If you would like it to appear as a clickable link on your page then it will need to be located in an <a> element in your body. Something like this: <a href="http://www.codecademy.com">Codecademy</a>

Next, this is CSS code: body { text-align: center;}, so it belongs in your style element. You already have that rule in your style element so you could just delete this.

Finally, placeholder="Email" is an attribute of the input element so it belongs inside the angle brackets just like type="email" is. LIke this:

<input type="email" placeholder="Email">

Let me know how you get on with sorting that out.

points
Submitted by Judy
about 9 years

Answer 5516f1a095e378ac4d0019ed

-2 votes

Permalink

This is the new code:

<!DOCTYPE html>
<head>

<style> 
body { 
background: url("https://codecademy-content.s3.amazonaws.com/courses/web-beginner-en-3pc6w/images/splash.jpg");
background-size: cover;
background-position: center center;
background-repeat: no-repeat;
background-attachment: fixed;
text-align: center;
background: black;
color : white;
font-family: Helvetica;
} 
    text-align: center;
}
</style>
</head>http://www.codecademy.com/

<body>
body { text-align: center;}   
Quentin.
Hi! I am learning how to make my very own web page! I  really like blueberry muffins and long walks on the beach.
<input type="email">
placeholder="Email"
</body>
points
Submitted by Quentin Eck
about 9 years