Web Design
Style Multiple Elements................ 128 Format Text with Spans................. 130 Group Elements with Divs............... ...
128 2 Within the style sheet, type a list of elements to which you want to apply a style. Separate the elements with commas. 3 P ...
129 CHAPTER Advanced CSS 5 TIPS What if I want only some of the styles to apply to all of the elements? You can use combined sty ...
130 Format Text with Spans ......................................... 2 Within the body text, type <span> before a word or ...
131 CHAPTER Advanced CSS 5 How can I style different pieces of text differently? You can wrap any text with the <span> tag ...
132 Group Elements with Divs ....................................... 3 After the closing tag of the last element in the group, t ...
133 CHAPTER Advanced CSS 5 TIP What is the difference between <div> and <span>? The <span> tag is an inline el ...
134 Apply Styles with Classes ....................................... 2 Within a tag to which you want to apply the style, type ...
135 CHAPTER Advanced CSS 5 Are there rules for naming classes? Yes. Class names must begin with a letter and can contain only le ...
136 Apply Styles with IDs ............................................ 2 Within a tag to which you want to apply the style, type ...
137 CHAPTER Advanced CSS 5 In Chapter 2, IDs were used as targets for links. Is this a different ID? No. IDs can be used for sev ...
138 Use Contextual Selectors ........................................ 2 Within the style sheet, type a parent element or ID and ...
139 CHAPTER Advanced CSS 5 How complex can my contextual selectors be? You can create contextual selectors as complex as you nee ...
140 Use Pseudo-Elements ............................................. 2 Within the style sheet, type the name of an element. 3 T ...
141 CHAPTER Advanced CSS 5 To which elements can I apply pseudo-elements? In theory, any element can take a pseudo-element. In p ...
142 Use Pseudo-Classes ............................................... 2 Within the style sheet, type a:link. 3 Press. 4 Type {. ...
143 CHAPTER Advanced CSS 5 TIP Are there other pseudo-classes beyond the ones for styling links? CSS defines a first-child pseud ...
144 Create an External Style Sheet ................................ 2 Select everything inside the <style> tag block. 3 Cl ...
145 CHAPTER Advanced CSS 5 Where should I save the CSS file? External style sheets can be saved anywhere within your Web site’s ...
146 Link a Style Sheet to a Page ................................... 2 In the head section of the document, type <link. 1 In ...
«
3
4
5
6
7
8
9
10
11
12
»
Free download pdf