HTML Flashcards
(160 cards)
Where do you put non-visible content about the HTML document?
<head>
</head>
Where do you put visible content about the HTML document?
<body>
</body>
Where do the <head> and <body> tags go in a valid HTML document?
Inside <html> element
What is the purpose of a <!DOCTYPE> declaration?
Tell the browser what version of HTML you’re using.
Give five examples of HTML element types.
<title>
<head>
<body>
<p>
<img></img>
</p></body></head></title>
What is the purpose of HTML attributes?
Attributes provide additional information about the contents of an element.
Give an example of an HTML entity (escape character).
©
How do block-level elements affect the document flow?
always appear to start on a new line in the browser window.
How do inline elements affect the document flow?
always appear to continue on the same line as their neighbouring elements.
What are the default width and height of a block-level element?
Take up full width of the containing block - 100%. Height determined by content - 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?
<ol> lists where each item in the list is numbered.
<ul> lists that begin with a bullet point (rather than characters that indicate order).
</ul></ol>
Is an HTML list a block element or an inline element?
Block
What HTML tag is used to link to another website?
<a></a>
What is an absolute URL?
starts with
the domain name for that site, and can be followed by the path to a specific page. If no page is specified, the site will display the homepage.
What is a relative URL?
link to files within your own files.
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?
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.
How do you indicate the relative link to the same directory?
just use the file name. (Nothing else is needed.)
What is the purpose of an HTML form element?
refer to different elements that allow you to collect information from visitors to your site.
Is an HTML <input></input> element a block element or an inline element?
inline
What purpose do the thead and tbody elements serve?
to show the difference from the first row and the rest of the data in the table
What are the names of the individual pieces of a CSS rule?
declaration block
property
value
Selector