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

2992Re: [soaplite] SOAP::Lite server side input processing

Expand Messages
  • Duncan Cameron
    Sep 12, 2003
      --- Thom Eden <the@...> wrote:
      > Folks,
      >
      > I am trying to write a bit of code on the server side to evaluate the
      > incoming parameters from my client. My incoming XML looks like this:
      >
      > <soap header...>
      > <INPUT_VARIABLES>
      > <Input_var varName="AAA">1</Input_var>
      > <Input_var varName="BBB">Test</Input_var>
      > <Input_var varName="CCC">267</Input_var>
      > <Input_var varName="DDD">Johnson</Input_var>
      > </INPUT_VARIABLES>
      >
      > On the server side, I can grab the array using something like
      >
      > myMethod {
      > my($self, $in) = @_;
      > my @input = @{$in};
      > foreach my $input (@input) {
      > print $input, "\n";
      > }
      > }
      >
      > Unfortunately, I can't seem to get the attribute (varName = ?) out f
      > this. Do I need to coerce the array element into a hash? If this were
      > a SOM object, I could evaluate the attribute using
      > $som->attr{'varName'}...

      You can get the SOM object by inheriting from SOAP::Server::Parameters
      class. See "ACCESSING HEADERS AND ENVELOPE ON SERVER SIDE" in the docs
      for an example.

      Duncan


      ________________________________________________________________________
      Want to chat instantly with your online friends? Get the FREE Yahoo!
      Messenger http://mail.messenger.yahoo.co.uk
    • Show all 3 messages in this topic