W3C home > Mailing lists > Public > www-html@w3.org > January 2002

RE: Cleanest way of making some minor additions to XHTML?

From: Christian Wolfgang Hujer <Christian.Hujer@itcqis.com>
Date: Wed, 23 Jan 2002 10:24:53 +0100
To: "Matthew Bloch" <mattbee@soup-kitchen.net>, <www-html@w3.org>
Message-ID: <000201c1a3ef$d063d7c0$c58f9b3e@andromedacwh>
Hello Matthew,

> -----Original Message-----
> Hello;
> I'm looking to add a few tags to XHTML for a particular device which has
> buttons down the side of the screen, and I wanted those buttons to be
> programmable to go to particular links when you press them, as well as
> adding a visual cue to the browser when this has occurred.
> My initial thoughts were just to add attributes to the <a> tag, i.e.
> <a href="go.html" sidebutton="1" sidetext="Go">
> <a href="stop.html" sidebutton="1" sidetext="Stop">
as long as they won't appear on the Web, it's okay.

> Now the browser (NetClue) throws these extra attributes away when it
> parses a document claiming to XHTML 1.0 compliant, presumably as it
> should, and once the page is rendered I cannot find them in the DOM from
> my program's code.  Assuming this is because they're not specified in the
> DTD, should I copy the XHTML 1.0 DTD wholesale and add those tags as being
> valid?  Then of course the xml pages for my device aren't recognised as
> XHTML any more because the DTD is a local one.  Or can somebody guide me
> through the practicalities of telling the browser to extend or selectively
> override a DTD, while still keeping my pages as recognisable XHTML?
XHTML 1.0 is not intended for extension, though the X in the name might
suggest it. XHTML 1.0 is just the reformulation of HTML 4.01 on an XML basis
instead of SGML. XHTML 1.0 was developed to allow a smooth transition for
both, (X)HTML users on the Web and those people that develop XHTML at the
W3C towards XHTML.

The most recent step in (X)HTML development was the modularization of XHTML.
It is described in:

Modularization of XHTML™
W3C Recommendation 10 April 2001

In section 4.4.1 (informative) you can find an small example for an abstract
module definition intended to extend XHTML.
Appendix D (normative) is titled "Building DTD Modules",
Appendix E (informative) is titled "Developing DTDs with defined and
extended modules".

These two appendices contain the information on how to extend XHTML with new
modules that define new elements with attributes, new attributes for
existing elements and content model extensions for existing elements.

The information on how to add new attributes to existing elements can be
extracted from section D.2.2. (the example set in green in the first ordered
list below 3.).

Two versions of XHTML using Modularization of XHTML already exist:
* XHTML 1.1
This is XHTML 1.0 Strict rewritten atop of Modularization of XHTML, dropping
some deprecated elements.
* XHTML Basic
This is a more restrictive version of XHTML which is mainly intended for
devices with much less software updates than PCs and Workstations, like TVs,
set top boxes, hand held devices, cell phones etc., that sometimes, but not
neccessarily, have small displays and usually do not get regular software
updates (anybody out there who already updated the software of his TV? ;).

I prefer XHTML Basic for development and XHTML 1.1 for publishing. (I use
transformation in XSLT to transform XHTML Basic in XHTML 1.1 with layout and

> I've found a little documentation on w3.org about this, specifically to do
> with namespaces and XHTML modularization, but no concrete examples as to
> how I could go about my task, and whether any particular software support
> is required.
Just read the appendices of Modularization of XHTML, and take a look at the
external subsets of the DTDs to XHTML Basic and XHTML 1.1, take a look at
some modules as examples, and if you have concrete questions, you know, the

Particular software support is indeed required. You need a validating parser
*without bugs*. MSXML, unpatched Ælfred or XMLSpy won't do, they all have
bugs and don't work with Modularization of XHTML.


Received on Wednesday, 23 January 2002 04:27:55 UTC

This archive was generated by hypermail 2.3.1 : Wednesday, 7 January 2015 15:05:58 UTC