In this lecture we'll explore how to add borders around an element.
We'll start by creating a class with commonly used border style declarations
we'll call this class my border
the first declaration border is used to specify where the border will be applied and at what thickness
the thickness is stated in pixels at the moment.
We have a four pixel thick border
for a border only at the top of an element.
We would use the border top declaration border bottom border right in border left are also other values
that can be used if we leave it is just border.
As we have known the border will be applied to all four sides.
Next we have the border color.
This will be the color of the border itself.
The color value can be represented by a color name such as red green or blue hexadecimal no as we currently
have or an RG b value.
We also have a we can also create a border style using the border style declaration.
There are several possible styles at the moment we've used dashed which will create a dashed line border
effect.
Let's go ahead and apply this class to one of our paragraphs
will apply it to the first paragraph.
So make a space after your first class and paste the second.
My border will save or file and preview it in our browser
so here we can see we have the dashed border
which has been applied to the first paragraph.