📄 class_active_option.ashx.cs
字号:
using System;
using System.Data;
using System.Web;
using System.Collections;
using System.Web.Services;
using System.Web.Services.Protocols;
using System.Data.SqlClient;
using System.Text;
namespace YXShop.Web.Admin.Article
{
/// <summary>
/// Summary description for $codebehindclassname$
/// </summary>
[WebService(Namespace = "http://tempuri.org/")]
[WebServiceBinding(ConformsTo = WsiProfiles.BasicProfile1_1)]
public class Class_Active_Option : IHttpHandler
{
public void ProcessRequest(HttpContext context)
{
context.Response.ContentType = "text/html";
if (HttpContext.Current.Request["channelId"] != "")
{
string strs = Channel_Class_Menu(HttpContext.Current.Request["channelId"]);
context.Response.Write(strs);
}
}
#region 频道的文章类别
public string Channel_Class_Menu(string channelId)
{
StringBuilder tempStr = new StringBuilder();
tempStr.Append("→顶级类别|0");
SqlDataReader dr =new YXShop.BLL.YixiangChannelClass().SelectChannelClass_Reader(channelId);;
while (dr.Read())
{
string tempText = "";
string spaceStr = "";
for (int i = 1; i < Convert.ToInt32(dr["Class_Depth"]); i++)
{
spaceStr += "";
}
tempText = spaceStr + "┝" + dr[1].ToString();
tempStr.Append("," + tempText + "|" + dr[0].ToString());
}
dr.Close();
return tempStr.ToString();
}
#endregion
public bool IsReusable
{
get
{
return false;
}
}
}
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -