HTML Flashcards
HTML-SKELETON
Where do you put non-visible content about the HTML document?
Within the Head Element
HTML-SKELETON
Where do you put visible content about the HTML document?
Within the Body Element
HTML-SKELETON
Where do the < head > and < body > tags go in a valid HTML document?
Within the HTML Element
HTML-SKELETON
What is the purpose of a !DOCTYPE declaration?
Declaration that tells the browser what version of HTML the document is written in
HTML-SYNTAX
Give five examples of HTML element types.
head element, body element, h1 element, p (paragraph) element, div element, etc.
HTML-SYNTAX
What is the purpose of HTML attributes?
Attributes indicates what kind of extra information you are supplying about the element’s content/define additional characteristics or properties of the element
HTML-SYNTAX
Give an example of an HTML entity (escape character).
“& + copy” is copyright symbol;
& is ampersand symbol
HTML-BLOCK-AND-INLINE
How do block-level elements affect the document flow?
Block-level elements takes all the space horizontally (width) and as much space as it needs vertically.
HTML-BLOCK-AND-INLINE
How do inline elements affect the document flow?
Inline elements uses the space within the block. Does not start a new line.
HTML-BLOCK-AND-INLINE
What are the default width and height of a block-level element?
width: 100%;
height: auto;
HTML-BLOCK-AND-INLINE
What are the default width and height of an inline element?
width: auto;
height: auto;
HTML-LISTS
What is the difference between an ordered list and an unordered list in HTML?
ordered list = numbered list, etc.
unordered list = bullet points, etc.
HTML-LISTS
Is an HTML list a block element or an inline element?
An HTML list is a block element
HTML-LINKS
What HTML tag is used to link to another website?
a tag (anchor) with href=”…link”>click here
HTML-LINKS
What is an absolute URL?
An absolute URL is a link that is a website link
HTML-LINKS
What is a relative URL?
A link that is in internal (the same website);
example: /file.html
HTML-Relative-Links
How do you indicate the relative link to a parent directory?
../foldername(if any)/filename
HTML-RELATIVE-LINKS
How do you indicate the relative link to a child directory?
foldername(if any)/filename
HTML-RELATIVE-LINKS
How do you indicate the relative link to a grand parent directory?
../../foldername(if any)/filename
HTML-RELATIVE-LINKS
How do you indicate the relative link to the same directory?
filename
HTML-FORMS
What is the purpose of an HTML form element?
HTML form element represents a document section containing interactive controls for submitting information.
HTML-FORMS
Give five examples of form control elements.
select, option, input, button, textarea, etc
HTML-FORMS
Give three examples of type attribute values for HTML elements.
radio, checkbox, value, etc
HTML-FORMS
Is an HTML element a block element or an inline element?
inline element
Others: What is the difference between div and span?
div = default for block element; span = default for inline element;
HTML-FORMS Others:
What is the purpose of “name” attribute in radio inputs?
The “name” attribute makes sure you can only choose one option
HTML-TABLES
What are the six primary HTML elements for creating tables?
table, thead, tbody, th, tr, td
HTML-TABLES
What purpose do the thead and tbody elements serve?
thead = for header column; tbody = for content itself;
HTML-TABLES
Give two examples of data that would lend itself well to being displayed in a table.
city and populations;
students and grades;