Re: Authoring tool specific attributes in XHTML 1.0+

Nicholas Atkinson, at 12:16 +0100 on Tue, 11 Sep 2001, wrote:

   But to do this the tool has to store additional information in the
   image element.  Which unfortunately means that validating the
   document will fail.

   It would be ideal if this tool-specific information could be put in
   the value of a special attribute which UAs will ignore (and maybe
   even other authoring tools if some convention were agreed based on
   the first few characters of the value, or something).  But,
   crucially, the document would still be valid XHTML.

It seems like you are missing a layer of processing.  In the end, you
don't want the UA to see your internal tags, no?  So why are you
processing documents (the ones with your internal attribute) that the end
user will see?  Should you not be creating an intermediary, internal step
of processing, one that can be used by your editing program, and need not
be valid XHTML (since it's only used internally)?  Simply strip out your
extended tags before sending the documents to the end user.

Actually, a better approach would be to use namespaces.  By putting your
attribute in your own namespace, you could also have your internal
documents conform to XHTML.

However, to be honest, I'm not too clear on how XHTML handles having
multiple namespaces in a document.  It seems to me, however, that you
should at least be able to throw elements and attributes in from other
namespaces, and have them be ignored if they are not understood.
(Children of unknown elements would not be ignored, though; this allows
someone to come up with their own <foo:div>).

-- 
Frank Tobin		http://www.neverending.org/~ftobin/

Received on Tuesday, 11 September 2001 08:30:12 UTC