0
0
CSSmarkup~5 mins

Border in CSS - Cheat Sheet & Quick Revision

Choose your learning style9 modes available
Recall & Review
beginner
What CSS property is used to add a border around an element?
The border property is used to add a border around an element. It can set the width, style, and color of the border.
Click to reveal answer
beginner
How do you make a border that is 2 pixels thick, solid, and red?
Use border: 2px solid red;. This sets the border width to 2 pixels, style to solid, and color to red.
Click to reveal answer
beginner
What are some common border styles you can use in CSS?
Common border styles include solid, dashed, dotted, double, and none.
Click to reveal answer
intermediate
How can you add different borders to each side of an element?
Use the side-specific properties: border-top, border-right, border-bottom, and border-left.
Click to reveal answer
beginner
What does the CSS property border-radius do?
border-radius rounds the corners of the border, making them curved instead of sharp.
Click to reveal answer
Which CSS property controls the thickness of a border?
Aborder-style
Bborder-width
Cborder-color
Dborder-radius
What value for border-style creates a dashed border?
Asolid
Bdouble
Cdotted
Ddashed
How do you remove a border from an element?
AAll of the above
Bborder: 0px solid;
Cborder: none;
Dborder-style: hidden;
Which property rounds the corners of a border?
Aborder-radius
Bborder-style
Cborder-color
Dborder-width
If you want a different border on the top and bottom, which properties do you use?
Aborder-width and border-style
Bborder-left and border-right
Cborder-top and border-bottom
Dborder-color and border-radius
Explain how to create a red, 3px thick, dotted border around a box in CSS.
Think about the order: width, style, color.
You got /4 concepts.
    Describe how you can make only the left border of an element blue and 5 pixels wide.
    Remember you need to set style along with width and color.
    You got /4 concepts.