Advertisement:

Author Topic: Karma'da kalan süreyi gösterme..  (Read 12464 times)

Offline Hoochie Coochie Man

  • SMF Hero
  • ******
  • Posts: 5,135
  • Gender: Male
    • İstanblues.org
Karma'da kalan süreyi gösterme..
« on: October 29, 2007, 05:53:36 PM »
Sources'de Karma.php dosyasın da..
Bul:
Code: [Select]
// Find out if this user has done this recently...
$request = db_query("
SELECT action
FROM {$db_prefix}log_karma
WHERE ID_TARGET = $_REQUEST[uid]
AND ID_EXECUTOR = $ID_MEMBER
LIMIT 1", __FILE__, __LINE__);
if (mysql_num_rows($request) > 0)
list ($action) = mysql_fetch_row($request);
mysql_free_result($request);

Değiştir:
Code: [Select]
// Find out if this user has done this recently...
$request = db_query("
SELECT action, logTime
FROM {$db_prefix}log_karma
WHERE ID_TARGET = $_REQUEST[uid]
AND ID_EXECUTOR = $ID_MEMBER
LIMIT 1", __FILE__, __LINE__);
if (mysql_num_rows($request) > 0)
list ($action, $time) = mysql_fetch_row($request);
mysql_free_result($request);

Bul:
Code: [Select]
// If you are gonna try to repeat.... don't allow it.
if ($action == $dir)
fatal_error($txt['smf62'] . ' ' . $modSettings['karmaWaitTime'] . ' ' . $txt[578] . '.', false);

Değiştir:
Code: [Select]
// If you are gonna try to repeat.... don't allow it.
if ($action == $dir)
{
// How much longer do they have to wait (in minutes)? Round to the nearest integer...
$waittime = round($modSettings['karmaWaitTime'] * 60) - ((time() - $time) / 60));
fatal_error($txt['smf62'] . ' ' . $modSettings['karmaWaitTime'] . ' ' . $txt[578] . ' (' . $waittime . ' more ' . $txt['totaltimelogged4'] . ')', false);
}

Bir Oldiesmann yapımıdır..
Orjinal Konu
« Last Edit: August 16, 2008, 02:08:17 PM by Hoochie Coochie Man »
İnadına SMF 1.1.X

Offline Hakanchess

  • Jr. Member
  • **
  • Posts: 133
Re: Karma'da kalan süreyi gösterme.. (Tüyo)
« Reply #1 on: July 15, 2008, 08:09:17 AM »
Teşekkürler...