aspose file tools*
The moose likes XML and Related Technologies and the fly likes xml id Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Engineering » XML and Related Technologies
Bookmark "xml id" Watch "xml id" New topic
Author

xml id

kahkean chor
Ranch Hand

Joined: Jan 26, 2013
Posts: 56
can i create a xml document without id?

is this correct?

<?xml version="1.0"?>
<cookies> <- root
<rmbme> <-name
<id>asdasd</id> <-element
<pw>asdsd</pw>
</rmbme>
</cookies>
Paul Clapham
Bartender

Joined: Oct 14, 2005
Posts: 18907
    
    8

You can have an element named "id" if you like. There are very few restrictions on elements names in XML, the main one being that they can't start with the string "xml". And you can have documents which don't contain any elements named "id" as well. If you've ever seen any other XML documents then chances are that you have seen a document without any such element.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: xml id