HTML Flashcards
Where do you put non-visible content about the HTML document?
In head element
Where do you put visible content about the HTML document?
In body element
Give five examples of HTML element types.
head element, p element, img element, a element, h1
What is the purpose of HTML attributes?
To provide additional information about the contents of an element.
Give an example of an HTML entity (escape character).
© Copyright symbol, ® Registered trademark, “ Quotation mark
How do block-level elements affect the document flow?
It always appear to start on a new line in the browser window.
h1, p, ul, li
How do inline elements affect the document flow?
It will always appear to continue on the same line as their neighbouring elements.
Examples of inline elements are a, b, em, img.
What are the default width and height of a block-level element?
The default width of a block-level element is the length of the page.
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
What is the difference between an ordered list and an unordered list in HTML?
Ordered lists are lists where each item in the list is numbered.
Unordered lists are lists that begin with a bullet point.
Is an HTML list a block element or an inline element?
List (Ordered, Unordered, Description and List Item) tags ol , ul , dl is a a block element.
What HTML tag is used to link to another website?
Links are created using the a element which has an attribute called href.
What is an absolute URL?
It’s a link to a different website.
What is a relative URL?
Link to other pages within the same site, no need to specify the domain name in the URL
How do you indicate the relative link to a parent directory?
Use ../ to indicate the folder above the current one, then follow it with the file name.
How do you indicate the relative link to a CHILD directory?
For a child folder, use the name of the child folder, followed by a forward slash, then the file name.
How do you indicate the relative link to a grand parent directory?
Repeat the ../ to indicate that you want to go up two folders (rather than one), then follow it with the file name. <a>Home</a>
How do you indicate the relative link to the same directory?
To link to a file in the same folder, just use the file name. (Nothing else is needed.) <a>Reviews</a>
What is the purpose of an HTML form element?
HTML forms give you a set of elements to collect data from your users
Give five examples of form control elements.
input, textarea, select, submIt button, radio button
Give three examples of type attribute values for HTML elements.
search, submit, text, button
Is an HTML input element a block element or an inline element?
input is “inline” element
What are the six primary HTML elements for creating tables?
A set of ‘table’ and ‘/table’
‘tbody’ The body should sit inside the ‘tbody’ element.
Table headers
A set of ‘th’ and ‘/th’ opening and closing tags respectively are required to create table headers.
Table Rows
A set of ‘tr’ and ‘/tr’ opening and closing tags respectively are required to create a row.
Table Columns
A set of ‘td’ and ‘/td’ opening and closing tags respectively are required to create a column.
What purpose do the thead and tbody elements serve?
The thead tag is used to group header content in an HTML table. The thead element is used in conjunction with the tbody and tfoot elements to specify each part of a table (header, body, footer).
*thead element must have one or more tags inside.
tbody is used to group the body content in an HTML table.
The tbody tag must be used in the following context: As a child of a element, after any caption, colgroup, and thead elements.