Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Best practices for referencing XML schema in XML document

Status
Not open for further replies.

drimell

Programmer
Aug 26, 2005
1
GB
Hi there,

I am new to both XML and this forum. I wonder if anybody could answer this question?

I have written my well-formed XML document, and i have written my XML schema document. I can validate my XML document against my schema by including the following line in my XML document:

------------------------------------------------------------
xsi:noNamespaceSchemaLocation="C:\test\OnlineProperties.xsd
------------------------------------------------------------

That's fine when i want to validate my XML code locally on my PC. However, I will be sending this XML feed to a third party company so i don't know which path to include because i don't know where they will be storing the XML schema.

If anyone has experience in using XML for transferring data from Business 2 Business:

- is it best to omit the path and always assume the XML schema will be saved in the same location as the xml doc?

- is the recipient normally responsible for setting the schema path?

- is it possible to embed the schema WITHIN the xml doc?

- is it best to make the schema available over the internet (not the best solution for me)

Hopefully you could give me the benefit of your experience.

Thanks

David
 
How will you be sending the data? Web service? Why don't you just validate it before you send it? Schema with URI is the best choice (internet)

Jon

"I don't regret this, but I both rue and lament it.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top