Hey.. Ugly one.

I have a webmethod that takes a string (which is actually XML), and parses
it.. does some stuff, and returns a success or error code to the caller.
(For the record, the reason it's a string instead of an XmlDocument
parameter or something similar is that originally we couldn't guarantee the
XML would be well-formed... we've since overcome that limitation and if
fixing the bug I'm about to describe involves changing my parameter from
string to something better.. that would be fine.)

At any rate, my problem is that if I get XML like the stuff shown below:

<Login LoginID="&amp;hithere" LoginIDScanned="FALSE"
Result="FAILURE_UNKNOWNUSER"/>

The '&' character in the post causes the data to get chopped in half (I'm
assuming this is because the '&' character is a field delimeter in http)..
Now, should the caller be replacing &'s with %26 before sending? Or is there
something I'm supposed to be doing...

thanks in advance,
~Phill

You can read messages from the DOTNET archive, unsubscribe from DOTNET, or
subscribe to other DevelopMentor lists at http://discuss.develop.com.

Reply via email to