DTcms.Web.UI/DTcms.Web.UI/ManagePage.cs
(开头部分) 3KB这里只显示每个文件的开头 60 行。登录后可以解锁完整代码。
using DTcms.BLL;
using DTcms.Common;
using DTcms.Model;
using System;
using System.Web.UI;
namespace DTcms.Web.UI
{
public class ManagePage : System.Web.UI.Page
{
protected internal DTcms.Model.siteconfig siteConfig;
public ManagePage()
{
base.Load += new EventHandler(this.ManagePage_Load);
this.siteConfig = new DTcms.BLL.siteconfig().loadConfig();
}
private void ManagePage_Load(object sender, EventArgs e)
{
if (!this.IsAdminLogin())
{
base.Response.Write("<script>parent.location.href='" + this.siteConfig.webpath + this.siteConfig.webmanagepath + "/login.aspx'</script>");
base.Response.End();
}
}
public bool IsAdminLogin()
{
bool result;
if (this.Session["dt_session_admin_info"] != null)
{
result = true;
}
else
{
string adminname = Utils.GetCookie("AdminName", "DTcms");
string adminpwd = Utils.GetCookie("AdminPwd", "DTcms");
if (adminname != "" && adminpwd != "")
{
DTcms.BLL.manager bll = new DTcms.BLL.manager();
DTcms.Model.manager model = bll.GetModel(adminname, adminpwd);
if (model != null)
{
this.Session["dt_session_admin_info"] = model;
result = true;
return result;
}
}
result = false;
}
return result;
}
public DTcms.Model.manager GetAdminInfo()
{
DTcms.Model.manager result;
if (this.IsAdminLogin())
{
DTcms.Model.manager model = this.Session["dt_session_admin_info"] as DTcms.Model.manager;
后面还有 68 行代码,购买后查看完整代码
24 小时内免费解锁 3 个项目,之后 1 算力/个。 规则说明
AI 解读 AI
登录后可用,每次 10 算力,解读结果公开显示在下面。
还没有人解读过这个文件。