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

RE: [soaplite] How can I force to output a parameter as a string

Expand Messages
  • Jon Kliegman
    We have to do the same thing on our servers and its easy to do. Use the SOAP::Data constructor to pre-type your value: $value = SOAP::Data- type( string =
    Message 1 of 2 , Jul 20, 2005
    • 0 Attachment
      Message
      We have to do the same thing on our servers and its easy to do.  Use the SOAP::Data constructor to pre-type your value:
       
      $value = SOAP::Data->type('string' => $value);
       
      Or if you've got a hash:
       
      $hash{$key} = SOAP::Data->type('string' => $hash{$key});
       
      Using 'string' (instead of 'xsd:string') will cause the SOAP libraries to still preform the proper encoding for a string so you don't need to do that.
       
      -Jon
      -----Original Message-----
      From: soaplite@yahoogroups.com [mailto:soaplite@yahoogroups.com] On Behalf Of daniel_mirt
      Sent: Wednesday, July 20, 2005 8:04 AM
      To: soaplite@yahoogroups.com
      Subject: [soaplite] How can I force to output a parameter as a string

      I have implemented a web service server in Perl. The response of a
      methode is a complex data type, that also includes a parameter of the
      type number. These paramter should be returned as a string, not as
      number. Is their a possibility, to force a paramter to be a string?



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