Chapter 2: CSS
- HTML elements enable Web page designers to mark up a document as to its structure.
- Two ways to create CSSs: Use a normal text editor and write the style sheets by hand or you can use a dedicated tool.
- A rule is a statement about one stylistic aspect of one or more elements.
- A style sheet is a set of one or more rules that apply to an HTML document.
- A rule consists of two parts: Selector - the part before the left curly brace. Declaration - the part within the curly braces.
- Declaration has two parts separated by a colon: Property - the part before the colon. Value - the part after the colon.
- Brevity was a goal in designing CSS.
- All declarations must be contained within the pair of curly braces.
- The style sheet and the HTML document must be combined so that they can work together to present the document.
- You can glue the style sheet and the HTML document together by putting the style sheet inside a style element at the top of your document.
- The style element is placed after the title element and before the body element.
- For CSS to work, you must use a browser that supports CSS.
CSS Tutorial - Starting with HTML & CSS
- For your first style sheet use a program like TextEdit.
- Don't use a wordprocessor - typically makes files that a Web browser cannot read.
- "Simple files is good, since it makes it easier to use the same style sheet for multiple HTML files: you only have to write the style sheet once."
- List at the top of the HTML page is meant to become a navigation menu.
No comments:
Post a Comment