validate-website 1.6.0 → 1.7.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (74) hide show
  1. checksums.yaml +4 -4
  2. data/History.md +8 -0
  3. data/LICENSE +1 -1
  4. data/README.md +1 -1
  5. data/lib/validate_website/core.rb +1 -0
  6. data/lib/validate_website/static.rb +4 -63
  7. data/lib/validate_website/static_link.rb +65 -0
  8. data/lib/validate_website/validator.rb +43 -39
  9. data/lib/validate_website/version.rb +1 -1
  10. data/man/man1/validate-website-static.1 +3 -3
  11. data/man/man1/validate-website.1 +3 -3
  12. data/test/crawler_test.rb +9 -5
  13. data/test/data/validator.nu-failure.json +1 -0
  14. data/test/data/validator.nu-success.json +1 -0
  15. data/test/static_test.rb +1 -1
  16. data/test/validator_test.rb +14 -41
  17. metadata +14 -68
  18. data/data/schemas/xhtml-access-1.xsd +0 -43
  19. data/data/schemas/xhtml-applet-1.xsd +0 -66
  20. data/data/schemas/xhtml-attribs-1.xsd +0 -67
  21. data/data/schemas/xhtml-basic-form-1.xsd +0 -195
  22. data/data/schemas/xhtml-basic-table-1.xsd +0 -169
  23. data/data/schemas/xhtml-basic10-model-1.xsd +0 -385
  24. data/data/schemas/xhtml-basic10-module-redefines-1.xsd +0 -61
  25. data/data/schemas/xhtml-basic10-modules-1.xsd +0 -233
  26. data/data/schemas/xhtml-basic10.xsd +0 -99
  27. data/data/schemas/xhtml-basic11-model-1.xsd +0 -622
  28. data/data/schemas/xhtml-basic11-modules-1.xsd +0 -508
  29. data/data/schemas/xhtml-basic11.xsd +0 -105
  30. data/data/schemas/xhtml-bdo-1.xsd +0 -72
  31. data/data/schemas/xhtml-blkphras-1.xsd +0 -155
  32. data/data/schemas/xhtml-blkpres-1.xsd +0 -32
  33. data/data/schemas/xhtml-blkstruct-1.xsd +0 -44
  34. data/data/schemas/xhtml-csismap-1.xsd +0 -91
  35. data/data/schemas/xhtml-edit-1.xsd +0 -34
  36. data/data/schemas/xhtml-form-1.xsd +0 -321
  37. data/data/schemas/xhtml-frames-1.xsd +0 -113
  38. data/data/schemas/xhtml-framework-1.xsd +0 -62
  39. data/data/schemas/xhtml-hypertext-1.xsd +0 -47
  40. data/data/schemas/xhtml-iframe-1.xsd +0 -68
  41. data/data/schemas/xhtml-image-1.xsd +0 -40
  42. data/data/schemas/xhtml-inlphras-1.xsd +0 -158
  43. data/data/schemas/xhtml-inlpres-1.xsd +0 -34
  44. data/data/schemas/xhtml-inlstruct-1.xsd +0 -45
  45. data/data/schemas/xhtml-legacy-1.xsd +0 -97
  46. data/data/schemas/xhtml-link-1.xsd +0 -45
  47. data/data/schemas/xhtml-list-1.xsd +0 -94
  48. data/data/schemas/xhtml-meta-1.xsd +0 -54
  49. data/data/schemas/xhtml-misc-1.xsd +0 -441
  50. data/data/schemas/xhtml-object-1.xsd +0 -71
  51. data/data/schemas/xhtml-param-1.xsd +0 -46
  52. data/data/schemas/xhtml-pres-1.xsd +0 -46
  53. data/data/schemas/xhtml-print-1.xsd +0 -85
  54. data/data/schemas/xhtml-print-model-1.xsd +0 -604
  55. data/data/schemas/xhtml-print-modules-1.xsd +0 -422
  56. data/data/schemas/xhtml-rdfa-1.xsd +0 -116
  57. data/data/schemas/xhtml-rdfa-model-1.xsd +0 -461
  58. data/data/schemas/xhtml-rdfa-modules-1.xsd +0 -548
  59. data/data/schemas/xhtml-ruby-1.xsd +0 -170
  60. data/data/schemas/xhtml-script-1.xsd +0 -65
  61. data/data/schemas/xhtml-struct-1.xsd +0 -85
  62. data/data/schemas/xhtml-style-1.xsd +0 -47
  63. data/data/schemas/xhtml-table-1.xsd +0 -267
  64. data/data/schemas/xhtml-text-1.xsd +0 -62
  65. data/data/schemas/xhtml11-model-1.xsd +0 -715
  66. data/data/schemas/xhtml11-module-redefines-1.xsd +0 -335
  67. data/data/schemas/xhtml11-modules-1.xsd +0 -605
  68. data/data/schemas/xhtml11.xsd +0 -107
  69. data/data/schemas/xml-handlers-2.xsd +0 -98
  70. data/data/schemas/xml-script-1.xsd +0 -38
  71. data/test/data/html5-linuxfr.html +0 -1286
  72. data/test/data/validator.nu-excessive.html +0 -118
  73. data/test/data/validator.nu-failure.html +0 -10
  74. data/test/data/validator.nu-success.html +0 -2
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: validate-website
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.6.0
4
+ version: 1.7.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Laurent Arnoud
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-09-24 00:00:00.000000000 Z
11
+ date: 2017-04-08 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: spidr
@@ -53,19 +53,19 @@ dependencies:
53
53
  - !ruby/object:Gem::Version
54
54
  version: '1'
55
55
  - !ruby/object:Gem::Dependency
56
- name: multipart_body
56
+ name: w3c_validators
57
57
  requirement: !ruby/object:Gem::Requirement
58
58
  requirements:
59
59
  - - "~>"
60
60
  - !ruby/object:Gem::Version
61
- version: '0.2'
61
+ version: '1.3'
62
62
  type: :runtime
63
63
  prerelease: false
64
64
  version_requirements: !ruby/object:Gem::Requirement
65
65
  requirements:
66
66
  - - "~>"
67
67
  - !ruby/object:Gem::Version
68
- version: '0.2'
68
+ version: '1.3'
69
69
  - !ruby/object:Gem::Dependency
70
70
  name: slop
71
71
  requirement: !ruby/object:Gem::Requirement
@@ -114,28 +114,28 @@ dependencies:
114
114
  requirements:
115
115
  - - "~>"
116
116
  - !ruby/object:Gem::Version
117
- version: '1'
117
+ version: '2.3'
118
118
  type: :development
119
119
  prerelease: false
120
120
  version_requirements: !ruby/object:Gem::Requirement
121
121
  requirements:
122
122
  - - "~>"
123
123
  - !ruby/object:Gem::Version
124
- version: '1'
124
+ version: '2.3'
125
125
  - !ruby/object:Gem::Dependency
126
126
  name: rubocop
127
127
  requirement: !ruby/object:Gem::Requirement
128
128
  requirements:
129
129
  - - "~>"
130
130
  - !ruby/object:Gem::Version
131
- version: '0.43'
131
+ version: 0.43.0
132
132
  type: :development
133
133
  prerelease: false
134
134
  version_requirements: !ruby/object:Gem::Requirement
135
135
  requirements:
136
136
  - - "~>"
137
137
  - !ruby/object:Gem::Version
138
- version: '0.43'
138
+ version: 0.43.0
139
139
  description: validate-website is a web crawler for checking the markup validity with
140
140
  XML Schema / DTD and not found urls.
141
141
  email: laurent@spkdev.net
@@ -155,81 +155,30 @@ files:
155
155
  - data/schemas/loose.dtd
156
156
  - data/schemas/strict.dtd
157
157
  - data/schemas/xframes-1.xsd
158
- - data/schemas/xhtml-access-1.xsd
159
- - data/schemas/xhtml-applet-1.xsd
160
- - data/schemas/xhtml-attribs-1.xsd
161
158
  - data/schemas/xhtml-base-1.xsd
162
- - data/schemas/xhtml-basic-form-1.xsd
163
- - data/schemas/xhtml-basic-table-1.xsd
164
- - data/schemas/xhtml-basic10-model-1.xsd
165
- - data/schemas/xhtml-basic10-module-redefines-1.xsd
166
- - data/schemas/xhtml-basic10-modules-1.xsd
167
- - data/schemas/xhtml-basic10.xsd
168
- - data/schemas/xhtml-basic11-model-1.xsd
169
- - data/schemas/xhtml-basic11-modules-1.xsd
170
159
  - data/schemas/xhtml-basic11.dtd
171
- - data/schemas/xhtml-basic11.xsd
172
- - data/schemas/xhtml-bdo-1.xsd
173
- - data/schemas/xhtml-blkphras-1.xsd
174
- - data/schemas/xhtml-blkpres-1.xsd
175
- - data/schemas/xhtml-blkstruct-1.xsd
176
160
  - data/schemas/xhtml-charent-1.xsd
177
161
  - data/schemas/xhtml-copyright-1.xsd
178
- - data/schemas/xhtml-csismap-1.xsd
179
162
  - data/schemas/xhtml-datatypes-1.xsd
180
- - data/schemas/xhtml-edit-1.xsd
181
163
  - data/schemas/xhtml-events-1.xsd
182
- - data/schemas/xhtml-form-1.xsd
183
- - data/schemas/xhtml-frames-1.xsd
184
- - data/schemas/xhtml-framework-1.xsd
185
- - data/schemas/xhtml-hypertext-1.xsd
186
- - data/schemas/xhtml-iframe-1.xsd
187
- - data/schemas/xhtml-image-1.xsd
188
- - data/schemas/xhtml-inlphras-1.xsd
189
- - data/schemas/xhtml-inlpres-1.xsd
190
- - data/schemas/xhtml-inlstruct-1.xsd
191
164
  - data/schemas/xhtml-inlstyle-1.xsd
192
165
  - data/schemas/xhtml-inputmode-1.xsd
193
166
  - data/schemas/xhtml-lat1.ent
194
- - data/schemas/xhtml-legacy-1.xsd
195
- - data/schemas/xhtml-link-1.xsd
196
- - data/schemas/xhtml-list-1.xsd
197
- - data/schemas/xhtml-meta-1.xsd
198
167
  - data/schemas/xhtml-metaAttributes-1.xsd
199
- - data/schemas/xhtml-misc-1.xsd
200
168
  - data/schemas/xhtml-nameident-1.xsd
201
169
  - data/schemas/xhtml-notations-1.xsd
202
- - data/schemas/xhtml-object-1.xsd
203
- - data/schemas/xhtml-param-1.xsd
204
- - data/schemas/xhtml-pres-1.xsd
205
- - data/schemas/xhtml-print-1.xsd
206
- - data/schemas/xhtml-print-model-1.xsd
207
- - data/schemas/xhtml-print-modules-1.xsd
208
170
  - data/schemas/xhtml-rdfa-1.dtd
209
- - data/schemas/xhtml-rdfa-1.xsd
210
- - data/schemas/xhtml-rdfa-model-1.xsd
211
- - data/schemas/xhtml-rdfa-modules-1.xsd
212
- - data/schemas/xhtml-ruby-1.xsd
213
171
  - data/schemas/xhtml-ruby-basic-1.xsd
214
- - data/schemas/xhtml-script-1.xsd
215
172
  - data/schemas/xhtml-special.ent
216
173
  - data/schemas/xhtml-ssismap-1.xsd
217
- - data/schemas/xhtml-struct-1.xsd
218
- - data/schemas/xhtml-style-1.xsd
219
174
  - data/schemas/xhtml-symbol.ent
220
- - data/schemas/xhtml-table-1.xsd
221
175
  - data/schemas/xhtml-target-1.xsd
222
- - data/schemas/xhtml-text-1.xsd
223
176
  - data/schemas/xhtml1-frameset.dtd
224
177
  - data/schemas/xhtml1-frameset.xsd
225
178
  - data/schemas/xhtml1-strict.dtd
226
179
  - data/schemas/xhtml1-strict.xsd
227
180
  - data/schemas/xhtml1-transitional.dtd
228
181
  - data/schemas/xhtml1-transitional.xsd
229
- - data/schemas/xhtml11-model-1.xsd
230
- - data/schemas/xhtml11-module-redefines-1.xsd
231
- - data/schemas/xhtml11-modules-1.xsd
232
- - data/schemas/xhtml11.xsd
233
182
  - data/schemas/xhtml2.xsd
234
183
  - data/schemas/xml-events-1.xsd
235
184
  - data/schemas/xml-events-2.xsd
@@ -238,8 +187,6 @@ files:
238
187
  - data/schemas/xml-events-copyright-1.xsd
239
188
  - data/schemas/xml-events-copyright-2.xsd
240
189
  - data/schemas/xml-handlers-1.xsd
241
- - data/schemas/xml-handlers-2.xsd
242
- - data/schemas/xml-script-1.xsd
243
190
  - data/schemas/xml.xsd
244
191
  - lib/validate_website.rb
245
192
  - lib/validate_website/colorful_messages.rb
@@ -248,6 +195,7 @@ files:
248
195
  - lib/validate_website/option_parser.rb
249
196
  - lib/validate_website/runner.rb
250
197
  - lib/validate_website/static.rb
198
+ - lib/validate_website/static_link.rb
251
199
  - lib/validate_website/utils.rb
252
200
  - lib/validate_website/validator.rb
253
201
  - lib/validate_website/version.rb
@@ -258,12 +206,10 @@ files:
258
206
  - test/data/assets/application-92f19110a9d47a56d2ebe744e15af301.css
259
207
  - test/data/cozy-community.html
260
208
  - test/data/html4-strict.html
261
- - test/data/html5-linuxfr.html
262
209
  - test/data/html5.html
263
210
  - test/data/news/ryzom-naissance-du-projet-libre-ryzom-forge.md
264
- - test/data/validator.nu-excessive.html
265
- - test/data/validator.nu-failure.html
266
- - test/data/validator.nu-success.html
211
+ - test/data/validator.nu-failure.json
212
+ - test/data/validator.nu-success.json
267
213
  - test/data/w3.org-xhtml1-strict-errors.html
268
214
  - test/data/xhtml1-strict.html
269
215
  - test/example/ruby smalltalk/blockcamp-paris-le-28-novembre.html
@@ -283,7 +229,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
283
229
  requirements:
284
230
  - - ">="
285
231
  - !ruby/object:Gem::Version
286
- version: 2.0.0
232
+ version: 2.1.0
287
233
  required_rubygems_version: !ruby/object:Gem::Requirement
288
234
  requirements:
289
235
  - - ">="
@@ -291,7 +237,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
291
237
  version: '0'
292
238
  requirements: []
293
239
  rubyforge_project:
294
- rubygems_version: 2.5.1
240
+ rubygems_version: 2.5.2
295
241
  signing_key:
296
242
  specification_version: 4
297
243
  summary: Web crawler for checking the validity of your documents
@@ -1,43 +0,0 @@
1
- <?xml version="1.0" encoding="UTF-8"?>
2
- <xs:schema
3
- xmlns:xs="http://www.w3.org/2001/XMLSchema"
4
- elementFormDefault="qualified"
5
- xmlns:xh11d="http://www.w3.org/1999/xhtml/datatypes/"
6
- >
7
- <xs:import namespace="http://www.w3.org/1999/xhtml/datatypes/"
8
- schemaLocation="xhtml-datatypes-1.xsd" />
9
-
10
- <xs:annotation>
11
- <xs:documentation>
12
- This is the XML Schema module for XHTML Access
13
- $Id: xhtml-access-1.xsd,v 1.1 2008/05/17 16:21:57 smccarro Exp $
14
- </xs:documentation>
15
- <xs:documentation source="xhtml-copyright-1.xsd"/>
16
- <xs:documentation source="http://www.w3.org/TR/xhtml-role#A_role"/>
17
- </xs:annotation>
18
- <xs:attributeGroup name="xhtml.access.attlist">
19
- <xs:attributeGroup ref="xhtml.Common.attrib"/>
20
- <xs:attribute name="activate" default="no">
21
- <xs:simpleType>
22
- <xs:restriction base="xs:NMTOKEN">
23
- <xs:enumeration value="yes"/>
24
- <xs:enumeration value="no"/>
25
- </xs:restriction>
26
- </xs:simpleType>
27
- </xs:attribute>
28
- <xs:attribute name="key" type="xh11d:Character"/>
29
- <xs:attribute name="targetid">
30
- <xs:simpleType>
31
- <xs:list itemType="xs:IDREF"/>
32
- </xs:simpleType>
33
- </xs:attribute>
34
- <xs:attribute name="targetrole" type="xh11d:CURIEs"/>
35
- </xs:attributeGroup>
36
- <xs:group name="xhtml.access.content">
37
- <xs:sequence/>
38
- </xs:group>
39
- <xs:complexType name="xhtml.access.type">
40
- <xs:group ref="xhtml.access.content"/>
41
- <xs:attributeGroup ref="xhtml.access.attlist"/>
42
- </xs:complexType>
43
- </xs:schema>
@@ -1,66 +0,0 @@
1
- <?xml version="1.0" encoding="UTF-8"?>
2
- <xs:schema
3
- xmlns:xs="http://www.w3.org/2001/XMLSchema"
4
- elementFormDefault="qualified"
5
- xmlns:xh11d="http://www.w3.org/1999/xhtml/datatypes/"
6
- >
7
- <xs:import namespace="http://www.w3.org/1999/xhtml/datatypes/" schemaLocation="xhtml-datatypes-1.xsd" />
8
-
9
- <xs:annotation>
10
- <xs:documentation>
11
- Java Applets
12
- This is the XML Schema module for Java Applets in XHTML
13
-
14
- * applet (param)
15
-
16
- This module declares the applet element type and its attributes,
17
- used to provide support for Java applets. The 'alt' attribute
18
- is now required (as it is on images). One of either code or
19
- object attributes must be present. In the document, place param
20
- elements before the object elements that require their content.
21
-
22
- Note that use of this module also instantiates of the
23
- Param Element Module.
24
-
25
- $Id: xhtml-applet-1.xsd,v 1.3 2005/09/26 22:54:52 ahby Exp $
26
- </xs:documentation>
27
- <xs:documentation source="xhtml-copyright-1.xsd"/>
28
- <xs:documentation
29
- source="http://www.w3.org/TR/2001/REC-xhtml-modularization-20010410/abstract_modules.html#s_appletmodule"/>
30
- </xs:annotation>
31
-
32
- <xs:include schemaLocation="xhtml-param-1.xsd">
33
- <xs:annotation>
34
- <xs:documentation>
35
- Param module
36
- Include Param Module
37
- </xs:documentation>
38
- </xs:annotation>
39
- </xs:include>
40
-
41
- <xs:attributeGroup name="xhtml.applet.attlist">
42
- <xs:attributeGroup ref="xhtml.Core.attrib"/>
43
- <xs:attribute name="alt" type="xh11d:Text" use="required"/>
44
- <xs:attribute name="archive" type="xh11d:CDATA"/>
45
- <xs:attribute name="code" type="xh11d:CDATA"/>
46
- <xs:attribute name="codebase" type="xh11d:URI"/>
47
- <xs:attribute name="object" type="xh11d:CDATA"/>
48
- <xs:attribute name="width" type="xh11d:Length" use="required"/>
49
- <xs:attribute name="height" type="xh11d:Length" use="required"/>
50
- </xs:attributeGroup>
51
-
52
- <xs:group name="xhtml.applet.content">
53
- <xs:sequence>
54
- <xs:choice minOccurs="0" maxOccurs="unbounded">
55
- <xs:element ref="param" />
56
- <xs:group ref="xhtml.Flow.mix"/>
57
- </xs:choice>
58
- </xs:sequence>
59
- </xs:group>
60
-
61
- <xs:complexType name="xhtml.applet.type" mixed="true">
62
- <xs:group ref="xhtml.applet.content"/>
63
- <xs:attributeGroup ref="xhtml.applet.attlist"/>
64
- </xs:complexType>
65
-
66
- </xs:schema>
@@ -1,67 +0,0 @@
1
- <?xml version="1.0" encoding="UTF-8"?>
2
- <xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" elementFormDefault="qualified" xmlns:xh11d="http://www.w3.org/1999/xhtml/datatypes/">
3
- <xs:import namespace="http://www.w3.org/1999/xhtml/datatypes/" schemaLocation="xhtml-datatypes-1.xsd"/>
4
-
5
- <xs:annotation>
6
- <xs:documentation>
7
- This is the XML Schema common attributes module for XHTML
8
- $Id: xhtml-attribs-1.xsd,v 1.7 2008/07/05 04:11:00 ahby Exp $
9
- </xs:documentation>
10
- <xs:documentation source="xhtml-copyright-1.xsd"/>
11
- <xs:documentation source="http://www.w3.org/TR/xhtml-modularization/abstract_modules.html#s_commonatts"/>
12
- </xs:annotation>
13
- <xs:import namespace="http://www.w3.org/XML/1998/namespace" schemaLocation="http://www.w3.org/2001/xml.xsd">
14
- <xs:annotation>
15
- <xs:documentation>
16
- This import brings in the XML namespace attributes
17
- The module itself does not provide the schemaLocation
18
- and expects the driver schema to provide the
19
- actual SchemaLocation.
20
- </xs:documentation>
21
- </xs:annotation>
22
- </xs:import>
23
- <xs:attributeGroup name="xhtml.id">
24
- <xs:attribute name="id" type="xs:ID"/>
25
- </xs:attributeGroup>
26
- <xs:attributeGroup name="xhtml.class">
27
- <xs:attribute name="class" type="xs:NMTOKENS"/>
28
- </xs:attributeGroup>
29
- <xs:attributeGroup name="xhtml.title">
30
- <xs:attribute name="title" type="xs:string"/>
31
- </xs:attributeGroup>
32
- <xs:attributeGroup name="xhtml.Core.attrib">
33
- <xs:attribute ref="xml:space"/>
34
- <xs:attributeGroup ref="xhtml.id"/>
35
- <xs:attributeGroup ref="xhtml.class"/>
36
- <xs:attributeGroup ref="xhtml.title"/>
37
- <xs:attributeGroup ref="xhtml.Core.extra.attrib"/>
38
- </xs:attributeGroup>
39
- <xs:attributeGroup name="xhtml.I18n.attrib">
40
- <xs:attribute ref="xml:lang"/>
41
- <xs:attributeGroup ref="xhtml.I18n.extra.attrib"/>
42
- </xs:attributeGroup>
43
- <xs:attributeGroup name="xhtml.Common.attrib">
44
- <xs:attributeGroup ref="xhtml.Core.attrib"/>
45
- <xs:attributeGroup ref="xhtml.I18n.attrib"/>
46
- <xs:attributeGroup ref="xhtml.Common.extra"/>
47
- </xs:attributeGroup>
48
- <!-- Global attributes -->
49
- <xs:attribute name="id" type="xs:ID"/>
50
- <xs:attribute name="class" type="xs:NMTOKENS"/>
51
- <xs:attribute name="title" type="xs:string"/>
52
- <xs:attributeGroup name="xhtml.Global.core.attrib">
53
- <xs:attribute ref="id"/>
54
- <xs:attribute ref="class"/>
55
- <xs:attribute ref="title"/>
56
- <xs:attributeGroup ref="xhtml.Global.core.extra.attrib"/>
57
- </xs:attributeGroup>
58
- <xs:attributeGroup name="xhtml.Global.i18n.attrib">
59
- <xs:attribute ref="xml:lang"/>
60
- <xs:attributeGroup ref="xhtml.Global.I18n.extra.attrib"/>
61
- </xs:attributeGroup>
62
- <xs:attributeGroup name="xhtml.Global.common.attrib">
63
- <xs:attributeGroup ref="xhtml.Global.core.attrib"/>
64
- <xs:attributeGroup ref="xhtml.Global.i18n.attrib"/>
65
- <xs:attributeGroup ref="xhtml.Global.Common.extra"/>
66
- </xs:attributeGroup>
67
- </xs:schema>
@@ -1,195 +0,0 @@
1
- <?xml version="1.0" encoding="UTF-8"?>
2
- <xs:schema
3
- xmlns:xs="http://www.w3.org/2001/XMLSchema"
4
- elementFormDefault="qualified"
5
- xmlns:xh11d="http://www.w3.org/1999/xhtml/datatypes/"
6
- >
7
- <xs:import namespace="http://www.w3.org/1999/xhtml/datatypes/"
8
- schemaLocation="xhtml-datatypes-1.xsd" />
9
- <xs:annotation>
10
- <xs:documentation>
11
- This is the XML Schema Basic Forms module for XHTML
12
- $Id: xhtml-basic-form-1.xsd,v 1.2 2005/09/26 22:54:53 ahby Exp $
13
- </xs:documentation>
14
- <xs:documentation source="xhtml-copyright-1.xsd"/>
15
- </xs:annotation>
16
-
17
- <xs:annotation>
18
- <xs:documentation>
19
- Basic Forms
20
-
21
- This forms module is based on the HTML 3.2 forms model, with
22
- the WAI-requested addition of the label element. While this
23
- module essentially mimics the content model and attributes of
24
- HTML 3.2 forms, the element types declared herein also include
25
- all HTML 4 common attributes.
26
-
27
- Elements defined here:
28
-
29
- * form, label, input, select, option, textarea
30
- </xs:documentation>
31
- <xs:documentation source="xhtml-copyright-1.xsd"/>
32
- <xs:documentation
33
- source="http://www.w3.org/TR/2001/REC-xhtml-modularization-20010410/abstract_modules.html#s_sformsmodule"/>
34
- </xs:annotation>
35
-
36
- <xs:attributeGroup name="xhtml.form.attlist">
37
- <xs:attributeGroup ref="xhtml.Common.attrib"/>
38
- <xs:attribute name="action" type="xh11d:URI" use="required"/>
39
- <xs:attribute name="method" use="optional" default="get">
40
- <xs:simpleType>
41
- <xs:restriction base="xs:NMTOKEN">
42
- <xs:enumeration value="get"/>
43
- <xs:enumeration value="post"/>
44
- </xs:restriction>
45
- </xs:simpleType>
46
- </xs:attribute>
47
- <xs:attribute name="enctype" type="xh11d:ContentType" default="application/x-www-form-urlencoded"/>
48
- </xs:attributeGroup>
49
-
50
- <xs:group name="xhtml.form.content">
51
- <xs:sequence>
52
- <xs:group ref="xhtml.BlkNoForm.mix" minOccurs="1" maxOccurs="unbounded"/>
53
- </xs:sequence>
54
- </xs:group>
55
-
56
- <xs:complexType name="xhtml.form.type">
57
- <xs:group ref="xhtml.form.content"/>
58
- <xs:attributeGroup ref="xhtml.form.attlist"/>
59
- </xs:complexType>
60
-
61
- <xs:group name="xhtml.label.content">
62
- <xs:sequence>
63
- <xs:choice minOccurs="0" maxOccurs="unbounded">
64
- <xs:element type="xhtml.input.type" name="input"/>
65
- <xs:element type="xhtml.select.type" name="select"/>
66
- <xs:element type="xhtml.textarea.type" name="textarea"/>
67
- <xs:group ref="xhtml.InlStruct.class"/>
68
- <xs:group ref="xhtml.InlPhras.class"/>
69
- <xs:group ref="xhtml.I18n.class"/>
70
- <xs:group ref="xhtml.InlPres.class"/>
71
- <xs:group ref="xhtml.InlSpecial.class"/>
72
- <xs:group ref="xhtml.Misc.class"/>
73
- </xs:choice>
74
- </xs:sequence>
75
- </xs:group>
76
-
77
- <xs:attributeGroup name="xhtml.label.attlist">
78
- <xs:attributeGroup ref="xhtml.Common.attrib"/>
79
- <xs:attribute name="for" type="xs:IDREF"/>
80
- <xs:attribute name="accesskey" type="xh11d:Character"/>
81
- </xs:attributeGroup>
82
-
83
- <xs:complexType name="xhtml.label.type" mixed="true">
84
- <xs:group ref="xhtml.label.content"/>
85
- <xs:attributeGroup ref="xhtml.label.attlist"/>
86
- </xs:complexType>
87
-
88
- <!--
89
- Basic Forms removes button, 'image' and 'file' input types.
90
- -->
91
- <xs:simpleType name="xhtml.InputType.class">
92
- <xs:restriction base="xs:NMTOKEN">
93
- <xs:enumeration value="text"/>
94
- <xs:enumeration value="password"/>
95
- <xs:enumeration value="checkbox"/>
96
- <xs:enumeration value="radio"/>
97
- <xs:enumeration value="submit"/>
98
- <xs:enumeration value="reset"/>
99
- <xs:enumeration value="hidden"/>
100
- </xs:restriction>
101
- </xs:simpleType>
102
-
103
- <xs:attributeGroup name="xhtml.input.attlist">
104
- <xs:attributeGroup ref="xhtml.Common.attrib"/>
105
- <xs:attribute name="type" type="xhtml.InputType.class" default="text"/>
106
- <xs:attribute name="name" type="xh11d:CDATA"/>
107
- <xs:attribute name="value" type="xh11d:CDATA"/>
108
- <xs:attribute name="checked">
109
- <xs:simpleType>
110
- <xs:restriction base="xs:NMTOKEN">
111
- <xs:enumeration value="checked"/>
112
- </xs:restriction>
113
- </xs:simpleType>
114
- </xs:attribute>
115
- <xs:attribute name="size" type="xh11d:Number"/>
116
- <xs:attribute name="maxlength" type="xh11d:Number"/>
117
- <xs:attribute name="src" type="xh11d:URI"/>
118
- <xs:attribute name="tabindex" type="xh11d:Number"/>
119
- <xs:attribute name="accesskey" type="xh11d:Character"/>
120
- </xs:attributeGroup>
121
-
122
- <xs:group name="xhtml.input.content">
123
- <xs:sequence/>
124
- </xs:group>
125
-
126
- <xs:complexType name="xhtml.input.type">
127
- <xs:group ref="xhtml.input.content"/>
128
- <xs:attributeGroup ref="xhtml.input.attlist"/>
129
- </xs:complexType>
130
-
131
- <xs:attributeGroup name="xhtml.select.attlist">
132
- <xs:attributeGroup ref="xhtml.Common.attrib"/>
133
- <xs:attribute name="name" type="xh11d:CDATA"/>
134
- <xs:attribute name="size" type="xh11d:Number"/>
135
- <xs:attribute name="multiple">
136
- <xs:simpleType>
137
- <xs:restriction base="xs:NMTOKEN">
138
- <xs:enumeration value="multiple"/>
139
- </xs:restriction>
140
- </xs:simpleType>
141
- </xs:attribute>
142
- <xs:attribute name="tabindex" type="xh11d:Number"/>
143
- </xs:attributeGroup>
144
-
145
- <xs:group name="xhtml.select.content">
146
- <xs:sequence>
147
- <xs:element name="option" type="xhtml.option.type" maxOccurs="unbounded"/>
148
- </xs:sequence>
149
- </xs:group>
150
-
151
- <xs:complexType name="xhtml.select.type">
152
- <xs:group ref="xhtml.select.content"/>
153
- <xs:attributeGroup ref="xhtml.select.attlist"/>
154
- </xs:complexType>
155
-
156
- <xs:attributeGroup name="xhtml.option.attlist">
157
- <xs:attributeGroup ref="xhtml.Common.attrib"/>
158
- <xs:attribute name="selected">
159
- <xs:simpleType>
160
- <xs:restriction base="xs:NMTOKEN">
161
- <xs:enumeration value="selected"/>
162
- </xs:restriction>
163
- </xs:simpleType>
164
- </xs:attribute>
165
- <xs:attribute name="value" type="xh11d:CDATA"/>
166
- <xs:attribute name="tabindex" type="xh11d:Number"/>
167
- </xs:attributeGroup>
168
-
169
- <xs:group name="xhtml.option.content">
170
- <xs:sequence/>
171
- </xs:group>
172
-
173
- <xs:complexType name="xhtml.option.type" mixed="true">
174
- <xs:group ref="xhtml.option.content"/>
175
- <xs:attributeGroup ref="xhtml.option.attlist"/>
176
- </xs:complexType>
177
-
178
- <xs:attributeGroup name="xhtml.textarea.attlist">
179
- <xs:attributeGroup ref="xhtml.Common.attrib"/>
180
- <xs:attribute name="name" type="xh11d:CDATA"/>
181
- <xs:attribute name="rows" type="xh11d:Number" use="required"/>
182
- <xs:attribute name="cols" type="xh11d:Number" use="required"/>
183
- <xs:attribute name="accesskey" type="xh11d:Character"/>
184
- </xs:attributeGroup>
185
-
186
- <xs:group name="xhtml.textarea.content">
187
- <xs:sequence/>
188
- </xs:group>
189
-
190
- <xs:complexType name="xhtml.textarea.type" mixed="true">
191
- <xs:group ref="xhtml.textarea.content"/>
192
- <xs:attributeGroup ref="xhtml.textarea.attlist"/>
193
- </xs:complexType>
194
-
195
- </xs:schema>