>What I want to do is the following: Let's supposed I have two Java
>Web Servers (or Application servers or whatever), and they are in
>two different geographical locations.
>I want them to use XML as their communications protocol, on top of
>HTTP. So that for example one side asks the other for sales info,
>and the other replies with the sales info. All this request and
>reply happens via XML with my own tags.
>My question was, I know how to parse XML now, but how do I go about
>dynamically creating the XML (easy) and sending it to the other
>side via HTTP? and then have the other side listen on the HTTP
>port, realize I'm sending XML, and pass the stream to the XML
Microsoft has documented on its site a feature of IE5 called XmlHttp,
which does the sending side of what you want by using the http POST. The
bad news is that the documentation says that the version in the beta is
different from the final version, and only the latter is documented. You
can interpret the response as XML (i.e. it can be parsed automatically),
but validation is turned off (shame - I think this is where it would be
useful). You can also interpret the response as text, so I imagine you
could put it in an XML island and parse and validate it there.
Server Objects (www.serverobjects.com has a product AspHttp that is
similar, but the response is text only.
I have seen Jonathan Borden mention XTRIME, and there is a demo on his
company site (search for XTRIME).
One of these should handle the sending and interpreting the response.
I'm not so sure about the receiving application. One way, if it is a web
server, would be to interpret the message as a single field form. That
is my current intention, but I would welcome other suggestions.