🟣| Web Design - Implementation Flashcards
Positioning:
Float
Definition
Floating elements to the left or right
Positioning:
Display
3
Definition
- Block: element is displayed as a block, generating line breaks before and after.
- Inline: element will be displayed on the same line as the preceding element (if there is space).
- None: element is not displayed.
Positioning:
Clear
3
Definition
- Left: no floating elements on the left of the specified element.
- Right: no floating elements on the right of the specified element.
- Both: no floating elements on the left or right of the specified element.
Positioning:
Margins
Definition
Sets a margin around a block to separate it from other elements.
Positioning:
Padding
Definition
Sets padding within a block to move the contents away from the edge.
Positioning:
Height & Width
Definition
Sets the height and width of an element
Display:
Removing Bulletpoints
Code
list-style-type:none
Display:
Hover
Definition
Triggered when the mouse hovers over an element
Form:
Text
Code
< input type=”text” name=”firstname”>
Form:
Number
Code
< input type=”number” name=”rating”>
Form:
Textarea
Code
< textarea name=”message” rows=”6” cols=”80”> < /textarea >
Form:
Radio
Code
< input type=”radio” name=”traffic-light” value=”red” checked>Red< br>
< input type=”radio” name=”traffic-light” value=”amber”>Amber< br>
< input type=”radio” name=”traffic-light” value=”green”>Green< br>
Form:
Select
Code
< select name=”bigcats”>
< option value=”lion”>Lion</option>
< option value="tiger">Tiger</option > < option value="panther">Panther</option > < option value="puma">Puma</option >
< /select >
Form:
Submit
Code
< input type=”submit” value=”Submit”>
Form:
Length Validation
Code
< input type=”text” maxlength=”15” minLength=”1”>
Form:
Range Validation
Code
< input type=”number” min=”0” max=”10”>
Form:
Presence Check
Code
< input type=”text” required>
How is a horizontal navigation bar created?
Definition / Code
- Remove bullet points (nav ul)
- Float left (nav ul li)
- Display block and padding (nav ul li a)
- Change appearance when mouse hovers (nav ul li a:hover)