| Introduction |
|
11 | (1) |
|
|
|
12 | (1) |
|
|
|
13 | (1) |
|
|
|
14 | (1) |
|
|
|
15 | (1) |
|
|
|
16 | (1) |
|
|
|
17 | (1) |
|
|
|
18 | (3) |
| Part 1: XML |
|
|
|
|
21 | (14) |
|
Elements, Attributes, and Values |
|
|
22 | (1) |
|
|
|
23 | (1) |
|
Declaring the XML Version |
|
|
24 | (1) |
|
Creating the Root Element |
|
|
25 | (1) |
|
Writing Non-Empty Elements |
|
|
26 | (1) |
|
|
|
27 | (1) |
|
|
|
28 | (1) |
|
|
|
29 | (1) |
|
|
|
30 | (1) |
|
Writing Five Special Symbols |
|
|
31 | (1) |
|
Displaying Elements as Text |
|
|
32 | (3) |
| Part 2: DTDs |
|
|
|
|
35 | (6) |
|
Declaring an Internal DTD |
|
|
36 | (1) |
|
|
|
37 | (1) |
|
|
|
38 | (1) |
|
Declaring a Personal External DTD |
|
|
39 | (1) |
|
Declaring a Public External DTD |
|
|
40 | (1) |
|
Defining Elements and Attributes in a DTD |
|
|
41 | (14) |
|
|
|
42 | (2) |
|
Defining an Element to Contain Only Text |
|
|
44 | (1) |
|
Defining an Element to Contain One Child |
|
|
45 | (1) |
|
Defining an Element to Contain a Sequence |
|
|
46 | (1) |
|
|
|
47 | (1) |
|
|
|
48 | (1) |
|
|
|
49 | (1) |
|
Defining Simple Attributes |
|
|
50 | (2) |
|
Defining Attributes with Unique Values |
|
|
52 | (1) |
|
Referencing Attributes with Unique Values |
|
|
53 | (1) |
|
Restricting Attributes to Valid XML Names |
|
|
54 | (1) |
|
Entities and Notations in DTDs |
|
|
55 | (14) |
|
Creating Shortcuts for Text |
|
|
56 | (1) |
|
|
|
57 | (1) |
|
Shortcuts for Text in External Files |
|
|
58 | (2) |
|
Creating and Using Shortcuts for DTDs |
|
|
60 | (2) |
|
Creating Entities for Unparsed Content |
|
|
62 | (2) |
|
Embedding Unparsed Content |
|
|
64 | (5) |
| Part 3: XML Schema and Namespaces |
|
|
|
|
69 | (6) |
|
|
|
70 | (1) |
|
Local and Global Declarations |
|
|
71 | (1) |
|
Beginning a Simple Schema |
|
|
72 | (1) |
|
Indicating a Simple Schema's Location |
|
|
73 | (1) |
|
|
|
74 | (1) |
|
|
|
75 | (18) |
|
Declaring an Element with a Simple Type |
|
|
76 | (2) |
|
Using Date and Time Types |
|
|
78 | (2) |
|
|
|
80 | (1) |
|
Deriving Custom Simple Types |
|
|
81 | (1) |
|
Using Anonymous Custom Types |
|
|
82 | (1) |
|
Specifying a Set of Acceptable Values |
|
|
83 | (1) |
|
Specifying a Pattern for a Simple Type |
|
|
84 | (2) |
|
Specifying a Range of Acceptable Values |
|
|
86 | (2) |
|
Limiting the Length of a Simple Type |
|
|
88 | (1) |
|
Limiting a Number's Digits |
|
|
89 | (1) |
|
|
|
90 | (1) |
|
Predefining an Element's Content |
|
|
91 | (2) |
|
|
|
93 | (20) |
|
Defining Elements to Contain Only Elements |
|
|
94 | (1) |
|
Requiring Elements to Appear in Sequence |
|
|
95 | (1) |
|
Creating a Set of Choices |
|
|
96 | (1) |
|
Allowing Elements to Appear in Any Order |
|
|
97 | (1) |
|
|
|
98 | (1) |
|
Referencing a Named Group |
|
|
99 | (1) |
|
Referencing Already Defined Elements |
|
|
100 | (1) |
|
|
|
101 | (1) |
|
Defining Elements to Contain Only Text |
|
|
102 | (1) |
|
|
|
103 | (1) |
|
Defining Elements with Mixed Content |
|
|
104 | (1) |
|
Basing Complex Types on Complex Types |
|
|
105 | (1) |
|
Declaring an Element of Complex Type |
|
|
106 | (1) |
|
Elements with Anonymous Complex Types |
|
|
107 | (1) |
|
|
|
108 | (1) |
|
|
|
109 | (1) |
|
Predefining an Attribute's Content |
|
|
110 | (1) |
|
Defining Attribute Groups |
|
|
111 | (1) |
|
Referencing Attribute Groups |
|
|
112 | (1) |
|
|
|
113 | (8) |
|
Designing a Namespace Name |
|
|
114 | (1) |
|
Declaring Default Namespaces |
|
|
115 | (1) |
|
Namespaces for Individual Elements |
|
|
116 | (2) |
|
How Namespaces Affect Attributes |
|
|
118 | (1) |
|
Namespaces, DTDs, and Valid Documents |
|
|
119 | (2) |
|
Namespaces, Schemas, and Validation |
|
|
121 | (14) |
|
|
|
122 | (1) |
|
|
|
123 | (1) |
|
Adding All Locally Declared Elements |
|
|
124 | (1) |
|
Adding Particular Locally Declared Elements |
|
|
125 | (1) |
|
Referencing Components with Namespaces |
|
|
126 | (2) |
|
The Schema of Schemas as the Default |
|
|
128 | (1) |
|
Namespaces and Validating XML |
|
|
129 | (1) |
|
Indicating Where a Schema Is |
|
|
130 | (1) |
|
Schemas in Multiple Files |
|
|
131 | (1) |
|
|
|
132 | (3) |
| Part 4: XSLT and XPath |
|
|
|
|
135 | (18) |
|
Transforming XML with XSLT |
|
|
136 | (2) |
|
Beginning an XSLT Style Sheet |
|
|
138 | (1) |
|
Creating the Root Template |
|
|
139 | (1) |
|
|
|
140 | (2) |
|
Outputting a Node's Content |
|
|
142 | (2) |
|
Creating and Applying Template Rules |
|
|
144 | (2) |
|
|
|
146 | (2) |
|
Processing Nodes Conditionally |
|
|
148 | (1) |
|
Adding Conditional Choices |
|
|
149 | (1) |
|
Sorting Nodes Before Processing |
|
|
150 | (1) |
|
|
|
151 | (2) |
|
XPath: Patterns and Expressions |
|
|
153 | (10) |
|
Determining the Current Node |
|
|
154 | (1) |
|
Referring to the Current Node |
|
|
155 | (1) |
|
Selecting a Node's Children |
|
|
156 | (1) |
|
Selecting a Node's Parent or Siblings |
|
|
157 | (1) |
|
Selecting All of the Descendants |
|
|
158 | (1) |
|
Disregarding the Current Node |
|
|
159 | (1) |
|
Selecting a Node's Attributes |
|
|
160 | (1) |
|
|
|
161 | (2) |
|
Test Expressions and Functions |
|
|
163 | (14) |
|
|
|
164 | (1) |
|
|
|
165 | (1) |
|
|
|
166 | (1) |
|
|
|
167 | (1) |
|
Multiplying, Dividing, Adding, Subtracting |
|
|
168 | (1) |
|
|
|
169 | (1) |
|
|
|
170 | (1) |
|
|
|
171 | (2) |
|
|
|
173 | (4) |
| Part 5: Cascading Style Sheets |
|
|
|
|
177 | (12) |
|
CSS with XML vs. CSS with HTML |
|
|
178 | (1) |
|
|
|
178 | (1) |
|
|
|
179 | (1) |
|
Specifying Where Styles Are To Be Applied |
|
|
180 | (2) |
|
Creating an External Style Sheet |
|
|
182 | (2) |
|
Calling a Style Sheet for an XML Document |
|
|
184 | (2) |
|
Calling a Style Sheet for an HTML Document |
|
|
186 | (1) |
|
Using Internal Style Sheets |
|
|
187 | (1) |
|
|
|
188 | (1) |
|
|
|
189 | (20) |
|
Defining Elements as Block-Level or Inline |
|
|
190 | (1) |
|
Hiding Elements Completely |
|
|
191 | (1) |
|
Offsetting Elements In the Natural Flow |
|
|
192 | (1) |
|
Positioning Elements Absolutely |
|
|
193 | (1) |
|
Setting the Height or Width for an Element |
|
|
194 | (1) |
|
|
|
195 | (1) |
|
Adding Padding Around an Element |
|
|
196 | (1) |
|
Setting the Margins around an Element |
|
|
197 | (1) |
|
Wrapping Text around Elements |
|
|
198 | (1) |
|
|
|
199 | (1) |
|
Changing the Foreground Color |
|
|
200 | (1) |
|
|
|
201 | (1) |
|
Positioning Elements in 3D |
|
|
202 | (1) |
|
Aligning Elements Vertically |
|
|
203 | (1) |
|
Determining Where Overflow Should Go |
|
|
204 | (1) |
|
|
|
205 | (1) |
|
|
|
206 | (2) |
|
|
|
208 | (1) |
|
|
|
209 | (16) |
|
|
|
210 | (1) |
|
Embedding Fonts on a Page |
|
|
211 | (1) |
|
|
|
212 | (1) |
|
|
|
213 | (1) |
|
|
|
214 | (1) |
|
|
|
215 | (1) |
|
Setting All Font Values at Once |
|
|
216 | (1) |
|
|
|
217 | (1) |
|
Changing the Text's Background |
|
|
218 | (1) |
|
|
|
219 | (1) |
|
|
|
220 | (1) |
|
|
|
221 | (1) |
|
|
|
222 | (3) |
| Part 6: XLink and XPointer |
|
|
Links and Images: XLink and XPointer |
|
|
225 | |
|
|
|
226 | |
|
|
|
228 | |
|
Defining Reference Points |
|
|
229 | |
|
|
|
230 | |
|
|
|
232 | |
|
Linking to Part of a File |
|
|
233 | |
|
Creating the Simplest XPointer |
|
|
234 | |
|
Creating Walking XPointers |
|
|
235 | |
|
Creating an XPointer Range |
|
|
236 | |
| Appendices |
|
|
|
|
239 | |
|
|
|
240 | |
|
|
|
241 | |
|
Declaring a DTD for XHTML |
|
|
242 | |
|
|
|
243 | |
|
Validating XML Files against a DTD |
|
|
244 | |
|
Validating XML with a Schema |
|
|
245 | |
|
Transforming XML with an XSLT Processor |
|
|
246 | |
|
Appendix C: Special Symbols |
|
|
247 | |
|
Using Character References |
|
|
248 | |
|
|
|
249 | |
|
|
|
250 | |
|
Appendix D: Colors in Hex |
|
|
251 | |
|
Finding a Color's RGB Components---in Hex |
|
|
252 | |
|
|
|
253 | |
|
|
|
253 | |
| Index, Colophon, and Note |
|
|
|
|
255 | |
|
|
|
270 | |