HTML & CSS- part 7 Flashcards
What’s the non-standard way to indent an unordered list?
Indent only the first line of text and make all other lines flush with the bullet:
ul {list-style-position: inside;}
In list, what are the markers?
Markers are the bullets in an unordered list or the numbers in an ordered list.
What options do you have for changing the markers in an UNordered list?
What’s the code?
ul {list-style-type: x;}
disc (solid and round)
circle (this is just the outline of a circle)
square
What options do you have for changing the markers in an ordered list?
What’s the code?
Six pairs:
ol {list-style-type: x;}
decimal—1, 2, 3 etc.
decimal-leading-zero—01, 02, 03
lower-alpha—a, b, c
upper-alpha—A, B, C
lower-roman—i., ii., iii
upper-roman—I, II, III
Can you use a picture as a list item marker?
What’s the code?
Yes, though it’s not advised.
ul {list-style-image: url(“image address”);}
In CSS, what’s the text that goes in front of { called?
A CSS selector is everything on the first line that precedes the {.
It’s the part of a style rule that tells the browser what elements, classes, and IDs a rule applies to
What does this mean? div > p { ?
It selects all <p> that are the child of a <div>
In CSS, what is the Universal Selector that selects all the elements on a page?
* {
In CSS, what is a combinator?
A symbol or space…
used in the selector area…
to specify the relationship of the selectors to each other
What are the four combinators?
(space)
>
+
~
What does this combinator mean?
div p {
What’s it called?
It selects all <p> elements inside <div> elements.
It’s called the Descendant Selector
What does this combinator mean?
div > p {
What’s it called?
It selects all <p> elements that are children of a <div> element.
It’s called the Child Selector
What does this combinator mean?
div + p {
What’s it called?
It selects the first <p> element that are placed immediately after <div> elements.
It’s called the Adjacent Sibling Selector
What does this combinator mean?
div ~ p {
What’s it called?
It selects all <p> elements that are next siblings of <div> elements.
It’s called the General Sibling Selector
What’s a good way to think of a table?
Tables are really just rows stacked on top of each other.
You build a table a row at a time, from the top.