Teee
March 10, 2024, 4:54am
1
Tell us what’s happening:
Please help I can’t figure this out, I’m sure this is correct. I searched online and this seems to be right.
Step 43
After your last .divider
element, create a p
element and give it the text Total Fat 8g 10%
. Wrap the text Total Fat
in a span
element with the class
of bold
. Wrap the text 10%
in another span
element with the class
of bold
. Finally, nest the Total Fat
span
element and the text 8g
in an additional span
element for alignment.
Your code so far
<div class="divider">
<p><span><span class="bold">Total Fat</span> 8g</span> <span class="bold">10%</span></p>
</div>
Teller
March 10, 2024, 5:02am
2
Welcome to the forum @Teee
You nested your code in the div
element, not below it.
Place the new code below this element.
<div class="divider"></div>
Happy coding
Teee
March 10, 2024, 5:17am
3
Hi i changed that but its still not working
Teller
March 10, 2024, 5:18am
4
Use the following method to post your full code to the forum:
On a separate line type three back ticks.
On a separate line paste your code.
On the last line type three back ticks. Here is a single back tick `
Happy coding
Teee
March 10, 2024, 5:22am
5
like this
<div class="divider"></div>
<p><span><span class="bold">Total Fat</span> 8g</span> <span class="bold">10%</span></p>
Teller
March 10, 2024, 5:24am
6
All of the code please, copy and then paste everything from the editor.
Teee
March 10, 2024, 5:26am
7
here you go
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>Nutrition Label</title>
<link href="https://fonts.googleapis.com/css?family=Open+Sans:400,700,800" rel="stylesheet">
<link href="./styles.css" rel="stylesheet">
</head>
<body>
<div class="label">
<header>
<h1 class="bold">Nutrition Facts</h1>
<div class="divider"></div>
<p>8 servings per container</p>
<p class="bold">Serving size <span>2/3 cup (55g)</span></p>
</header>
<div class="divider large"></div>
<div class="calories-info">
<div class="left-container">
<h2 class="bold small-text">Amount per serving</h2>
<p>Calories</p>
</div>
<span>230</span>
</div>
<div class="divider medium"></div>
<div class="daily-value small-text">
<p class="bold right">% Daily Value *</p></div>
<div class="divider"></div>
<p><span><span class="bold">Total Fat</span> 8g</span> <span class="bold">10%</span></p>
Teller
March 10, 2024, 5:37am
8
Remove the closing div
tag at the end of this paragraph
element.
Then at the end of your code add:
two closing div
tags
one closing body
tag
one closing html
tag
1 Like
Teee
March 10, 2024, 5:42am
9
Omg that worked thank you so much I was going crazy there tbh. can’t wait till I’m a pro and can figure these things out on my own.
Again thanks a million
2 Likes
system
Closed
September 8, 2024, 5:43pm
10
This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.