请亲们翻译一下页面加载中的这段代码吧?第一次做B/S项目,不是很懂哈~~
protectedvoidPage_Load(objectsender,EventArgse){this.pagesize=webset.ContentPageNum;i...
protected void Page_Load(object sender, EventArgs e)
{
this.pagesize = webset.ContentPageNum;
if (!int.TryParse(Request.Params["page"] as string, out this.page))
{
this.page = 0;
}
if (!int.TryParse(Request.Params["classId"] as string, out this.classId))
{
this.classId = 0;
}
if (!string.IsNullOrEmpty(Request.Params["keywords"]))
{
this.keywords = Request.Params["keywords"].Trim();
}
if (!Page.IsPostBack)
{
chkLoginLevel("viewContents");
//绑定类别
ChannelTreeBind(0, "所有类别", (int)Channel.Fanli, this.ddlClassId);
this.RptBind("Id>0" + CombSqlTxt(this.kindId, this.classId, this.keywords));
}
} 展开
{
this.pagesize = webset.ContentPageNum;
if (!int.TryParse(Request.Params["page"] as string, out this.page))
{
this.page = 0;
}
if (!int.TryParse(Request.Params["classId"] as string, out this.classId))
{
this.classId = 0;
}
if (!string.IsNullOrEmpty(Request.Params["keywords"]))
{
this.keywords = Request.Params["keywords"].Trim();
}
if (!Page.IsPostBack)
{
chkLoginLevel("viewContents");
//绑定类别
ChannelTreeBind(0, "所有类别", (int)Channel.Fanli, this.ddlClassId);
this.RptBind("Id>0" + CombSqlTxt(this.kindId, this.classId, this.keywords));
}
} 展开
1个回答
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询