Advertisement:

Author Topic: profilin yaninda konu sayilari nasil görünür  (Read 4776 times)

Offline tecrube85

  • Jr. Member
  • **
  • Posts: 248
profilin yaninda konu sayilari nasil görünür
« on: August 26, 2007, 02:34:51 PM »
Üyelerin avatarlarinin ve mesaj sayilarinin yazdiği yerin hemen altinda üyelerin açmiş olduğu konu sayisininda görünmesini istiyorum

bunu yapmak mümkün müdür acaba ?

Mümkünse Nasil ?

Yardimlarinizi bekliyorum . şimdiden teşekkür ederim
« Last Edit: August 26, 2007, 04:46:26 PM by oyunsiteniz »

Offline tecrube85

  • Jr. Member
  • **
  • Posts: 248
Re: profilin yaninda konu sayilari nasil görünür
« Reply #1 on: August 28, 2007, 02:57:25 PM »
2 gündür cevap veren olmamiş . konu arka sayfalara gitti bayaği


Bunun nasil yapilacağini bilen yok mu arkadaşlar ?

yardimlarinizi bekliorm

Offline Shean

  • Jr. Member
  • **
  • Posts: 398
  • Gender: Male
    • Myanimelist
Re: profilin yaninda konu sayilari nasil görünür
« Reply #2 on: August 28, 2007, 06:01:34 PM »
böyle bir şey var profildeki ek bilgiden ulaşılır

Offline tecrube85

  • Jr. Member
  • **
  • Posts: 248
Re: profilin yaninda konu sayilari nasil görünür
« Reply #3 on: August 29, 2007, 08:15:33 AM »
böyle bir şey var profildeki ek bilgiden ulaşılır

profildeki ek bilgi derken neyi kastettin . biraz daha açar misin kardeş

Offline tecrube85

  • Jr. Member
  • **
  • Posts: 248
Re: profilin yaninda konu sayilari nasil görünür
« Reply #4 on: September 05, 2007, 05:09:40 PM »
Flood yapmak istemiyorum ama konum çok aşağilara gidiyor . böyle olunca da kimse görüp mesaj yollamiyor

aradan 6 gün geçti .


bilen yok mu acaba nasil yapildiğini ?

Offline Yağız...

  • SMF Super Hero
  • *******
  • Posts: 10,809
  • Gender: Male
    • MMO Browser
Re: profilin yaninda konu sayilari nasil görünür
« Reply #5 on: September 05, 2007, 05:26:22 PM »
http://www.simplemachines.org/community/index.php?topic=192745.0
Bu konuda tartistigimiz icin seninki gerilere gidiyor ;)

Offline Abraxas

  • Semi-Newbie
  • *
  • Posts: 57
  • Gender: Male
    • Türkiye'nin Cep Portalı
Re: profilin yaninda konu sayilari nasil görünür
« Reply #6 on: September 05, 2007, 05:27:49 PM »
.......
« Last Edit: September 05, 2007, 06:08:10 PM by Abraxas »

Offline Abraxas

  • Semi-Newbie
  • *
  • Posts: 57
  • Gender: Male
    • Türkiye'nin Cep Portalı
Re: profilin yaninda konu sayilari nasil görünür
« Reply #7 on: September 05, 2007, 05:54:19 PM »
Modu kendi sitemde kuruludur.. isteyenler linke örnek olarak bakabilir.

http://forumalemi.net/index.php?topic=5.0



şunu buldum hocam... belki buda işine yarar.



profil bölümünden herkes görebilir.Üye profilinde 2 yerde çıkacak butonlar
Sources/Profile.php yi aç bul

Code: [Select]
// Show all posts by the current user
function showPosts($memID)
{
Öncesine ekle

Code: [Select]
// Show all topics by the current user <><><><><><><><><><><><><><><>
function showTopics($memID)
{
global $txt, $user_info, $scripturl, $modSettings, $db_prefix;
global $context, $user_profile, $ID_MEMBER, $sourcedir;

// If just deleting a message, do it and then redirect back.
if (isset($_GET['delete']))
{
checkSession('get');

// We can be lazy, since removeMessage() will check the permissions for us.
require_once($sourcedir . '/RemoveTopic.php');
removeMessage((int) $_GET['delete']);

// Back to... where we are now ;).
redirectexit('action=profile;u=' . $memID . ';sa=showTopics;start=' . $_GET['start']);
}

// Is the load average too high to allow searching just now?
if (!empty($context['load_average']) && !empty($modSettings['loadavg_show_posts']) && $context['load_average'] >= $modSettings['loadavg_show_posts'])
fatal_lang_error('loadavg_show_posts_disabled', false);

// Default to 10.
if (empty($_REQUEST['viewscount']) || !is_numeric($_REQUEST['viewscount']))
$_REQUEST['viewscount'] = '10';

// If this is a large forum, try a temporary table.
if ($modSettings['totalMessages'] > 100000 && $user_profile[$memID]['posts'] > 100)
{
db_query("
DROP TABLE IF EXISTS {$db_prefix}topics_posted_in", false, false);

// Let's try to avoid as many locks as possible.
$have_temp_table = db_query("
CREATE TEMPORARY TABLE {$db_prefix}topics_posted_in (
PRIMARY KEY (ID_TOPIC)
)
SELECT ID_TOPIC, ID_BOARD
FROM {$db_prefix}messages
WHERE ID_MEMBER = $memID
GROUP BY ID_TOPIC", false, false);
}

// The join on topics here, although unnecessary, forces the use of the participation index.
$request = db_query("
SELECT COUNT(m.ID_MSG)
FROM ({$db_prefix}messages AS m, {$db_prefix}topics AS t, {$db_prefix}boards AS b)
WHERE m.ID_MEMBER = $memID
AND t.ID_TOPIC = m.ID_TOPIC
AND b.ID_BOARD = t.ID_BOARD
AND t.ID_FIRST_MSG = m.ID_MSG
AND $user_info[query_see_board]", __FILE__, __LINE__);
list ($msgCount) = mysql_fetch_row($request);
mysql_free_result($request);

// View all the topics, or just a few?
$maxIndex = isset($_REQUEST['view']) && $_REQUEST['view'] == 'all' ? $msgCount : $modSettings['defaultMaxMessages'];

// Make sure the starting place makes sense and construct our friend the page index.
$context['page_index'] = constructPageIndex($scripturl . '?action=profile;u=' . $memID . ';sa=showTopics', $_REQUEST['start'], $msgCount, $maxIndex);
$context['start'] = $_REQUEST['start'];
$context['current_page'] = $context['start'] / $maxIndex;
$context['current_member'] = $memID;

$context['page_title'] = $txt[4582] . ' ' . $user_profile[$memID]['realName'];

// Find this user's posts.  The left join on categories somehow makes this faster, weird as it looks.
// !!!SLOW This query uses a filesort.
$request = db_query("
SELECT
b.ID_BOARD, b.name AS bname, c.ID_CAT, c.name AS cname, m.ID_TOPIC, m.ID_MSG,
t.ID_MEMBER_STARTED, t.ID_FIRST_MSG, t.ID_LAST_MSG, m.body, m.smileysEnabled,
m.subject, m.posterTime
FROM (" . (empty($have_temp_table) ? '' : "{$db_prefix}topics_posted_in AS pi, ") . "{$db_prefix}messages AS m, {$db_prefix}topics AS t, {$db_prefix}boards AS b)
LEFT JOIN {$db_prefix}categories AS c ON (c.ID_CAT = b.ID_CAT)
WHERE " . (empty($have_temp_table) ? '' : "t.ID_TOPIC = pi.ID_TOPIC
AND ") . "m.ID_MEMBER = $memID
AND m.ID_TOPIC = t.ID_TOPIC
AND t.ID_BOARD = b.ID_BOARD
AND $user_info[query_see_board]
AND t.ID_FIRST_MSG = m.ID_MSG
ORDER BY m.ID_MSG DESC
LIMIT $_REQUEST[start], $maxIndex", __FILE__, __LINE__);
// Start counting at the number of the first message displayed.
$counter = $_REQUEST['start'];
$context['posts'] = array();
$board_ids = array('own' => array(), 'any' => array());
while ($row = mysql_fetch_assoc($request))
{
// Censor....
censorText($row['body']);
censorText($row['subject']);

 if ($row["ID_FIRST_MSG"] == $row["ID_MSG"]) {

// Do the code.
$row['body'] = parse_bbc($row['body'], $row['smileysEnabled'], $row['ID_MSG']);
// And the array...
$context['posts'][++$counter] = array(
'body' => $row['body'],
'counter' => $counter,
'category' => array(
'name' => $row['cname'],
'id' => $row['ID_CAT']
),
'board' => array(
'name' => $row['bname'],
'id' => $row['ID_BOARD']
),
'topic' => $row['ID_TOPIC'],
'subject' => $row['subject'],
'start' => 'msg' . $row['ID_MSG'],
'time' => timeformat($row['posterTime']),
'timestamp' => forum_time(true, $row['posterTime']),
'id' => $row['ID_MSG'],
'can_reply' => false,
'can_mark_notify' => false,
'can_delete' => false,
'delete_possible' => ($row['ID_FIRST_MSG'] != $row['ID_MSG'] || $row['ID_LAST_MSG'] == $row['ID_MSG']) && (empty($modSettings['edit_disable_time']) || $row['posterTime'] + $modSettings['edit_disable_time'] * 60 >= time()),
);


if ($ID_MEMBER == $row['ID_MEMBER_STARTED'])
$board_ids['own'][$row['ID_BOARD']][] = $counter;
$board_ids['any'][$row['ID_BOARD']][] = $counter;
}


}
mysql_free_result($request);

// These are all the permissions that are different from board to board..
$permissions = array(
'own' => array(
'post_reply_own' => 'can_reply',
'delete_own' => 'can_delete',
),
'any' => array(
'post_reply_any' => 'can_reply',
'mark_any_notify' => 'can_mark_notify',
'delete_any' => 'can_delete',
)
);

// For every permission in the own/any lists...
foreach ($permissions as $type => $list)
foreach ($list as $permission => $allowed)
{
// Get the boards they can do this on...
$boards = boardsAllowedTo($permission);

// Hmm, they can do it on all boards, can they?
if (!empty($boards) && $boards[0] == 0)
$boards = array_keys($board_ids[$type]);

// Now go through each board they can do the permission on.
foreach ($boards as $board_id)
{
// There aren't any posts displayed from this board.
if (!isset($board_ids[$type][$board_id]))
continue;

// Set the permission to true ;).
foreach ($board_ids[$type][$board_id] as $counter)
$context['posts'][$counter][$allowed] = true;
}
}

// Clean up after posts that cannot be deleted.
foreach ($context['posts'] as $counter => $dummy)
$context['posts'][$counter]['can_delete'] &= $context['posts'][$counter]['delete_possible'];
}

// <><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><>

bul
      
Code: [Select]
'showPosts' => array(array('profile_view_any', 'profile_view_own'), array('profile_view_any')),Sonrasına ekle

      
Code: [Select]
'showTopics' => array(array('profile_view_any', 'profile_view_own'), array('profile_view_any')),
bul
         
Code: [Select]
$context['profile_areas']['info']['areas']['showPosts'] = '<a href="' . $scripturl . '?action=profile;u=' . $memID . ';sa=showPosts">' . $txt['showPosts'] . '</a>';Sonrasına ekle

         
Code: [Select]
$context['profile_areas']['info']['areas']['showTopics'] = '<a href="' . $scripturl . '?action=profile;u=' . $memID . ';sa=showTopics">' . $txt['showTopics'] . '</a>';         

languages/Profile.turkish.php yi aç bul
   
Code: [Select]
$txt[461] = 'son mesajları göster';Sonrasına ekle

Code: [Select]
$txt[462] = 'son konuları göster';
bul
Code: [Select]
$txt[458] = 'Son gönderdiği mesajlar: ';Sonrasına ekle

Code: [Select]
$txt[4582] = 'Son Açtığı Konular: ';
bul
Code: [Select]
$txt['showPosts'] = 'Mesajları Göster';Sonrasına ekle

Code: [Select]
$txt['showTopics'] = 'Konuları Göster';
Profile.template.php yi aç
Bul

Code: [Select]
// Template for showing all the posts of the user, in chronological order.
function template_showPosts()
{
Öncesine ekle

Code: [Select]
// Template for showing all the posts of the user, in chronological order.  <><><><><><><><><>
function template_showTopics()
{
global $context, $settings, $options, $scripturl, $modSettings, $txt;

echo '
<table border="0" width="85%" cellspacing="1" cellpadding="4" class="bordercolor" align="center">
<tr class="titlebg">
<td colspan="3" height="26">
&nbsp;<img src="', $settings['images_url'], '/icons/profile_sm.gif" alt="" align="top" />&nbsp;', $txt['showTopics'], '
</td>
</tr>';

// Only show posts if they have made some!
if (!empty($context['posts']))
{
// Page numbers.
echo '
<tr class="catbg3">
<td colspan="3">
', $txt[139], ': ', $context['page_index'], '
</td>
</tr>
</table>';

// Button shortcuts
$quote_button = create_button('quote.gif', 145, 'smf240', 'align="middle"');
$reply_button = create_button('reply_sm.gif', 146, 146, 'align="middle"');
$remove_button = create_button('delete.gif', 121, 31, 'align="middle"');
$notify_button = create_button('notify_sm.gif', 131, 125, 'align="middle"');

// For every post to be displayed, give it its own subtable, and show the important details of the post.
foreach ($context['posts'] as $post)
{
echo '
<table border="0" width="85%" cellspacing="1" cellpadding="0" class="bordercolor" align="center">
<tr>
<td width="100%">
<table border="0" width="100%" cellspacing="0" cellpadding="4" class="bordercolor" align="center">
<tr class="titlebg2">
<td style="padding: 0 1ex;">
', $post['counter'], '
</td>
<td width="75%" class="middletext">
&nbsp;<a href="', $scripturl, '#', $post['category']['id'], '">', $post['category']['name'], '</a> / <a href="', $scripturl, '?board=', $post['board']['id'], '.0">', $post['board']['name'], '</a> / <a href="', $scripturl, '?topic=', $post['topic'], '.', $post['start'], '#msg', $post['id'], '">', $post['subject'], '</a>
</td>
<td class="middletext" align="right" style="padding: 0 1ex; white-space: nowrap;">
', $txt[30], ': ', $post['time'], '
</td>
</tr>
<tr>
<td width="100%" height="80" colspan="3" valign="top" class="windowbg2">
<div class="post">', $post['body'], '</div>
</td>
</tr>
<tr>
<td colspan="3" class="windowbg2" align="', !$context['right_to_left'] ? 'right' : 'left', '"><span class="middletext">';

if ($post['can_delete'])
echo '
<a href="', $scripturl, '?action=profile;u=', $context['current_member'], ';sa=showPosts;start=', $context['start'], ';delete=', $post['id'], ';sesc=', $context['session_id'], '" onclick="return confirm(\'', $txt[154], '?\');">', $remove_button, '</a>';
if ($post['can_delete'] && ($post['can_mark_notify'] || $post['can_reply']))
echo '
', $context['menu_separator'];
if ($post['can_reply'])
echo '
<a href="', $scripturl, '?action=post;topic=', $post['topic'], '.', $post['start'], '">', $reply_button, '</a>', $context['menu_separator'], '
<a href="', $scripturl, '?action=post;topic=', $post['topic'], '.', $post['start'], ';quote=', $post['id'], ';sesc=', $context['session_id'], '">', $quote_button, '</a>';
if ($post['can_reply'] && $post['can_mark_notify'])
echo '
', $context['menu_separator'];
if ($post['can_mark_notify'])
echo '
<a href="' . $scripturl . '?action=notify;topic=' . $post['topic'] . '.' . $post['start'] . '">' . $notify_button . '</a>';

echo '
</span></td>
</tr>
</table>
</td>
</tr>
</table>';
}

// Show more page numbers.
echo '
<table border="0" width="85%" cellspacing="1" cellpadding="4" class="bordercolor" align="center">
<tr>
<td colspan="3" class="catbg3">
', $txt[139], ': ', $context['page_index'], '
</td>
</tr>
</table>';
}
// No posts? Just end the table with a informative message.
else
echo '
<tr class="windowbg2">
<td>
', $txt[170], '
</td>
</tr>
</table>';
}

// <><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><>

bul
         
Code: [Select]
<a href="', $scripturl, '?action=profile;u=', $context['member']['id'], ';sa=showPosts">', $txt[460], ' ', $txt[461], '.</a><br />Sonrasına ekle

         
Code: [Select]
<a href="', $scripturl, '?action=profile;u=', $context['member']['id'], ';sa=showTopics">', $txt[460], ' ', $txt[462], '.</a><br />

/////////////////////////////////////////

edit: son eklentim. üyenin mesaj yazdığı alanındaki profile açtığı konulara link vermek için


yukarıdaki işlemleri yaptıktan sonra

index.turkish.php.de bul

Code: [Select]
$txt[24] = '(Konu Yok)';
$txt[26] = 'Mesaj Say&yacute;s&yacute;';

altına ekle
Code: [Select]
$txt[266] = 'Açtığı Konular';

display . template.php de

bul

Code: [Select]
// Show how many posts they have made.
echo '
', $txt[26], ': ', $message['member']['posts'], '<br />
<br />';

altına ekle

Code: [Select]
// uyenin actigi konular ivan_
echo '
<a href="', $scripturl, '?action=profile;u=', $message['member']['id'], ';sa=showTopics">', $txt[266], '</a><br />
<br />';






« Last Edit: September 05, 2007, 06:09:51 PM by Abraxas »

Offline Yağız...

  • SMF Super Hero
  • *******
  • Posts: 10,809
  • Gender: Male
    • MMO Browser
Re: profilin yaninda konu sayilari nasil görünür
« Reply #8 on: September 06, 2007, 01:29:04 AM »
Bu cok baska birsey.Bu konulari gosteriyor.Biz konu sayilarini istiyoruz ;)

Offline tecrube85

  • Jr. Member
  • **
  • Posts: 248
Re: profilin yaninda konu sayilari nasil görünür
« Reply #9 on: September 13, 2007, 01:25:42 PM »
evet . konu sayisini gösteren bi kod vs olsaydi iyi olurdu

Bu cok baska birsey.Bu konulari gosteriyor.Biz konu sayilarini istiyoruz ;)

Offline <<<C@nZéY>>>

  • Semi-Newbie
  • *
  • Posts: 74
  • Gender: Male
    • Kantin
Re: profilin yaninda konu sayilari nasil görünür
« Reply #10 on: December 09, 2007, 06:28:10 AM »
ewet arkadaşlar suan sitemde sistemim konu sayısına göre işliyor yani konu açan üyelere ayrıcalık yapıyoruz yani konu sayısı gözükse orda üyeleri konu açmaya teşvik etsek

Offline Yağız...

  • SMF Super Hero
  • *******
  • Posts: 10,809
  • Gender: Male
    • MMO Browser
Re: profilin yaninda konu sayilari nasil görünür
« Reply #11 on: December 09, 2007, 06:34:19 AM »