What is XML namespace?

XML namespace are similar to package in Java and used to provide a way to avoid conflict between two xml tags of same name but different sources. XML namespace is defined using xmlns attribute at top of the XML document and has following syntax xmlns:prefix=’URI’. later that prefix is used along with actual tag in XML documents. Here is an example of using XML namespace :
1<root xmlns:i88="http://it.goyun.info/marketing"
2  <i88:client>
3      <i88:number>188</i88:number>
4   </i88:client>


Popular posts from this blog