0% found this document useful (0 votes)
44 views

Divs CSS

This document contains HTML code with CSS styling for different divs and paragraphs of text. Styles are defined for font size, color, text decoration, and boxes with different background colors and sizes. The code samples different CSS classes applied to paragraphs within divs and a span within a paragraph.

Uploaded by

Ania Neal
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
44 views

Divs CSS

This document contains HTML code with CSS styling for different divs and paragraphs of text. Styles are defined for font size, color, text decoration, and boxes with different background colors and sizes. The code samples different CSS classes applied to paragraphs within divs and a span within a paragraph.

Uploaded by

Ania Neal
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 3

Divs: divs.

html
!

<!doctype html>
<html>
<head>
<title>Learning CSS</title>

<meta charset="utf-8" />
<meta http-equiv="Content-type" content="text/html; charset=utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1" />

<style type="text/css">

.large {
font-size:200%;
}

#green {
color:green;
}

.underline {
text-decoration:underline;
}

.bold {

font-weight:bold;
}

.bluebox {
background-color:blue;
width:200px;
height:200px;
}

.redbox {
background-color:red;
width:300px;
height:100px;
}
</style>

</head>

<body>

<div class="bluebox">

<p class="large">This is some text.</p>

</div>

<div class="redbox">

<p id="green" class="large">This is some more text.</p>



</div>

<p>The third <span class="underline large bold">word</span> in this
paragraph is underlined.</p>

</body>
</html>

You might also like