POST'ing XML from VB ASP to Perl

B

Bob

I have a client that is trying to post XML data to my Perl script
using the following VB code and I am having difficulty getting the XML
data. I do not see it in the normal ENV. My side is an apache server
running mod_perl. I have run tcpdump and can see the XML is making it
to my server. I have no control over the VB code. Can anyone point
me in the right direction? I have looked into HTTP::Request but I can
not seem to make it work properly.


-------VB CODE-------
<%
Set objdom = CreateObject("Microsoft.XMLDOM")
objdom.async = False
objdom.Load ("d:\inetpub\wwwroot\myxml.xml")

destination = "http://myserver.com/cgi-bin/XMLReceive.pl"
Set http = CreateObject("MSXML2.ServerXMLHTTP")
With http
.Open "POST", destination, False
.send objdom
end with

%>
-------END VB CODE-------
 
S

Sherm Pendley

Bob said:
I have a client that is trying to post XML data to my Perl script
using the following VB code and I am having difficulty getting the XML
data. I do not see it in the normal ENV. My side is an apache server
running mod_perl. I have run tcpdump and can see the XML is making it
to my server. I have no control over the VB code. Can anyone point
me in the right direction? I have looked into HTTP::Request but I can
not seem to make it work properly.

I don't do VB, so I'm unclear on what this example is doing exactly.

Is it using a standard HTTP post, like a browser would do when
submitting an HTML form? If that's the case, you need to use either
CGI.pm or (since you're using mod_perl) Apache::Request. Looking in %ENV
and trying to parse what you find there is *not* the "normal" way to
parse form data. Using one of the standard modules is.

If the VB is sending something via XML-RPC, it looks like there's a CPAN
module that will help with that too: Apache::RPC::Server. I haven't used
it though, so I can't help you with it.

sherm--
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,744
Messages
2,569,479
Members
44,899
Latest member
RodneyMcAu

Latest Threads

Top