Web/head_top.ascx.cs

(开头部分) 2KB

这里只显示每个文件的开头 60 行。登录后可以解锁完整代码。

using Common;
using System;
using System.Collections;
using System.Collections.Generic;
using System.Linq;
using System.Text.RegularExpressions;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;

namespace Web
{
    public partial class head_top : System.Web.UI.UserControl
    {
        public string ProSum = "0";
        public string PriceSum = "0";
        public int IsShow = 0;
        public Model.Member model = new Model.Member();
        protected void Page_Load(object sender, EventArgs e)
        {
            if (Session["MemberLogin_Id"] != null)
            {
                BLL.Member bll = new BLL.Member();
                model = bll.GetModel(int.Parse(Session["MemberLogin_Id"].ToString()));
                IsShow = 1;
            }
            if (Session["UbuyPriceSum"] != null)
            {
                PriceSum = Session["UbuyPriceSum"].ToString();
            }
            if (Session["UbuyProSum"] != null)
            {
                ProSum = Session["UbuyProSum"].ToString();
            }
        }
        /// <summary>
        /// 返回伪静态统一链接地址
        /// </summary>
        public static string URLRewrite(string _key, params object[] _params)
        {
            Model.WebSet SiteConfig = new BLL.WebSet().loadConfig(Utils.GetXmlMapPath("Configpath"));
            Hashtable _siteurls = new BLL.SiteUrl().loadConfig(Utils.GetXmlMapPath("Urlspath"));
            Model.SiteUrl model = _siteurls[_key] as Model.SiteUrl;
            if (model == null)
            {
                return "";
            }
            try
            {
                string _rewriteurl = string.Format(model.Path, _params);
                int count = SiteConfig.ArticlePageNum_Client;
                if (SiteConfig.IsUrlRewrite == 1)
                {
                    return SiteConfig.WebPath.TrimEnd('/') + _rewriteurl;
                }
                string _originalurl = model.Page;
                if (!string.IsNullOrEmpty(model.QueryString))
                {
                    _originalurl = model.Page + "?" + Regex.Replace(_rewriteurl, model.Pattern, model.QueryString, RegexOptions.None | RegexOptions.IgnoreCase);
                }
后面还有 9 行代码,购买后查看完整代码

24 小时内免费解锁 3 个项目,之后 1 算力/个。 规则说明

AI 解读 AI

登录后可用,每次 10 算力,解读结果公开显示在下面。

还没有人解读过这个文件。