Utility/RSSysConfigManage.cs
(开头部分) 5KB这里只显示每个文件的开头 60 行。登录后可以解锁完整代码。
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Xml;
namespace Utility
{
public class RSSysConfigManage
{
static string appPath = System.Web.HttpContext.Current.Request.ApplicationPath;
/// <summary>
/// 获取xml文档对象
/// </summary>
/// <returns></returns>
public static XmlDocument CreateXmlDoc()
{
XmlDocument xmlDoc = new XmlDocument();
try
{
//xmlDoc.Load(System.Web.HttpContext.Current.Server.MapPath("SMBECms.config"));
xmlDoc.Load(System.Web.HttpContext.Current.Server.MapPath(appPath + "/RenShiSys.config"));
}
catch
{
}
return xmlDoc;
}
/// <summary>
/// 保存xml文档
/// </summary>
/// <param name="xmlDoc"></param>
public static void SaveXmlDoc(XmlDocument xmlDoc)
{
xmlDoc.Save(System.Web.HttpContext.Current.Server.MapPath(appPath + "/RenShiSys.config"));
}
/// <summary>
/// 获取一个节点
/// </summary>
/// <param name="xPath"></param>
/// <returns></returns>
public static XmlNode GetNode(string xPath)
{
XmlDocument xmlDoc = CreateXmlDoc();
XmlNode xn = xmlDoc.SelectSingleNode(xPath);
return xn;
}
/// <summary>
/// 获取所有节点
/// </summary>
/// <param name="xPath"></param>
/// <returns></returns>
public static XmlNodeList GetNodes(string xPath)
{
XmlDocument xmlDoc = CreateXmlDoc();
XmlNodeList xnl = xmlDoc.SelectNodes(xPath);
后面还有 106 行代码,购买后查看完整代码
24 小时内免费解锁 3 个项目,之后 1 算力/个。 规则说明
AI 解读 AI
登录后可用,每次 10 算力,解读结果公开显示在下面。
还没有人解读过这个文件。
