AGAMES 討論區

 找回密碼
 快速註冊
搜索
查看: 1885|回復: 0
打印 上一主題 下一主題

小三格-圖片-最新 [複製鏈接]

七級帝王會員

☆Prince★}+}|電腦王子

Rank: 7Rank: 7Rank: 7

帖子
3799
EXP
6040 點
金幣
4990 個
好友
0
註冊時間
2008-3-27

友誼之星勳章

跳轉到指定樓層
樓主
發表於 2008-12-1 19:05:12 |只看該作者 |倒序瀏覽
插件名稱:小三格-圖片-最新
作  者:TCheung
適用版本:DZ6.0 6.1 6.1F
演  示:http://in-city.coms.hk/bbs
功能說明:圖片-最新主題-最後回覆-娛樂設施連接
1.上傳templates資料夾 及 images資料夾 及 picc.php 到論壇更目錄

2.修改index.php
  找:
     

  1. $newthreads = round(($timestamp - $lastvisit + 600) / 1000) * 1000;
複製代碼


  下加:

  1. //新貼//
  2. $hack_cut_str = 20; //修改標題顯示字數
  3. $new_post_threadlist = array();
  4. $nthread = array();
  5. $colorarray = array('', 'red', 'orange', 'yellow', 'green', 'cyan', 'blue', 'purple', 'gray');
  6. $query = $db->query("SELECT t.*, f.name FROM {$tablepre}threads t, {$tablepre}forums f WHERE t.fid<>'$fid' AND f.fid=t.fid ORDER BY t.dateline DESC LIMIT 0, 10");
  7. while($nthread = $db->fetch_array($query)) {
  8.         $nthread['forumname'] = $nthread['name'];
  9.         $nthread['view_subject'] = cutstr($nthread['subject'],$hack_cut_str);
  10. $nthread['date']= gmdate("$dateformat $timeformat", $nthread['dateline'] + $timeoffset * 3600);
  11.         $nthread['lastreplytime']= gmdate("$dateformat $timeformat", $nthread[lastpost] + ($timeoffset * 3600));
  12. if($nthread['highlight']) {
  13.         $string = sprintf('%02d', $nthread['highlight']);
  14.         $stylestr = sprintf('%03b', $string[0]);
  15.         $nthread['highlight'] = 'style="';
  16.         $nthread['highlight'] .= $stylestr[0] ? 'font-weight: bold;' : '';
  17.         $nthread['highlight'] .= $stylestr[1] ? 'font-style: italic;' : '';
  18.         $nthread['highlight'] .= $stylestr[2] ? 'text-decoration: underline;' : '';
  19.         $nthread['highlight'] .= $string[1] ? 'color: '.$colorarray[$string[1]] : '';
  20.         $nthread['highlight'] .= '"';
  21.     } else {
  22.         $nthread['highlight'] = '';
  23.     }

  24.         $new_post_threadlist[] = $nthread;
  25. }
  26. //新貼//
  27. //新回覆
  28. $hack_cut_str = 20; //修改標題顯示字數
  29. $new_reply_threadlist = array();
  30. $rthread = array();
  31. $colorarray = array('', 'red', 'orange', 'yellow', 'green', 'cyan', 'blue', 'purple', 'gray');
  32. $query = $db->query("SELECT t.*, f.name FROM {$tablepre}threads t, {$tablepre}forums f WHERE t.fid<>'$fid' AND f.fid=t.fid  AND t.closed NOT LIKE 'moved|%' AND t.replies !=0 ORDER BY t.lastpost DESC LIMIT 0, 10");
  33. while($rthread = $db->fetch_array($query)) {
  34.         $rthread['forumname'] = $rthread['name'];
  35.         $rthread['view_subject'] = cutstr($rthread['subject'],$hack_cut_str);
  36. $rthread['date']= gmdate("$dateformat $timeformat", $rthread['dateline'] + $timeoffset * 3600);
  37.         $rthread['lastreplytime']= gmdate("$dateformat $timeformat", $rthread[lastpost] + ($timeoffset * 3600));
  38. if($rthread['highlight']) {
  39.         $string = sprintf('%02d', $rthread['highlight']);
  40.         $stylestr = sprintf('%03b', $string[0]);
  41.         $rthread['highlight'] = 'style="';
  42.         $rthread['highlight'] .= $stylestr[0] ? 'font-weight: bold;' : '';
  43.         $rthread['highlight'] .= $stylestr[1] ? 'font-style: italic;' : '';
  44.         $rthread['highlight'] .= $stylestr[2] ? 'text-decoration: underline;' : '';
  45.         $rthread['highlight'] .= $string[1] ? 'color: '.$colorarray[$string[1]] : '';
  46.         $rthread['highlight'] .= '"';
  47.     } else {
  48.         $rthread['highlight'] = '';
  49.     }

  50.         $new_reply_threadlist[] = $rthread;
  51. }
  52. //回覆//
複製代碼

3.修改discuz.htm
  找:

  1. <!--{if !empty($insenz['vfstatus'])}--><script type="text/javascript" src="campaign.php?action=list"></script><!--{/if}-->
複製代碼

(或者你想加入3格的位置)
  
  下加:
  1. {template foruminfo}
複製代碼

4:更新緩存 完畢!


需要修改論壇設施連接

1.修改foruminfo.htm
找:
  1. <td width="395" height="8" align="left" valign="top" scope="col"><div align="center"><span class="style1"><a href="http://in-city.coms.hk/bbs/index.php?showforumlist=default" class="style1">傳統風格</a></span> <span class="style3"><a href="http://in-city.coms.hk/bbs/index.php?showforumlist=straightdisplay" class="style1">直排風格</a></span> <a href="http://in-city.coms.hk/bbs/plugin.php?identifier=chat&module=chat" class="style1">論壇聊天</a> <a href="http://in-city.coms.hk/bbs/game.htm" class="style1">論壇熱舞</a> <a href="http://in-city.coms.hk/bbs/plugin.php?identifier=dance_7ree&module=dance_7ree" class="style1">跳舞賺錢</a> <a href="plugin.php?identifier=bank&module=bank" class="style1">社區銀行</a> <span class="style1"><a href="http://5ybbs.net/upload2.php" class="style1">上傳圖片</a></span></div></td>
複製代碼
附件: 你需要登錄才可以下載或查看附件。沒有帳號?快速註冊
Alta Multimedia - OnlineGames:http://www.alta.hk
您需要登錄後才可以回帖 登錄 | 快速註冊

Archiver|手機版|AGAMES 討論區

GMT+8, 2024-9-20 13:38 , Processed in 0.044184 second(s), 11 queries .

Powered by Discuz! X2

© 2001-2011 Comsenz Inc.

回頂部