HTML/CSS lesson 9: is there a bug?


#1

Below is my code for lesson 9. I'm trying to change the font colour, font family and the background colour. Whats wrong with the below?

Any help greatly appreciated.

Kind Regards,
Joe









What's CSS for?


CSS is for styling HTML pages!


Why use it?


It makes webpages look really rad.


What do I think of it?


It's awesome!





#2

Please paste in your code using this format

```

  replace this line with your code, leave backticks


```

#3

<!DOCTYPE html>
<html>
	<head>
		<link type="text/css" rel="stylesheet" href="stylesheet.css"/>
		<title>I Know Kung Fu (er, CSS)</title>
	</head>
	<body>
		<div>
			<h3 {color:red;}>What's CSS for?</h3>
			<p  {font-family:Courier;}>CSS is for styling HTML pages!</p >
			<h3 {color:red;}>Why use it?</h3>
			<p  {font-family:Courier;}>It makes webpages look <span {background-color:yellow;}>really rad</span>.</p>
			<h3 {color:red;}>What do I think of it?</h3>
			<p  {font-family:Courier;}>It's awesome!</p>
		</div>
	</body>
</html>

#4

To add in-line styling you use style=" "

eg:

<p style="color: blue; font-size: 12px;"> my text </p>

#5

thanks a lot for your help


#6

You're welcome :green_heart:

Happy Learning :slightly_smiling:
Happy coding !

What inspired you to learn programming/coding?
Join the discussion


#7

shouldn't the exeternal stylesheet be used in this lesson?