HTML Flashcards
What is the difference between an ordered list and an unordered list in HTML?
An ordered list uses numbers while an unordered list uses bullet points
Is an HTML list a block element or an inline element?
Block element
Where do you put non-visible content about the HTML document?
In the head and title element
Where do you put visible content about the HTML document?
In the body element
Where do the <head> and <body> tags go in a valid HTML document?
Within the html element
What is the purpose of a <!DOCTYPE> declaration?
To let the browser know which type of HTML it should be reading
What is the purpose of HTML attributes?
They help give more information about the contents of an element
How do block-level elements affect the document flow?
They take up the entire horizontal space of it’s parent element and the vertical space equal to the height of it’s content
They start on a new line as well
How do inline elements affect the document flow?
They don’t start on a new line and only take up the space bounded by the tags of the defining element
What are the default width and height of a block-level element?
Default width is it taking up the full width available (100%) and default height is based upon the amount of content within the block. (auto)
What are the default width and height of an inline element?
Only takes up the necessary amount of width and height is auto.
What HTML tag is used to link to another website?
The anchor tag <a> href=” “</a>
What is an absolute URL?
When you want to visit a specific page, you link a URL that contains the domains name within it.
What is a relative URL?
When you include a link to another page on the same site.
Linking to a file located in your own files.
How do you indicate the relative link to a parent directory?
../