Skip to Content.
Sympa Menu

en - RE: [sympa-users] sympa_soap_client.pl and special characters

Subject: The mailing list for listmasters using Sympa

List archive

Chronological Thread  
  • From: Steve Shipway <address@concealed>
  • To: Alexander Bech <address@concealed>, "address@concealed" <address@concealed>
  • Subject: RE: [sympa-users] sympa_soap_client.pl and special characters
  • Date: Wed, 9 Mar 2016 23:17:21 +0000

Title: sympa_soap_client.pl and special characters

Nicely spotted!  UTF8 is a nightmare.

 

This might be necessary in some other places, too.  Definitely happens in 6.1.x, is 6.2 also affected?  I think a lot of these functions were rewritten in 6.2

 

Steve

 

Steve Shipway

T: +64 9 3737 599 ext 86487

E: address@concealed

(

 

From: address@concealed [mailto:address@concealed] On Behalf Of Alexander Bech
Sent: Thursday, 10 March 2016 12:10 p.m.
To: address@concealed
Subject: Re: [sympa-users] sympa_soap_client.pl and special characters

 

Am 18.12.2015 um 22:34 schrieb Alexander Bech:

Hi,

i wrote a bash script to add subscribers to a list from a csv-file.
Works fine with the commands add, setDetails and setCustom.

However, there is a problem with special characters such as "umlaut marks" with add and setCustom commands.

Soap-command add:

sympa_soap_client.pl --trusted_application=soapapp --trusted_application_password=...pwd --soap_url=http://listen.bakarasse.de/sympasoap --service=add
--address@concealed --service_parameters=test5,address@concealed,Jürgen\ Adrian

calling authenticateRemoteAppAndRun( soapapp, detailspwd, address@concealed,add,test5,address@concealed,Jürgen Adrian)

0
    ''

result: gecos is wrong
add


this change in List.pm, sub createXMLCustomAttribute, gives me the
special characters back:

-        $XMLstr .= "<custom_attribute id=\"$k\"><value>".&tools::escape_html($custom_attr->{$k}{value})."</value></custom_attribute>";
+        $XMLstr .= "<custom_attribute id=\"$k\"><value>".Encode::decode_utf8(&tools::escape_html($custom_attr->{$k}{value}))."</value></custom_attribute>";


ok


Thanks,
Alex

Attachment: smime.p7s
Description: S/MIME cryptographic signature




Archive powered by MHonArc 2.6.19+.

Top of Page