Grammar extracted by Vadim Zaytsev, see the Grammar Zoo entry for details: html/guyard/extracted
Source used for this grammar: Pierrick Guyard, XHTML 1.0, XHTML.ecore
, 2005/06/23
ValuedElement
, CDATA
, PCDATA
, NMTOKEN
, IDREF
, IDREFS
, ID
, EMPTY
, ContentType
, ContentTypes
, Charset
, Charsets
, LanguageCode
, Character
, Number
, LinkTypes
, MediaDesc
, URI
, UriList
, Datetime
, ScriptExpression
, StyleSheet
, Text
, Length
, MultiLength
, Pixels
, Shape
, Coords
, CoreAttrs
, Direction
, I18n
, Attrs
, Specialpre
, Special
, Fontstyle
, Phrase
, Inlineforms
, Miscinline
, Misc
, inline
, Inline
, Heading
, Lists
, Blocktext
, block
, Block
, Flow
, PreContent
, ButtonContent
, Html
, HeadMisc
, Head
, HeadElement
, TitleHeadElement
, BaseTitleHeadElement
, BaseHeadElement
, TitleBaseHeadElement
, Title
, Base
, Meta
, Link
, Style
, Script
, Noscript
, Body
, Div
, P
, H1
, H2
, H3
, H4
, H5
, H6
, Ul
, Ol
, Li
, Dl
, DlElement
, Dt
, Dd
, Address
, Hr
, Pre
, Blockquote
, Ins
, Del
, A
, Span
, Bdo
, Br
, Em
, Strong
, Dfn
, Code
, Samp
, Kbd
, Var
, Cite
, Abbr
, Acronym
, Q
, Sub
, Sup
, Tt
, I
, B
, Big
, Small
, ObjectElement
, Object
, ValueType
, Param
, Img
, MapContent
, Map
, Area
, FomeMethod
, Form
, Label
, InputType
, Input
, Select
, SelectElement
, Optgroup
, Option
, Textarea
, FieldsetElement
, Fieldset
, Legend
, ButtonType
, Button
, TFrame
, TRules
, CellHAlign
, CellVAlign
, Table
, ColElement
, TableElement
, Caption
, Thead
, Tfoot
, Tbody
, Colgroup
, Col
, Tr
, TrElement
, Scope
, Th
, Td
, String
, Integer
, Boolean
), 0 root (—), 6 top (ValuedElement
, EMPTY
, CoreAttrs
, CellHAlign
, CellVAlign
, Integer
), 3 bottom (AContent
, FormContent
, MapElement
).[value]
5, [idrefs]
, [contentTypes]
, [charsets]
, [uris]
, [rect]
, [circle]
, [poly]
, [default]
, [lengths]
, [ltr]
, [rtl]
, [i18n]
5, [id]
9, [xmlns]
, [head]
, [body]
, [profile]
, [headmisc]
5, [headelement]
, [html]
2, [title]
4, [baseTitleHeadElement]
, [base]
2, [titleBaseHeadElement]
, [href]
4, [httpequiv]
, [name]
9, [content]
, [scheme]
, [charset]
3, [hreflang]
2, [type]
8, [rel]
2, [rev]
2, [media]
2, [xml:space]
3, [src]
3, [defer]
, [block]
, [bodyElements]
, [onload]
, [onunload]
, [divElements]
, [pElements]
, [h1Elements]
, [h2Elements]
, [h3Elements]
, [h4Elements]
, [h5Elements]
, [h6Elements]
, [li]
2, [liElements]
, [dlElements]
, [dtElements]
, [ddElements]
, [addressElements]
, [preElements]
, [blockquoteElements]
, [cite]
4, [flowelement]
2, [datetime]
2, [acontent]
, [shape]
2, [coords]
2, [spanElements]
, [bdoElements]
, [lang]
, [xml:lang]
, [dir]
, [emElements]
, [strongElements]
, [dfnElements]
, [codeElements]
, [sampElements]
, [kbdElements]
, [varElements]
, [citeElements]
, [abbrElements]
, [acronymElements]
, [qElements]
, [subElements]
, [supElements]
, [ttElements]
, [iElements]
, [bElements]
, [bigElements]
, [smallElements]
, [objectelement]
, [declare]
, [classid]
, [codebase]
, [data]
2, [codetype]
, [archive]
, [standby]
, [height]
2, [width]
5, [usemap]
3, [tabindex]
2, [ref]
, [object]
, [valuetype]
, [alt]
3, [longdesc]
, [ismap]
, [mapElements]
, [mapelement]
, [class]
, [style]
, [nohref]
, [get]
, [post]
, [formelement]
, [action]
, [method]
, [enctype]
, [onsubmit]
, [onreset]
, [accept]
2, [accept-charset]
, [labelelements]
, [for]
, [accesskey]
2, [onfocus]
2, [onblur]
2, [text]
, [password]
, [checkbox]
, [radio]
, [submit]
2, [reset]
2, [file]
, [hidden]
, [image]
, [button]
2, [checked]
, [disabled]
6, [readonly]
2, [size]
2, [maxlength]
, [onselect]
2, [onchange]
3, [selectelement]
, [multiple]
, [options]
, [label]
2, [selected]
, [optionvalue]
, [rows]
2, [cols]
4, [fieldsetelements]
, [legendelement]
, [buttoncontent]
, [void]
, [above]
, [below]
, [hsides]
, [lhs]
, [rhs]
, [vsides]
, [box]
, [border]
2, [none]
, [groups]
, [all]
, [left]
, [center]
, [right]
, [justify]
, [char]
, [top]
, [middle]
, [bottom]
, [baseline]
, [caption]
, [colelement]
, [thead]
, [tfoot]
, [tableelement]
, [summary]
, [frame]
, [rules]
, [cellspacing]
, [cellpadding]
, [colgroup]
2, [tbody]
, [tr]
4, [captionelement]
, [span]
2, [trelements]
, [row]
, [col]
, [rowgroup]
, [thelement]
, [abbr]
2, [axis]
2, [headers]
2, [scope]
2, [rowspan]
2, [colspan]
2, [tdelement]
.ValuedElement ::= CDATA
ValuedElement ::= PCDATA
ValuedElement ::= NMTOKEN
ValuedElement ::= IDREF
ValuedElement ::= ID
CDATA ::= ContentType
CDATA ::= Charset
CDATA ::= Character
CDATA ::= Number
CDATA ::= LinkTypes
CDATA ::= MediaDesc
CDATA ::= URI
CDATA ::= Datetime
CDATA ::= ScriptExpression
CDATA ::= StyleSheet
CDATA ::= Text
CDATA ::= Length
CDATA ::= MultiLength
CDATA ::= Pixels
CDATA ::= ContentType Charset Character Number LinkTypes MediaDesc URI Datetime ScriptExpression StyleSheet Text Length MultiLength Pixels
PCDATA ::= Title
PCDATA ::= Style
PCDATA ::= Script
PCDATA ::= Textarea
NMTOKEN ::= LanguageCode
IDREF ::= [value]::String
IDREFS ::=
[idrefs]::IDREF
ID ::= [value]::String
EMPTY ::= Base
EMPTY ::= Meta
EMPTY ::= Link
EMPTY ::= Hr
EMPTY ::= Br
EMPTY ::= Param
EMPTY ::= Img
EMPTY ::= Area
EMPTY ::= Input
EMPTY ::= Col
ContentType ::= ε
ContentTypes ::= [contentTypes]::ContentType
Charset ::= ε
Charsets ::= [charsets]::Charset
LanguageCode ::= ε
Character ::= ε
Number ::= ε
LinkTypes ::= ε
MediaDesc ::= ε
URI ::= ε
UriList ::= [uris]::URI
Datetime ::= ε
ScriptExpression ::= ε
StyleSheet ::= ε
Text ::= ε
Length ::= ε
MultiLength ::= ε
Pixels ::= ε
Shape ::= [rect]::ε [circle]::ε [poly]::ε [default]::ε
Coords ::= [lengths]::Length
CoreAttrs ::= Attrs
CoreAttrs ::= Bdo
Direction ::= [ltr]::ε [rtl]::ε
I18n ::= Map
Attrs ::= Body
Attrs ::= Li
Attrs ::= DlElement
Attrs ::= Caption
Attrs ::= Noscript
Attrs ::= Div
Attrs ::= P
Attrs ::= H1
Attrs ::= H2
Attrs ::= H3
Attrs ::= H4
Attrs ::= H5
Attrs ::= H6
Attrs ::= Ul
Attrs ::= Ol
Attrs ::= Dl
Attrs ::= Address
Attrs ::= Pre
Attrs ::= Blockquote
Attrs ::= Ins
Attrs ::= Del
Attrs ::= A
Attrs ::= Span
Attrs ::= Em
Attrs ::= Strong
Attrs ::= Dfn
Attrs ::= Code
Attrs ::= Samp
Attrs ::= Kbd
Attrs ::= Var
Attrs ::= Cite
Attrs ::= Abbr
Attrs ::= Acronym
Attrs ::= Q
Attrs ::= Sub
Attrs ::= Sup
Attrs ::= Tt
Attrs ::= I
Attrs ::= B
Attrs ::= Big
Attrs ::= Small
Attrs ::= Object
Attrs ::= Form
Attrs ::= Label
Attrs ::= Select
Attrs ::= Fieldset
Attrs ::= Legend
Attrs ::= Button
Attrs ::= Table
Attrs ::= Thead
Attrs ::= Tfoot
Attrs ::= Tbody
Attrs ::= Colgroup
Attrs ::= Tr
Attrs ::= Optgroup
Specialpre ::= Span
Special ::= Specialpre
Fontstyle ::= Tt
Fontstyle ::= I
Fontstyle ::= B
Fontstyle ::= Big
Fontstyle ::= Small
Phrase ::= Em
Phrase ::= Strong
Phrase ::= Dfn
Phrase ::= Code
Phrase ::= Samp
Phrase ::= Kbd
Phrase ::= Var
Phrase ::= Cite
Phrase ::= Abbr
Phrase ::= Acronym
Phrase ::= Q
Phrase ::= Sub
Phrase ::= Sup
Inlineforms ::= Label
Inlineforms ::= Select
Miscinline ::= Ins
Miscinline ::= Del
Misc ::= Miscinline
Misc ::= Noscript
inline ::= Special
inline ::= Fontstyle
inline ::= Phrase
inline ::= Inlineforms
Inline ::= inline
Heading ::= H1
Heading ::= H2
Heading ::= H3
Heading ::= H4
Heading ::= H5
Heading ::= H6
Lists ::= Ul
Lists ::= Ol
Lists ::= Dl
Blocktext ::= Address
Blocktext ::= Pre
Blocktext ::= Blockquote
block ::= Heading
block ::= Lists
block ::= Blocktext
block ::= Fieldset
Block ::= Misc
Block ::= block
Flow ::= Inline
PreContent ::= Specialpre
ButtonContent ::= Special
ButtonContent ::= Heading
ButtonContent ::= Lists
ButtonContent ::= Blocktext
Html ::= [i18n]::I18n [id]::ID [xmlns]::URI [head]::Head [body]::Body
HeadMisc ::= Meta
HeadMisc ::= Style
Head ::=
[i18n]::I18n [id]::ID [profile]::URI [headmisc]::HeadMisc
[headelement]::HeadElement [html]::HtmlHeadElement ::= TitleHeadElement
HeadElement ::= BaseHeadElement
TitleHeadElement ::= [title]::Title [headmisc]::HeadMisc[baseTitleHeadElement]::BaseTitleHeadElement
BaseTitleHeadElement ::=
[base]::Base [headmisc]::HeadMisc
BaseHeadElement ::= [base]::Base [headmisc]::HeadMisc[titleBaseHeadElement]::TitleBaseHeadElement
TitleBaseHeadElement ::=
[title]::Title [headmisc]::HeadMisc
Title ::= [i18n]::I18n [id]::ID
Base ::= [href]::URI [id]::ID
Meta ::= [i18n]::I18n [id]::ID [httpequiv]::CDATA [name]::CDATA [content]::CDATA [scheme]::CDATA
Link ::= [charset]::Charset [href]::URI [hreflang]::LanguageCode [type]::ContentType [rel]::LinkTypes [rev]::LinkTypes [media]::MediaDesc
Style ::= [i18n]::I18n [id]::ID [type]::ContentType [media]::MediaDesc [title]::Text [xml:space]::String
Script ::= [id]::ID [charset]::Charset [type]::ContentType [src]::URI [defer]::String [xml:space]::String
Noscript ::= [block]::Block
Body ::=
[bodyElements]::Block
[onload]::ScriptExpression [onunload]::ScriptExpression [html]::HtmlDiv ::=
[divElements]::Flow
P ::=
[pElements]::Inline
H1 ::=
[h1Elements]::Inline
H2 ::=
[h2Elements]::Inline
H3 ::=
[h3Elements]::Inline
H4 ::=
[h4Elements]::Inline
H5 ::=
[h5Elements]::Inline
H6 ::=
[h6Elements]::Inline
Ul ::=
[li]::Li
Ol ::=
[li]::Li
Li ::=
[liElements]::Flow
Dl ::=
[dlElements]::DlElement
DlElement ::= Dt
DlElement ::= Dd
Dt ::=
[dtElements]::Inline
Dd ::=
[ddElements]::Flow
Address ::=
[addressElements]::Inline
Hr ::= ε
Pre ::=
[preElements]::PreContent
[xml:space]::StringBlockquote ::=
[blockquoteElements]::Block
[cite]::URIIns ::=
[flowelement]::Flow
[cite]::URI [datetime]::DatetimeDel ::=
[flowelement]::Flow
[cite]::URI [datetime]::DatetimeA ::=
[acontent]::AContent
[charset]::Charset [type]::ContentType [name]::NMTOKEN [href]::URI [hreflang]::LanguageCode [rel]::LinkTypes [rev]::LinkTypes [shape]::Shape [coords]::CoordsSpan ::=
[spanElements]::Inline
Bdo ::=
[bdoElements]::Inline
[lang]::LanguageCode [xml:lang]::LanguageCode [dir]::DirectionBr ::= ε
Em ::=
[emElements]::Inline
Strong ::=
[strongElements]::Inline
Dfn ::=
[dfnElements]::Inline
Code ::=
[codeElements]::Inline
Samp ::=
[sampElements]::Inline
Kbd ::=
[kbdElements]::Inline
Var ::=
[varElements]::Inline
Cite ::=
[citeElements]::Inline
Abbr ::=
[abbrElements]::Inline
Acronym ::=
[acronymElements]::Inline
Q ::=
[qElements]::Inline
[cite]::URISub ::=
[subElements]::Inline
Sup ::=
[supElements]::Inline
Tt ::=
[ttElements]::Inline
I ::=
[iElements]::Inline
B ::=
[bElements]::Inline
Big ::=
[bigElements]::Inline
Small ::=
[smallElements]::Inline
ObjectElement ::= Param
Object ::=
[objectelement]::ObjectElement
[declare]::Boolean [classid]::URI [codebase]::URI [data]::URI [type]::ContentType [codetype]::ContentType [archive]::UriList [standby]::Text [height]::Length [width]::Length [usemap]::URI [name]::NMTOKEN [tabindex]::NumberValueType ::= [data]::ε [ref]::ε [object]::ε
Param ::= [id]::ID [name]::CDATA [value]::CDATA [valuetype]::ValueType [type]::ContentType
Img ::= [src]::URI [alt]::Text [longdesc]::URI [height]::Length [width]::Length [usemap]::URI [ismap]::Boolean
MapContent ::=
[mapElements]::MapElement
Map ::= [mapelement]::MapContent [id]::ID [class]::CDATA [style]::StyleSheet [title]::Text [name]::NMTOKEN
Area ::= [shape]::Shape [coords]::Coords [href]::URI [nohref]::Boolean [alt]::Text
FomeMethod ::= [get]::ε [post]::ε
Form ::=
[formelement]::FormContent
[action]::URI [method]::FomeMethod [enctype]::ContentType [onsubmit]::ScriptExpression [onreset]::ScriptExpression [accept]::ContentTypes [accept-charset]::CharsetsLabel ::=
[labelelements]::Inline
[for]::IDREF [accesskey]::Character [onfocus]::ScriptExpression [onblur]::ScriptExpressionInputType ::= [text]::ε [password]::ε [checkbox]::ε [radio]::ε [submit]::ε [reset]::ε [file]::ε [hidden]::ε [image]::ε [button]::ε
Input ::= [type]::InputType [name]::CDATA [value]::CDATA [checked]::Boolean [disabled]::Boolean [readonly]::Boolean [size]::CDATA [maxlength]::Number [src]::URI [alt]::CDATA [usemap]::URI [onselect]::ScriptExpression [onchange]::ScriptExpression [accept]::ContentTypes
Select ::=
[selectelement]::SelectElement
[name]::CDATA [size]::Number [multiple]::Boolean [disabled]::Boolean [tabindex]::Number [onfocus]::ScriptExpression [onblur]::ScriptExpression [onchange]::ScriptExpressionSelectElement ::= Optgroup
SelectElement ::= Option
Optgroup ::=
[options]::Option
[disabled]::Boolean [label]::TextOption ::= [selected]::Boolean [disabled]::Boolean [label]::Text [optionvalue]::CDATA
Textarea ::= [name]::CDATA [rows]::Number [cols]::Number [disabled]::Boolean [readonly]::Boolean [onselect]::ScriptExpression [onchange]::ScriptExpression
FieldsetElement ::= Legend
Fieldset ::=
[fieldsetelements]::FieldsetElement
Legend ::=
[legendelement]::Inline
[accesskey]::CharacterButtonType ::= [button]::ε [submit]::ε [reset]::ε
Button ::=
[buttoncontent]::ButtonContent
[name]::CDATA [value]::CDATA [type]::ButtonType [disabled]::BooleanTFrame ::= [void]::ε [above]::ε [below]::ε [hsides]::ε [lhs]::ε [rhs]::ε [vsides]::ε [box]::ε [border]::ε
TRules ::= [none]::ε [groups]::ε [rows]::ε [cols]::ε [all]::ε
CellHAlign ::= [left]::ε [center]::ε [right]::ε [justify]::ε [char]::ε
CellVAlign ::= [top]::ε [middle]::ε [bottom]::ε [baseline]::ε
Table ::=
[caption]::Caption
[colelement]::ColElement [thead]::Thead [tfoot]::Tfoot [tableelement]::TableElement [summary]::Text [width]::Length [border]::Pixels [frame]::TFrame [rules]::TRules [cellspacing]::Length [cellpadding]::LengthColElement ::= [cols]::Col[colgroup]::Colgroup
TableElement ::= [tbody]::Tbody[tr]::Tr
Caption ::=
[captionelement]::Inline
Thead ::=
[tr]::Tr
Tfoot ::=
[tr]::Tr
Tbody ::=
[tr]::Tr
Colgroup ::=
[cols]::Col
[span]::Number [width]::MultiLengthCol ::= [span]::Number [width]::MultiLength
Tr ::=
[trelements]::TrElement
TrElement ::= Th
TrElement ::= Td
Scope ::= [row]::ε [col]::ε [rowgroup]::ε [colgroup]::ε
Th ::=
[thelement]::Flow
[abbr]::Text [axis]::CDATA [headers]::IDREFS [scope]::Scope [rowspan]::Number [colspan]::NumberTd ::=
[tdelement]::Flow
[abbr]::Text [axis]::CDATA [headers]::IDREFS [scope]::Scope [rowspan]::Number [colspan]::NumberString ::= string
Integer ::= integer
Boolean ::= "true" "false"