document ::= prolog?,element+,Misc* prolog prolog ::= XMLDecl? Misc* (doctypedecl Misc*)? XMLDecl ::= '<?xml' VersionInfo EncodingDecl? SDDecl? S? '?>' VersionInfo ::= S 'version' Eq ("'" VersionNum "'" | '"' VersionNum '"') EncodingDecl ::= S 'encoding' Eq ('"' EncName '"' | "'" EncName "'" ) SDDecl ::= S 'standalone' Eq (("'" ('yes' | 'no') "'") | ('"' ('yes' | 'no') '"'))
Comment ::= '<!--' ((Char - '-') | ('-' (Char - '-')))* '-->' S ::= (#x20 | #x9 | #xD | #xA)+ PI ::= '<?' PITarget (S (Char* - (Char* '?>' Char*)))? '?>' <![CDATA[ " and end with the string " ]]>
Misc ::= Comment | PI | S
doctypedecl ::= '<!DOCTYPE' S Name (S ExternalID)? S? ('[' intSubset ']' S?)? '>' ExternalID ::= 'SYSTEM' S SystemLiteral | 'PUBLIC' S PubidLiteral S SystemLiteral
<?xml version="1.0" encoding="UTF-8" ?> <!DOCTYPE greeting SYSTEM "hello.dtd"> <greeting>Hello,world!</greeting> (编辑:李大同)
【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容!
|