W3C home > Mailing lists > Public > www-dom@w3.org > July to September 2001

Re: setting an element's value?

From: Tom Bradford <bradford@dbxmlgroup.com>
Date: Mon, 09 Jul 2001 16:21:32 -0700
Message-ID: <3B4A3C7C.A298F270@dbxmlgroup.com>
To: www-dom@w3.org
Gavin Stokes wrote:
> It seems that the only reason you can't just have the "value" text in
> between the element tags (before or after all the subnodes) is the
> perceived necessity to have multiple independent blocks of text
> interspersed with the subnodes.  But why should that be allowed anyway?  If
> you want a bunch of independent text nodes under an element, then yes, they
> should have to be added as subnodes.   An element should have only one
> value.  Wouldn't this work?

<p>This is a <b>bold</b> statement</p>

What's the value of p?  Is it "this is a", "statement", "This is a bold
statement", or "This is a <b>bold</b> statement"?  The answer, of course
depends on the type of application you're building, and should not be an
assumption made by the DOM.

-- 
Tom Bradford --- The dbXML Project --- http://www.dbxml.org/
Relational XML support?  I liked it more when it was a CLOB.
Received on Monday, 9 July 2001 19:17:24 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Friday, 22 June 2012 06:13:49 GMT