国产探花免费观看_亚洲丰满少妇自慰呻吟_97日韩有码在线_资源在线日韩欧美_一区二区精品毛片,辰东完美世界有声小说,欢乐颂第一季,yy玄幻小说排行榜完本

首頁 > CMS > Discuz > 正文

discuz 帖內調用作者所有帶封面帖子

2024-09-11 09:05:23
字體:
來源:轉載
供稿:網友
目錄 帖內調用作者所有帶封面帖子,可在viewthread.htm中使用。         
<div class="uc-piclist">            <!--{eval $theuid = $_G[forum_thread][authorid]}-->            <!--{eval $authorthreads = DB::fetch_all("SELECT * FROM ".DB::table('forum_thread')." WHERE `authorid`= '$theuid' AND `cover`!=0 ORDER by dateline DESC LIMIT 0,9;");}-->            <ul>                <!--{loop $authorthreads $authorthread}-->                <!--{eval $threadcover = DB::result(DB::query("SELECT attachment FROM ".DB::table('forum_threadimage')." WHERE `tid`= '$authorthread[tid]'"));}-->                <!--{eval $threadfname = DB::result(DB::query("SELECT name FROM ".DB::table('forum_forum')." WHERE `fid`= '$authorthread[fid]'"));}-->                <li>                    <div class="uc-piclist-con-top">                        <div class="uc-thumb">                            <a href="forum.php?mod=viewthread&tid={$authorthread['tid']}" onclick="atarget(this)" title="$authorthread[subject] by admin" class="z">                            <img src="http://file.cmsbj.cn/cmsbj_file/forum/$threadcover" alt="$authorthread[subject] by $authorthread[author]" width="265" height="auto">                            </a>                        </div>                        <div class="uc-title">                            <a href="forum.php?mod=viewthread&tid={$authorthread['tid']}" onclick="atarget(this)" title="$authorthread[subject] by $authorthread[author]" class="uc-title-a"><span>$authorthread[subject]</span></a>                            <div class="uc-title-bg"></div>                        </div>                    </div>                    <div class="uc-piclist-con-bot">                        <div class="uc-stat">                            <span title="查看"><i class="ico-eye-open ico-gray"></i>$authorthread[views]</span>                            <span title="回復"><i class="ico-comment ico-gray"></i>$authorthread[replies]</span>                            <span title="喜歡"><i class="ico-heart ico-gray"></i>$authorthread[favtimes]</span>                            <!--{if $authorthread[digest] > 0}--><span title="精華"><font color=red>精華</font></span><!--{/if}-->                        </div>                        <div class="uc-author">                            <span><!--{echo dgmdate($authorthread[dateline], 'u', '9999', getglobal('setting/dateformat'))}--></span>                            <a href="forum.php?mod=forumdisplay&fid={$authorthread[fid]}" class="uc-forumname" title="TA發表在<!--{$threadfname}-->"><!--{$threadfname}--></a>                        </div>                    </div>                </li>                <!--{/loop}-->            </ul>            <div class="morethreads cl pgbtn"><a href="home.php?mod=space&uid=$authorthread[authorid]" hidefocus="true">去看更多...</a></div>        </div>
根據帖子作者uid查詢帖子,再用獲取到的tid查詢帖子封面表獲取封面。 圖片路徑是遠程附件路徑,本服務器的換成data/attachment/forum/$threadcover 也可縮略圖顯示,loop中加入<!--{eval $imagelistkeys = getforumimg($threadcover, 0, 265, 0); }-->。
發表評論 共有條評論
用戶名: 密碼:
驗證碼: 匿名發表
主站蜘蛛池模板: 沽源县| 阜康市| 遂宁市| 枣阳市| 文成县| 红河县| 龙山县| 桃园市| 金昌市| 财经| 文成县| 建阳市| 府谷县| 黔西| 莲花县| 奉新县| 武汉市| 贵阳市| 西平县| 山东省| 图片| 乐至县| 亳州市| 桃园县| 郓城县| 道真| 大石桥市| 洛阳市| 团风县| 拉萨市| 台南县| 华宁县| 马关县| 博客| 始兴县| 建平县| 岳阳县| 奉节县| 肃北| 靖江市| 双流县|