HTML Flashcards
Where do you put non-visible content about the HTML document?
head element
Where do you put visible content about the HTML document?
body element
Where do the head and body tags go in a valid HTML document?
in the html element
What is the purpose of a !DOCTYPE declaration?
tells the browser which version of HTML the page is using
Give five examples of HTML element tags.
p, div, head, body, li
What is the purpose of HTML attributes?
provide more info about the content of the element
Give an example of an HTML entity (escape character).
copyright symbol = © & copy ;
How do block-level elements affect the document flow?
they start on a new line in the browser window
How do inline elements affect the document flow?
they don’t start a new line, they only take up as much space as the content does
What are the default width and height of a block-level element?
width: 100%, height: auto
What are the default width and height of an inline element?
width: auto, height: auto
What is the difference between an ordered list and an unordered list in HTML?
ordered lists have numbered items while unordered lists have bulleted items
Is an HTML list a block element or an inline element?
li is a block element, starts on a new line by default
What HTML tag is used to link to another website?
anchor tag
What is an absolute URL?
full web address, including domain name
What is a relative URL?
shorthand, navigation within same domain
How do you indicate the relative link to a parent directory?
../file-name
How do you indicate the relative link to a child directory?
child-directory/file-name
How do you indicate the relative link to a grand parent directory?
../../file-name
How do you indicate the relative link to the same directory?
file-name
What is the purpose of an HTML form element?
element that encloses all form controls, which receive info from visitors of a webpage
Give five examples of form control elements.
input, option, select, button, textarea
Give three examples of type attributes for HTML input elements.
radio, checkbox, text
Is an HTML input element a block element or an inline element?
inline
What are the six primary HTML elements for creating tables?
table, thead, tbody, tr, th, td
What purpose do the thead and tbody elements serve?
they define where the head and body of the table is
Give two examples of data that would lend itself well to being displayed in a table.
payroll and train timetable