Re: Empty element tags

Aha!  You have made a good point. 

So the empty element syntax is not connected to an EMPTY element per a schema. I had overlooked that point.  

As an author, I often find that confusing.  I have been using oXygen lately, and it will sometimes present an empty <p/> element when I haven't yet typed in my text.  I have been thrown off by this.  It is not entirely intuitive for me.  I guess I need to forget my SGML DTD training and start to think of empty elements as though they are contractions, like isn't or aren't.  



On 2012-08-14, at 10:37 AM, Uche Ogbuji <uche@ogbuji.net> wrote:

> On Tue, Aug 14, 2012 at 8:23 AM, Murray Maloney <murray@muzmo.com> wrote:
> James,
> 
> As a content creator, I tend to agree that it is easier to write <empty foo="bar"/> than it is to write <empty foo="bar"></empty>
> 
> More importantly, the empty element version reinforces the notion that content is not allowed inside of this element. Thus it assists writers and editors who may not be experts in markup languages.
> 
> But use of empty element syntax is not really saying that content is not *allowed* inside of the element, though I agree that, that probably happens to be the most common case. I wouldn't want use of an empty element to send a strong signal to another writer or editor on a document that they cannot expand the element to have content. Such a signal should strictly come from the schema layer.
> 
> I do agree that empty element syntax is nice for authors, and it doesn't complicate the syntax much (one additional production).  James has advocated that it have no role at all in the data model, so no complication there at this stage.
> 
> 
> -- 
> Uche Ogbuji                       http://uche.ogbuji.net
> Founding Partner, Zepheira        http://zepheira.com
> http://wearekin.org
> http://www.thenervousbreakdown.com/author/uogbuji/
> http://copia.ogbuji.net
> http://www.linkedin.com/in/ucheogbuji
> http://twitter.com/uogbuji
> 

Received on Tuesday, 14 August 2012 14:52:46 UTC