Are there any formal recommendations on element casing in XML?
I know XHTML uses lowercase element names (as opposed to HTML which canonically uses uppercas
To expand on my comment above: the use of 'lowercase with hyphens' has some problems in XSLT. Specifically it is easy to confuse a node called, say, 'year-from-age' with a formula 'year - age' (e.g. subtract age from year).
As @KarlKieninger points out, this is only a problem at the human level and not for the XSLT parser. However since this will often not produce an error, using 'lowercase with hyphens' as a standard is asking for trouble, IMHO.
Some pertinent examples:
11
outputs 2, as expected
11
DOES NOT ERROR, BUT OUTPUTS NOTHING AT ALL
In the above code, you must put at least one space before a subtraction operator, but there is no such requirement for an addition operator.
1 1
outputs 0, as expected
But note how confusing the above is to read!
13 2
outputs 3
13 2
outputs -1
The presence of a single space changes the output above, but neither variant is an error.