求助:xml操作
XmlDocument doc = new XmlDocument();doc.LoadXml("<root>" +
"<elem>some text<child>more text</child></elem>" +
"</root>");
XmlNode elem = doc.DocumentElement.FirstChild;
Response.Write(elem.InnerText);//显示innertext的内容
Response.Write(elem.InnerXml);
elem.InnerText = "文本包含<markup/>字符(<)和char()逃脱";
Response.Write(elem.OuterXml);
elem.InnerXml = "Text containing <markup/>.文本包含<markup/>";
Response.Write(elem.OuterXml);
我知道innertext的功能,它显示的是some textmore text
innerXml、后面两个elem.outerxml显示的内容就不太清楚了