[
Lists Home |
Date Index |
Thread Index
]
- From: Peter Murray-Rust <peter@ursus.demon.co.uk>
- To: Sean Mc Grath <digitome@iol.ie>, xml-dev@ic.ac.uk
- Date: Sat, 20 Dec 1997 12:24:49
A lot of members on this list are new to XML and SGML, and will hope to
"learn as they read". (This can be quite hard as they may have
misconceptions through experience of "broken" HTML.) I think it will be
useful if all sample code is well-formed XML (rather than SGML) unless
explicitly specified. (e.g. if you include SGML rather than XML, write
<!-- this is SGML, not XML -->
<!ELEMENT (Open|Close) EMPTY>
At 11:16 20/12/97 +0000, Sean Mc Grath wrote:
[... lots of very exciting stuff ...]
>a simple bank account model:
>
><!element BankAccount (Open,Transactions,Close)>
><!attlist BankAccount Balance CDATA>
><!element Open,Close EMPTY>
><!element Transactions (Debit|Credit|Enquiry)*>
><!element Debit (FundsAvailable|FundsNotAvailable)>
This isn't WF XML for several reasons. A correct version might read:
<!ELEMENT BankAccount (Open,Transactions,Close)>
<!ATTLIST BankAccount Balance CDATA #REQUIRED>
<!ELEMENT Open EMPTY>
<!ELEMENT Close EMPTY>
<!ELEMENT Transactions (Debit|Credit|Enquiry)*>
<!ELEMENT Debit (FundsAvailable|FundsNotAvailable)>
>...
[...]
>
>within a syntactic asses roar of DTDs. A Jackson structure editor is a bit
We all make syntactic asses of ourselves and I have done so on numerous
occasions, especially on XML-SIG. People have been very patient - "they
know what I mean". But here the readers *don't* know what you mean. So we
can all try to be well-formed asses :-).
Therefore:
(a) try to be very careful about XML examples and related matters. People
will say "this is written by an expert so it must be right - I'll cut and
paste it..."
(b) tactfully and gently correct any errors that *do* get through. It won't
be taken badly - we all make errors. For example I've corrected the
"element" to
"ELEMENT" as this is now required by the PR. [At one stage it wasn't, and
it's often easy to work with outdated versions.]. If it's unclear, you
might ask
"why isn't this "X"? - the answer may be revealing.
I have *never* seen any flames on these lists when people are corrected for
genuine mistakes.
P.
Peter Murray-Rust, Director Virtual School of Molecular Sciences, domestic
net connection
VSMS http://www.nottingham.ac.uk/vsms, Virtual Hyperglossary
http://www.venus.co.uk/vhg
xml-dev: A list for W3C XML Developers. To post, mailto:xml-dev@ic.ac.uk
Archived as: http://www.lists.ic.ac.uk/hypermail/xml-dev/
To (un)subscribe, mailto:majordomo@ic.ac.uk the following message;
(un)subscribe xml-dev
To subscribe to the digests, mailto:majordomo@ic.ac.uk the following message;
subscribe xml-dev-digest
List coordinator, Henry Rzepa (mailto:rzepa@ic.ac.uk)
|