Chris Curvey wrote: > I'm writing an XMLRPC server, which is receiving a request (from a > non-Python client) that looks like this (formatted for legibility): > > <?xml version="1.0"?> > <methodCall> > <methodName>echo</methodName> > <params> > <param> > <value> > <string>Le Martyre de Saint André <BR> avec inscription > 'Le Dominiquain.' et 'Le tableau fait par le dominicain, > d'après son dessein à... est à Rome, à > l'église Saint André della Valle' sur le > cadre<BR> craie noire, plume et encre brune, lavis brun > rehaussé de blanc sur papier brun<BR> 190 x 228 mm. (7 1/2 x > 9 in.)</string> > </value> > </param> > </params> > </methodCall> > > But when my "echo" method is invoked, the value of the string is: > > Le Martyre de Saint Andr; <BR> avec inscription 'Le Dominiquain.' et > 'Le tableau fait par le dominicain, d'apr:s son dessein 2... est 2 > Rome, 2 l';glise Saint Andr; della Valle' sur le cadre<BR> craie noire, > plume et encre brune, lavis brun rehauss; de blanc sur papier brun<BR> > 190 x 228 mm. (7 1/2 x 9 in.) > > Can anyone give me a lead on how to convert the entity references into > something that will make it through to my method call?
Are you rolling your own XML parser? (Why?) An off-the-shelf parser should take care of this for you. Do you know about xmlrpclib and SimpleXMLRPCServer? Kent -- http://mail.python.org/mailman/listinfo/python-list