模版以post开头的部分模版,本部分以发新帖为例子,回复的代码基本相同,只是有些字不同而已
注:附加CSS即没在
css.htm中,而在网页书写中以style=""形式出现的CSS属性
相应位置请参照图
发帖.gif (42.72 KB)
2007-8-21 18:28
1 头部导航文字
所属CSS class或ID:nav
CSS代码: 复制内容到剪贴板 代码:#nav { margin: 10px 5px; }
#nav a { font-weight: bold; color: {HIGHLIGHTLINK}; }
2 预览帖子部分
1 总框架
所属CSS class或ID:mainbox & viewthread(总量很多,下面再次出现的这两个class就不把代码写出来了)
CSS代码:
mainbox部分: 复制内容到剪贴板 代码:.mainbox .headactions { color: {HEADERTEXT}; }
.mainbox .headactions a, .mainbox .headactions span, .mainbox .headactions strong { background: url({IMGDIR}/headactions_line.gif) no-repeat 100% 50%; padding-right: 10px; margin-right: 8px; color: {HEADERTEXT}; }
.mainbox .headactions strong { font-weight: bold; background-image: url({IMGDIR}/arrow_left.gif); }
.mainbox { background: {TABLEBG}; border: {BORDERWIDTH} solid {BORDERCOLOR}; padding: {TABLESPACE}; margin-bottom: {BOXSPACE}; }
.mainbox h1, .mainbox h3, .mainbox h6 { line-height: 31px; padding-left: 1em; {HEADERBGCODE}; background-repeat: repeat-x; background-position: 0 0; color: {HEADERTEXT}; }
.mainbox h1 a, .mainbox h3 a { color: {HEADERTEXT}; }
.mainbox table { width: 100%; }
.mainbox thead th, .mainbox thead td { background: {CATCOLOR}; padding: 2px 5px; line-height: 22px; color: {TEXT}; }
.mainbox thead.category th, .mainbox thead.category td { {CATBGCODE}; }
.mainbox thead.separation th, .mainbox thead.separation td { border-top: 1px solid {BGBORDER} }
.mainbox tbody th, .mainbox tbody td { border-top: 1px solid {BGBORDER}; padding: 5px; }
.mainbox tbody cite, .mainbox tbody em { line-height: 1.3em; }
.mainbox td.postauthor { width: 180px; background: {ALTBG2}; padding: 5px; overflow: hidden; }
.content .mainbox { padding-bottom: 5px; }
.content .mainbox tbody th, .content .mainbox tbody td { border-top: none; border-bottom: 1px solid {BGBORDER}; }
viewthread部分: 复制内容到剪贴板 代码:.viewthread { padding-bottom: 1px; }
.viewthread table, #pmprompt table, #forumlinks, #pmlist, #specialpost { table-layout: fixed; }
.viewthread ins { display: block; text-align: center; text-decoration: none; margin-bottom: 1px; background: {COMMONBOXBG}; border-bottom: 1px solid {CATBORDER}; line-height: 26px; }
.viewthread ins, .viewthread ins a { color: {NOTICETEXT}; }
.viewthread td.postcontent, .viewthread td.postauthor { vertical-align: top; padding: 0 1px; border: none; overflow: hidden; background: {TABLEBG}; }
2 文字class(顶部title请参照总框架中所有h1标记的定义)
1 左部框架
所属CSS class或ID:postauthor
CSS代码: 复制内容到剪贴板 代码:.mainbox td.postauthor { width: 180px; background: {ALTBG2}; padding: 5px; overflow: hidden; }
3 发新话题总框架
所属CSS class或ID:mainbox & formbox
CSS代码(mainbox部分见上)
formbox部分: 复制内容到剪贴板 代码:.formbox th { width: 180px; }
.formbox th, .formbox td { padding: 5px; }
.formbox th, .formbox td { border-bottom: 1px solid {BGBORDER}; }
.formbox table a { color: {HIGHLIGHTLINK}; }
.formbox label { cursor: pointer; }
.formbox th ul { padding: 5px 0; margin: 5px 0; }
#menu li, .popupmenu_popup li, #announcement li, .portalbox li, .tabs li, .postmessage fieldset li, .side li, .formbox li, .notice li { list-style: none; }
.forumlist tbody strong, .threadlist tbody strong , .formbox tbody strong { color: {NOTICETEXT}; }
4 顶部title
1 积分策略说明
所属CSS class或ID:.headactions
CSS代码: 复制内容到剪贴板 代码:.headactions { float: right; line-height: 1em; padding: 10px 10px 0 0; }
.headactions img { vertical-align: middle; cursor: pointer; padding: 0 5px; }
.mainbox .headactions { color: {HEADERTEXT}; }
.mainbox .headactions a, .mainbox .headactions span, .mainbox .headactions strong { background: url({IMGDIR}/headactions_line.gif) no-repeat 100% 50%; padding-right: 10px; margin-right: 8px; color: {HEADERTEXT}; }
.mainbox .headactions strong { font-weight: bold; background-image: url({IMGDIR}/arrow_left.gif); }
.pages_btns { width: 100%; padding: 0 0 8px; overflow: hidden; }
.blockcode .headactions { color: {TEXT}; font-size: {MSGSMALLSIZE}; cursor: pointer; padding-top: 5px; }
.headactions .popupmenu_popup a, .headactions .popupmenu_popup strong { color: {TEXT}; background: none; white-space: nowrap; }
.headactions .popupmenu_popup { width: 120px; }
2 右部title请参照总框架中所有h1标记的定义
5 标题输入部分
1 标题外框
CSS代码:BORDER-BOTTOM-WIDTH: 0px
2 主题分类外框
CSS代码:BORDER-BOTTOM-WIDTH: 0px
3 标题输入框
所属CSS class或ID:threadtypes
CSS代码: 复制内容到剪贴板 代码:#threadtypes table td, #threadtypes table th { border-top: 1px solid {BGBORDER}; border-bottom: 0;}
外部附加CSS: 复制内容到剪贴板 代码:BORDER-TOP-WIDTH: 0px; PADDING-RIGHT: 0px; PADDING-LEFT: 0px; BORDER-LEFT-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; PADDING-BOTTOM: 0px; PADDING-TOP: 0px; BORDER-RIGHT-WIDTH: 0px
6 内容部分
所属CSS class或ID:posteditor_left
无CSS代码
7 smilies
所属CSS class或ID:smilieslist
CSS代码 复制内容到剪贴板 代码:#smilieslist { border: 1px solid {COMMONBOXBORDER}; overflow: hidden; text-align: center; }
#quickpost #smilieslist { margin: 0 1em; }
#smilieslist td { border: none; padding: 8px 0; cursor: pointer; }
#smilieslist td:hover { background: {COMMONBOXBORDER}; }
#smilieslist .pages { float: none; border-width: 1px 0 0; }
8 editor编辑按钮部分
1 总框架
所属CSS class或ID:editor
CSS代码: 复制内容到剪贴板 代码:#editor { border: solid; border-color: {CATBORDER}; border-width: 1px 1px 0; background: {COMMONBOXBG}; }
#editor td { border: none; padding: 2px; }
2 编辑按钮框架
所属CSS class或ID:editortoolbar
CSS代码: 复制内容到剪贴板 代码:.editortoolbar table { width: auto; }
.editortoolbar a, .editortoolbar .a { display: block; padding: 1px; border: 1px solid {COMMONBOXBG}; cursor: pointer; }
.editortoolbar a.hover, .editortoolbar a:hover, .editortoolbar .a1 { background-color: {ALTBG2}; border: 1px solid {BORDERCOLOR}; text-decoration: none; }
9 内容输入部分
1 总框架
所属CSS class或ID:editor_text
CSS代码: 复制内容到剪贴板 代码:.editor_text { border: 1px solid; border-color: {CATBORDER} {CATBORDER} {CATBORDER} {CATBORDER}; }
.editor_text textarea { border: none; width: 99%; font: 12px/1.6em "Courier New", Courier, monospace; }
2 输入部分
标记为textarea,请参照上面的标记部分
附加CSS:WIDTH: 99%; HEIGHT: 250px
textarea控制DISCUZ代码模式的背景颜色
所见即所得模式的背景颜色修改可参照以下方法
查找 复制内容到剪贴板 代码:#wysiwyg { font: {MSGFONTSIZE}/1.6em {FONT} !important; }
将其修改为 复制内容到剪贴板 代码:#wysiwyg { font: {MSGFONTSIZE}/1.6em {FONT} !important; background:{ALTBG2};}
10 上传附件title(请参考总框架中的TH标记)
1 阅读权限及售价部分
所属CSS class或ID:nums
CSS代码: 复制内容到剪贴板 代码:td.nums { width: 80px; text-align: center; }
11 发新话题按钮
控制标签:BUTTON
CSS代码: 复制内容到剪贴板 代码:button { border: 1px solid; border-color: {COMMONBOXBORDER} {LIGHTTEXT} {LIGHTTEXT} {COMMONBOXBORDER}; background: {CATCOLOR}; height: 2em; line-height: 2em; cursor: pointer; }(所有的按钮基本都是这个控制,如首页的快速登陆)
button.submit { margin-right: 1em; border: 1px solid; border-color: #FFFDEE #FDB939 #FDB939 #FFFDEE; background: #FFF8C5; color: {NOTICETEXT}; padding: 0 10px; }(部分提交按钮由这个控制,比如这里的提交按钮,登陆页面的提交等)