1/28
Name | Mastery | Learn | Test | Matching | Spaced |
|---|
No study sessions yet.
Which of the following is a correct syntax for using an HTML attribute?
What HTML tags that will preserve all spaces and linebreaks when the element is displayed.
<pre> </pre> called preformatted
CSS to remove the underline from the link
style="text-decoration:none”
Add a line through (strikeout) the letters "blue" in the text
<del> blue </blue>
Highlight the word "FUN" in the text
<mark>FUN</mark>
how to add a horizontal rule? explain why
<hr>
is a void element in HTML — meaning it does not need a closing tag.
</hr> You should not write (that’s invalid in modern HTML).
Add a link to a bookmark, on the same page, with the id="mytext".
<a href ="#mytext ">Jump to new text</a>
The letters "WHO" in the text below is an abbreviation of "World Health Organization". Use an HTML element to provide the specified abbreviation of "WHO".
<p>
The < abbr title= "World Health Organization">
WHO</abbr> was founded in 1948.
</p>
Specify an alternate text for the image.
Alternate text is useful when the image cannot be displayed, like when the page is read by a screen reader.
<img src=”w3schools.png" alt="w3schools Logo">
Insert the HSLA value to make a color with no hue, 100% saturation, 50%
lightness, and 50% transparency.
<p style="color:hsla(0,100%,50%,0.5 )">This is a paragraph.</p>
HSL color values will result in a black color?
hsl(0, 100% ,0)
What is a correct syntax for linking to a bookmark named C4 on another page?
<a href= 'demo. html#C4' >Jump to Chapter 4</a>
What is a correct syntax for linking to an external stylesheet?
<link rel="stylesheet" href="styles.css">
Why it's correct:
is the correct tag for linking external resources like stylesheets.
rel="stylesheet" tells the browser the relationship is a stylesheet.
href="styles.css" specifies the path to the CSS file.
One of these elements is NOT a legal HTML element, which one?
image ❌ (invalid, correct answer)
picture ✅ valid (used for responsive images)
source ✅ valid (used inside , , )
Two of the following HTML elements makes the text bold, which two?
<strong> semantic emphasis, bold by default
<b> stylistic bold
<em> italic emphasis, not bold
<big> enlarges text, not bold
<mark> highlights text, not bold
Correct: <strong> and <b>
What is a correct way to add a background color to an HTML document?
<body style='background-color:pink; '> ✅ correct inline CSS
To add a background image on an entrire HTML page, on which element
should you specify the background image?
<body> ✅ correct element to style
Which type of elements takes up the full width available?
Block elements ☑ (e.g., <div> ,<p>, <h1>)
Inline elements X (e.g., <span>, <a>)
What is a correct HTML markup for the document type declaration?
< ! DOCTYPE html>
Which one of the following will result in a grey color?
#A0A0A0 ✅ grey shade
#FF00FF ❌ magenta
#00FF00 ❌ bright green
Which of the following headers is the largest and most important header?
<h1>
What HTML attribute is used to create a bookmark?
id ✅ correct (you can link to it with #id)
Which of the following is NOT a quotation element (in fact, not an HTML element at all)?
- <q> ✅ inline quote element
- <blockquote> ✅ block-level quote element
- <quote> ❌ not a valid HTML element
What does HTML stand for?
Hyper Text Markup Language
Who invented HTML?
Tim Berners-Lee
Examples of empty elements
Some HTML elements have no content (like the <br> element). These elements are called empty elements. Empty elements do not have an end tag!
What do you call <h1> and </h1> as tags?
start tags and end tags
are html tags case sensitive?
HTML tags are not case sensitive: <P> means the same as <p>.
The HTML standard does not require lowercase tags, but W3C recommends lowercase in HTML, and demands lowercase for stricter document types like XHTML.
Defines the root of an HTML document
<html>