Do you know that? Always have the client deposit a certain percentage of the money up-front. next

Contact Email: teammmrem@yahoo.com

<< All Upwork (oDesk) and Elance Tests << Elance test answers << IT & Programming category

Test answers for CSS 2016

(531, CL) Last updated: January 22
Elance • IT & Programming
Questions and answers are regularly updated. Answered and not answered tests questions.

This helps getting job: Hundreds of (cover letter examples , interview questions , profile samples ) • Earn on Upwork (oDesk)
Job assistance: jobs popularityfreelance rates

Popular test answers: HTML, .Net, CSS, English, SEO, Photoshop, iOS, Java, Android, Ruby, Python, JavaScript

See all 6 tests answers updated

Find Upwork (oDesk) and Elance test answers on this website:



Collapse | Expand

531 Answered Test Questions:

1. Identify the selector in the following rule: h1 { color: blue; }

Answers:

• color: blue

• h1

• color

• { }

• blue

2. What does the outline-offset property do?

Answers:

• Both of the other answers are correct.

• Draws an outline beyond the border edge.

• Offsets an outline

3. Which of the following is true about inline styles?

Answers:

• They will be overridden by a default value.

• They will be overridden by a style defined inside the <head> tag.

• They will be overridden by an external style sheet.

• They will override a style defined inside the <head> tag, in an external style sheet or in a browser (a default value).

4. In which direction are elements floated?

Answers:

• Circularly

• All of these

• Vertically

• Horizontally

5. Which of the following is used to select one paticular tag, rather than a group of tags?

Answers:

• Id selector

• Pseudo-class selector

• Class Selector

• Contextual selector

6. The pseudo selector ":nth-child(2n)" can also be written as:

Answers:

• :nth-child(even)

• :nth-child(everysecond)

• :nth-child(second)

• :nth-child(odd)

7. Which is the correct shorthand to specify padding: 10 pixels at the top, 7 pixels at the bottom, 25 pixels at the right and 2 pixels to the left?

Answers:

• padding: 25px 10px 7px 2px

• padding: 10px 7px 25px 2px

• padding <10px 25px 7px 2px>

• padding:10px 25px 7px 2px

8. The text-align property is used to set the ______ alignment of a text.

Answers:

• neither

• horizontal

• vertical

• both

9. Which value of the "text-transform" property transforms the first character in each word to uppercase?

Answers:

• uppercase

• none

• lowercase

• capitalize

10. What is NOT a correct value of background-position property?

Answers:

• right bottom

• 15% 20%

• left top

• 10px 10px

• middle

11. If an image is floated to the right, where does a following text flow?

Answers:

• around it, to the left

• around it, to the right

• around it, to the top

• around it, to the bottom

12. Which of the following css declarations will create italicized text?

Answers:

• {font-weight: italic;}

• {text-decoration: italic;}

• {text-style: italic;}

• {font-style: italic;}

13. Which property specifies spacing behavior between text characters?

Answers:

• letter-spacing

• font-spacing

• text-transform

• text-letter-spacing

14. What is true about image sprites?

Answers:

• Both of these

• It is a collection of images put into a single image.

• Using image sprites will reduce the number of server requests.

15. In order to have a block element stay in the same position in the viewport regardless of where the user scrolls, what should the "position" property be set to?

Answers:

• relative

• absolute

• fixed

• static

• inherit

16. What property is used to specify the indentation of the first line of a text?

Answers:

• text-decorate

• text-format-indentation

• text-transform

• text-indentation

17. In this code, where will the <p> element be displayed?  <body> <div style="position:relative"> <p style="position:absolute; bottom:0;"> </p> </div> </body>

Answers:

• At the bottom of the child element

• At the bottom of the <div> element

• Wherever it appears inline in the document

• At the bottom of the browser window

18. How do you hide an element, but have it still take up space and affect the layout?

Answers:

• visibility: hidden;

• display: none;

• visibile: zero;

• show: hidden;

• visibility: none;

19. What is the scale for opacity from least to most?

Answers:

• 1 - 100

• 1 - 10

• 0 - 100

• 0 - 1

20. Is a # required before colors in CSS?

Answers:

• No, unless you are using more than ten colors

• No, it is optional

• No, only when specifying colors as hexadecimal values.

• Yes, always

21. Which operator is used for pseudo classes?

Answers:

• : (colon)

• [space]

• < (less than)

• > (greater than)

• :: (double colon)

22. The caption-side property specifies the placement of a table caption.  Which of the following is NOT a valid value?

Answers:

• bottom

• top

• side

• inherit

23. What is text-align set to each line when text is stretched so that every line has equal width, and the left and right margins are straight?

Answers:

• center

• Both justify and center

• justify

24. What is "inline" for the CSS display property?

Answers:

• It displays the element in sequence, line by line.

• It displays a line between each element.

• It displays a line between each lines of text.

• An inline element has no line break before or after it, and it tolerates HTML elements next to it.

25. What does "padding:15px 20px 25px" mean?

Answers:

• - top padding is 15px - bottom padding is 20px - right and left paddings are 25px

• - bottom padding is 15px - right and left paddings are 20px - top padding is 25px

• - right and left paddings are 15px - top padding is 20px - bottom padding is 25px

• - right padding is 15px - top and bottom paddings are 20px - left padding is 25px

• - top padding is 15px - right and left paddings are 20px - bottom padding is 25px

26. In this CSS code, what element is the property?  table {color: red;}

Answers:

• table

• blue

• color

• None of these

27. By default, the background-image property repeats an image...

Answers:

• no-repeat

• horizontally

• vertically

• both horizontally and vertically

28. What is the syntax for a customized cursor?

Answers:

• Selector-cursor{style:value}

• Selector{value:property}

• Selector {cursor:value}

• Selector {value:cursor}

• Selector-style {property:value}

29. display:none hides an element, and it will...

Answers:

• still take up space. The element will be hidden, and the page will be displayed as if the element is NOT there

• still take up space. The element will be hidden, and the page will be displayed as if the element is STILL there

• not take up any space. The element will be hidden, and the page will be displayed as the element is NOT there

• not take up any space. The element will be hidden, and the page will be displayed as if the element is STILL there

30. Which of the following specifies the type of list-item marker?

Answers:

• list-style-marker

• list-marker

• list-style-all

• list-style-type

31. Given the following css rule, where would the style apply?  #content table tr td ul li a {font-weight:bold;}

Answers:

• Text inside of a list inside of a table inside of something named content

• A link with an id of "content"

• Links inside of a list inside of a table inside of an element with an id of 'content'

• A list inside of a table inside of something named content

32. How do you target the submit button for the <form id="example">?

Answers:

• .example input[type:submit]

• #example input.submit

• .example input[type="submit"]

• #example input[type:submit]

• #example input[type="submit"]

33. Given .class {  padding: 20px 10px; }, in what order do padding values apply?

Answers:

• left, right

• top, bottom

• top & left, right & bottom

• top & bottom, left & right

34. Which of the following applies a different background color for odd numbered rows in a given table?

Answers:

• td:nth-child(odd)

• th:nth-child(odd)

• col:nth-child(odd)

• tr:nth-child(odd)

35. What's the name of the technique when multiple images used throughout a website are combined into a background image to be selected with the background-position property?

Answers:

• CSS Image Mix

• CSS Image Sprites

• CSS Image Code

• CSS Image Group

36. What does the * stand for in CSS?

Answers:

• Universal Selector

• Major Selector

• Class Selector

• Master Selector

• Attribute Selector

37. Where is the margin property located in the CSS box model?

Answers:

• Inside the box

• Outside the box

• It could be inside or outside the box, depending on where you place it in your code

38. Which declaration removes bullets from a navigation list?

Answers:

• list-style-type:no bullets

• list-style-none

• list-style-type:none

• list-bullets:none

39. What are the differences between "display:none" and "visibility:hidden" code?

Answers:

• "visibility:hidden" hides the element and remove it's placeholder, "display:none" hides the element but keeps it's place blank.

• "display:none" hides the element and remove it's placeholder, "visibility:hidden" hides the element but keeps it's place blank.

• Both are same

40. What does image sprite do in CSS?

Answers:

• It specify a link to an image.

• It is a way to open one image at a time within the html.

• It specify the image style.

• It is a style of an image in different page of the website.

• It is a collection of images put into a single image.

41. You have three blocks of code that share property values. Which of the following ways is the most efficient?

Answers:

• .one .two .three { property: value; }

• .one, .two, .three { property: value; }

• .one / .two / .three { property: value; }

• .one { property: value; } .two { property: value; } .three { property: value; }

42. What is the correct order if you want a div with left margin of 10, right margin of 2, top margin of 5, and bottom margin of 0?

Answers:

• div {margin: 5px 0 10px 2px}

• div {margin: 5px 2px 0 10px}

• div {margin: 10px 2px 5px 0}

• div {margin: 10px 5px 2px 0}

43. Of the following elements, which will be frontmost, on the top of the stack using z-index?

Answers:

• Element with z-index of 2

• Element with z-index of 9

• Element with z-index of 1

• Element with z-index of 6

44. What HTML tag can you use to import a style sheet into a document?

Answers:

• Use the HTML <link /> tag, like this: <link rel='stylesheet' type='text/css' href='styles.css' /> .

• Use the HTML <link /> tag, like this: <link rel='style' type='text/css' href='styles.css' /> .

• You can use '@import' sentence.

45. In CSS3, which property is used to make sure a given element has a width of at least a set value?

Answers:

• min-width

• minimum-width

• max-width

• margin-width

• offset-width

46. What does XSL, another style sheet language for XHTML, stand for?

Answers:

• Extensible Stylesheet Language

• Extensible Sheet Logo

• Extraordinary Stylesheet Language

• Extended Styles Language

47. If the name of a font family is more than one word, it must be in quotation marks.

Answers:

• True

• False

48. What is the CSS syntax for changing the default cursor to a pointing finger?

Answers:

• cursor: pointer;

• cursor: cursor;

• cursor: finger;

• cursor: hover;

• cursor: hand;

49. What of the following is the correct syntax in CSS?

Answers:

• Selector-declarations {Value: Property;}

• style {Property: Value;}

• rules {Property: Value : Type;}

• Selector {Value: Property;}

• Selector {Property: Value;}

50. What does the list-style-position property do?

Answers:

• It specifies the orientation of a list.

• It specifies the font style of a list item.

• It specifies if the list-item markers should appear inside or outside the content flow.

• It specifies the color of a list item in a fixed position.

51. Which of the following is the correct syntax for a pseudo-class?

Answers:

• pseudo-class { ... }

• selector->pseudo-class { ... }

• selector.pseudo-class { ... }

• selector:pseudo-class { ... }

52. Which of the following will remove the default underline under the link with an id of "content"?

Answers:

• a#content {text-decoration:none;}

• #content a {underline:none;}

• a {underline:none;}

• a {content text-decoration:underline;}

53. Which declaration can be used to have a block element always displays scrollbars?

Answers:

• {overflow:auto}

• {overflow:on}

• {scroll:on}

• {overflow:always}

• {overflow:scroll}

54. When adjusting a CSS sprite, which property do you use?

Answers:

• color

• background-position

• font-style

• text-indent

55. Which property is used to set whether table borders are collapsed into a single border or detached as in standard HTML?

Answers:

• border-separation

• border-collapse

• border

• border-spacing

56. What css selector selects the input element which has focus?

Answers:

• input:focus

• a:input

• a:focus

• input+focus

57. A definition list has two types of items: the term and the description. Which of the following is NOT a valid definition-related tag set?

Answers:

• <dl></dl>

• <dd></dd>

• <dt></dt>

• <do></do>

58. If an image is floated to the right, the following text flows around it...

Answers:

• to the bottom

• to the top

• to the center

• to the right

• to the left

59. What css selector selects all <div> elements and all <p> elements?

Answers:

• div;;p

• div,p

• div:p

• div:;p

60. On which position value does the z-index property work?

Answers:

• position: absolute;

• position: relative;

• all of the answers

• position: fixed;

61. Which declaration will make each word in an element start with a uppercase letter?

Answers:

• text-transform: capitalize;

• type-transform: capitalize;

• text-transform: capitalize first;

• type-style: capitalize;

62. Which pseudo class is used in conjunction with an ID when the pound symbol in the current URL matches that ID. For example, if you are at URL www.yoursite.com/#home

Answers:

• #home:indeterminate

• #home:target

• #home:hash

• #home:enabled

63. To specify the style for a list, use the _________ property.

Answers:

• Both ol-style and ul-style depending on the list type.

• listStyle

• list-style

• ol-style

• ul-style

64. In the CSS box model, where is the margin located?

Answers:

• Between the padding and the box border

• Immediately within the box border

• None of these

• Immediately outside the box border

65. Which of the following produces a black border that is 1-pixel thick and dashed?

Answers:

• dashed-border: black 1px

• border-dashed: 1px #000000

• border: 1px dotted black

• border-color: black; border-style: 1px dashed

• border: 1px dashed #000

66. Which style does the following rule apply to?  div.wrapper h2 {      font-size: 18px;       margin-top: 0px; }

Answers:

• None of these

• h2 heading inside element div of any class

• h2 heading inside element div of id wrapper

• h2 heading inside element div of class wrapper

67. What does minifying CSS do?

Answers:

• gzips the file

• combines it with HTML code to integrate it and make it faster

• compresses the code by removing whitespace, which is not needed

• compiles it completely

68. An ____ style loses many of the advantages of style sheets by mixing content with presentation.

Answers:

• Inline

• External

• Internal

69. What css selector selects every element that is not a <p> element?

Answers:

• :notp

• :not(p)

• :no-p

• :all-but-p

70. Which property is used to horizontally align the text in the table?

Answers:

• vertical-align

• horizontal-align

• text-align

71. Which style will cause all links to "http://www.smarterer.com" to be blue?

Answers:

• a[link="http://www.smarterer.com"] { color: blue; }

• a[href="smarterer.com"] { color: #ff0000; }

• a[link="http://www.smarterer.com"] { color: #0000ff; }

• a[href="http://www.smarterer.com"] { color: blue; }

72. Which syntax does older versions of Internet Explorer use for transparency?

Answers:

• filter:alpha(opacity=x).

• opacity=x

• opacity:x

73. Which measurement can't be used to size text in CSS?

Answers:

• huge

• px

• em

• %

• pt

74. How do you apply multiple classes to an element?

Answers:

• <div class="[class1][class2]" ></div>

• <div class="class1 class2" ></div>

• This isn't possible in CSS.

• <div class="class1,class2" ></div>

• <div class="class1" class="class2" ></div>

75. If table {color: red;} is specified in a stylesheet, what happens to the table?

Answers:

• Padding appears red

• Table background is red

• Border around the table is red

• Text within it is red

76. How can you override css cascade priority and force a particular css rule to apply?

Answers:

• All of these

• p { color:red !important; }

• p { color:red force; }

• p { color:red important; }

77. Which of the following is true about vertical-align property?

Answers:

• To vertically align an image: img { vertical-align:text-top; }

• It sets the vertical alignment of an the entire webpage.

• It sets the vertical alignment of an element.

78. How do you remove browser default margin and padding settings?

Answers:

• Set margin and padding to custom

• Set margin and padding to auto

• Set margin and padding to css

• Set margin and padding to 0

79. Which is the correct syntax for referring to a pseudo-class?

Answers:

• #hover

• .hover

• :hover

• hover

80. Block elements can be aligned to center by setting the left and right...

Answers:

• margins to none

• margins to 50%

• margins to auto

• margins to center

81. Every CSS style definition has two components. What are they?

Answers:

• selection, properties

• copy, properties

• section, id

• selector, properties

82. Which of the following selects all unvisited links?

Answers:

• "link"

• :link

• +link

• link

83. How do you set a paragraph to have a border of 5px in red color?

Answers:

• p { border-style:5px solid red; }

• paragraph { border:5px solid red; }

• p { border:5px; solid; red; }

• p { border:5px solid red; }

• paragraph { border-width:5 solid red; }

84. Which HTML tag is used to define an embedded style sheet?

Answers:

• <css>

• <style>

• <embed>

• <script>

85. What is the child selector in css?

Answers:

• #

• .

• >

• +

• ~

86. Normally, elements after a 'floated' element will flow around it. Which property can be used to avoid this?

Answers:

• the negative-float property

• the no-float property

• the clear property

87. If a block element might not have enough space to display all of its content, which property might you use to enable scrollbars if they're needed?

Answers:

• v-scrollbar: auto

• scrollbar: on

• overflow: auto

• show: force

• h-scrollbar: scroll

88. Which of the following properties can be used to add space outside an element's box?

Answers:

• padding

• None of these

• spacer

• margin

89. True or False : CSS class name starting with a number is supported by all browsers.

Answers:

• True

• False

90. Which of the following is true about border styles?

Answers:

• Borders must be on all 4 sides

• Borders must be equal weights on all 4 sides

• None of these

• Borders must be the same color on all 4 sides

91. Which of the following is NOT a valid image opacity rule?

Answers:

• opacity: 0.5;

• opacity: 1;

• opacity: 2.0;

• opacity: 0;

92. What css selctor Selects every <p> element that is the last child of its parent?

Answers:

• p:last-children

• p:last-parent-child

• p:last-child

• p:last-child-parent

93. What does the property text-align:center; do?

Answers:

• Aligns text in the center and places it at the top of the page

• Aligns text in vertical center of the page

• Aligns text to the center of the nearest image as a caption

• Aligns text in horizontal center of the containing element

94. With what characters are CSS declarations separated?

Answers:

• colon ( : )

• semicolon ( ; )

• space ( )

• hash ( # )

• period ( . )

95. What does the child selector (">") do?

Answers:

• Matches all descendants (recursively)

• None of these

• Matches elements that are a direct child of the parent match

• Matches any element

96. When using the background-color property with rgba(255, 0, 255, 0.5) what does the "a" refer to?

Answers:

• Opacity (Alpha channel)

• Black

• Grey

• This is incorrect syntax and will do nothing

97. In this CSS code, what element is the selector?  table {color: red;}

Answers:

• table

• color

• red

• None of these

98. What css selector selects all <p> elements that are contained inside of an element with an ID of 'content'?

Answers:

• #content 'p'

• #content <p>

• #content < p

• #content p

• #content [p]

99. An attribute selector allows you to select an element with a specific attribute. To select a <input type="submit"> you would use:

Answers:

• input-submit { }

• input[type=submit] { }

• input:type.submit { }

• input::submit { }

100. What rule is generally used, for responsive web design, to target devices with different widths?

Answers:

• @type

• @media

• @screen

• @import

101. How do you hide an element and remove it from the document flow?

Answers:

• Add "visibility: invisible" to your style sheet rule.

• Add "display: none" to your style sheet rule.

• Add "visibility: hidden" to your style sheet rule.

• Add "display: hide" to your style sheet rule.

• Add "image: hide" to your style sheet rule.

102. With what characters are multiple fonts separated with?

Answers:

• dashes

• brackets

• commas

• periods

103. When using z-index which other property is required?

Answers:

• background

• list-style

• overflow

• float

• position

104. Which of the following sets all the border properties in one declaration?

Answers:

• border-css

• border

• border-main

• border-style

• border-all

105. How can you create responsive websites through css?

Answers:

• Referencing multiple external stylesheets with different type attributes for device MIME types.

• Use an @media query.

• None of these.

106. What is the correct pseudo-class for modifying only the first element of a selector?

Answers:

• :first-child

• :1st

• :first-of-type

• :first-element

107. What does the pseudo class last-child do?

Answers:

• selects the last element on the page

• targets the last element on the style sheet

• selects the last element in a targeted parent element.

108. Which of the following will apply a hex color of #445566 to each active link?

Answers:

• a {active-color: #445566;}

• a {color:#445566;}

• a:active {color:#445566;}

• a:active {text-color:#445566;}

109. What are the three methods for implementing a stylesheet?

Answers:

• Linked, Appended, and Embedded

• Internal, Embedded, and External

• Inline, Embedded, and External

• Direct call, Indirect call, and Embedded

110. What is the correct shorthand syntax for a border?

Answers:

• border: 1px solid #777;

• border: 1px 1px solid #777;

• border: 1px rounded #777;

• border: 1px solid #77;

111. Which line changes the background color of a link when a visitor hovers it?

Answers:

• a:link { background-color: #FF704D; }

• a:active { background-color: #FF704D; }

• a:hover { background-color: #FF704D; }

• a:hover { color: #FF704D; }

112. In CSS, the term "box model" is used when talking about?

Answers:

• design and layout

• shipping and receiving

• forms and fields

• html

113. Which of the following has the highest priority?

Answers:

• External style sheet

• Browser default

• Internal style sheet (in the head section)

• Inline style (inside an HTML element)

114. Which of the following is the correct syntax for using z-index?

Answers:

• img z-index:-1}

• img {z-index:-1;}

• img: {z index:-1;}

• img {z index -1;}

115. How will this display: margin: 10px 5px;

Answers:

• Top: 5px, right: 10px, bottom: 5px, left: 10px

• Bottom: 10px, right: 10px: top: 5px, left: 5px

• Top: 10px, right: 5px, bottom:10px, left:5px

• Top: 10px, left: 10px, bottom: 5px, right:5px

• Top: 10px, right: 10px, bottom: 5px, left: 5px

116. What attribute is NOT required when using the <link> tag?

Answers:

• type

• head

• rel

• href

117. Which of these examples of using the clear property are correct?

Answers:

• .text_line { clear:both; }

• .text_line { clear:all; }

• .text_line.clear;

118. How much space does an element take up within the document (on modern browsers) if it has "display: none" styling applied?

Answers:

• It will take up the minimum possible space.

• It will not take up any space.

• It will take up the maximum possible space.

119. Which of the following is the correct syntax for importing one style sheet into another?

Answers:

• import href="other.css";

• link import="other.css";

• style import="other.css";

• @import url("other.css");

120. Which of the following defines the boundary within the element box against which background-image positioning is calculated?

Answers:

• mailorigin

• bg-origin

• image-origin

• background-origin

121. To create a border of 3-pixel width, which css declaration would you use?

Answers:

• border width: 3;

• border-style: 3px;

• border-size: 3px;

• border-width: 3px;

122. Which of the following characters is used to begin a css declaration block?

Answers:

• {

• .

• (

• #

• None of these

123. #container {margin: 20px 30px 10px 50px} The margin-right value will be...

Answers:

• 30px

• 50px

• 20px

• 10px

124. What are the three methods for using style sheets with a web page?

Answers:

• Dreamweaver, GoLive or FrontPage

• Handcoded, Generated or WYSIWYG

• Inline, embedded or document level and external

• Save as .css extension, Save as .css3 extension, Save as .style extension

125. You can apply a style to a selector within a selector without affecting the same selector outside the parent selector.

Answers:

• False

• True

126. Which property controls the additional space between the selected element(s) border and its content?

Answers:

• padding

• spacer

• none of these

• margin

127. Which of these has the highest priority?

Answers:

• inline style

• browser default value

• external style sheet

128. How do you specify 30% opacity in CSS (ignoring IE)?

Answers:

• opacity: 0.3

• opacity: 30%

• opacity: 0.7

• opacity: 70%

129. How would you hide an element using the display property?

Answers:

• display: block;

• display: none;

• display: hidden;

• display: 0;

• display: invisible;

130. Which of the following declarations would display a list without bullets?

Answers:

• list-type: none

• list-style-type: no

• list-style-type: nobullets

• list-style-type: none

131. By which of the following is a declaration terminated?

Answers:

• ;

• !

• ::

• //

132. Which side of the element with ID 'element' will have a 10px margin?  #element { margin: 0px 5px 10px 20px;}

Answers:

• right

• top

• bottom

• left

133. What selector is used to select all elements?

Answers:

• p

• head

• *

• body

• div

134. How do you set the text color in a css rule?

Answers:

• text-color:

• color:

• font-color:

135. Can web fonts be imported with .css files directly

Answers:

• Yes, by using @import url("fontname");

• No, web fonts can't be imported

• Web fonts can only be imported using the <link> tag

136. What is one way to center a fixed-width element (relative to its container)?

Answers:

• left-to-right: center;

• margin: 0 auto;

• float: middle;

• horizontal-align: middle;

137. Which attribute creates space between content and its container?

Answers:

• clear

• margin

• padding

• float

• stuffing

138. Which of the following is correct to transform text into uppercase?

Answers:

• h1 {text-transform:upper;}

• h1 {text:uppercase;}

• h1 {text-transform:uppercase;}

• h1 {text-style:uppercase;}

139. Which of the following selects the active link?

Answers:

• #:active

• all=active

• :active

• active

140. Which of the following sets the stack order of a positioned element?

Answers:

• All of these

• z-index

• ar-index

• s-index

141. Which of the following elements takes up the full width available, and has a line break before and after it?

Answers:

• Square Element

• Box Element

• Side Element

• Block element

142. What is the correct CSS syntax for making all the <p> elements bold?

Answers:

• p { font: bold; }

• p { font-weight: 400; }

• p { font-weight: strong; }

• <p style="text-size: strong">

• p { font-weight: bold; }

143. Which css rule will make an element with an id of "box" invisible?

Answers:

• #box {visibility:hidden}

• #box {visibility:invisible}

• #box {invisible:true}

• box {visibility: visible}

144. What is the difference between margin and padding?

Answers:

• There is no difference they both do the same thing.

• Margin is for creating space between text and padding is for making sure elements do not collide.

• Padding is on the outside of block elements while margin is on the inside.

• Margin is for absolute positioning and padding is for fixed positioning.

• Margin is on the outside of block elements while padding is on the inside.

145. Which of the following units of measurement can be used when creating a margin?

Answers:

• em

• pt

• All of these

• px

146. Which of the following will set h1 to 16 pixels, bold, and underline?

Answers:

• #h1 {font-size: 16px} {font-weight: bold} {text-decoration: underline}

• h1 {font-size: 16px; font-weight: bold; text-decoration: underline;}

• h1 {font-size: 18px; font-weight: bold; text-decoration: underline;}

• h1 {font-size: 16px; font-weight: bold; text: underline;}

147. How can you assign a higher specificity to a property value?

Answers:

• no-override: body { background: blue; }

• body:important { background: blue; }

• body { background: blue !important; }

• body { /* background: blue; */ }

148. Which of the following removes the bullet from an unordered list?

Answers:

• style-type: none;

• list: none;

• list-style-type: none;

149. Which of the following will create a box with a 2 pixel border on the top, 1 pixel border on the bottom, and no other borders?

Answers:

• #box {border: 2px, 0px, 1px, 0px;}

• #box {border: 0px, 0px, 1px, 2px;}

• #box {border: 2px, 1px, 0px, 0px;}

• #box {border: 0px, 2px, 1px, 0px;}

150. Which of the following applies a 2D or 3D transformation to an element?

Answers:

• 3d-transform

• d-transform

• 2d-transform

• transform

151. Which of these can be used to apply style rules to elements in a document?

Answers:

• Inline styles.

• All of these

• Externally linked stylesheets.

• Embedded stylesheets.

152. How can you add a comment to a stylesheet?

Answers:

• Enclose comment between opening and closing comment markers as follows: /* and */

• Enclose comment between opening and closing comment markers as follows: <? and ?>

• Enclose comment between opening and closing comment markers as follows: <!-- and -->

• Enclose comment between opening and closing comment markers as follows: # and #

153. Selects all elements with class="intro"

Answers:

• <intro>

• #intro

• =intro

• .intro

154. Which of the following sets all the properties for a list in one declaration?

Answers:

• list-main

• list-all

• list-style

• list-css

155. Which value is used to define a dashed border?

Answers:

• dashed

• dotted

• dashing

156. What is a CSS rule?

Answers:

• Main markup language for creating web pages and other information.

• HyperText Markup Language

• Statements that tell the web browser how to render certain element or elements on the page.

• Statements that tell the users computer where to go and what to do.

• Statements that tell the server what to do.

157. Which of the following is correct to transform text to lowercase?

Answers:

• p {text:lower;}

• p {text-style:lower;}

• p {text-transform:lowercase;}

• p {text-case:lower;}

• p {text-transform:lower;}

158. Which of the following will set Verdana as the entire page's font type?

Answers:

• body {font-family: Verdana;}

• font {Verdana;}

• body {font-type: Verdana;}

• page {font-family: Verdana;}

159. What is CSS valid syntax for setting the margin value to 0?

Answers:

• margin-all: 0;

• margin: 0;

• margin: 0 0 0 0 px;

• margin; 0;

160. Which of the following code elements will ensure that all images have no border?

Answers:

• #img { border: none; }

• #img { noborder; }

• img { noborder; }

• img { border: none; }

• img { border: noborder; }

161. Which css property can be used to display text with all uppercase, all lowercase, or with forced first-letter capitalization?

Answers:

• text-capital

• text-transform

• text-smaller

• text-styles

162. The CSS3 property for transparency is...

Answers:

• transparency

• opacity

• transparency %

• see-through %

163. Which of the following always refers to text color?

Answers:

• text-color`

• color

• hue

• font-color

164. Which of the following pseudo-elements are invalid?

Answers:

• ;last-paragraph

• :before

• :after

• ::first-line

• ::first-letter

165. Which are the two main parts of a CSS rule?

Answers:

• Only Selector

• Design and Definition

• Selector and Declaration

• Selector and Example

166. What css selector selects the document’s root element

Answers:

• :main-root

• :root-file

• :root

• :root-level

167. What property can be used to turn everything into uppercase or lowercase letters, or capitalize the first letter of each word?

Answers:

• text-transform

• all-text

• capitalize

• transformation

168. Which answer is equivalent to this: h1 { font-family: sans-serif; } h2 { font-family: sans-serif; } h3 { font-family: sans-serif; }

Answers:

• h1, h2, h3 { font-family: sans-serif; }

• h1 h2 h3 { font-family: sans-serif; }

• h* { font-family: sans-serif; }

• None of these

169. What property is used to a set minimum height for an element?

Answers:

• minimum-height

• m-heights

• min: height

• min-height

170. What does the property font-family do?

Answers:

• Specifies the font colors

• Tells you about the relatives of fonts

• Specifies the font size

• Specifies which font to use

171. With these specifications, how will the paddings appear in browser?   padding: 6px 3px 0px 3px;

Answers:

• top: 0px, right: 6px, bottom: 3px, left: 6px

• top: 6px, right: 3px, bottom: 0px, left: 3px,

• top: 6px, right: browser default, bottom: 0px, left: 3px

• top: 6px, right: 0px, bottom: 0px, left: 3px

• top: 0px, right: 6px, bottom: 0px, left: 3px

172. On which side will there be a 20px padding if this is the specified:  	padding: 30px 15px 20px 10px;

Answers:

• left

• top

• bottom

• right

173. Which  property specifies the spacing between lines?

Answers:

• line-height

• line-x

• lineHeight

• textHeight

• height

174. What css selector Insert content before every <p> element

Answers:

• p:before

• P`before

• before=p

• p<before>

175. Which HTML tag is used to define an internal style sheet?

Answers:

• <css>

• <style>

• <link>

• <script>

176. In margin: 10px 20px 40px 30px; what will be the bottom margin?

Answers:

• 40px

• 0

• 10px

• 20px

• 30px

177. Which of the following is an example of using group selectors?

Answers:

• group(h1, h2, p) { color:green;}

• h1, h2, p { color:green;}

• selector(h1, h2, p) { color:green;}

• [h1, h2, p] { color:green;}

178. True or False: Hexadecimal color values are supported in all major browsers.

Answers:

• False

• True

179. Which answer best describes the following statement? <div style="text-align:center; font-size: 14px;"></div>

Answers:

• Internal CSS

• Smart CSS

• Inline CSS

• External CSS

180. What color does this hexadecimal code represent: #000?

Answers:

• black

• opaque

• white

• gray

181. How do you display hyperlinks without an underline?

Answers:

• a {text-decoration:no underline}

• a {text-decoration:none}

• a {decoration:no underline}

• a {underline:none}

• a {decoration: no-underline}

182. Which of the following css declarations will create bold text?

Answers:

• {font-weight: bold;}

• {text: bold;}

• {text-weight: bold;}

• {font: bold;}

183. Which of the following is NOT a valid technique for applying styles to a document?

Answers:

• internal styles

• exceptional styles

• inline styles

• external styles

184. What is the correct method of changing text color?

Answers:

• {color:#000000;}

• {font-color:#000000;}

• {text:#000000;}

• {text-color:#000000;}

185. What is the main difference between styling a <span> and a <div> element?

Answers:

• There is none. They can be styled with the same parameters in mind.

• <span> is an inline element by default, while <div> is a block element.

• You cannot use class inside a <span> tag, only id.

• A <div> is a child-element of <span>, while <span> can't be a child of <div>.

186. Is :focus a pseudo-class?

Answers:

• No

• Yes

187. What property changes the text color of an element?

Answers:

• color

• text-color

• fore-color

• foreground-color

188. Which of the following is NOT a CSS font property?

Answers:

• font-size

• font

• font-invariant

• font-family

• font-style

189. Which of the following css declarations would style hyperlinks using sans-serif fonts?

Answers:

• a:link {font-family: "times new roman", serif;}

• a:link {font-family: "lucida sans unicode", sans-serif;}

• body: font-family: "lucida sans unicode", sans-serif

• paragraph {font-family: "lucida sans unicode", sans-serif;}

190. What is the correct selector format for ID elements in CSS, where id_name is unique ID name to be formatted?

Answers:

• #id_name { }

• if id=id_name then { }

• /* idname { } */

• .id_name { }

191. How would you define class 'myclass' that sets the width of an element to 640px and the height to 480px ?

Answers:

• .myclass {width: 640px; height: 480px;}

• myclass.class {width: 640px; height: 480px;}

• .myclass {width: 480px; height: 640px;}

• myclass {width: 640px; height: 480px;}

• class.myclass {width: 640px; height: 480px;}

192. Internet Explorer supports the fixed value only if...

Answers:

• !DOCTYPE is specified.

• header is specified.

• !DOCTYPE is not specified.

193. Setting the left and right margins to auto specifies that they should split the available margin equally, resulting in...

Answers:

• an element to the left side

• a centered element

• an element to the left of center

• an element to the right side

• an element to the right of center

194. How do you designate an inline style?

Answers:

• style = " "

• src = " "

• css = " "

• href = " "

• inline = " "

195. With what character does a declaration block start and end with?

Answers:

• starts with { and ends with }

• starts with ( and ends with )

• starts with # and ends with .

• starts with " and ends with "

196. What does the float property do?

Answers:

• Aligns HTML elements to the right or left while allowing content to flow around it

• Allows web designers to overlap elements or to stack them on top of each other

• Allows users to drag and drop images to another location on the page

197. What can CSS selectors look for?

Answers:

• certain HTML tags

• all of these

• hovered or clicked objects

• certain classes and ids

• certain objects inside of other certain objects

198. What is the difference between ID and Class?

Answers:

• Classes have browser default values, ID's don't

• You can use multiple classes on the same element, but you can't do that with ID's

• You can use multiple ID's on the same element, but you can't do that with classes

• ID's have browser default values, classes don't

199. Which of the following CSS3 properties is used to round the corners of elements?

Answers:

• rounded-corners

• border-curve

• border-radius

200. What property is used to a set maximum height for an element?

Answers:

• max: height

• m-height

• max-height

• maximum-height

201. Which of the following will set the entire page background color?

Answers:

• #body {background-color:#FFFFFF;}

• body background {color:#FFFFFF;}

• body {background-color:#FFFFFF;}

• body {color:#FFFFFF;}

202. In which example below will all HTML elements with class="master" will be center-aligned?

Answers:

• master -align:center;}

• #master{text-align:center;}

• master:center

• .master {text-align:center;}

• .center {text-:master;}

203. Which of the following defines the tiling pattern for one or more background images?

Answers:

• background tile

• background-repeat

• background-x

• backround-y

204. When does aligning a block element have no effect?

Answers:

• when it's width is set to 100%

• when it's width is set to 50%

205. The background image for a page can be set like this:

Answers:

• background-image:url=sand

• body {background-image:sand.gif';}

• body {background-:sand}

• body {background-image:url('sand.gif');}

206. Block elements can be centered by setting the left and right margins to:

Answers:

• auto

• 100%

• default

• random

207. Which CSS property controls the text size?

Answers:

• font-style

• font-size

• text-style

• text-size

208. Where in an HTML document is the correct place to refer to an external style sheet?

Answers:

• At the top of the document

• At the end of the document

• In the <body> section

• In the <head> section

209. A class is prefaced by what symbol?

Answers:

• #

• @

• <

• </

• .

210. To set the bottom border width...

Answers:

• border-bottom-width:15px;

• border--width:15px;

• border/bottom-width:15px;

• border-bottom"width":15px;

211. Which statement is true about the following markup? <img src="klematis.jpg" width="150" height="113" alt="klematis" style="opacity:0.4;filter:alpha(opacity=40)" />

Answers:

• This image will be completely hidden.

• This image will be partially transparent.

• This image will be partially clipped.

• This image will fade in slowly over time.

212. What is the best way to insert CSS styles across multiple HTML files?

Answers:

• Inline CSS

• Internal CSS

• External CSS

• Don't use CSS, use Google

213. Which HTML attribute is used to define inline styles?

Answers:

• font

• instyles

• style

• styles

• class

214. The id selector uses the id attribute of the HTML element, and is defined with a...

Answers:

• "#"

• "{ }"

• "d"

• :."

• "."

215. Is this a proper statement? body {    font-family: Arial, Helvetica, sans-serif;    color: #000;    background-color: #FFF; }

Answers:

• Yes

• No

216. What does the border-radius property do?

Answers:

• Creates square corners

• Creates colorful corners

• Controls the spacing in a table

• Creates rounded corners

217. Which CSS property contains the following attributes: normal, italic, oblique

Answers:

• font-format

• font-appearance

• font-weight

• font-intensity

• font-style

218. Hex colors are based off of what other web based color mode?

Answers:

• Indexed

• CMYK

• RGB

• Grayscale

219. Which of the following places one or more images in the background of the element?

Answers:

• image-bg

• imagesbackground

• bgimage

• background-image

• background-img

220. What does background-origin property do?

Answers:

• It specifies the background text.

• It specifies the positioning area of the background images.

• It specifies the background color.

221. Which property is used to control the space between the border and content in a table?

Answers:

• padding

• align

• spacing

222. Which tag is used to link External Style Sheets?

Answers:

• <link>

• <ess>

• <external>

• <sheet>

223. Which answer best describes the following css rule? a {text-decoration:none;}

Answers:

• Paragraphs will have hidden text

• It's an anchor with no ship

• Links will be styled with no underlines

• It is invalid

224. Pseudo-elements can be combined with CSS classes.

Answers:

• True

• False

225. In CSS, it is possible to specify different padding for different sides?

Answers:

• Yes

• Only for images

• No

• Only for <P> tags

226. Which of the following is true for setting font type?

Answers:

• p ( font:"Times New Roman",Georgia,Serif; )

• p { font-style:"Times New Roman",Georgia,Serif; }

• p { font-type:"Times New Roman",Georgia,Serif; }

• p { font:"Times New Roman",Georgia,Serif; }

• p { font-family:"Times New Roman",Georgia,Serif; }

227. How do you add a background color?

Answers:

• div {bgcolor : red}

• div {background-color : red}

• div {background-color = red}

• div {bgcolor = red}

228. Which of the following statements is true given the following css and markup? a.red:visited {color:#FF0000;} <a class="red" href="css_syntax.asp">CSS Syntax</a>

Answers:

• The link in the example will turn red on mouseover

• If the link in the example has been visited, it will be displayed in red

• If the link in the example has been visited, it will not be displayed

• The link in the example will always be red

229. What does CSS stand for?

Answers:

• Cascading System Sheets

• Cascaded Style Sheets

• Creative Style Sheets

• Cascading Style Sheets

230. .center {text-align:center;} is an example of

Answers:

• an html tag

• the ID Selector

• the class Selector

231. What is the default file extension for a CSS style sheet?

Answers:

• .style

• .styles

• .main

• .css

232. Which is the correct CSS syntax?

Answers:

• {body;color:black}

• body:color=black

• body (color: black)

• body {color: black}

• {body:color=black(body}

233. Which of these is the correct format for specifying a color?

Answers:

• rgb(255,255,255)

• #ffffff

• #fff

• white

• All of the above

234. Which is the correct syntax for centering the text in the header?

Answers:

• h1 {text-align: centered;}

• h1 {font-align: centered;}

• p {text-align: center}

• h1 {text-align: center;}

235. How do you add a background color for all "<h1>" elements?

Answers:

• h1:all-childs { background-color: #FFFFFF; }

• h1.all { background-color: #FFFFFF; }

• h1 { bg-color: #FFFFFF; }

• h1 { background-color: #FFFFFF; }

236. What pseudo-class need to be used to style a link which has the mouse over it?

Answers:

• a:hover

• mouse over

• a:over

• a:link

237. Which of the following sets how a background image will be repeated?

Answers:

• repeat,background

• background-x-y

• repeat

• background-repeat+image

• background-repeat

238. What does the scale() method do?

Answers:

• It rotates the element

• It increases or decreases the size of element

• It adds color to the element

239. Where in an HTML document is the correct place to refer to an external style sheet?

Answers:

• In the <body>

• In the <head>

• In the <footer>

• In the HTTP headers

240. Which of the following properties is used to set a minimum width on an element?

Answers:

• hsize

• width

• min-width

• x-spacing

• size

241. Which is the correct way to write a comment in CSS?

Answers:

• /*This is a comment*/

• </ This is a comment />

• #This is a comment#

• //This is a comment

242. Which of these is the correct way to specify color?

Answers:

• h1 {color:#00ff00;}

• h2 {color:rgb(255,0,0);}

• All of these

• body {color:blue;}

243. Which syntax displays hyperlinks with an underline?

Answers:

• a {font: decoration: none}

• a {text-decoration: u}

• a {text-decoration: underline}

• a: font-decoration: underline

244. Colors in CSS can be specified by the following methods:

Answers:

• RGB colors

• Hexadecimal colors

• HSL colors

• HSLA colors

• All of these

245. How do you add a background color for all <h1> elements?

Answers:

• all:h1 { background-color: #FFF; }

• h1 { background-color: #FFF; }

• h1.all { background-color: #FFF;}

• h1:all { background-color: #FFF; }

• all.h1 { background-color: #FFF; }

246. What symbol do you use in CSS to call out to an ID?

Answers:

• id=""

• @

• .

• $

• #

247. What is the correct HTML for referring to an external style sheet?

Answers:

• <text/css" href="main.css">

• <link to ="stylesheet" type="text/css" href="main.css">

• <link rel="stylesheet" type="text/css" href="main.css">

• <link/"stylesheet" type="text/css" href="main.css">

248. Which CSS property controls the text size?

Answers:

• Time's Up!

• font-style

• text-size

• text-style

• size-font

• font-size

249. Where in an HTML document is the correct place to refer to an external style sheet?

Answers:

• In the <body> section

• In the <head> section

• Between the <style> tags

• At the end of the document

• At the top of the document

250. What css selector selects all elements?

Answers:

• ~

• !

• ^

• *

251. Which of the following increases or decreases the horizontal  space between characters?

Answers:

• kerning

• tracking

• letter-spacing

252. Which is the correct CSS syntax?

Answers:

• selector { property: value; }

• selector ( property:value )

• selector /property=value

• selector, property=value

• selector { property, value }

253. Dimension properties allow you to control:

Answers:

• the text size in an element

• the color of an element

• the height and width of an element

254. What do the height and width CSS dimension properties allow you to control?

Answers:

• the importance order of the cascade

• 2d and 3d dimensions

• the depth of nested divs

• the height and width of an element

255. The outline property is used to control:

Answers:

• width of outline

• style of outline

• color of outline

• all of these

256. Which of the following CSS declarations would change the border style?

Answers:

• border-style: solid;

• border-weight: solid;

• border-width: solid;

• borderstyle solid;

257. Which property is used to specify the kind of border to display?

Answers:

• border-design

• border-display

• border-kind

• border-style

258. What property alters an elements background color?

Answers:

• color

• bgcolor

• background-color

259. Who maintains CSS?

Answers:

• Mozilla

• W3C

• Google

• Apple

• Microsoft

260. Which tag is used to define an Internal Style Sheet?

Answers:

• <iss>

• <script>

• <style>

• <internal>

261. Which of these is not a vendor prefix?

Answers:

• -o-

• They are all vendor prefixes.

• -moz-

• -webkit-

• -ms-

262. The class selector is used to specify a style for:

Answers:

• a group of elements

• the <head> tag

• the <p > tag

• the <a> tag

263. What is the correct HTML for referring to an external style sheet?

Answers:

• <style src="mystyle.css">

• <link rel="stylesheet" type="text/css" href="mystyle.css">

• <stylesheet>mystyle.css</stylesheet>

264. What are the possible values of the property background-attachment?

Answers:

• scroll

• fixed

• Both scroll and fixed

265. Which HTML tag is used to define an internal style sheet?

Answers:

• <script>

• <style>

• <css>

266. Which element/pseudo-element pair can be used to create a mouseover effect on all links?

Answers:

• a:unvisited

• a:active

• a:hover

• a:link

• a:visited

267. CSS stands for

Answers:

• Common Style Sheets

• Cascading Style for Strings

• Common Style for Strings

• Cascading Style Sheets

• Community Specification of Styles

268. Which of the following characters is used to end a css declaration block?

Answers:

• >

• ]

• }

• None of these

• )

269. Which is the correct CSS syntax?

Answers:

• body:color=black

• body { color; red }

• body { color: red; }

• { body; color: black }

• { body: color=black(body }

270. Which property is used to change the background color?

Answers:

• backgroundcolor:

• background-color:

• color-bkgd:

• bgcolor:

• color-background:

271. Which of these is the correct CSS syntax for specifying the left margin of an element?

Answers:

• p {margin-left:20px;}

• {p = margin-left:20px}

• {p: margin-left:(20px)}

• {p: margin-left:20px;}

272. In an HTML document, where is the correct place to refer to an external CSS file?

Answers:

• In the <head> section

• At the end of the document

• In the <body> section

• In the <title> section

273. When does the link state a:hover occur?

Answers:

• When the user mouses over it

• When the user has visited it

• It is a normal link

• When the user clicks it

274. Which answer best describes the purpose of the following markup?  <link rel="stylesheet" href="style.css" type="text/css" />

Answers:

• To call an external stylesheet

• To call an internal stylesheet

• To request a sandwich

• It does nothing

275. Which of the following is NOT a web-safe font?

Answers:

• Zapfino

• Times New Roman

• Arial

• Verdana

• Georgia

276. Which of the following determines whether the text should be displayed as italics or regular text?

Answers:

• foont

• styles-font

• font-decoration

• font-style

• foont-styles

277. Which symbol is used to define an ID?

Answers:

• % (percent sign)

• $ (dollar sign)

• # (pound sign)

• ! (exclamation point)

• @ (the "at" symbol)

278. What does the background-color property do?

Answers:

• Specifies the background color of an element

• Specifies the background image

• Copies the background color from another element

• Returns "true" if the background color matches another element

279. What is the extension for an external style sheet?

Answers:

• .css

• .theme

• .sass

• .style

• .styles

280. The background color can be specified by:

Answers:

• a HEX, e.g., #00ff00

• a color name, e.g., yellow

• All of these

• an RGB value, e.g., rgb(255,0,255)

281. Which character, followed by the selector's name, is used for defining ID selectors?

Answers:

• #

• !

• %

• &

282. Which properties can be applied to first-line pseudo-element?

Answers:

• All of these

• background properties

• word-spacing

• vertical-align

• font properties

283. What should CSS be used for?

Answers:

• scripting

• just themes

• styling

• structure

284. .css files may be created using what software?

Answers:

• All of these, any text editor will do.

• Smultron

• BBEdit

• Text Mate

285. Which contemporary web browser(s) support CSS?

Answers:

• Internet Explorer

• Firefox

• All of these

• Chrome

286. Which CSS property controls the text size?

Answers:

• text-style

• font-size

• font-style

• text-size

287. The default value of the font-variant property is

Answers:

• small-caps

• different

• large-caps

• normal

288. What's the name of the layout technique that relies on CSS3 media queries to apply different styles based on the width of the browser window?

Answers:

• Fluid

• Responsive

• Elastic

• Liquid

289. Which property can be used to set the color of a text?

Answers:

• color

• color-spacing

• color-space

290. An id is prefaced by what symbol?

Answers:

• #

• <

• @

• </

• .

291. What is the correct HTML for referring to an external style sheet?

Answers:

• <style src="mystyle.css" />

• <stylesheet>mystyle.css</stylesheet />

• <link rel="stylesheet" type="text/css" href="mystyle.css">

292. Where in an HTML document is the correct place to refer to an external style sheet?

Answers:

• At the beginning of the document

• In the <head> section

• In the <body> section

• At the end of the document

293. What does CSS stand for?

Answers:

• Creative Style Sheets

• Computer Style Sheets

• Colorful Style Sheets

• Cascading Style Sheets

294. What does CSS stand for?

Answers:

• Cascading Style Sheets

• Common Style Syntax

• Creative Style Sheet

• Computer Style Sheets

295. Which configuration of the web elements in the page markup gives you great flexibility in the design of your site?

Answers:

• margins

• All are correct

• border

• padding

296. What is the correct HTML for referring to an external style sheet?

Answers:

• <link to ="stylesheet" type="text/css" href="main.css">

• <text/css" href="main.css">

• <link/"stylesheet" type="text/css" href="main.css">

• <link rel="stylesheet" type="text/css" href="main.css">

297. Which is the correct CSS syntax?

Answers:

• selector, property=value

• selector { property: value; }

• selector /property=value

• selector { property, value }

• selector ( property:value )

298. Where in an HTML document is the correct place to refer to an external style sheet?

Answers:

• In the HTTP headers

• In the <footer>

• In the <head>

• In the <body>

299. Where in an HTML document is the correct place to refer to an external style sheet?

Answers:

• At the end of the document

• At the top of the document

• In the <head> section

• Between the <style> tags

• In the <body> section

300. Which is the correct CSS syntax?

Answers:

• body (color: black)

• body:color=black

• {body;color:black}

• body {color: black}

• {body:color=black(body}

301. How do you add a background color for all <h1> elements?

Answers:

• h1 {background-color:#FFFFFF;}

• all.h1 {background-color:#FFFFFF;}

• h1.all {background-color:#FFFFFF;}

302. The id selector uses the id attribute of the HTML element, and is defined with a

Answers:

• "%"

• "#"

• "@"

• "_"

303. What does CSS stand for?

Answers:

• Cascading Style Sheets

• Cascading System Sheets

• Cascaded Style Sheets

• Creative Style Sheets

304. Where in an HTML document is the correct place to refer to an external style sheet?

Answers:

• At the end of the document

• In the <body> section

• In the <head> section

• At the top of the document

305. Which is the correct syntax of the background color for links?

Answers:

• a:link {background-color:#B2FF99;}

• a:link {background-color:@B2FF99;}

• a:link {background-color:!B2FF99;}

• a:link {background-color:%B2FF99;}

306. Which property can be used, along with a position property, to create an effect of layers?

Answers:

• x-index

• z-index

• a-b testing

• y-index

307. The _________ means an element that has the user's mouse pointer hovering over it.

Answers:

• a:hover

• a:visited

• a:link

308. Which CSS property can provide to add an effect when changing from one style to another,without using Flash animations or javascript?

Answers:

• transistor

• Associations

• Transitions

309. Which is the correct CSS syntax?

Answers:

• <p style="text-align:left or color:#00CC00"> This text is in left. </p>

• <p style="text-align:left;color:#00CC00"> This text is in left. </p>

• <p style="text-align:left and color:#00CC00"> This text is in left. </p>

• <p style="text-align:left,color:#00CC00"> This text is in left. </p>

310. Which property can be used to control the flow and formatting of text?

Answers:

• white-space

• red-space

• blue-space

• green-space

311. How do you make the text bold?

Answers:

• style:bold

• font-weight:bold

• font:b

312. Which of the following ways below is correct to write a CSS?

Answers:

• body {color: black}

• {body:color=black(body}

• {body;color:black}

• body:color=black

313. Negative values for transition-duration are treated as

Answers:

• 1

• 3

• 2

• 0

314. The ..................... specifies whether a border should be solid, dashed line, doted line, double line, groove etc.

Answers:

• border-layout

• border-decoration

• border-weight

• border-style

315. They must be define a border-style for the border to show up. Available terms:

Answers:

• thick

• thin

• All are correct

• medium

316. A ___________ property can help you to create more complex webpage layouts

Answers:

• x-index

• y-index

• z-index

317. The CSS list properties allow you to:

Answers:

• Set different list item markers for unordered lists

• Set an image as the list item marker

• Set different list item markers for ordered lists

• All are correct

318. What does CSS define in HTML?

Answers:

• How to made HTML elements

• How to display HTML elements

• How to send HTML elements

• How to save HTML elements

319. CSS colors are defined using a _________ notation for the combination of Red, Green, and Blue color values (RGB).

Answers:

• octadecimal

• pentadecimal

• hexadecimal

• nanodecimal

320. The <link> tag goes inside

Answers:

• body section

• The head section

• title section

321. How to apply the text-shadow around the text?

Answers:

• <all.p style="text-shadow:6px 6px 10px #FF0000 "> Text-shadow is of red color. </p>

• <p style="text-shadow:6px 6px 10px #FF0000 "> Text-shadow is of red color. </p>

• <p.all style="text-shadow:6px 6px 10px #FF0000 "> Text-shadow is of red color. </p>

322. Which states whether the text is underlined or not?

Answers:

• text-transform:

• text-shadow:

• text-spacing:

• text-decoration:

323. ...................... is used to import an external style sheet in a manner similar to the <link> element.

Answers:

• @import

• #insert

• @insert

• #import

324. The ________________ specifies whether a border should be solid, dashed line, doted line, double line, groove etc.

Answers:

• border-style

• border-weight

• border-decoration

• border-layout

325. In reality layers are often used in more dynamic ways:

Answers:

• Flying elements/banners on the page

• Menus that pop out when triggered

• Games where you move an object around

• All are correct

326. Which properties is used to change the case of the text?

Answers:

• text-shadow:

• text-transform:

• text-decoration:

• text-spacing:

327. Which is the correct syntax of css border?

Answers:

• .two { border->solid 6px #fff; position-> relative; z-index-> 1; }

• .two { border= solid 6px #fff; position=relative; z-index=1; }

• .two { border: solid 6px #fff position: relative z-index: 1

• .two { border: solid 6px #fff; position: relative; z-index: 1; }

328. True or False? With CSS, it's possible to customize the numbers that appear next to list items within <ol> elements.

Answers:

• True

• False

329. Which property can be used to decorate links by specifying no underline with the text?

Answers:

• text-decoration:line-through

• text-decoration:overline

• text-decoration:none

• text-decoration:underline

330. True or False: The universal selector, written "*", matches the name of any element type. It matches any single element in the document tree.

Answers:

• True

• False

331. The ___________ property allows to specify how much space appear between the content of an element and it's border.

Answers:

• Content-border

• Marking

• padding

• Spacing

332. __________ property is mostly used to remove underlines from links:

Answers:

• text-trans

• text-decoration

• text-transformation

333. The ___________ property allows you to control the shape or style of bullet point in the case of unordered lists, and the style of numbering characters in ordered list.

Answers:

• list-style-layout

• list-style-type

• list-type

• list-type-style

334. The text-decoration are:

Answers:

• text-decoration:line-through

• All are correct

• text-decoration:underline

• text-decoration:overline

335. Which is the correct CSS syntax?

Answers:

• <p"style=direction:inherit"> Possible values are ltr,rtl and inhert. </p>

• <p "style:direction=inherit"> Possible values are ltr,rtl and inhert. </p>

• <p style="direction:inherit"> Possible values are ltr,rtl and inhert. </p>

• <p "style=direction->inherit"> Possible values are ltr,rtl and inhert. </p>

336. The ____________ property allows to specify how much space appear between the content of an element and it's border.

Answers:

• Spacing

• Padding

• Marking

• Content-border

337. Which Represents a line that acts as a boundary?

Answers:

• Margin

• Border

• Padding

338. How do you make a list that lists its items with squares?

Answers:

• list-type: square

• list-style-type: square

• type: square

339. A ......... tag is used to specify that the browser is to fetch and use an external style sheet file

Answers:

• <sheet>

• <src>

• <link>

340. Which property can be used to specify all the list properties into a single expression?

Answers:

• ls-style

• None

• list-style

• liststyle

341. Which styles of border can be look in dotted?

Answers:

• border-style: outset;

• border-style: solid;

• border-style: dashed;

• border-style: dotted;

342. To create a layer all you need to do is assign the _______ attribute to your style

Answers:

• location

• direction

• position

343. Which property gets provide the increments or decrements the space between characters?

Answers:

• white-space

• letter-spacing

• direction

344. Hex values are written as 3 double digit numbers, starting with a

Answers:

• % sign

• @ sign

• # sign

• $ sign

345. CSS comments are inserted inside .

Answers:

• <!..................>

• /*..................*/

• All of them

• //...................//

346. Which is the correct syntax of the CSS?

Answers:

• <p style=font-size:"14pt"> Welcome to teds-india.</p>

• <p style="fontsize:14pt"> Welcome to teds-india.</p>

• <p "style=font-size:14pt"> Welcome to teds-india.</p>

• <p style="font-size:14pt"> Welcome to teds-india.</p>

347. What are the two components of every CSS style definition?

Answers:

• selector, properties

• copy, properties

• section, id

• selection, properties

348. What do the Greater Than sign > indicate in CSS

Answers:

• Selects the next element

• Selects the previous element

• Select the child of the element it follows

• Selects the last element

349. What is the correct way to set the color of hover links?

Answers:

• <style type="text/css"> a->hover {color:#000000} </style>

• <style type='text/css'> hover:a {color:#000000} </style>

• <style type="text/css"> a:hov {color:#000000} </style>

• <style type="text/css"> a:hover {color:#000000} </style>

350. The id selector is used to specify a style for

Answers:

• single, common element

• single, unique element

• multiple,unique element

• multiple,common element

351. p { width:220px; padding:10px; border:5px solid gray; margin:0px; } The total width of an element is calculated like this:

Answers:

• Total element width = width + right padding + right border + right margin

• Total element width = width + left padding + left border + left margin

• Total element width = width + left padding + right padding + left border + right border + left margin + right margin

352. Which concept uses the CSS from which implies that every HTML element is a box?

Answers:

• box model

• table model

• frame model

353. Which of the syntax is correct?

Answers:

• <div style="position:relative; font-size:50px; z-index:2;">LAYER 1</div>

• <div style="position:rel; font-size:50px; z-index:2;">LAYER 1</div>

• <div style="position:relative; font-size:50px; z-ind:2;">LAYER 1</div>

• <div style="position:relative; font-size:50px; yz-index:2;">LAYER 1</div>

354. Which part of the box, where text and images appear?

Answers:

• Border

• Padding

• Margin

• Content

355. The completion of a CSS Transition generates a corresponding

Answers:

• MOD Event

• OMD Event

• DOM Event

356. The correct example of class selector is .

Answers:

• #h2 type1 {color: #000000;}

• h2 type1 {color: #000000;}

• h2.type1 {color: #000000;}

• h2 #type1 {color: #000000;}

357. Pseudo classes may be applied to any element but are most commonly used with the __ element.

Answers:

• 'd'

• 'c'

• 'b'

• 'a'

358. Multiple font faces are separated by __________

Answers:

• Slash

• Semicolon

• Comma

• Dot

359. Which is the correct CSS syntax?

Answers:

• <p "style=direction:lttr"> This text is in left direction. </p>

• <p style="direction:lltr"> This text is in left direction. </p>

• <p style="direction:ltr"> This text is in left direction. </p>

• <p style:"direction=ltr"> This text is in left direction. </p>

360. The following syntax to set margin around a paragraph will make- p{margin:10px 2%}

Answers:

• Top margin will be 10px and other margins will be 2% of the total width

• Top and bottom margin will be 10px and left and right margin will be 2% of the total width.

• Left and right margin will be 10px and top and bottom margin will be 2% of the total height

• Left margin will be 10px and other margins will be 2% of the total width

361. The possible values of white-space are

Answers:

• <p style="white-space->normal"> Use of normal white-space. </p>

• <p style="white-space:normal"> Use of normal white-space. </p>

• <p style=white-space:"normal"> Use of normal white-space. </p>

• <p style="whitespace:normal"> Use of normal white-space. </p>

362. What property is used to specify the indentation of the first line of a text?

Answers:

• text-transform

• text-format-indentation

• text-indent

• text-decorate

363. What does a 'position: fixed;' declaration accomplish?

Answers:

• Fixes the element on its parent element

• Fixes the element relative to the browser's viewport

• Fixes the element on its child element

364. You have three blocks of markup that share property values. Which of the following ways is the most efficient?

Answers:

• .one { property: value; } .two { property: value; } .three { property: value; }

• .one .two .three { property: value; }

• .one / .two / .three { property: value; }

• .one, .two, .three { property: value; }

365. Which values can be used to set text direction?

Answers:

• mltr and mrtl

• ltr and rtl

• ttr and btr

• None

366. An outline is always placed __________ of the box

Answers:

• Inline

• backline

• Outline

367. The_________ means unvisited hyperlinks.

Answers:

• :visited

• :hover

• :active

• :link

368. Which two properties are the defaults when positioning a layer?

Answers:

• bottom, left

• top, right

• top, left

• bottom, right

369. The transition-duration property is in fact the only property required

Answers:

• as if transition-property is not supplied

• all properties that are able to undergo a transition

• All are correct

• to create a transition effect

370. What CSS selector selects all elements with a target attribute?

Answers:

• {target}

• `target

• /target/

• [target]

371. ____________ properties provide several options to place the content on the web page.

Answers:

• Margin

• Positioning

• Location

372. Which properties specifying whether to write the text from left to right or from right to left?

Answers:

• white-space

• letter-spacing

• none

• direction

373. A shorthand property for setting the four transition properties into a single property

Answers:

• transition

• transition-duration

• transition-property

• transition-delay

374. p.outset {border-style: outset; } In the code snippet above, which part represents the property?

Answers:

• border-style

• outset

• p

375. Fonts such as Times New Roman which have spaces in between must be wrapped inside ______

Answers:

• Curly Braces

• Quotation Mark

• Triangular Brackets

• Round Brackets

376. Which of the following elements will be matched by the CSS selector: div[class*="foo"] ?

Answers:

• <div class="baz-foo"> ... </div>

• <div class="foobar"> ... </div>

• All of these elements will be matched.

• <div class="foo"> ... </div>

377. Write the css selector for the 3rd list item within an ordered list.

Answers:

• li:nth-child(2n+1) { // do something }

• li:nth-child(3n) { // do something }

• li:nth-child(1n+2) { // do something }

• li:nth-child(3) { // do something }

• none of these

378. Which of the correct syntax css cursor code?

Answers:

• p { cursor: late } h4 { cursor: help } h5 { cursor: circlehair }

• p { cursor: wait } h4 { cursor: help } h5 { cursor: crosshair }

• p { cursor: reply } h4 { cursor: request } h5 { cursor: crosshair }

• p { cursor: wt } h4 { cursor: hp } h5 { cursor: crshair }

379. The First step of transition is

Answers:

• transition-duration

• transition-property

• transition-timing-function

• transition-delay

380. Which of the following elements will be matched by this CSS selector: div[class|="foo"] ?

Answers:

• <div class="foo"> ... </div>

• All of these elements will be matched.

• <div class="foo-bar foo-baz"> ... </div>

• <div class="foo-bar"> ... </div>

381. State whether True or False.  i) Any inline style sheet takes highest priority. ii) Any rule defined in <style> ...........................</style> tag will override rules defined in any external style sheet file.

Answers:

• i-True, ii-False

• i-True, ii-True

• i-False, ii-True

• i-False, ii-False

382. The possible values of white-space are

Answers:

• All are correct

• post

• pre

• normal(default value)

383. The_____________ property indicates whether a cell without any content should have a border displayed.

Answers:

• noborder-cells

• nocontent-cells

• empty-cells

• blank-cells

384. What CSS selector selects all elements with a target attribute?

Answers:

• [blank]

• [target_blank]

• [target]

• [target=_blank]

385. Which of the following color values is invalid?

Answers:

• transparent

• #abcdef

• rgb(1, 2, 3)

• #f00

• They're all valid.

386. The ................... property indicates whether a cell without any content should have a border displayed.

Answers:

• empty-cells

• blank-cells

• nocontent-cells

• noborder-cells

387. Which of the following code samples could be used to style a link whose URL begins with "https://sales."?

Answers:

• a:before { content: attr(href) "https://sales."; color: pink; }

• a { prepend: href='https://sales.'; color: pink; }

• a[href^='https://sales.'] { color: pink; }

• None of these, can't do that in CSS

388. Which of the following is true about the overflow property?

Answers:

• It specifies what happens if content overflows an element's box.

• It fixes the content in the table, if content overflows an element's box.

• The property values of the overflow properties include: visible, hidden, scroll, set and parent.

389. What does the following selector do: element[foo]

Answers:

• Matches any element without a foo attribute.

• Matches only elements without the foo attribute set.

• Matches any element with the foo attribute set.

• Matches only one element with the foo attribute set.

390. What does "Cascading" in CSS refer to?

Answers:

• The hierarchy of rules which determines how element properties are inherited

• Separates a document's content from its display rules

• The way elements of a document can "cascade" by being moved on the page

• A series of independent rules to control document style

391. The transition-duration property's initial value is 0, meaning that the transition is

Answers:

• simultaneous

• stantaneous

• instantaneous

392. Which list-style-type property renders a filled circle?

Answers:

• square

• circle

• disc

393. Which HTML tag can be used to connect one page with an external resource?

Answers:

• tree

• link

• node

• src

394. The Text spacing properties are

Answers:

• The letter-spacing property :

• The word-spacing property :

• All are correct

• The text-indent property :

395. Does using or not using a doctype (in HTML) affect how CSS styles HTML? (also known as standards mode vs quirks mode)

Answers:

• no, it's strictly for HTML

• yes, it affects HTML rendering and CSS styling

396. Which value of the border style property can look as though it were embedded in the canvas?

Answers:

• ridge

• hidden

• inset

• groove

397. Which type of border attribute can be used to have a unique look for each side of the border?

Answers:

• border-(location)

• border-(downwarddirection)

• border-(direction)

• border-(upwarddirection)

398. What is the border-spacing property?

Answers:

• It is the distance between the border and text in the table.

• It is the distance between 1 table to another table.

• It sets the distance between the borders of adjacent cells (only for the "separated borders" model).

• It is the distance between a table and text outside the table.

• It is the distance between the text in 1 cell to the text of adjacent cells.

399. What does the following mean: ul[id^="name-here"]

Answers:

• target any <ul> with an ID that starts with 'name-here'

• target any <ul> with an ID that ends with 'name-here'

• target any <ul> with an ID that contains 'name-here'

• target any <ul> with an ID similar to 'name-here'

400. True or False: The :first-line pseudo-element applies special styles to the contents of all but the first formatted line of a paragraph.

Answers:

• True

• False

401. Which properties allow specifying the formatting rules for the textual content on a Web page?

Answers:

• CSS textual

• CSS text

• CSS texting

• None

402. What colors are displayed when using six identical hexadecimal numbers to define color?

Answers:

• red, purple or blue

• white, gray or black

• yellow, orange or red

• red, green or blue

403. Which property is used to specify typefaces ?

Answers:

• font-name

• font-face

• font-type

• font-family

404. Which of the following properties is MOST likely to increase the amount of time it takes the browser to repaint?

Answers:

• box-shadow

• opacity

• border-width

• color

• font-weight

405. Which value will continue to display the text on the same line,until the BR element is specified?

Answers:

• post

• nowrap

• normal

• pre

406. Which of the following is invalid ?

Answers:

• .selector { background-image: url("image.png"); }

• .selector { content: url("image.png"); }

• .selector { background-image: url(image.png); }

• .selector { background-image: content("image.png"); }

• .selector { background: url("image.png"); }

407. In which position it will be calculated from the upper left corner of the parent layer?

Answers:

• position:absolute

• position:relative

408. What is absolute positioning?

Answers:

• When an element is positioned using only z-index positioning.

• When an element is positioned in a natural location in a page's flow.

• When an element is positioned relative to the first parent element that has a position other than static.

• When an element is positioned relative to the browser window.

409. A user can only view the border after specifying the

Answers:

• All are correct

• width

• styles

• color

410. The ______________ property describes how the intermediate values used during a transition will be calculated

Answers:

• transition-timing-function

• transition time

• transition duration

411. The value of letter-spacing property is

Answers:

• both normal or of length type

• either normal or of length type

• neither normal or of length type

412. Which aspect of CSS has some direct resemblance with the common regular expression syntax?

Answers:

• Pseudo classes

• Property names

• Property values

• Attribute selectors

• 3d translating

413. In which position will be calculated from that exact spot in the middle of your page where it was added?

Answers:

• position:relative

• position:absolute

414. Which part of the following selector does the browser parse first?  ul > li a[title="home"]

Answers:

• li

• ul

• >

• a[title="home"]

415. Which of the following selectors is the MOST efficient?

Answers:

• #menu ul .text { ... }

• ul#menu li a.text { ... }

• ul#menu .text { ... }

• #menu ul li a.text { ... }

• #menu .text { ... }

416. In CSS tables, the possible values for the caption-side property can have the following values.

Answers:

• left or right

• top, bottom, left or right

• top or bottom

• top, bottom, center, left or right

417. What does the CSS cue property do?

Answers:

• Specifies the frequency of the speaking voice

• Prompts the user to enter a voice command

• Specifies a sound to be played before and after the selected element

• Specifies a sound to be played as a background while an element's content is spoken

418. To style a link that ends in .html differently than a link that ends with another file extension you would use which code?

Answers:

• a[href&='.html']{color: purple;}

• a[href^='.html']{color: purple;}

• a[href$='.html']{color: purple;}

• a[href*='.html']{color: purple;}

419. Which value preserves the white spaces as specified in the content?

Answers:

• nowrap

• post

• normal

• pre

420. Which of the following is correct CSS syntex for using font property?

Answers:

• <p style="font: italic, bold, 15px;"> ................ </p>

• None of these

• <p style="font: italic bold 15px;"> ....................... </p>

• <p style="font-style: italic font-weight: bold font-size: 15px;"> ................... </p>

421. Which of the following declarations is incorrect?

Answers:

• table { direction: rtl; }

• table { display: table-column-grouped; }

• table { border-collapse: separate; }

• table { empty-cells: hide; }

• table { table-layout: fixed; }

422. Describes how the speed during a transition will be calculated. Default "ease"

Answers:

• transition-property

• transition-delay

• transition-timing-function

• transition-duration

423. A Group of font families with a similar look

Answers:

• font-size family

• inherit family

• font family

• generic family

424. Which property defines the distance between the nearest border edges of a marker and its associated principal box in an unordered list?

Answers:

• list-spacing

• marker-spacing

• list-offset

• marker-offset

425. A final property is the visibility property that will allow you to create

Answers:

• enable layers

• invisible layers

• visible layers

426. Which is not a valid pseudo class?

Answers:

• :root

• :valid

• :matches()

• :only-of-type

• :nth

427. The color names are defined in the HTML and CSS color specification (___ standard colors plus ____ more).

Answers:

• 18,126

• 17,124

• 15,123

• 16,125

428. In css border radius is not supported by Internet explorer version under

Answers:

• 9

• 10

• 8

• 7

• 6

429. To use inline styles you use the style attribute in the ............... tag

Answers:

• relevant tag

• link tag

• style tag

430. Which of the following declarations is incorrect?

Answers:

• ul { list-style-type: decimal-leading-zero; }

• ul { list-style-type: roman; }

• ul { list-style-type: circle; }

• ul { list-style-type: hiragana; }

• ul { list-style-type: lower-alpha; }

431. Which property is used to specify table borders in CSS?

Answers:

• border

• edge

• dimension

432. How do you add images to list items?

Answers:

• li-image-style: url(../images/bullet.gif);

• list-style-image: url(../images/bullet.gif);

• list-image: url(../images/bullet.gif);

• list-image-style: url(../images/bullet.gif);

433. Which of the following is invalid ?

Answers:

• .selector { content: url("image.png"); }

• .selector { background-image: content("image.png"); }

• .selector { background: url("image.png"); }

• .selector { background-image: url("image.png"); }

• .selector { background-image: url(image.png); }

434. Which of these is NOT a CSS pseudo-class?

Answers:

• a:blur

• p:after

• a:hover

• input:focus

• a:active

435. What is the order of precedence (highest to lowest) when applying styles?

Answers:

• external > inline > embedded

• inline > embedded > external

• inline > external > embedded

• embedded > external > inline

436. To ensure consistent behavior when the user resizes text, font-size should be declared in units of:

Answers:

• pt

• px

• em

• percent

437. Which of the following code samples could be used to style a link whose URL begins with "https://sales."?

Answers:

• a { prepend: href='https://sales.'; color: pink; }

• a[href^='https://sales.'] { color: pink; }

• None of these, can't do that in CSS

• a:before { content: attr(href) "https://sales."; color: pink; }

438. All monospace characters have the same...

Answers:

• height

• weight

• width

• decoration

439. What CSS syntax can be used to hide an image without affecting the documents layout?

Answers:

• visibility: hidden

• display: none

• visibility: invisible

• image: hide

• display: hide

440. Does using or not using a doctype (in HTML) affect how CSS styles HTML? (also known as standards mode vs quirks mode)

Answers:

• yes, it affects HTML rendering and CSS styling

• no, it's strictly for HTML

441. Which of the following is true about the overflow property?

Answers:

• It fixes the content in the table, if content overflows an element's box.

• It specifies what happens if content overflows an element's box.

• The property values of the overflow properties include: visible, hidden, scroll, set and parent.

442. Which version of CSS supports this tag   :nth-child   ?

Answers:

• CSS 2.1

• CSS 1

• CSS 2

• All versions

• CSS 3

443. What would the following do?  tr:nth-child(2n){background-color: red; }

Answers:

• Changes the background color of every even number table row to red

• Changes the text color of every even number table row to red

• Changes the background color of ONLY the second row in a table to red

• Is invalid CSS

• Changes the text color of ONLY the second row in a table to red

444. The Hex color #0000FF is equal to:

Answers:

• green

• red

• blue

• yellow

445. What is the border-spacing property?

Answers:

• It is the distance between the text in 1 cell to the text of adjacent cells.

• It is the distance between a table and text outside the table.

• It sets the distance between the borders of adjacent cells (only for the "separated borders" model).

• It is the distance between 1 table to another table.

• It is the distance between the border and text in the table.

446. What does the following mean: ul[id^="name-here"]

Answers:

• target any <ul> with an ID that ends with 'name-here'

• target any <ul> with an ID that starts with 'name-here'

• target any <ul> with an ID that contains 'name-here'

• target any <ul> with an ID similar to 'name-here'

447. What property defines whether background images scroll along with the element when the document is scrolled?

Answers:

• bg-move

• bg

• background-scroll

• main-bg-scroll

• background-attachment

448. Which of the following is NOT a common browser layout engine that determines CSS default styles?

Answers:

• Commando

• Trident

• Gecko

• WebKit

449. A CSS ________ is a keyword added to selectors that specifies a special state of the element to be selected.

Answers:

• selector

• operator

• element

• pseudo-class

• rule

450. What is the name for a property that clears an area outside the border and is completely transparent?

Answers:

• box model

• border

• padding

• content

• margin

451. What property is used with the :before and :after pseudo-elements to insert generated content?

Answers:

• value

• insert

• content

• html

• text

452. What does the outline-offset property do?

Answers:

• Draws an outline beyond the border edge.

• Both of the other answers are correct.

• Offsets an outline

453. If an element appears before a floated element that element will...

Answers:

• float to the center

• float to the bottom

• not be affected.

• float around it

• float to the top

454. When using "position: absolute;" the reference point is the browser window UNLESS one of the parent elements contain one of the following...

Answers:

• position: static;

• position: inherit;

• position: fixed;

• All of these

• position: relative

455. What has the greatest specificity?

Answers:

• h2.foo {color: blue;}

• *.foo tr:first-child {background: black;}

• #footer {background: white;}

• div strong {font-weight: bolder;}

456. Which property is used to specify type faces ?

Answers:

• font-type

• font-face

• font-name

• font-family

457. What character is used before the pseudo-class property?

Answers:

• colon

• dot

• semicolon

• hash

458. What does a 'position: fixed;' declaration accomplish?

Answers:

• Fixes the element on its parent element

• Fixes the element relative to the browsers viewport

• Fixes the element on the page

459. What does "Cascading" in CSS refer to?

Answers:

• The hierarchy of rules which determines how element properties are inherited

• The way elements of a document can "cascade" by being moved on the page

• A series of independent rules to control document style

• Separates a document's content from its display rules

460. Select the correct value to set the background to silver for even rows.

Answers:

• tr:nth-child(2) {background: silver;}

• tr:nth-child(1) {background: silver;}

• tr:nth-child(2n) {background: silver;}

• tr:even {background: silver;}

461. What does the background-attachment property do?

Answers:

• It sets whether a background image should scroll with the content, or be fixed.

• It links background as an external file.

• It displays a link to the background.

• It attaches an image to the background.

462. Where will a block level element appear in relations to the previous element in the document (by default)?

Answers:

• Above the previous element

• On top of the previous element

• Alongside the previous element

• Below the previous element

463. What is NOT an advantage of using CSS files?

Answers:

• Ability to hide the CSS code from the user.

• The ability to change the look of a whole site by changing a single file.

• Separation of style and content.

• Less-cluttered HTML code, making it easier to read and maintain.

464. Which at-rule allows you to define custom fonts?

Answers:

• @type-family { }

• @font-family { }

• @font-face { }

• @font { }

465. Pseudo-classes are used to represent _______.

Answers:

• Casual Events

• Dynamic Events

• Static Events

• Related Events

466. Which of the following best describes the effect that a floated element has on surrounding elements?

Answers:

• The elements after the floating element will flow around it.

• The elements before the floating element will be affected.

• If an image is floated to the right, a following text flows around it, to the right:

467. What does the following declaration accomplish?  div{background-color: rgba(255,255,255,0.8); }

Answers:

• It sets a white background with a transparency of 80% to the div element.

• It sets a black background with a transparency of 80% to the div element.

• It sets a light gray background with a transparency of 80% to the div element and its children.

• It sets a dark gray background to the div element.

• Nothing: this declaration is not supported in Webkit browsers.

468. Given: table { color: blue; }, which part represents the property?

Answers:

• { color: blue; }

• blue

• table

• color

469. Identify the value in the following rule: a:hover { text-decoration: none; }

Answers:

• none

• text-decoration

• a

• text-decoration: none;

• a:hover

470. Which of the following color values is invalid?

Answers:

• #f00

• rgb(1, 2, 3)

• transparent

• They're all valid.

• #abcdef

471. What are the correct values for "float" property?

Answers:

• left, right, top, bottom

• left, right

• left, right, all

• left, right, none

472. What CSS selector selects all elements with a target attribute?

Answers:

• [target]

• [blank]

• [target=_blank]

• [target_blank]

473. Which selector specifies that a list uses squares?

Answers:

• list-style: square;

• list-type-style: square;

• type: square;

• type: 4 corners;

• list-style-type: square;

474. What is the effect of the following css rule? [title]{color:blue;}

Answers:

• The titlebar of the browser will be blue

• Nothing

• All elements with a title attribute will be blue

• All elements other than a title attribute will be blue

475. The elements after the floating element will...

Answers:

• be deleted

• move a way from it

• flow around it

• not be affected

• clear

476. What is the purpose of line-height?

Answers:

• Set the height of the html hr tag.

• Set the height for each line of text in an html element.

• To vertical align text in an html element.

• All of these.

477. Which property is used to set all the outline properties in one declaration?

Answers:

• outline-all

• outline-total

• outline

• all of these

478. Which of the following tells the browser where you want to apply the rule?

Answers:

• Body

• Selector

• Main

• Value

• Property

479. The box model consists of which of the following:

Answers:

• margins,borders, padding, and the actual content

• display, visibility, position, and z-index

• width, height, border, and length

• div and table

• HTML, CSS, and Javascript

480. Which of the following is true for the max-width property?

Answers:

• The max-width sets the width of the table border to another border.

• Set the maximum width of a paragraph with the following: p { max-width:full; }

• The max-width property does not include padding, borders, or margins.

481. how to set multiple images in background through css

Answers:

• background:image= url(a2z.png), url(xyz.png);

• background-image= url(xyz.png) > url(a2z.png);

• background-image: url(xyz.png); background-image:url(a2z.png);

• background-image: url(xyz.png), url(a2z.png);

• background-image: url(xyz.png) url(a2z.png);

482. Which element is a block element?

Answers:

• <ul>

• <p>

• <h1>

• <div>

• All

483. Why will the following declaration not work? p {    margin-right: 80 px;  }

Answers:

• the P does not have a #

• a right margin can only be 50 pixels or less

• It should be right-margin

• there is a space between 80 and px

484. Which of the following specifies what the style actually does?

Answers:

• Class

• Selector

• Properties

• Id

485. What is the direction property in CSS?

Answers:

• It specifies the text direction/writing direction.

• It specifies the orientation an ordered list.

• It specifies the orientation of the webpage.

• It specifies the orientation an image.

486. What hyperlink property specifies whether new destination links should open in a new window or in a new tab of an existing window?

Answers:

• target-new

• target-open-window

• tafget-open-new

• target-fresh

487. The following is an example of which type of CSS selector?  E > F

Answers:

• Child selector

• Sibling selector

• Adjacent selector

• Parent selector

488. When determining hex colors, which value is the greatest?

Answers:

• e

• 9

• 0

• f

489. What is the CSS shorthand to set a borders top to 10, bottom to 5, left to 20 and right to 1 pixel?

Answers:

• border: 10px 20px 5px 1px;

• border: 5px 20px 10px 1px;

• border: 10px 5px 20px 1px;

• border: 10px 1px 5px 20px;

490. What is the transform: translate() method used for?

Answers:

• the text is translated to the language given as parameter in the method

• to translate the text into English

• To use non-euclidean geometry

• to move elements from their current position by an offset depending on the X and Y parameters

491. In the following line;     H1 { color:blue } What is the part within the curly braces?

Answers:

• Value

• Selector

• Property

• Declaration

492. Which one is not a correct value of  clear property?

Answers:

• clear:none;

• clear:both;

• clear:inherit;

• clear:left;

• clear:all;

493. What is absolute positioning?

Answers:

• When an element is positioned relative to the browser window.

• When an element is positioned in a natural location in a page's flow.

• When an element is positioned relative to the first parent element that has a position other than static.

• When an element is positioned using only z-index positioning.

494. What is the default value of position: ?

Answers:

• absolute

• relative

• static

• fixed

• inherit

495. Which property allows you to increase or decrease the white space between words?

Answers:

• word-spacing

• word-margin

• text-spacing

• letter-spacing

496. Which of the following is correct for specifying the print media type?

Answers:

• @media-print { p.test {font-family:times,serif;font-size:10px;} }

• @media-screen: print { p.test {font-family:times,serif;font-size:10px;} }

• @media-type: print { p.test {font-family:times,serif;font-size:10px;} }

• @media print { p.test {font-family:times,serif;font-size:10px;} }

497. What is the default align for <tfoot>?

Answers:

• none

• justify

• right

• left

498. Which of these is not a valid generic font-family?

Answers:

• handwriting

• sans-serif

• monospace

• serif

• fantasy

499. Which tags are used to fill the semantic need for text to be marked as more important or stressed?

Answers:

• <em>, <b>

• <strong>, <important>

• <strong>, <b>

• <em>, <strong>

• <i>, <strong>

500. Which of the following properties can be used to create multiple columns for laying out text - like in newspapers?

Answers:

• column-rule

• all of these

• column-count

• column-gap

501. What is the effect of using a negative number in a padding declaration?  Example: p {padding-top: -10px;}

Answers:

• Same as padding-top: 0px;

• Same as margin-top: -10px;

• Same as position: absolute; top: -10px;

• same as padding-top: 10px;

502. What is the cascading order (from lowest to highest priority) when there are multiple styles specified for an HTML element?

Answers:

• 1) inline style (inside an HTML element), 2) internal style sheet (in the head section), 3) external style sheet, 4) browser default

• 1) browser default, 2) inline style (inside an HTML element), 3) internal style sheet (in the head section), 4) external style sheet

• 1) internal style sheet (in the head section), 2) inline style (inside an HTML element), 3) browser default, 4) external style sheet

• 1) browser default, 2) external style sheet, 3) internal style sheet (in the head section), 4) inline style (inside an HTML element)

• 1) external style sheet, 2) internal style sheet (in the head section), 3) inline style (inside an HTML element), 4) browser default

503. When styling links, a:active must come _____ a:hover.

Answers:

• after

• before

504. Which of the following is correct for the word-wrap Property?

Answers:

• p.test {word-wrap:break-text;}

• p.test {word-wrap:break;}

• p.test {word:wrap-text;}

• p.test {word-wrap:wrap;}

• p.test {word-wrap:break-word;}

505. Which vertical-align value is not correct?

Answers:

• vertical-align: sub

• vertical-align: bottom

• vertical-align: text-base

• vertical-align: super

506. What is the adjacent sibling selector?

Answers:

• >

• :

• +

• -

• *

507. Which value of display property is NOT valid?

Answers:

• display: table-row;

• display: table-row-group;

• display: inline-table;

• display: list-item;

• display: inline-caption;

508. To style a link that ends in .html differently than a link that ends with another file extension you would use which code?

Answers:

• a[href*='.html']{color: purple;}

• a[href^='.html']{color: purple;}

• a[href&='.html']{color: purple;}

• a[href$='.html']{color: purple;}

509. How can you keep the parent element from collapsing when all elements inside are being floated?

Answers:

• Using a clear fix

• Using overflow: hidden;

• Specify a height

• All of these

510. What is the specificity calculation for an ID in CSS?

Answers:

• 100

• 050

• 001

• 010

• 101

511. How do you select all the first <p> elements that immediately follow a <h2> element?

Answers:

• h2 p { }

• h2 > p { }

• h2 + p { }

• h2 ~ p { }

512. If the link to the external css is placed after the embedded css in the <head>...

Answers:

• the embedded css will override the external styles.

• the external styles will override the embedded styles.

513. Which of the following declarations is incorrect?

Answers:

• table { border-collapse: separate; }

• table { direction: rtl; }

• table { table-layout: fixed; }

• table { display: table-column-grouped; }

• table { empty-cells: hide; }

514. With regards to the cascade effect of CSS, when does the order of css style rules matter most?

Answers:

• The order only matters when using external style sheets.

• The order does not matter.

• When the rules are equal in specificity.

• The order always matters.

515. Which of the following is true about this style?  border-width: thin medium thick 3px;

Answers:

• The bottom border is medium thickness.

• All borders are thin.

• Thick borders have a thickness of 3px.

• The left border will have a thickness of 3px.

516. What does the CSS speak-header property do?

Answers:

• Specifies whether the tables contents should be spoken or not

• Specifies a sound to be played before speaking a tables content

• Specifies whether table headers are spoken before every cell

• Specifies whether the tables caption should be spoken or not

• Specifies whether content will render aurally

517. What is the total width for this div : div { width: 100px; margin: 5px; padding: 10px 5px 15px 5px; border: 5px solid #000; }

Answers:

• 130px

• 110px

• 120px

518. Which of the following is NOT valid.

Answers:

• visibility: collapse

• visibility: hidden

• visibility: inherit

• visibility: none

• visibility: visible

519. Which of the following text-decoration styles is not correct?

Answers:

• text-decoration: overline

• text-decoration: inherit

• text-decoration: underline

• text-decoration: strike-through

520. What does the CSS cue property do?

Answers:

• Specifies a sound to be played as a background while an element's content is spoken

• Specifies the frequency of the speaking voice

• Prompts the user to enter a voice command

• Specifies a sound to be played before and after the selected element

521. Which of the following is a required box-shadow property?

Answers:

• color

• spread

• h-shadow

• blur

• inset

522. What is the recommended order for styling an <a> tag?

Answers:

• a:active { } , a:visited { } , a:hover { } , a:link { }

• a:link { } , a:visited { } , a:hover { } , a:active { }

• a:link { } , a:hover { } , a:active { } , a:visited { }

• a:link { } , a:active { } , a:hover { } , a:visited { }

• a:active { } , a:link { } , a:hover { } , a:visited { }

523. The css property border-style:dotted solid; would have the following effect:

Answers:

• Specifies all four borders are dotted

• Is not correct

• Would specify different borders for different sides

• Specifies a double border

524. What page media property gives a hint for how to scale a replaced element if neither its width nor its height property is auto?

Answers:

• main

• size

• scale

• fit

525. Which of the following declarations is incorrect?

Answers:

• ul { list-style-type: circle; }

• ul { list-style-type: hiragana; }

• ul { list-style-type: decimal-leading-zero; }

• ul { list-style-type: lower-alpha; }

• ul { list-style-type: roman; }

526. Which of the following is not a pseudo class?

Answers:

• link

• lang

• first

• active

527. When can a semicolon be omitted?

Answers:

• When there is only one statement in a rule

• All of the above.

• Last statement in a group

• Inline style setting in an HTML tag

528. Which of the following specifies the number of times an animation should be played?

Answers:

• iteration-count

• iteration

• animation-iteration-count

• animation-count

529. position: absolute means...

Answers:

• That the element is positioned accordingly to the closest ancestor with a position.

• That the element is positioned accordingly to the closest ancestor with a relative position.

• That the element is positioned accordingly to the browser window.

• That the element is positioned accordingly to the closest ancestor with an absolute position.

530. Specifies a rotation in the right or clockwise direction that a user agent applies to an image

Answers:

• image-rotation

• image-transform

• image-orientation

• image-move

531. What CSS value scales the background image to the largest size contained within the element?

Answers:

• fill

• repeat

• contain

• cover