NDSU Comm 260 Midterm Exam
Study Guide
In the code that follows margin: 0 auto; the auto keyword means - Answer to center the
element horizontally within the containing block
The code that follows "border-style: solid none;" means that the box should have -
Answer solid top and bottom borders
The code that follows "padding: .5em 0 .25em;" applies this padding to an element: -
Answer .5em above, 0 left and right, and .25em below
To calculate the height of a box when using the box model, you add the height of the
content area to the sum of the heights of the - Answer top and bottom borders, and top
and bottom padding
When you set a border for a block element, you can set the color, style, and
_____________________________. - Answer width
In the box model, the border comes between the margin and the _____________________
for box. - Answer padding
If you set the background color for the body of a page to blue and you don't set the
background color for a section within the body, the background of the section will be
_____________________________. - Answer blue
If the bottom margin for one element is 1.5 em and the top margin for the element below
it is 1 em, how large is the margin between the two elements when the page is rendered
in a browser? ________________________________ - Answer 1.5 em
By default, the box for a block element is as wide as the _________________ that it's in. -
Answer container
By default, if you specify a background image for a block element, it will be
_____________________________ both horizontally and vertically so it fills the block
element. - Answer repeated
As a best practice, you should only use the height and width attributes of an img element
to specifiy - Answer the actual size of the image
Although the img element is an inline element, you can use CSS to
_______________________ an img element so the HTML elements that come after it will flow
into the space along side of it. - Answer float
The most common type of image format for photographs in web pages is the
_____________________ format. - Answer jpg
, To help the visually impaired, you should always provide an adequate description of the
image in the _______________________ attribute for the image. - Answer alt
Which of the following units of measurement is equal to the font size for the current font?
- Answer an em
Pseudo-class selectors let you apply formatting - Answer when specific conditions
occur
For user accessibility, you should apply the same formatting to the :focus pseudo-class
for an element as you apply to the ____________________ pseudo-class for that element. -
Answer :hover
Which of the following selectors applies to all <a> elements with "hot" as their class
name that are coded within a div element that has "header" as its id? - Answer #header
a.hot
Which of the following is NOT one of the ways that you can specify a color in CSS? -
Answer color: getColor("red");
Underlining and overlining are a type of text formatting that is referred to as text
____________________________. - Answer decoration
When you use an external style sheet with an HTML document, you get all but one of the
benefits that follow. Which one is it? - Answer Your CSS files are easy to create and
maintain
To provide the top-level formatting for a page, a style sheet commonly formats - Answer
body and HTML5 semantic elements
To include a CSS file in an HTML document, you use the _______________________
element. - Answer link
Times New Roman is a font ____________________________. - Answer family
To include styles in an HTML document, you can use an external style sheet, an
embedded style sheet or ____________________________ attributes on inline HTML
elements. - Answer style
Which of the following is a valid selector for a class named menu? - Answer menu
You can use ems or percentages to specify a _______________________ unit of
measurement. - Answer relative
In the rule set that follows, the selector applies to all elements that have "red" as their
____________________________ name. .red { color: red; } - Answer class
Which of the following selectors is most specific? - Answer #nav
If two CSS rules conflict, which of the following rules overrides the other rule? - Answer
The benefits of buying summaries with Stuvia:
Guaranteed quality through customer reviews
Stuvia customers have reviewed more than 700,000 summaries. This how you know that you are buying the best documents.
Quick and easy check-out
You can quickly pay through credit card or Stuvia-credit for the summaries. There is no membership needed.
Focus on what matters
Your fellow students write the study notes themselves, which is why the documents are always reliable and up-to-date. This ensures you quickly get to the core!
Frequently asked questions
What do I get when I buy this document?
You get a PDF, available immediately after your purchase. The purchased document is accessible anytime, anywhere and indefinitely through your profile.
Satisfaction guarantee: how does it work?
Our satisfaction guarantee ensures that you always find a study document that suits you well. You fill out a form, and our customer service team takes care of the rest.
Who am I buying these notes from?
Stuvia is a marketplace, so you are not buying this document from us, but from seller Flat. Stuvia facilitates payment to the seller.
Will I be stuck with a subscription?
No, you only buy these notes for $8.99. You're not tied to anything after your purchase.