protected override System.Xml.XmlReader GetReaderForMessage(System.Web.Services.Protocols.SoapClientMessage message, int bufferSize)
{
System.Xml.XmlReader reader = base.GetReaderForMessage(message, bufferSize);
if (m_ForceSOAP12)
{
StringBuilder sb = new StringBuilder();
while(reader.Read())
{
sb.AppendLine(reader.ReadOuterXml());
}
/**/
String content = sb.ToString();
content = content.Replace(@"http://schemas.xmlsoap.org/soap/envelope/", @"http://www.w3.org/2003/05/soap-envelope");
content = content.Replace(@"http://schemas.xmlsoap.org/soap/encoding/", @"http://www.w3.org/2003/05/soap-encoding");
/**/
//String content = sb.ToString();
//System.Xml.XmlDocument doc = new System.Xml.XmlDocument();
//doc.Load(reader);
//string content = doc.InnerXml.ToString();
//content = content
// .Replace(@"http://schemas.xmlsoap.org/soap/envelope/", @"http://www.w3.org/2003/05/soap-envelope")
// .Replace(@"http://schemas.xmlsoap.org/soap/encoding/", @"http://www.w3.org/2003/05/soap-encoding");
System.Xml.XmlReader reader2 = System.Xml.XmlReader.Create(new System.IO.StringReader(content));
return reader2;
}
else
{
return reader;
}
}