Ch4: Cascading Style Sheets Basics Flashcards

1
Q

Which type of CSS is coded in the body of the web page as an attribute of an HTML tag?

A

inline
Inline CSS is configured as a value of the style attribute within an HTML tag.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

Which of the following can be a CSS selector?

A

an HTML element name, a class name, and an id name can be configured as CSS selectors
A CSS selector can be configured with an HTML element name, a class name, or an ID name.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

Which of the following is the CSS property used to set the background color?

A

background-color
The background-color property configures background color of an element.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

Which of the following describes two components of CSS rules?

A

selectors and declarations
A CSS rule contains a selector and one or more declarations.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

Which of the following associates a web page with an external style sheet?

A

Coding a link element with the rel and href attributes
The link element used with the rel and href attributes associates an external style sheet with a web page.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

Which of the following configures a CSS class called news with text and background colors?

A

Code the class name as “.news” along with the color and background-color properties

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

An external style sheet uses the _____ file extension.

A

CSS
The CSS file extension indicates an external style sheet file.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

Where do you place the code to associate a web page with an external style sheet?

A

in the head section of the web page document
Code a link element in the head section to associate a web page with an external style sheet.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

Which of the following configures a background color of #FFF8DC for a web page using CSS?

A

Code “body” as the CSS selector along with the background-color property.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

Which of the following do you configure to apply a style to more than one area on a web page?

A

class
A class can be applied to more than one area on a web page.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly