|
1 <!-- |
|
2 Wireless Markup Language (WML) Document Type Definition. |
|
3 WML is an XML language. Typical usage: |
|
4 <?xml version="1.0"?> |
|
5 <!DOCTYPE wml PUBLIC "-//WAPFORUM//DTD WML 1.2//EN" |
|
6 "http://www.wapforum.org/DTD/wml12.dtd"> |
|
7 <wml> |
|
8 ... |
|
9 </wml> |
|
10 |
|
11 Terms and conditions of use are available from the Wireless Application Protocol Forum |
|
12 Ltd. web site at http://www.wapforum.org/docs/copyright.htm. |
|
13 |
|
14 --> |
|
15 |
|
16 <!ENTITY % length "CDATA"> <!-- [0-9]+ for pixels or [0-9]+"%" for |
|
17 percentage length --> |
|
18 <!ENTITY % vdata "CDATA"> <!-- attribute value possibly containing |
|
19 variable references --> |
|
20 <!ENTITY % HREF "%vdata;"> <!-- URI, URL or URN designating a hypertext |
|
21 node. May contain variable references --> |
|
22 <!ENTITY % boolean "(true|false)"> |
|
23 <!ENTITY % number "NMTOKEN"> <!-- a number, with format [0-9]+ --> |
|
24 <!ENTITY % coreattrs "id ID #IMPLIED |
|
25 class CDATA #IMPLIED"> |
|
26 <!ENTITY % ContentType "%vdata;"> <!-- media type. May contain variable |
|
27 references --> |
|
28 <!ENTITY % emph "em | strong |b |i |u |big |small"> |
|
29 <!ENTITY % layout "br"> |
|
30 <!ENTITY % text "#PCDATA | %emph;"> |
|
31 <!-- flow covers "card-level" elements, such as text and images --> |
|
32 <!ENTITY % flow "%text; | %layout; | img | anchor |a |table"> |
|
33 <!-- Task types --> |
|
34 <!ENTITY % task "go | prev | noop | refresh"> |
|
35 <!-- Navigation and event elements --> |
|
36 <!ENTITY % navelmts "do | onevent"> |
|
37 <!--================ Decks and Cards ================--> |
|
38 <!ELEMENT wml ( head?, template?, card+ )> |
|
39 <!ATTLIST wml |
|
40 xml:lang NMTOKEN #IMPLIED |
|
41 %coreattrs; |
|
42 > |
|
43 <!-- card intrinsic events --> |
|
44 <!ENTITY % cardev |
|
45 "onenterforward %HREF; #IMPLIED |
|
46 onenterbackward %HREF; #IMPLIED |
|
47 ontimer %HREF; #IMPLIED" |
|
48 > |
|
49 <!-- card field types --> |
|
50 <!ENTITY % fields "%flow; | input | select | fieldset"> |
|
51 <!ELEMENT card (onevent*, timer?, (do | p | pre)*)> |
|
52 <!ATTLIST card |
|
53 title %vdata; #IMPLIED |
|
54 newcontext %boolean; "false" |
|
55 ordered %boolean; "true" |
|
56 xml:lang NMTOKEN #IMPLIED |
|
57 %cardev; |
|
58 %coreattrs; |
|
59 > |
|
60 <!--================ Event Bindings ================--> |
|
61 <!ELEMENT do (%task;)> |
|
62 <!ATTLIST do |
|
63 type CDATA #REQUIRED |
|
64 label %vdata; #IMPLIED |
|
65 name NMTOKEN #IMPLIED |
|
66 optional %boolean; "false" |
|
67 xml:lang NMTOKEN #IMPLIED |
|
68 %coreattrs; |
|
69 > |
|
70 <!ELEMENT onevent (%task;)> |
|
71 <!ATTLIST onevent |
|
72 type CDATA #REQUIRED |
|
73 %coreattrs; |
|
74 > |
|
75 <!--================ Deck-level declarations ================--> |
|
76 <!ELEMENT head ( access | meta )+> |
|
77 <!ATTLIST head |
|
78 %coreattrs; |
|
79 > |
|
80 <!ELEMENT template (%navelmts;)*> |
|
81 <!ATTLIST template |
|
82 %cardev; |
|
83 %coreattrs; |
|
84 > |
|
85 <!ELEMENT access EMPTY> |
|
86 <!ATTLIST access |
|
87 domain CDATA #IMPLIED |
|
88 path CDATA #IMPLIED |
|
89 %coreattrs; |
|
90 > |
|
91 <!ELEMENT meta EMPTY> |
|
92 <!ATTLIST meta |
|
93 http-equiv CDATA #IMPLIED |
|
94 name CDATA #IMPLIED |
|
95 forua %boolean; "false" |
|
96 content CDATA #REQUIRED |
|
97 scheme CDATA #IMPLIED |
|
98 %coreattrs; |
|
99 > |
|
100 <!--================ Tasks ================--> |
|
101 <!ELEMENT go (postfield | setvar)*> |
|
102 <!ATTLIST go |
|
103 href %HREF; #REQUIRED |
|
104 sendreferer %boolean; "false" |
|
105 method (post|get) "get" |
|
106 enctype %ContentType; "application/x-www-form-urlencoded" |
|
107 accept-charset CDATA #IMPLIED |
|
108 %coreattrs; |
|
109 > |
|
110 <!ELEMENT prev (setvar)*> |
|
111 <!ATTLIST prev |
|
112 %coreattrs; |
|
113 > |
|
114 <!ELEMENT refresh (setvar)*> |
|
115 <!ATTLIST refresh |
|
116 %coreattrs; |
|
117 > |
|
118 <!ELEMENT noop EMPTY> |
|
119 <!ATTLIST noop |
|
120 %coreattrs; |
|
121 > |
|
122 <!--================ postfield ================--> |
|
123 <!ELEMENT postfield EMPTY> |
|
124 <!ATTLIST postfield |
|
125 name %vdata; #REQUIRED |
|
126 value %vdata; #REQUIRED |
|
127 %coreattrs; |
|
128 > |
|
129 <!--================ variables ================--> |
|
130 <!ELEMENT setvar EMPTY> |
|
131 <!ATTLIST setvar |
|
132 name %vdata; #REQUIRED |
|
133 value %vdata; #REQUIRED |
|
134 %coreattrs; |
|
135 > |
|
136 <!--================ Card Fields ================--> |
|
137 <!ELEMENT select (optgroup|option)+> |
|
138 <!ATTLIST select |
|
139 title %vdata; #IMPLIED |
|
140 name NMTOKEN #IMPLIED |
|
141 value %vdata; #IMPLIED |
|
142 iname NMTOKEN #IMPLIED |
|
143 ivalue %vdata; #IMPLIED |
|
144 multiple %boolean; "false" |
|
145 tabindex %number; #IMPLIED |
|
146 xml:lang NMTOKEN #IMPLIED |
|
147 %coreattrs; |
|
148 > |
|
149 <!ELEMENT optgroup (optgroup|option)+ > |
|
150 <!ATTLIST optgroup |
|
151 title %vdata; #IMPLIED |
|
152 xml:lang NMTOKEN #IMPLIED |
|
153 %coreattrs; |
|
154 > |
|
155 <!ELEMENT option (#PCDATA | onevent)*> |
|
156 <!ATTLIST option |
|
157 value %vdata; #IMPLIED |
|
158 title %vdata; #IMPLIED |
|
159 onpick %HREF; #IMPLIED |
|
160 xml:lang NMTOKEN #IMPLIED |
|
161 %coreattrs; |
|
162 > |
|
163 <!ELEMENT input EMPTY> |
|
164 <!ATTLIST input |
|
165 name NMTOKEN #REQUIRED |
|
166 type (text|password) "text" |
|
167 value %vdata; #IMPLIED |
|
168 format CDATA #IMPLIED |
|
169 emptyok %boolean; "false" |
|
170 size %number; #IMPLIED |
|
171 maxlength %number; #IMPLIED |
|
172 tabindex %number; #IMPLIED |
|
173 title %vdata; #IMPLIED |
|
174 accesskey %vdata; #IMPLIED |
|
175 xml:lang NMTOKEN #IMPLIED |
|
176 %coreattrs; |
|
177 > |
|
178 <!ELEMENT fieldset (%fields; | do)* > |
|
179 <!ATTLIST fieldset |
|
180 title %vdata; #IMPLIED |
|
181 xml:lang NMTOKEN #IMPLIED |
|
182 %coreattrs; |
|
183 > |
|
184 <!ELEMENT timer EMPTY> |
|
185 <!ATTLIST timer |
|
186 name NMTOKEN #IMPLIED |
|
187 value %vdata; #REQUIRED |
|
188 %coreattrs; |
|
189 > |
|
190 <!--================ Images ================--> |
|
191 <!ENTITY % IAlign "(top|middle|bottom)" > |
|
192 <!ELEMENT img EMPTY> |
|
193 <!ATTLIST img |
|
194 alt %vdata; #REQUIRED |
|
195 src %HREF; #REQUIRED |
|
196 localsrc %vdata; #IMPLIED |
|
197 vspace %length; "0" |
|
198 hspace %length; "0" |
|
199 align %IAlign; "bottom" |
|
200 height %length; #IMPLIED |
|
201 width %length; #IMPLIED |
|
202 xml:lang NMTOKEN #IMPLIED |
|
203 %coreattrs; |
|
204 > |
|
205 <!--================ Anchor ================--> |
|
206 <!ELEMENT anchor ( #PCDATA | br | img | go | prev | refresh )*> |
|
207 <!ATTLIST anchor |
|
208 title %vdata; #IMPLIED |
|
209 accesskey %vdata; #IMPLIED |
|
210 xml:lang NMTOKEN #IMPLIED |
|
211 %coreattrs; |
|
212 > |
|
213 <!ELEMENT a ( #PCDATA | br | img )*> |
|
214 <!ATTLIST a |
|
215 href %HREF; #REQUIRED |
|
216 title %vdata; #IMPLIED |
|
217 accesskey %vdata; #IMPLIED |
|
218 xml:lang NMTOKEN #IMPLIED |
|
219 %coreattrs; |
|
220 > |
|
221 <!--================ Tables ================--> |
|
222 <!ELEMENT table (tr)+> |
|
223 <!ATTLIST table |
|
224 title %vdata; #IMPLIED |
|
225 align CDATA #IMPLIED |
|
226 columns %number; #REQUIRED |
|
227 xml:lang NMTOKEN #IMPLIED |
|
228 %coreattrs; |
|
229 > |
|
230 <!ELEMENT tr (td)+> |
|
231 <!ATTLIST tr |
|
232 %coreattrs; |
|
233 > |
|
234 <!ELEMENT td ( %text; | %layout; | img | anchor |a )*> |
|
235 <!ATTLIST td |
|
236 xml:lang NMTOKEN #IMPLIED |
|
237 %coreattrs; |
|
238 > |
|
239 <!--================ Text layout and line breaks ================--> |
|
240 <!ELEMENT em (%flow;)*> |
|
241 <!ATTLIST em |
|
242 xml:lang NMTOKEN #IMPLIED |
|
243 %coreattrs; |
|
244 > |
|
245 <!ELEMENT strong (%flow;)*> |
|
246 <!ATTLIST strong |
|
247 xml:lang NMTOKEN #IMPLIED |
|
248 %coreattrs; |
|
249 > |
|
250 <!ELEMENT b (%flow;)*> |
|
251 <!ATTLIST b |
|
252 xml:lang NMTOKEN #IMPLIED |
|
253 %coreattrs; |
|
254 > |
|
255 <!ELEMENT i (%flow;)*> |
|
256 <!ATTLIST i |
|
257 xml:lang NMTOKEN #IMPLIED |
|
258 %coreattrs; |
|
259 > |
|
260 <!ELEMENT u (%flow;)*> |
|
261 <!ATTLIST u |
|
262 xml:lang NMTOKEN #IMPLIED |
|
263 %coreattrs; |
|
264 > |
|
265 <!ELEMENT big (%flow;)*> |
|
266 <!ATTLIST big |
|
267 xml:lang NMTOKEN #IMPLIED |
|
268 %coreattrs; |
|
269 > |
|
270 <!ELEMENT small (%flow;)*> |
|
271 <!ATTLIST small |
|
272 xml:lang NMTOKEN #IMPLIED |
|
273 %coreattrs; |
|
274 > |
|
275 <!ENTITY % TAlign "(left|right|center)"> |
|
276 <!ENTITY % WrapMode "(wrap|nowrap)" > |
|
277 <!ELEMENT p (%fields; | do)*> |
|
278 <!ATTLIST p |
|
279 align %TAlign; "left" |
|
280 mode %WrapMode; #IMPLIED |
|
281 xml:lang NMTOKEN #IMPLIED |
|
282 %coreattrs; |
|
283 > |
|
284 <!ELEMENT br EMPTY> |
|
285 <!ATTLIST br |
|
286 %coreattrs; |
|
287 > |
|
288 <!ELEMENT pre (#PCDATA |a |br |i |b |em |strong | input | select )*> |
|
289 <!ATTLIST pre |
|
290 xml:space CDATA #FIXED "preserve" |
|
291 %coreattrs; |
|
292 > |
|
293 <!ENTITY quot """> <!-- quotation mark --> |
|
294 <!ENTITY amp "&#38;"> <!-- ampersand --> |
|
295 <!ENTITY apos "'"> <!-- apostrophe --> |
|
296 <!ENTITY lt "&#60;"> <!-- less than --> |
|
297 <!ENTITY gt ">"> <!-- greater than --> |
|
298 <!ENTITY nbsp " "> <!-- non-breaking space --> |
|
299 <!ENTITY shy "­"> <!-- soft hyphen (discretionary hyphen) --> |