In: Computer Science
1. Which tag do you use to access an external style sheet? *
a) <a>
b) <head>
c) <style>
d) <link>
2. Which of the following CSS properties below specifies the name of the font to use? *
a) font-face
b) font-type
c) font-family
d) font-use
3. Choose the INVALID value for the area element’s shape attribute. *
a) square
b) rect
c) circle
d) poly
4. Which of these CSS properties DOES NOT have the top, right, left, and bottom specification? *
a) margin
b) border
c) padding
d) None of the above
c) circle
d) poly
5. The hover pseudo-class gives the author access to text styling under which situation? *
a) When the mouse is over an element.
b) When the mouse moves off of an element.
c) When the mouse is to the left of an element.
d) None of the above
6.CSS inline style requires _________ style in order to declare an individual element’s format. *
a) attribute
b) behaviour
c) tag
d) None of the above
7.Select the CORRECT CSS property in order to set image.jpg as the background image. *
a) background-image:url[image.jpg];
b) bground-image:url[image.jpg];
c) background-image:url(image.jpg);
d) bground-image:url(image.jpg);
8. In __________ positioning, elements are positioned relatively to other elements.
a) relative
b) absolute
c) surface
d) dynamic
1). Ans:Option (d) <link>
<link> tag is used to access an external style sheet
Eg:
<link rel="stylesheet" href="abc.css">
2). Ans: Option (c) font - family
font family is used to specify the name of the font to use
Eg:
p.classname {
font-family: Impact, Charcoal, sans-serif;
}
3). Ans: Option (a) square
There are only 4 attribute values for the area elements shape attribute.
They are
a). default
b). circle
c). rect
d). poly
Therefore square is the invalid option
4). Ans: Option (c) circle
circle does not have top right left and bottom specifications. It only has centre and readius specifications
5). Ans: Option (a) When the mouse is over an element.
The hover pseudo-class gives the author access to text styling When the mouse is over an element.
6). Ans: Option (c) tag
CSS inline style requires tag style in order to declare an individual element’s format.
Eg:
<style>
body {
background-color: linen;
}
Here body is the tag. So we require the style of the tag
7).Ans: Option (c) background-image: url ("image.jpg")
background-image: url ("image.jpg"); is used for background image in css
8). Ans: Option (a) relative
In relative positioning elements are positioned relative to other elements