Gönderen Konu: Advanced Recent Posts / Topics  (Okunma sayısı 4080 defa)

0 Üye ve 1 Ziyaretçi konuyu incelemekte.

Çevrimdışı Balaban

  • SGT-Admin
  • *
  • İleti: 3804
  • PR ( Rep ) : 117
  • Cinsiyet: Bay
    • Metal Vids
Advanced Recent Posts / Topics
« : SmfGrup Saati : 13 Ekim Pzt 2008, 00:15 »
Mod Nam  Gelişmiş Yeni Konular/Başlıklar
Mod's Links :   Mod | Manuel
Compatible With: 1.1.4
Created By: Marook

Translated by tarık for SMFGrup

This mod alters the recent posts. Now you will see the message icon, the number of views additional to the standard items (Author, Categorie, Date and Subject).


Installation Instructions for 1.1.x series

$Sourcedir/Recent.php
Find

Kod: [Seç]
global $scripturl, $txt, $db_prefix, $user_info, $modSettings, $func; // Find all the posts. Newer ones will have higher IDs. (assuming the last 20 * number are accessable...) // !!!SLOW This query is now slow, NEEDS to be fixed. Maybe break into two? $request = db_query(" SELECT m.posterTime, m.subject, m.ID_TOPIC, m.ID_MEMBER, m.ID_MSG, IFNULL(mem.realName, m.posterName) AS posterName, t.ID_BOARD, b.name AS bName, LEFT(m.body, 384) AS body, m.smileysEnabled FROM ({$db_prefix}messages AS m, {$db_prefix}topics AS t, {$db_prefix}boards AS b) LEFT JOIN {$db_prefix}members AS mem ON (mem.ID_MEMBER = m.ID_MEMBER) WHERE m.ID_MSG >= " . max(0, $modSettings['maxMsgID'] - 20 * $showlatestcount) . " AND t.ID_TOPIC = m.ID_TOPIC AND b.ID_BOARD = t.ID_BOARD" . (!empty($modSettings['recycle_enable']) && $modSettings['recycle_board'] > 0 ? " AND b.ID_BOARD != $modSettings[recycle_board]" : ''  . " AND $user_info[query_see_board] ORDER BY m.ID_MSG DESC LIMIT $showlatestcount", __FILE__, __LINE__);
Replace With:

Kod: [Seç]
global $scripturl, $txt, $db_prefix, $user_info, $modSettings, $func, $settings, $ID_MEMBER; // Find all the posts. Newer ones will have higher IDs. (assuming the last 20 * number are accessable...) // !!!SLOW This query is now slow, NEEDS to be fixed. Maybe break into two? if (!empty($modSettings['recent_topics']) && $modSettings['recent_topics']){ $request = db_query(" SELECT m.posterTime, ms.subject, m.ID_TOPIC, m.ID_MEMBER, m.ID_MSG, b.ID_BOARD, b.name AS bName, IFNULL(mem.realName, m.posterName) AS posterName, " . ($user_info['is_guest'] ? '1 AS isRead, 0 AS new_from' : ' IFNULL(lt.ID_MSG, IFNULL(lmr.ID_MSG, 0)) >= m.ID_MSG_MODIFIED AS isRead, IFNULL(lt.ID_MSG, IFNULL(lmr.ID_MSG, -1)) + 1 AS new_from'  . ", LEFT(m.body, 384) AS body, m.smileysEnabled, m.icon, t.numReplies, t.numViews FROM ({$db_prefix}messages AS m, {$db_prefix}topics AS t, {$db_prefix}boards AS b, {$db_prefix}messages AS ms) LEFT JOIN {$db_prefix}members AS mem ON (mem.ID_MEMBER = m.ID_MEMBER)" . (!$user_info['is_guest'] ? " LEFT JOIN {$db_prefix}log_topics AS lt ON (lt.ID_TOPIC = t.ID_TOPIC AND lt.ID_MEMBER = $ID_MEMBER) LEFT JOIN {$db_prefix}log_mark_read AS lmr ON (lmr.ID_BOARD = b.ID_BOARD AND lmr.ID_MEMBER = $ID_MEMBER)" : ''  . " WHERE t.ID_LAST_MSG >= " . ($modSettings['maxMsgID'] - 35 * min($showlatestcount, 5)) . " AND t.ID_LAST_MSG = m.ID_MSG AND b.ID_BOARD = t.ID_BOARD" . (empty($exclude_boards) ? '' : " AND b.ID_BOARD NOT IN (" . implode(', ', $exclude_boards) . " "  . " AND $user_info[query_see_board] AND ms.ID_MSG = t.ID_FIRST_MSG ORDER BY t.ID_LAST_MSG DESC LIMIT $showlatestcount", __FILE__, __LINE__); } else { $request = db_query(" SELECT m.posterTime, m.subject, m.ID_TOPIC, m.ID_MEMBER, m.ID_MSG, IFNULL(mem.realName, m.posterName) AS posterName, t.ID_BOARD, b.name AS bName, LEFT(m.body, 384) AS body, m.smileysEnabled, m.icon, t.numViews, t.numReplies FROM ({$db_prefix}messages AS m, {$db_prefix}topics AS t, {$db_prefix}boards AS b) LEFT JOIN {$db_prefix}members AS mem ON (mem.ID_MEMBER = m.ID_MEMBER) WHERE m.ID_MSG >= " . max(0, $modSettings['maxMsgID'] - 20 * $showlatestcount) . " AND t.ID_TOPIC = m.ID_TOPIC AND b.ID_BOARD = t.ID_BOARD" . (!empty($modSettings['recycle_enable']) && $modSettings['recycle_board'] > 0 ? " AND b.ID_BOARD != $modSettings[recycle_board]" : ''  . " AND $user_info[query_see_board] ORDER BY m.ID_MSG DESC LIMIT $showlatestcount", __FILE__, __LINE__); }
Find

Kod: [Seç]
), 'topic' => $row['ID_TOPIC'],
Add After

Kod: [Seç]
'icon' => file_exists($settings['theme_dir'] . '/images/post/' . $row['icon'] . '.gif'  ? $settings['images_url'] . '/post/' . $row['icon'] . '.gif' : $settings['default_images_url'] . '/post/' . $row['icon'] . '.gif', 'views' => $row['numViews'], 'replies' => $row['numReplies'],
$Themedir/BoardIndex.template.php

Find

Kod: [Seç]
<table cellpadding="0" cellspacing="0" width="100%" border="0">';
Replace With

Kod: [Seç]
<table cellpadding="0" cellspacing="1" width="100%" border="0">  <tr>  <td class="catbg2" style="text-align:left;" colspan="2">', $txt[70] ,'</td>  <td class="catbg2" style="text-align:center;">', $txt[110] ,'</td>  <td class="catbg2" style="text-align:center;">', $txt[301] ,'</td>  <td class="catbg2" style="text-align:center;">', $txt[20] ,'</td>  <td class="catbg2" style="text-align:center;">', $txt[29] ,'</td>  <td class="catbg2" style="text-align:right;">', $txt[317] ,'</td>  </tr>';
Find

Kod: [Seç]
foreach ($context['latest_posts'] as $post) echo ' <tr> <td class="middletext" valign="top"><b>', $post['link'], '</b> ', $txt[525], ' ', $post['poster']['link'], ' (', $post['board']['link'], ' </td> <td class="middletext" align="right" valign="top" nowrap="nowrap">', $post['time'], '</td> </tr>';
Replace With

Kod: [Seç]
$cnt = 0; foreach ($context['latest_posts'] as $post){ $cnt++; $class = ($cnt % 2) ? 'windowbg' : 'windowbg2'; echo ' <tr>  <td class="', $class, '"><img src="', $post['icon'] , '" alt="" /></td>  <td class="', $class, '"" title="', $post['preview'] ,'">', $post['link'], '</td>  <td class="', $class, '"" style="text-align:center;">', $post['replies'], '</td>  <td class="', $class, '"" style="text-align:center;">', $post['views'], '</td> <td class="', $class, '"" style="text-align:center;">',$post['board']['link'], '</td>  <td class="', $class, '"" style="text-align:center;">',$post['poster']['link'], '</td>  <td class="', $class, '"" style="text-align:right;" nowrap="nowrap">', $post['time'], '</td>  </tr>'; }
$Sourrcedir/ModSettings.php

Find

Kod: [Seç]
// Who's online. array('check', 'who_enabled' ,
Add After

Kod: [Seç]
'', // Recent topics ? array('check', 'recent_topics',null, &$txt['recent_topics']),
$Themedir/languages/modsettings.turkish.php

Find

Kod: [Seç]
?>
Add Before

Kod: [Seç]
$txt['recent_topics'] = 'Son konular yerine son başlıkları göster';   
« Son Düzenleme: SmfGrup Saati : 13 Ekim Pzt 2008, 00:16 Gönderen: nuwanda »

Çevrimdışı Sinan ANDIRMAN

  • Sarı Fırtına
  • Sr. Member
  • **
  • İleti: 1035
  • PR ( Rep ) : 26
  • Cinsiyet: Bay
Ynt: Advanced Recent Posts / Topics
« Yanıtla #1 : SmfGrup Saati : 13 Ekim Pzt 2008, 00:30 »
thanks friens for mod

Çevrimdışı KaRaKıZ

  • Sr. Member
  • **
  • İleti: 2191
  • PR ( Rep ) : 22
  • Cinsiyet: Bayan
  • bebek bekliyoruzz(has urfalı)
Ynt: Advanced Recent Posts / Topics
« Yanıtla #2 : SmfGrup Saati : 13 Ekim Pzt 2008, 09:09 »
thanks friens for mod

arkadaş türk türkçe neden konşmuyoruz

saol nuwanda


Translate: friend is turkish,why do we speak turkish?

thanks nuwanda

Edit: You must speak english in this board
« Son Düzenleme: SmfGrup Saati : 13 Ekim Pzt 2008, 09:16 Gönderen: Sinan ANDIRMAN »
Allah tan tek dileğimsin
 

Çevrimdışı Sinan ANDIRMAN

  • Sarı Fırtına
  • Sr. Member
  • **
  • İleti: 1035
  • PR ( Rep ) : 26
  • Cinsiyet: Bay
Ynt: Advanced Recent Posts / Topics
« Yanıtla #3 : SmfGrup Saati : 13 Ekim Pzt 2008, 09:13 »
because this board is english board

Çevrimdışı KaRaKıZ

  • Sr. Member
  • **
  • İleti: 2191
  • PR ( Rep ) : 22
  • Cinsiyet: Bayan
  • bebek bekliyoruzz(has urfalı)
Ynt: Advanced Recent Posts / Topics
« Yanıtla #4 : SmfGrup Saati : 13 Ekim Pzt 2008, 09:17 »
oooooooooo true sory  :D
Allah tan tek dileğimsin
 

Çevrimdışı Sinan ANDIRMAN

  • Sarı Fırtına
  • Sr. Member
  • **
  • İleti: 1035
  • PR ( Rep ) : 26
  • Cinsiyet: Bay
Ynt: Advanced Recent Posts / Topics
« Yanıtla #5 : SmfGrup Saati : 13 Ekim Pzt 2008, 09:21 »
not at all

Çevrimdışı KaRaKıZ

  • Sr. Member
  • **
  • İleti: 2191
  • PR ( Rep ) : 22
  • Cinsiyet: Bayan
  • bebek bekliyoruzz(has urfalı)
Ynt: Advanced Recent Posts / Topics
« Yanıtla #6 : SmfGrup Saati : 13 Ekim Pzt 2008, 09:27 »
thank  :-[
Allah tan tek dileğimsin
 

Çevrimdışı Linkinpark

  • Sr. Member
  • **
  • İleti: 2394
  • PR ( Rep ) : 133
  • Cinsiyet: Bay
  • slaytyeri.blogspot.com
    • janjanlı
Ynt: Advanced Recent Posts / Topics
« Yanıtla #7 : SmfGrup Saati : 18 Ekim Cts 2008, 18:54 »
thanks.
ÖSS BİTTİ SONUNDA :)

Çevrimdışı кнη

  • khaan
  • SMF-Modifikasyon
  • *
  • İleti: 3214
  • PR ( Rep ) : 61
  • Cinsiyet: Bay
    • Smf Grup
  • SMF Sürümü: 1.1.x
Ynt: Advanced Recent Posts / Topics
« Yanıtla #8 : SmfGrup Saati : 19 Ekim Paz 2008, 20:54 »
thanks
Yapamam duramam buralarda..
Bu şehir bana dar geliyor..

Unutup
Seni kalbime gömmek..
Ölümden daha zor geliyor..

Çevrimdışı Neloangelo

  • Yeni Üye
  • *
  • İleti: 245
  • PR ( Rep ) : 12
  • Cinsiyet: Bayan
    • Devil May Cry Türk
Ynt: Advanced Recent Posts / Topics
« Yanıtla #9 : SmfGrup Saati : 30 Ekim Prş 2008, 16:27 »
nuwanda got it !

It is very important Modification. I think everybody likes it but it is 1.1.4  :1S

I cant use it.

Nevermind.

Just Thanks

Çevrimdışı TuTKuN

  • Yeni Üye
  • *
  • İleti: 105
  • PR ( Rep ) : 2
  • Cinsiyet: Bayan
    • http://www.tutkun.net/forum
Ynt: Advanced Recent Posts / Topics
« Yanıtla #10 : SmfGrup Saati : 30 Ekim Prş 2008, 16:35 »
than`x
TutkunLarin Mekani

Çevrimdışı Balaban

  • SGT-Admin
  • *
  • İleti: 3804
  • PR ( Rep ) : 117
  • Cinsiyet: Bay
    • Metal Vids
Ynt: Advanced Recent Posts / Topics
« Yanıtla #11 : SmfGrup Saati : 01 Kasım Cts 2008, 01:12 »

I think everybody likes it but it is 1.1.4

No problem . u can use for 1.1.6 .

Çevrimdışı Neloangelo

  • Yeni Üye
  • *
  • İleti: 245
  • PR ( Rep ) : 12
  • Cinsiyet: Bayan
    • Devil May Cry Türk
Ynt: Advanced Recent Posts / Topics
« Yanıtla #12 : SmfGrup Saati : 01 Kasım Cts 2008, 11:28 »
Mmm Nice. I like it   

Çevrimdışı byburkay

  • FORUM VERi || www.forumveri.com
  • Hero Member
  • ***
  • İleti: 2650
  • PR ( Rep ) : 59
  • Cinsiyet: Bay
  • byburkay
Ynt: Advanced Recent Posts / Topics
« Yanıtla #13 : SmfGrup Saati : 01 Kasım Cts 2008, 11:33 »
Thanks nuwanda!

Çevrimdışı joomlamz

  • Yeni Üye
  • *
  • İleti: 24
  • PR ( Rep ) : 0
  • Cinsiyet: Bay
Ynt: Advanced Recent Posts / Topics
« Yanıtla #14 : SmfGrup Saati : 25 Şubat Çrş 2009, 16:21 »
Good work
thank you