This is a normal substitution and *should* happen automatically; &
(like < and >) is an illegal XML character, so it gets encoded as
& in the SOAP XML message and is parsed back out at decode.
However, older versions of SOAP::Lite didn't do this substitution; I
just upgraded all my Ubuntu 6 boxen from 0.66 (the version from the
distribution) to the latest 0.71 from CPAN in order to fix this
specific issue. I'm sure you'll find other SOAP implementations that
don't do this automatically either.
On Jul 4, 2008, at 5:59 AM, Mark Knoop wrote:
> I suspect this may be obvious but I am not clear on what happens
> I have to make a SOAP method call to a 3rd party, passing a return
> URL as
> one of the parameters, and then redirect to the url they give me
> back. They
> then redirect back to the URL I passed them. The URL has GET srtyle
> parameters which I was using ; to seperate as with an older version
> od SOAP
> it just did not work at all with & (also I understand ; is the new
> standard). Unfortunatle we found some circumstances out of our
> control where
> ; breaks things so I changed back to &. Sure enough this broke the
> requests again but before I started askin questions I updated to the
> recent SOAP::Lite module and it appeared to start working. On closer
> examination the QUERY_STRING of the request after the redirection
> back to us
> contains '&'s instead of '&'s.
> Now one thing that confused me is that this does not seem to break
> under all circumstances (I realise this is OT but does anyone know
> if CGI.pm
> auto unescapes & ?)
> However it does seem to be causing weirdnesses in some scenarios.
> So the question is what is the correct way to pass & as a SOAP::Lite
> parameter so that it is interpreted as a & at the server side? Is it
> simple as escaping it before making the SOAP method call? Or is this
> happening automatically? In which case there is nothing I can do to
> get the
> QUERY_STRING correct at source?
> If anyone can explain or point me in the right direction to find out
> what happens behind the scenes with escaping/unescaping characters in
> SOAP::Lite it would really help me to decide the best way of doing