These are my reading notes for Code Fellows
Two types of lists: ordered and unordered
<ol>
for Ordered Lists – these will appear like so:
<ul>
for Unordered Lists – these will appear like so:IMPORTANT NOTE: before the lists will actually look like that, you have to add <li>
or list items (in the examples above, the list items would be “item 1” etc.)
Another important note: to create the nested look, you have to put another <ol>
or <ul>
element inside an <li>
element
<dl>
for Definition Lists
<dt>
for what is being defined<dd>
for the definition itselfBoxes from our last reading notes are set just big enough to contain their contents unless you specify otherwise
max-width
or min-width
to do exactly what it sounds like! Useful if you just don’t want an image or text box to exceed a certain size, but otherwise vary in size
min-height
and max-height
do the same but with heightoverflow: hidden;
means the extra text is just hiddenoverflow: scroll;
will create a scrollbarimage credit: stackoverflow.com
Increasing margin and padding increases the space between text/images and other text/images
Borders literally draw boxes around text/images and can be changed to look a number of different ways
text-align:
to change justification of the text and its corresponding boxOften used for a site’s nav bar
inline
= lines up list items (<li>
) one next to anotherblock
= makes the <li>
act like a blockinline-block
= has features of both
Border images allow you to use custom images for your border, instead of the standard ones included in CSS
Border radius allows you to round the corners on a box
border-bottom-right-radius: 10px 20px;
===
instead of ==
because of weird quirks with JavaScript (sometimes it considers a string to be a number in an effort to be more user friendly)
===
false
)true
)A code block will run repeatedly (in a loop) until it returns the condition of false
.
for
runs a code a certain number of times
while
code will continue to run as long as a condition is true
do...while
like while
, with some caveats
i++
or i--
adds or subtracts one, respectively)