zoukankan
html css js c++ java
在看discuz nt 1.0。
2.0一直也不推出,前几天看了几篇讨论dnt 1.0的文章,信心倍减。
还是有一些地方看不太懂(没时间去懂?),今天看到一段AdminPage里的代码,有关显示AdminPage里的PageHeader的,看得心一下就凉了。。。
出在也没有办法换其它的论坛了,还有两三个小功能什么时候我能开发得出来啊 :(
觉得自己懂的太少了,效率又低,一直说的“多写代码”去还是写得太少。
public
void
OutPutPageHeader(
string
pagename,
string
adminname)
{
string
opname
=
""
;
string
headerStr
=
""
;
根据当前页面名称显示相应的提示信息
#region
根据当前页面名称显示相应的提示信息
switch
(pagename.ToLower())
{
case
"
shortcut.aspx
"
:
opname
=
"
快捷操作
"
;
break
;
case
"
setting.aspx
"
:
opname
=
"
快速设置向导
"
;
break
;
case
"
systeminf.aspx
"
:
opname
=
"
系统信息
"
;
break
;
case
"
baseset.aspx
"
:
opname
=
"
基本设置
"
;
break
;
case
"
registerandvisit.aspx
"
:
opname
=
"
注册与访问控制
"
;
break
;
case
"
uiandshowstyle.aspx
"
:
opname
=
"
界面与显示方式
"
;
break
;
case
"
searchengine.aspx
"
:
opname
=
"
搜索引擎优化
"
;
break
;
case
"
forumfunction.aspx
"
:
opname
=
"
论坛功能
"
;
break
;
case
"
scoreset.aspx
"
:
opname
=
"
积分设置
"
;
break
;
case
"
safecontrol.aspx
"
:
opname
=
"
安全控制
"
;
break
;
case
"
timespan.aspx
"
:
opname
=
"
时间段设置
"
;
break
;
case
"
userrights.aspx
"
:
opname
=
"
用户权限
"
;
break
;
case
"
attach.aspx
"
:
opname
=
"
附件设置
"
;
break
;
case
"
other.aspx
"
:
opname
=
"
其他设置
"
;
break
;
case
"
urlgrid.aspx
"
:
opname
=
"
伪静态url的替换规则
"
;
break
;
case
"
detachtable.aspx
"
:
opname
=
"
分表设置
"
;
break
;
case
"
forumstree.aspx
"
:
opname
=
"
版块管理
"
;
break
;
case
"
forumcombination.aspx
"
:
opname
=
"
论坛合并
"
;
break
;
case
"
forumsmove.aspx
"
:
opname
=
"
移动论坛
"
;
break
;
case
"
forumsgrid.aspx
"
:
opname
=
"
手动调整版块
"
;
break
;
case
"
updateforumstatic.aspx
"
:
opname
=
"
论坛数据维护
"
;
break
;
case
"
addfirstforum.aspx
"
:
opname
=
"
添加版块
"
;
break
;
case
"
addforums.aspx
"
:
opname
=
"
添加版块
"
;
break
;
case
"
editforums.aspx
"
:
opname
=
"
编辑版块
"
;
break
;
case
"
delforums.aspx
"
:
opname
=
"
删除版块
"
;
break
;
case
"
forumbatchset.aspx
"
:
opname
=
"
论坛设置复制
"
;
break
;
case
"
scorestrategy.aspx
"
:
opname
=
"
积分策略
"
;
break
;
case
"
addusergroup.aspx
"
:
opname
=
"
用户组添加
"
;
break
;
case
"
addusergroupspecial.aspx
"
:
opname
=
"
特殊组添加
"
;
break
;
case
"
addadminusergroup.aspx
"
:
opname
=
"
管理组添加
"
;
break
;
case
"
usergroupgrid.aspx
"
:
opname
=
"
用户组编辑
"
;
break
;
case
"
editusergroup.aspx
"
:
opname
=
"
用户组编辑
"
;
break
;
case
"
usergroupspecialgrid.aspx
"
:
opname
=
"
特殊组组编辑
"
;
break
;
case
"
editusergroupspecial.aspx
"
:
opname
=
"
特殊组编辑
"
;
break
;
case
"
adminusergroupgrid.aspx
"
:
opname
=
"
管理组编辑
"
;
break
;
case
"
editadminusergroup.aspx
"
:
opname
=
"
管理组编辑
"
;
break
;
case
"
editsysadminusergroup.aspx
"
:
opname
=
"
系统组编辑
"
;
break
;
case
"
sysadminusergroupgrid.aspx
"
:
opname
=
"
系统组编辑
"
;
break
;
case
"
combinationusergroup.aspx
"
:
opname
=
"
组合并
"
;
break
;
case
"
allowparticipatescore.aspx
"
:
opname
=
"
允许的评分范围
"
;
break
;
case
"
adduser.aspx
"
:
opname
=
"
添加用户
"
;
break
;
case
"
usergrid.aspx
"
:
opname
=
"
编辑用户
"
;
break
;
case
"
edituser.aspx
"
:
opname
=
"
编辑用户
"
;
break
;
case
"
combinationuser.aspx
"
:
opname
=
"
合并用户
"
;
break
;
case
"
emailconfig.aspx
"
:
opname
=
"
邮箱设置
"
;
break
;
case
"
usergroupsendemail.aspx
"
:
opname
=
"
批量邮件发送
"
;
break
;
case
"
sendsmtogroup.aspx
"
:
opname
=
"
批量短消息发送
"
;
break
;
case
"
givemedals.aspx
"
:
opname
=
"
勋章编辑
"
;
break
;
case
"
resetpassword.aspx
"
:
opname
=
"
重设用户密码
"
;
break
;
case
"
auditnewtopic.aspx
"
:
opname
=
"
审核主题
"
;
break
;
case
"
auditpost.aspx
"
:
opname
=
"
审核帖子
"
;
break
;
case
"
audittopicgrid.aspx
"
:
opname
=
"
主题回收站
"
;
break
;
case
"
auditingtopic.aspx
"
:
opname
=
"
主题回收站
"
;
break
;
case
"
audituser.aspx
"
:
opname
=
"
审核新用户
"
;
break
;
case
"
bbcodegrid.aspx
"
:
opname
=
"
Discuz!NT代码
"
;
break
;
case
"
addbbcode.aspx
"
:
opname
=
"
添加Discuz!NT代码
"
;
break
;
case
"
editbbcode.aspx
"
:
opname
=
"
编辑Discuz!NT代码
"
;
break
;
case
"
wordgrid.aspx
"
:
opname
=
"
词语过滤
"
;
break
;
case
"
smilegrid.aspx
"
:
opname
=
"
表情管理
"
;
break
;
case
"
addsmile.aspx
"
:
opname
=
"
添加表情
"
;
break
;
case
"
iconfilegrid.aspx
"
:
opname
=
"
图标管理
"
;
break
;
case
"
addiconfile.aspx
"
:
opname
=
"
添加图标
"
;
break
;
case
"
attachtypesgrid.aspx
"
:
opname
=
"
附件类型尺寸
"
;
break
;
case
"
templatesgrid.aspx
"
:
opname
=
"
模版管理
"
;
break
;
case
"
templatetree.aspx
"
:
opname
=
"
模版管理
"
;
break
;
case
"
templatesedit.aspx
"
:
opname
=
"
模版管理
"
;
break
;
case
"
templatevariable.aspx
"
:
opname
=
"
模版变量列表
"
;
break
;
case
"
announcegrid.aspx
"
:
opname
=
"
论坛公告
"
;
break
;
case
"
addannounce.aspx
"
:
opname
=
"
公告添加
"
;
break
;
case
"
editannounce.aspx
"
:
opname
=
"
公告编辑
"
;
break
;
case
"
advsgrid.aspx
"
:
opname
=
"
广告管理
"
;
break
;
case
"
addadvs.aspx
"
:
opname
=
"
广告添加
"
;
break
;
case
"
editadvs.aspx
"
:
opname
=
"
广告编辑
"
;
break
;
case
"
medalgrid.aspx
"
:
opname
=
"
勋章列表
"
;
break
;
case
"
addmedal.aspx
"
:
opname
=
"
勋章添加
"
;
break
;
case
"
onlinelistgrid.aspx
"
:
opname
=
"
在线列表订制
"
;
break
;
case
"
uploadonlieninco.aspx
"
:
opname
=
"
用户在线图例列表
"
;
break
;
case
"
forumlinksgrid.aspx
"
:
opname
=
"
友情链接列表
"
;
break
;
case
"
avatargrid.aspx
"
:
opname
=
"
论坛头像列表
"
;
break
;
case
"
uploadavatar.aspx
"
:
opname
=
"
上传论坛头像
"
;
break
;
case
"
runsql.aspx
"
:
opname
=
"
运行指定的SQL语句
"
;
break
;
case
"
dbtableinf.aspx
"
:
opname
=
"
数据库结构信息
"
;
break
;
case
"
backupandrestore.aspx
"
:
opname
=
"
数据库信息备份与恢复
"
;
break
;
case
"
logandshrinkdb.aspx
"
:
opname
=
"
数据库日志管理
"
;
break
;
case
"
searchattchment.aspx
"
:
opname
=
"
编辑附件
"
;
break
;
case
"
attchemntgrid.aspx
"
:
opname
=
"
编辑附件
"
;
break
;
case
"
seachtopic.aspx
"
:
opname
=
"
批量主题管理
"
;
break
;
case
"
topicsgrid.aspx
"
:
opname
=
"
批量主题管理
"
;
break
;
case
"
searchpost.aspx
"
:
opname
=
"
批量删贴
"
;
break
;
case
"
postgridmanage.aspx
"
:
opname
=
"
批量删贴
"
;
break
;
case
"
searchsm.aspx
"
:
opname
=
"
请理短消息
"
;
break
;
case
"
postgrid.aspx
"
:
opname
=
"
发贴列表
"
;
break
;
case
"
cachemanage.aspx
"
:
opname
=
"
更新缓存
"
;
break
;
case
"
adminvisitloggrid.aspx
"
:
opname
=
"
后台日志
"
;
break
;
case
"
admincacheloggird.aspx
"
:
opname
=
"
缓存日志
"
;
break
;
case
"
moderatormanagelog.aspx
"
:
opname
=
"
管理日志
"
;
break
;
case
"
ratescorelog.aspx
"
:
opname
=
"
评分日志
"
;
break
;
case
"
medalsloggird.aspx
"
:
opname
=
"
勋章授予日志
"
;
break
;
case
"
paymentloggrid.aspx
"
:
opname
=
"
积分交易日志
"
;
break
;
case
"
editawardtime.aspx
"
:
opname
=
"
新增抽奖
"
;
break
;
}
#endregion
headerStr
=
string
.Format(
"
<table width=\
"
100
%
\
"
border=\
"
0
\
"
cellspacing=\
"
0
\
"
cellpadding=\
"
0
\
"
>
"
+
"
<tr bgcolor=\
"
#FFFFFF\
"
>
"
+
"
<td width=\
"
300
\
"
height=\
"
42
\
"
valign=\
"
bottom\
"
background=\
"
..
/
images
/
fairy.png\
"
>
"
+
"
<table width=\
"
100
%
\
"
border=\
"
0
\
"
cellspacing=\
"
0
\
"
cellpadding=\
"
0
\
"
>
"
+
"
<tr><td width=\
"
50
\
"
> </td>
"
+
"
<td width=\
"
250
\
"
><span style=\
"
color:#
333333
;font
-
size:14px;font
-
family:Tahoma,Verdana\
"
>{0}</span></td>
"
+
"
</tr><tr><td height=\
"
8
\
"
colspan=\
"
2
\
"
></td></tr>
"
+
"
</table>
"
+
"
</td>
"
+
"
<td align=right>当前管理员:{1} <a href=\
"
http:
//
nt.discuz.net/tools/help.aspx\">帮助</a> <a href=\"../logout.aspx\" target=\"_parent\">退出</a> </td>" +
"
</tr>
"
+
"
<tr>
"
+
"
<td height=\
"
1
\
"
colspan=\
"
2
\
"
bgcolor=\
"
#
999999
\
"
></td>
"
+
"
</tr>
"
+
"
</table>
"
,
opname,
"
<a href=../../usercp.aspx title=查看信息 target=_blank>
"
+
adminname
+
"
</a>
"
);
if
(opname
!=
""
)
{
this
.Page.RegisterClientScriptBlock(
"
Form1
"
, headerStr);
}
}
无语不说了。
查看全文
相关阅读:
通过JDBC连接hive
大数据技术Hadoop入门理论系列之一----hadoop生态圈介绍
lightning mdb 源代码分析(5)-事务控制
lightning mdb 源代码分析(4)—MVCC/COW
lightning mdb 源代码分析(1)
lightning mdb 源代码分析(2)
Ubuntu 15.10安装elementary desktop
lightning mdb 源代码分析系列(3)
async和enterproxy控制并发数量
Express4.x API (一):application (译)
原文地址:https://www.cnblogs.com/nonlyli/p/843822.html
最新文章
初学JAVA简记——随机数的产生
Ubuntu 14.04 FTP服务器--vsftpd的安装和配置
CentOs conn mysql
centos minimal net-conn
ubuntu安装配置sublime_text 入门和插件
vbox修改虚拟磁盘大小
ubuntu安装jdk
CentOs中JDK与tomcat配置
CentOs中触摸板配置
ubuntu上架设vsftpd
热门文章
ubuntu下安装Apache+PHP+Mysql
Maximum Entropy Markov Models for Information Extraction and Segmentation
an introduction to conditional random fields
HMM MEMM & label bias
ML的灌水现象
C头文件和源文件的连
C、C++编译,链接,extern链接
四年没更新了
大数据技术hadoop入门理论系列之二—HDFS架构简介
转:值得推荐的C/C++框架和库(真的很强大)
Copyright © 2011-2022 走看看