A page's content and structure are already correct, but its headings need a different color. Which technology should be used to make that change?
1 How the Web and Browsers Work Online Quiz Questions
Use this free practice quiz with 20 questions to review 1 How the Web and Browsers Work, test your knowledge, and prepare for your next test or exam.
True or false: The browser parses HTML into a tree of objects representing the document's elements and text.
- A
True
- B
False
A page uses a regular script without async or defer. What can happen when the browser reaches the script while parsing HTML?
- A
HTML parsing can pause while the script is fetched and executed.
- B
The browser skips parsing the HTML that follows the script.
- C
The script can only change CSS, not the DOM.
- D
The browser must finish painting the page before it runs the script.
True or false: A browser must finish downloading every referenced resource before it can display any part of a page.
- A
True
- B
False
A button click should replace the text in a heading without reloading the page. Which technology is responsible for implementing that behavior?
- A
HTML
- B
CSS
- C
JavaScript
- D
CSSOM
What is the name of the tree of objects that a browser builds by parsing HTML? Enter its three-letter acronym.
Complete the division of roles: describes a page's content and structure, while describes how its elements look and are arranged.
In the simplified rendering model, after building the render tree, the browser calculates visible elements' sizes and positions during , then displays the result as pixels during .
Select all statements supported by the browser rendering model.
- A
Changing the DOM with JavaScript can affect rendering.
- B
Once the browser paints a page, later changes cannot affect its layout.
- C
Resizing a window can make the browser recalculate layout or repaint parts of the page.
- D
A browser always repeats every rendering step from the beginning after any change.
In a basic HTML page, which element contains the page's visible content? Enter the element name without angle brackets.
Select all statements that can describe what happens as a browser loads a page.
- A
The browser can begin building the DOM before the entire HTML document has downloaded.
- B
The browser may request stylesheets, scripts, or images referenced by the page.
- C
The browser waits until every resource is loaded before it starts parsing HTML.
- D
A referenced image is incorporated into the DOM as a stylesheet.
After a browser has displayed a page, the user resizes the window. Explain why the browser may need to do more rendering work and name at least one kind of work that may be repeated or updated.
A page needs an element that identifies a control users can activate. Which HTML element most directly expresses that meaning?
- A
button
- B
span
- C
div
- D
footer
True or false: The browser's CSS Object Model (CSSOM) is the style information built from CSS, distinct from the DOM built from HTML.
- A
True
- B
False
A page’s content and interactions are already in place, but you need to change its typography and spacing. Which technology is responsible for those presentation changes?
- A
HTML
- B
CSS
- C
JavaScript
- D
The DOM
A page should change a heading’s text when a user clicks a button. Which technology would provide that behavior?
- A
HTML
- B
CSS
- C
JavaScript
- D
The CSS Object Model
When organizing a typical HTML page, where should metadata and resource references go, and where should the visible page content go?
- A
Put metadata and resource references in the head, and visible page content in the body.
- B
Put visible page content in the head, and metadata in the body.
- C
Put all page content and metadata in the body.
- D
Put metadata in the body and resource references outside the html element.
A developer wants to inspect a browser structure that represents both page elements and text, including which elements are nested inside others. Which structure should they inspect?
- A
A list of CSS rules with no representation of document content
- B
A tree of objects representing elements, text, and their relationships
- C
A pixel image of the finished page
- D
A record of the browser’s network requests
What is the name of the style-information model that the browser builds by parsing CSS?
In a typical HTML page, which element is the root of the document?