Beefy Boxes and Bandwidth Generously Provided by pair Networks
No such thing as a small change
 
PerlMonks  

Soap::Lite set charset

by Anonymous Monk
on Sep 13, 2019 at 18:21 UTC ( [id://11106138]=perlquestion: print w/replies, xml ) Need Help??

Anonymous Monk has asked for the wisdom of the Perl Monks concerning the following question:

Simple question but I can't figure it out.
I want to send iso-8858-5 to a Soap service, but Soap::Lite client defaults to utf8.
How do I change that?

Replies are listed 'Best First'.
Re: Soap::Lite set charset
by poj (Abbot) on Sep 13, 2019 at 20:50 UTC

    Not sure what you mean but try

    $client->encoding('iso-8858-5');
    poj
      The client sends by default "Content-Type: text/xml; charset=utf-8"
      But what if my charset is iso and not utf? Would the server interpret the characters correctly?
      I can't find any instructions on how to chanhe that!
Re: Soap::Lite set charset
by choroba (Cardinal) on Sep 16, 2019 at 11:08 UTC
    Are you sure it's iso-8858-5?
    $ perl -MEncode -wE 'say encode("iso-8858-5", "abc")' Unknown encoding 'iso-8858-5' at -e line 1.

    Maybe you need iso-8859-5?

    map{substr$_->[0],$_->[1]||0,1}[\*||{},3],[[]],[ref qr-1,-,-1],[{}],[sub{}^*ARGV,3]
Re: Soap::Lite set charset
by Anonymous Monk on Sep 13, 2019 at 19:09 UTC
    What?

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: perlquestion [id://11106138]
Approved by Marshall
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others cooling their heels in the Monastery: (4)
As of 2024-04-20 00:27 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found