8. can you swing it? (no)


#1



https://www.codecademy.com/courses/web-beginner-en-WF0CF/1/4?curriculum_id=50579fb998b470000202dc8b#


It keeps telling me I did not bold all summary and introduction paragraphs. Maybe it's because I haven't really got this whole "grandparent, parent, child" thing. I've been using numbers after tags ( < span1> ) to separate them so I can style specifically in CSS.


<!DOCTYPE html>
<html>
	<head>
		<link type="text/css" rel="stylesheet" href="stylesheet.css"/>
		<title>Ultimate Text Challenge</title>
	</head>
	<body>
		<p1>Introduction: Cascading with CSS</p1>
		<div>
			<span><p>Synopsis: When you set a property of a selector like 'p' to a certain value, that value applies to <em>all</em> p tags.
			If, however, you change that same property to a different value for a more specific instance of p,
			that change will <em>override</em> the 'general rule'.</span>
			</p>
			<ul>
				<li><p>If you say p { font-family: Garamond}, all 'p's will have the font Garamond.</p></li>
				<li><p>BUT if you say li p {font-family: Verdana}, 'p's outside of 'li's will be
					   in Garamond, and 'p's INSIDE 'li's will be in Verdana.
				</p></li>
				<li><p>The more specific your selectors are, the higher importance CSS gives to the styling you apply!</p></li>
			</ul>
		</div>
		<span1><p>Summary: Greater specificity makes CSS prioritize that particular styling.</p></span1>
	</body>
</html>
p{ font-family: Garamond;}
p1{ font-weight: bold}
span p{ color:#7ac5cd; } 
ul{ color:#000000; text-decoration: underline; }
span1{ font-weight:bold}


#2

Reset the exercise, and don't temper with the html. You should use css only, otherwise is exercise is nearly impossible to pass. Read the information in the left column, about direct children (>)


#3

I only tampered with the html to be able to figure out how to specifically bold the "Synposis" paragraph w/o editing the ul. I guess I'm asking for a better explanations as to how you're supposed to nest family tags in the CSS style sheet.


#4

But you shouldn't tamper with the html at all. Synposis is a direct child of div


#5

When I code div p{ font-style: underline} it ends up editing the whole ul.


#6

font-style is so far i know not a valid css property.

Well, that will select all paragraphs somewhere inside a div, the paragraphs inside the list are still inside the div. You need to use > to grab direct children:

div > p

#7

I meant text-decoration, whoops. Anyways you fixed my problem, thanks.