discuz修改添加隐藏附件背景图片_附件隐藏美化

方法一:

其实也比较简单,就是修改一下这部分的CSS样式,文件位置在:template/default/common/module.css 大概1041行,可以在这个文件搜索:.locked 即可找到位置,将下面的CSS样式:

.locked { overflow: hidden; margin: 10px 0; padding: 8px 8px 8px 24px; border: 1px dashed #FF9A9A; background: {WRAPBG} url({IMGDIR}/locked.gif) no-repeat 6px 50%; font-size: 12px; zoom: 1; }                .locked:hover background-color: #F7F7F7; }

两边加上/**/ 注释掉,或者直接删除,然后添加下面的代码:

.locked{        margin: 0 auto;    height: 161px;        color: #000;    font-size: 18px;    padding: 0px;    background: #FFF url(图片地址链接) no-repeat right bottom !important;    border-radius: 5px !important;    width: 540px !important;    text-indent: 15px;    line-height: 160px;    overflow: hidden;    -webkit-transition: all 0.3s linear 0s;    -moz-transition: all 0.3s linear 0s;    -o-transition: all 0.3s linear 0s;    transition: all 0.3s linear 0s;                }        .locked:hover{                background: #FFF url(图片地址链接) no-repeat right bottom !important;        }

 

自用方法二:

1、创建yingcang.css文件

.locked{margin: 0 auto;height: 161px;color: #000;font-size: 18px;padding: 0px;background: #FFF url(locked1.jpg) no-repeat right bottom !important;border:1px dashed #F66;width: 540px !important;text-indent: 15px;line-height: 160px;overflow: hidden;-webkit-transition: all 0.3s linear 0s;-moz-transition: all 0.3s linear 0s;-o-transition: all 0.3s linear 0s;transition: all 0.3s linear 0s;}        
.locked:hover{background: #FFF url(lockhover.jpg) no-repeat right bottom !important;}

2、在使用模板forum/viewthread.htm文件引用css

例如:

<link rel="stylesheet" href="{$_G['style']['styleimgdir']}/yincang.css?{VERHASH}" type="text/css" media="all" id="yincang_css">

里面的两个图片地址可以自己修改为喜欢的背景图片,也可以根据需要修改完善这段代码,达到自己的要求!最后更新缓存生效!

示例图片

阅读剩余
THE END