وضعت هذا الهاك في منتدى الأثير منذ فتره:
http://al-atheer.com/vb
يجب عليك اضافة 2 تمبلت Templates جديده..
الاولى اسمِها whoposted وضع فيها الكود التالي:
كود:
<html dir="rtl">
<head>
<title>$bbtitle - تفصيل الردود</title>
$headinclude
</head>
<body bgcolor="#ffffff" text="#000000" rightMargin=0 leftMargin=0 topMargin=0 marginheight="0" marginwidth="0" id=all>
<table cellpadding=4 cellspacing=1 border=0 bgcolor="{tablebordercolor}" width="100%">
<tr>
<td colspan="2" bgcolor="{pagebgcolor}"><FONT face="arial, helvetica" size="3" ><b>مجموع الردود : $totalposts</b></font></B></td>
</tr>
<tr>
<td bgcolor="#E3F1FF" width="100%"><FONT face="arial (arabic)" size="2" ><b>الاسم</b></font></b></td>
<td bgcolor="#E3F1FF"><FONT face="arial (arabic)" size="2" ><b>عدد الردود</b></font></b></td>
</tr>
$posters
</table>
</body>
</html>
والثانيه اسمِها whopostedbit وضع فيها:
كود:
<tr>
<td bgcolor="$backcolor">
<FONT face="arial, helvetica" size="3" >
<a href="member.php?s=$session[sessionhash]&action=getinfo&userid=$post[userid]" target="_blank">$post[username]</a>
</font></B></td>
<td bgcolor="$backcolor"><FONT face="arial, helvetica" size="3" >$post[posts]</font></B></td>
</tr>
الآن افتح التمبلت forumdisplay_threadlist واضف هذا الكود الى بداية الكود الموجود مسبقا:
كود:
<!-- topic table -->
<script language="Javascript">
function who(threadid) {
window.open("whoposted.php?s=$session[sessionhash]&threadid="+threadid, "moo", "toolbar=no,scrollbars=yes,resizable=yes,width=200,height=300");
}
</script>
ثم افتح التمبلت forumdisplaybit وابحث عن الكود:
واستبدله بهذا:
كود:
<a href="javascript:who($thread[threadid])">$thread[replycount]</a>
اخيرا افتح النوتباد Notepad ضع فيها هذا الكود واسمِه whoposted.php ثم حمله الى السيرفر ASCII
كود:
<?php
// whoposted.php
// Kier Darby kier@ap3d.com
// Version 1.0 7.3.2001
$templatesused = "whoposted,whopostedbit";
require ("./global.php");
$posts = $DB_site->query("SELECT
COUNT(postid) AS posts, post.userid, user.username
FROM post
LEFT JOIN user USING (userid)
WHERE threadid=\"$threadid\"
GROUP BY post.userid
ORDER BY posts DESC");
while ($post = $DB_site->fetch_array($posts))
{
if (($counter++ % 2) != 0)
$backcolor="#E3F1FF";
else
$backcolor = "#E3F1FF";
$totalposts += $post[posts];
eval("\$posters .= \"".gettemplate("whopostedbit")."\";");
}
$totalposts = number_format($totalposts);
eval("dooutput(\"".gettemplate("whoposted")."\");");
?>
========
كاتبه Kier من vBulletin