YKT_EShop/Admin/Plus/Picture/Main.cs

(开头部分) 3KB

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

using System;
using System.Collections.Generic;

using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using YKT_EShop._Class;
using System.IO;

namespace YKT_EShop.Admin.Plus.Picture
{
    public partial class Main : System.Web.UI.Page
    {
        protected string backHtml;
        protected string folderPath = HttpContext.Current.Request.QueryString["path"];
        protected System.Text.StringBuilder currPath = new System.Text.StringBuilder("");

        protected int folderNum = 0;
        protected int fileNum = 0;
        protected Repeater rptList;
        protected System.Text.StringBuilder builder = new System.Text.StringBuilder("");

        public string rootPath = "";
        protected void Page_Load(object sender, EventArgs e)
        {
            rootPath = Server.MapPath("~/");
            // 操作处理
            YKT_EShop._Class.FileManagerProcessor fileManage = new YKT_EShop._Class.FileManagerProcessor(Request.QueryString["act"]);
            builder.Append(fileManage.Value);

            if (string.IsNullOrEmpty(folderPath))
            {
                folderPath = Server.MapPath("~/UploadFiles/");
            }

            // 组合路径, 快速导航
            string comePath = "";
            foreach (string q in folderPath.Split('\\'))
            {
                comePath += q;
                currPath.AppendFormat("<a href=\"Main.aspx?path={1}\">{0}</a>", q + "\\", comePath);
                comePath += "\\";
            }

            // 返回上级
            if (new DirectoryInfo(folderPath).Root.ToString().Replace("\\", "") != folderPath.ToUpper())
            {
                string previousFolder = folderPath.Substring(0, folderPath.LastIndexOf("\\"));
                backHtml = "<tr class=\"m-row2\"><td colspan=\"5\"><a href=\"Main.aspx?path=" + Server.UrlEncode(previousFolder) + "\"><img src=\"Images/IcoLeft.gif\" alt=\"返回上级\" align=\"absmiddle\" /> 返回上级</a></td></tr>";
            }
            else
            {
                folderPath += "\\";
            }

            // 绑定数据
            fileManage = new YKT_EShop._Class.FileManagerProcessor();
            List<YKT_EShop._Class.FileFolderInfo> files = fileManage.GetDirectories(folderPath);

            if (fileManage.Access)
后面还有 22 行代码,解锁后查看完整代码

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

AI 解读 AI

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

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