zoukankan      html  css  js  c++  java
  • Discuz 首页图文列表实现

    <div id="shoucang">
    
    <!--{eval $list_count=0;}-->
    <!--{loop $threadlist $thread}-->
    <!--{eval $list_count+=1;}-->
    
            <div class="scitem scitemimage show"{if $list_count%3==0}style="margin-right: 0px;"{/if}>
            
            <!--{eval $syaidtable='forum_attachment_'.$thread[tid]%10;}-->
            <!--{eval $fujian=DB::result_first("SELECT `attachment` FROM ".DB::table($syaidtable)." WHERE tid=$thread[tid] AND isimage=1");}-->
            <!--{if $fujian}-->
                <!--{eval $iconurl='data/attachment/forum/'.$fujian}-->
            <!--{else}-->
                <!--{eval $iconurl='static/image/common/nophotosmall.gif'}--> 
            <!--{/if}-->
            
            <a style="text-decoration:underline;color: #000" class="simage" href="forum.php?mod=viewthread&tid=$thread[tid]" target="_blank">
            <img style=" 290px;height:180px" src="$iconurl" onerror='this.src="template/iscwo_design_2013/img/nophoto.gif"' border='0' />
            <div class="simagemask">
                <p>
                    $thread[subject]{echo messagecutstr(strip_tags($thread['post']['message']), 200);}
                </p>
            </div>
            </a>
            
                <div class="simgbody">
                    <div class="simgh">
                        <a href="forum.php?mod=viewthread&tid=$thread[tid]" class="simgtitle" target="_blank">$thread[subject]</a>
            <!--{eval $syaidtable='forum_attachment_'.$thread[tid]%10;}-->
            <!--{eval $fujian=DB::result_first("SELECT `aid` FROM ".DB::table($syaidtable)." WHERE tid=$thread[tid] AND isimage=0");}-->
            <!--{if $fujian}-->
            <a href="forum.php?mod=viewthread&tid=$thread[tid]" class="sylist_fj" title="有附件"  hidefocus="true"></a> 
            <!--{else}-->
            <a href="forum.php?mod=viewthread&tid=$thread[tid]" class="sylist_blank" title="新窗口打开" hidefocus="true" target="_blank"></a> 
            <!--{/if}-->
    
    
                    </div>
                    <div class="clear">
                    </div>
                    
                    <!--<a href="/" target="_blank">视觉设计</a>-->
    </p>
    
                
                    <div class="clear">
                    </div>
                    <div class="simgfoot">
                        <div>
                            <span class="simgdate"></span><span>2013-07-18</span>
                        </div>
    
            <script type="text/javascript" src="{$_G['setting']['jspath']}forum_viewthread.js?{VERHASH}"></script>
            
            
    
                        <p class="itemfoot">
                            <a href="" class="yyicon2 yy2dian"></a><span class="iftxt">$thread[views]</span>
                            <a href="" class="yyicon2 yy2dian"></a><span class="iftxt">$thread[replies]</span>
    
                 <!--{if ($_G['group']['allowrecommend'] || !$_G['uid']) && $_G['setting']['recommendthread']['status']}-->
                <!--{if !empty($_G['setting']['recommendthread']['addtext'])}-->
                        
                            <a id="recommend_add$list_count" class="yyicon2 yy2xiaoxin" hidefocus="true" href="forum.php?mod=misc&action=recommend&do=add&tid=$thread[tid]&hash={FORMHASH}" {if $_G['uid']}onclick="ajaxmenu(this, 3000, 1, 0, '43', 'recommendupdate({$_G['group']['allowrecommend']})');return false;"{else} onclick="showWindow('login', this.href)"{/if} onmouseover="this.title = $('recommendv_add{$list_count}').innerHTML + ' {lang activity_member_unit}喜欢'"><span class="ftishi">添加到我喜欢</span></a>
                            
                            <span class="iftxt">$thread[recommend_add]</span>
                <!--{/if}-->
                            
              <!--{/if}-->
                        </p>
                    </div>
                </div>
                <div class="clear">
                </div>
            </div>
    
    
    <!--{/loop}-->

    <div style="margin-top:20px;" class="wp1024 mbw cl">

    <p class="{if $lastpage && $nextpage}fd_page2{else}fd_page1{/if}">

    <!--{if $lastpage}--><a class="fd_last" href="forum.php?page=$lastpage"></a><!--{/if}-->

    <!--{if $nextpage}--><a class="fd_next" href="forum.php?page=$nextpage"></a><!--{/if}-->

    </p>

    </div>
  • 相关阅读:
    V2热帖:要多健壮的代码才能支撑起千变万化的需求?
    jmeter生成html报告的命令
    jmeter5.x&4.x搭配使用Serveragent 监听服务端性能参数
    springboot关于tomcat的几个默认配置
    nginx日志统计分析-shell
    OpenStack虚拟机VIP配置步骤
    openstack 3.14.3 虚拟机增加指定IP网卡
    OpenStack各组件的常用命令
    Filebeat的Registry文件解读
    一个shell脚本的实践
  • 原文地址:https://www.cnblogs.com/lingzhao/p/3539361.html
Copyright © 2011-2022 走看看