Re: XML as a config file (was: Re: Gnome-Bugs and SMTP)



> <package>
>   <name>gnome-libs</name>
>   <version>1.0.53</version>
> </package>
> <package>
>    <name>gnome-core</name>
>    <version>1.0.54</version>
> </package>

> oh by the way - what if there is /more/ than one root element (like the 
> whole above example is the entire .xml file) - When I reach the last 
> element of the first block when I do a 'cur = cur -> next' will it go to 
> the next root element?

I think there can only be one root element.
so you'd have to wrap it inside a single element
like
<root>
	<package>
	...
	</package>
	<package>
	...
	</package>
</root>

I think you have to do that, but I'm not 100% sure.

iain



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