SA_User sa MC45NzcwNjA5MTgyMDk2OTIz 2010-08-31T20:56:14Z blah... blah... blah... #### use strict; use SOAP::Transport::HTTP; SOAP::Transport::HTTP::CGI ->dispatch_to('Quote') ->handle; BEGIN { package Quote; use vars qw(@ISA); @ISA = qw(Exporter SOAP::Server::Parameters); use SOAP::Lite; use Data::Dumper::Simple; sub GetQuote { my @params = @_; print STDERR Dumper(\@params); return('ok'); } } #### use strict; use LWP::UserAgent; use HTTP::Request::Common; my $ua = LWP::UserAgent->new(agent => 'perl post'); my $file = $ARGV[0]; my $msg = slurp_file($file); my $resp = $ua->request(POST 'http://localhost/perl/server.cgi', Content_Type => 'text/xml', Content => $msg); print $resp->error_as_HTML unless $resp->is_success; print $resp->as_string; exit(0); sub slurp_file { my $file = shift; # Read in a text file without using open return(do { local( @ARGV, $/ ) = $file ; <> }); } #### soap:MustUnderstandUnrecognized header has mustUnderstand attribute set to 'true'