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

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

Expand Messages
  • Jim Cromie
    I think that should be: $xml_content =~ s/ n?//; # strip the $xml_content =~ s/ n?//; # strip .*? is non-greedy - if youre
    Message 1 of 3 , May 20, 2003
      I think that should be:
      $xml_content =~ s/<\?xml.*?\?>\n?//; # strip the <?xml blah?>
      $xml_content =~ s/<!.*?>\n?//;      # strip

      .*? is non-greedy - if youre operating on a whole-file buffer this could
      be important, but testing would tell you that youve deleted large chunks of your content.
      <>! are not special inside a regex, and dont need escaped.

      Byrne Reese <breese@...> wrote:
      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);

      Do you Yahoo!?
      The New Yahoo! Search - Faster. Easier. Bingo.

    Your message has been successfully submitted and would be delivered to recipients shortly.