Loading ...
Sorry, an error occurred while loading the content.

2637Re: [soaplite] How to send and raw XML.

Expand Messages
  • Byrne Reese
    May 20, 2003
    • 0 Attachment
      To package raw XML in a SOAP::Data element, simply:

      my $xml_content = fetch($url);
      $xml_content =~ s/\<\?xml.*\?\>\n?//; # strip the <?xml blah?>
      $xml_content =~ s/\<\!.*\>\n?//; # strip
      return SOAP::Data->type('xml' => $xml_content);

      In the above case I was dealing with a complete document, so I had to
      first strip the parts of the xml document I didn't need. Once that was
      done, just set the type to 'xml' and the value to your document...
      SOAP::Lite will do the rest.

      As always - the answer (and in this case the complete answer since there
      is a lot of somewhat irrelevant background) can also be found at the
      SOAP::Lite Solutions blog:


      On Tue, 2003-05-20 at 00:30, kopetnik wrote:
      > How to send through SOAP::Lite a message instead of calling remote
      > subroutine? Just to put some XML into envelope - <soap-env:Body>
      > and send it to server. The same with server - receive pure XML message
      > and response with
      > another XML message.
      > I can't find any solution in the docs.
      > --
      > Thanks in advance for an answer, regards,
      > Lech
      > Yahoo! Groups Sponsor
      > Click Here for a Quote!
      > To unsubscribe from this group, send an email to:
      > soaplite-unsubscribe@yahoogroups.com
      > Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.
      Byrne Reese
      Developer Program Manager
      Grand Central Communications
    • Show all 3 messages in this topic