Re: [xml] XML newbie question



On Mon, Aug 07, 2006 at 01:01:25AM -0700, Gopi Rajagopal wrote:
   When I compile this program and run it, the xml generated is as follows:

<?xml version="1.0"?>
<config><host><hname hcmnd1="uname" hostname="solhost" osname="Solaris" 
osver="10"
/><proc hcmnd2="psrinfo" procname="sparcv9"/></host></config>

My question is this:

Why is my opening tag wrong and my closing tag missing?
Why do I see
<hname hcmnd1="uname" hostname="solhost" ... />
instead of
<hname> hcmnd1="uname" hostname="solhost" ...</hname>

  The element is empty, even newbies should spend the minimum time needed to
understand the spec !

    http://www.w3.org/TR/REC-xml/#NT-EmptyElemTag

Daniel

-- 
Daniel Veillard      | Red Hat http://redhat.com/
veillard redhat com  | libxml GNOME XML XSLT toolkit  http://xmlsoft.org/
http://veillard.com/ | Rpmfind RPM search engine http://rpmfind.net/



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]