HTML Flashcards
Where do the and tags go in a valid HTML document?
The element is a container for metadata (data about data) and is placed between the tag and the tag.
The must be the second element after the tag or it should be placed between and tags.
What is the purpose of a declaration?
The DOCTYPE declaration is an instruction to the web browser about what version of HTML the page is written in. This ensures that the web page is parsed the same way by different web browsers. In HTML 4.01, the DOCTYPE declaration refers to a document type definition (DTD)
Give five examples of HTML element types.
, , <h1> , </h1><p>,<br></br>,</p>
What is the purpose of HTML attributes?
HTML attributes can be used to change the color, size, and other features of HTML elements.
Give an example of an HTML entity (escape character)
& & ® ® ™ ™ © © € €
How do block-level elements affect the document flow?
A Block-level element occupies the entire horizontal space of its parent element (container), and vertical space equal to the height of its contents, thereby creating a “block”. Browsers typically display the block-level element with a newline both before and after the element
How do inline elements affect the document flow?
By default, inline elements do not force a new line to begin in the document flow.
What are the default width and height of a block-level element?
All block level elements inherit the width of their parent element by default
What are the default width and height of an inline element?
The height of an inline element is the height of the content. The width of an inline element is the width of the content. The height and width of an inline element cannot be set in CSS. You cannot set the height and width of block-level elements in CSS
What is the difference between an ordered list and an unordered list in HTML?
Unordered list — Used to create a list of related items, in no particular order. Ordered list — Used to create a list of related items, in a specific order.
Is an HTML list a block element or an inline element?
Block Level Elements
A block-level element is an HTML element that begins a new line on a web page and extends the full width of the available horizontal space of its parent element. It creates large blocks of content like paragraphs or page divisions. In fact, most HTML elements are block-level elements
What HTML tag is used to link to another website?
The <a> tag defines a hyperlink, which is used to link from one page to another. The most important attribute of the </a><a> element is the href attribute, which indicates the link’s destination.</a>
What is an absolute URL?
An absolute URL contains all the information necessary to locate a resource.
What is a relative URL?
A relative URL locates a resource using an absolute URL as a starting point.
How do you indicate the relative link to a parent directory?
../review