HTML Flashcards
Where do you put non-visible content about the HTML document?
Inside the title tags
Where do you put visible content about the HTML document?
Inside the body tags
Where do the and tags go in a valid HTML document?
Inside the HTML tag
What is the purpose of a declaration?
to inform a website visitor’s browser that the document being rendered is an HTML document
Give five examples of HTML element tags.
anchor tag: <a> image tag: <img> body tag: title tag: h1 tag: <h1></h1></a>
What is the purpose of HTML attributes?
Modify/enhance tags
Give an example of an HTML entity (escape character).
< : <
How do block-level elements affect the document flow?
A block-level element always starts on a new line and takes up the full width available (stretches out to the left and right as far as it can).
How do inline elements affect the document flow?
An inline element does not start on a new line and only takes up as much width as necessary.
What is the difference between an ordered list and an unordered list in HTML?
Ordered: has numbers
Unordered: no numbers
Is an HTML list a block element or an inline element?
Block element
What HTML tag is used to link to another website?
Anchor tags: <a></a>
What is an absolute URL?
A URL to a different page, the exact URL address
What is a relative URL?
A URL on the same site, usually just redirects to the folder directory
How do you indicate the relative link to a parent directory?
../parentName.html
How do you indicate the relative link to a child directory?
Just the name of the folder then / then file name
How do you indicate the relative link to a grand parent directory?
../../grandParentName.html
How do you indicate the relative link to the same directory?
just the file name
What is the purpose of an HTML form element?
Allows your HTML document to collect user input (and then send that info over to a server)
Give five examples of form control elements.
Radio button Text box Checkbox Select (with options) Button
Give three examples of type attributes for HTML elements.
Submit
Radio
Text
Checkbox
Is an HTML element a block element or an inline element?
Inline
What are the six primary HTML elements for creating tables?
Table Td Tr Td Thead tbody
What purpose do the thead and tbody elements serve?
Thead: heading data
Tbody: all the main content
Give two examples of data that would lend itself well to being displayed in a table.
Student grades
Population data
What are the default width and height of a block-level element?
Width is the width of the document (width is 100% of the parent container by default)
Height is how much height it needs
What are the default width and height of an inline element?
The width and height will be whatever the width and height of the content the inline element contains.
Why would a tag need to be placed at the bottom of the HTML content instead of at the top?
So that all of the html code will be loaded in the document before you can query it with dom
If you put it first, the dom will query nothing.
Which HTML meta tag is used in mobile-responsive web pages?
Viewport meta tag