[phpBB Debug] PHP Notice: in file /includes/acp/acp_forums.php on line 686: Undefined index: enable_thanks
[phpBB Debug] PHP Notice: in file /adm/index.php on line 150: Cannot modify header information - headers already sent by (output started at /includes/functions.php:3208)
[phpBB Debug] PHP Notice: in file /adm/index.php on line 152: Cannot modify header information - headers already sent by (output started at /includes/functions.php:3208)
[phpBB Debug] PHP Notice: in file /adm/index.php on line 153: Cannot modify header information - headers already sent by (output started at /includes/functions.php:3208)
[phpBB Debug] PHP Notice: in file /adm/index.php on line 154: Cannot modify header information - headers already sent by (output started at /includes/functions.php:3208)
Still waiting for a reply on this.ValorSolo wrote:Any chance of getting a top 5 (or 10) thanked users add-on.
This would display on the index page.
Maybe modeled after this Mod.
http://www.phpbb.com/community/viewtopi ... s+on+Index
If I could code well enough, I'd do it.
But the mysql stuff is out of my realm of knowledge.
Code: Select all
<table class="tablebg" width="100%" cellspacing="1">
<tr>
<td class="cat" colspan="2"><h4>{L_TOP_THANKED}</h4></td>
</tr>
<tr>
<td class="row1"><img src="{T_THEME_PATH}/images/whosonline.gif" alt="{L_TOP_THANKED}" /></td>
<td class="row1" width="100%" valign="middle"><p class="genmed">{TOP_THANKED_LIST}</p></td>
</tr>
</table>
Code: Select all
<!-- IF THANKS_ADDON_MOD_ENABLE -->
Code: Select all
<!-- IF postrow.S_IS_OWN_POST -->
<!-- IF THANKS_ENABLE and S_USER_LOGGED_IN -->
<!-- IF postrow.THANKS_LIST -->
<div class="post bg3">
<div class="inner"><span class="corners-top"><span></span></span>
<dl class="postbody">
<dd>
<!-- IF postrow.THANKS_LIST and S_USER_LOGGED_IN-->
<strong>{postrow.THANKS_FROM}</strong>: {postrow.THANKS_LIST}
<!-- ENDIF -->
</dd>
</dl>
<span class="corners-bottom"><span></span></span></div>
</div>
<hr class="divider" />
<!-- ENDIF -->
<!-- ENDIF -->
<!-- ELSE -->
<!-- IF THANKS_ENABLE and S_USER_LOGGED_IN -->
<div class="post bg3">
<div class="inner"><span class="corners-top"><span></span></span>
<dl class="postbody">
<dd>
<!-- IF postrow.THANKS_LIST and S_USER_LOGGED_IN-->
<strong>{postrow.THANKS_FROM}</strong>: {postrow.THANKS_LIST}
<!-- ENDIF -->
</dd>
</dl>
<dl>
<dt style="text-align: center">
<!-- IF postrow.S_FIRST_POST and not postrow.S_GIVE_THANKS and not postrow.S_IS_OWN_POST --><a href="{postrow.U_THANKS}"><img src="{T_IMAGESET_LANG_PATH}/thanks_posts.gif" alt="{L_THANKS1}"/></a><!-- ENDIF -->
<!-- IF postrow.S_GIVE_THANKS -->
<dl>
<dt style="text-align: center">
<a href="{postrow.U_THANKS}"><img src="{T_IMAGESET_LANG_PATH}/thanks_remove.gif" alt="{L_THANKS_REMOVE}"/></a>
</dt>
</dl><!-- ENDIF -->
</dt>
</dl>
<span class="corners-bottom"><span></span></span></div>
</div>
<hr class="divider" />
<!-- ENDIF -->
<!-- ENDIF -->
Code: Select all
<!-- IF postrow.S_IS_OWN_POST -->
<!-- IF THANKS_ENABLE and S_USER_LOGGED_IN -->
<!-- IF postrow.THANKS_LIST -->
<table class="tablebg" width="100%" cellspacing="0">
<!-- IF postrow.S_ROW_COUNT is even -->
<tr class="row1">
<!-- ELSE -->
<tr class="row2">
<!-- ENDIF -->
<td valign="top" style="padding-left: 4px;">
<!-- IF postrow.THANKS_LIST and S_USER_LOGGED_IN-->
{postrow.THANKS_FROM}: {postrow.THANKS_LIST}
<!-- ENDIF -->
</td>
</tr>
<tr>
<td class="spacer" colspan="2" height="1"><img src="images/spacer.gif" alt="" width="1" height="1" /></td>
</tr>
</table>
<!-- ENDIF -->
<!-- ENDIF -->
<!-- ELSE -->
<!-- IF THANKS_ENABLE and S_USER_LOGGED_IN -->
<table class="tablebg" width="100%" cellspacing="0">
<!-- IF postrow.S_ROW_COUNT is even -->
<tr class="row1">
<!-- ELSE -->
<tr class="row2">
<!-- ENDIF -->
<td style="text-align: center;" width="155">
<!-- IF THANKS_ENABLE -->
<!-- IF postrow.S_FIRST_POST and not postrow.S_GIVE_THANKS and not postrow.S_IS_OWN_POST --><a href="{postrow.U_THANKS}"><img style="align: center;" src="{T_IMAGESET_LANG_PATH}/thankposts.gif" alt="{L_THANKS1}" /></a><!-- ENDIF --><!-- ENDIF -->
<!-- IF postrow.S_GIVE_THANKS -->
<a href="{postrow.U_THANKS}"><img src="{T_IMAGESET_LANG_PATH}/removethanks.gif" alt="{L_THANKS_REMOVE}"/></a>
<!-- ENDIF -->
</td>
<td valign="top" style="padding-left: 4px;">
<!-- IF postrow.THANKS_LIST and S_USER_LOGGED_IN-->
{postrow.THANKS_FROM}: {postrow.THANKS_LIST}
<!-- ENDIF -->
</td>
</tr>
<tr>
<td class="spacer" colspan="2" height="1"><img src="images/spacer.gif" alt="" width="1" height="1" /></td>
</tr>
</table>
<!-- ENDIF -->
<!-- ENDIF -->
Code: Select all
UPDATE `phpbb_forums` SET enable_thanks = 1
thanks . it works greatknmt wrote:Change phpbb to your forum's prefix.Code: Select all
UPDATE `phpbb_forums` SET enable_thanks = 1
Code: Select all
[phpBB Debug] PHP Notice: in file /viewtopic.php on line 1450: Undefined index: thanks
[phpBB Debug] PHP Notice: in file /viewtopic.php on line 1451: Undefined index: thanked
[phpBB Debug] PHP Notice: in file /viewtopic.php on line 1451: Undefined index: thanked
[phpBB Debug] PHP Notice: in file /viewtopic.php on line 1452: Undefined index: thanks_post
[phpBB Debug] PHP Notice: in file /viewtopic.php on line 1452: Undefined index: thanks_post
[phpBB Debug] PHP Notice: in file /viewtopic.php on line 1450: Undefined index: thanks
[phpBB Debug] PHP Notice: in file /viewtopic.php on line 1451: Undefined index: thanked
[phpBB Debug] PHP Notice: in file /viewtopic.php on line 1451: Undefined index: thanked
[phpBB Debug] PHP Notice: in file /viewtopic.php on line 1452: Undefined index: thanks_post
[phpBB Debug] PHP Notice: in file /viewtopic.php on line 1452: Undefined index: thanks_post
[phpBB Debug] PHP Notice: in file /viewtopic.php on line 1450: Undefined index: thanks
[phpBB Debug] PHP Notice: in file /viewtopic.php on line 1451: Undefined index: thanked
[phpBB Debug] PHP Notice: in file /viewtopic.php on line 1451: Undefined index: thanked
[phpBB Debug] PHP Notice: in file /viewtopic.php on line 1452: Undefined index: thanks_post
[phpBB Debug] PHP Notice: in file /viewtopic.php on line 1452: Undefined index: thanks_post
[phpBB Debug] PHP Notice: in file /viewtopic.php on line 1450: Undefined index: thanks
[phpBB Debug] PHP Notice: in file /viewtopic.php on line 1451: Undefined index: thanked
[phpBB Debug] PHP Notice: in file /viewtopic.php on line 1451: Undefined index: thanked
[phpBB Debug] PHP Notice: in file /viewtopic.php on line 1452: Undefined index: thanks_post
[phpBB Debug] PHP Notice: in file /viewtopic.php on line 1452: Undefined index: thanks_post
[phpBB Debug] PHP Notice: in file /viewtopic.php on line 1450: Undefined index: thanks
[phpBB Debug] PHP Notice: in file /viewtopic.php on line 1451: Undefined index: thanked
[phpBB Debug] PHP Notice: in file /viewtopic.php on line 1451: Undefined index: thanked
[phpBB Debug] PHP Notice: in file /viewtopic.php on line 1452: Undefined index: thanks_post
[phpBB Debug] PHP Notice: in file /viewtopic.php on line 1452: Undefined index: thanks_post
[phpBB Debug] PHP Notice: in file /viewtopic.php on line 1450: Undefined index: thanks
[phpBB Debug] PHP Notice: in file /viewtopic.php on line 1451: Undefined index: thanked
[phpBB Debug] PHP Notice: in file /viewtopic.php on line 1451: Undefined index: thanked
[phpBB Debug] PHP Notice: in file /viewtopic.php on line 1452: Undefined index: thanks_post
[phpBB Debug] PHP Notice: in file /viewtopic.php on line 1452: Undefined index: thanks_post
[phpBB Debug] PHP Notice: in file /viewtopic.php on line 1450: Undefined index: thanks
[phpBB Debug] PHP Notice: in file /viewtopic.php on line 1451: Undefined index: thanked
[phpBB Debug] PHP Notice: in file /viewtopic.php on line 1451: Undefined index: thanked
[phpBB Debug] PHP Notice: in file /viewtopic.php on line 1452: Undefined index: thanks_post
[phpBB Debug] PHP Notice: in file /viewtopic.php on line 1452: Undefined index: thanks_post
[phpBB Debug] PHP Notice: in file /viewtopic.php on line 1450: Undefined index: thanks
[phpBB Debug] PHP Notice: in file /viewtopic.php on line 1451: Undefined index: thanked
[phpBB Debug] PHP Notice: in file /viewtopic.php on line 1451: Undefined index: thanked
[phpBB Debug] PHP Notice: in file /viewtopic.php on line 1452: Undefined index: thanks_post
[phpBB Debug] PHP Notice: in file /viewtopic.php on line 1452: Undefined index: thanks_post
[phpBB Debug] PHP Notice: in file /viewtopic.php on line 1450: Undefined index: thanks
[phpBB Debug] PHP Notice: in file /viewtopic.php on line 1451: Undefined index: thanked
[phpBB Debug] PHP Notice: in file /viewtopic.php on line 1451: Undefined index: thanked
[phpBB Debug] PHP Notice: in file /viewtopic.php on line 1452: Undefined index: thanks_post
[phpBB Debug] PHP Notice: in file /viewtopic.php on line 1452: Undefined index: thanks_post
[phpBB Debug] PHP Notice: in file /includes/functions.php on line 3795: Cannot modify header information - headers already sent by (output started at /includes/functions.php:3187)
[phpBB Debug] PHP Notice: in file /includes/functions.php on line 3797: Cannot modify header information - headers already sent by (output started at /includes/functions.php:3187)
[phpBB Debug] PHP Notice: in file /includes/functions.php on line 3798: Cannot modify header information - headers already sent by (output started at /includes/functions.php:3187)
[phpBB Debug] PHP Notice: in file /includes/functions.php on line 3799: Cannot modify header information - headers already sent by (output started at /includes/functions.php:3187)
Code: Select all
$postrow = array(
'POST_AUTHOR_FULL' => get_username_string('full', $poster_id, $row['username'], $row['user_colour'], $row['post_username']),
'POST_AUTHOR_COLOUR' => get_username_string('colour', $poster_id, $row['username'], $row['user_colour'], $row['post_username']),
'POST_AUTHOR' => get_username_string('username', $poster_id, $row['username'], $row['user_colour'], $row['post_username']),
'U_POST_AUTHOR' => get_username_string('profile', $poster_id, $row['username'], $row['user_colour'], $row['post_username']),
//Begin Thank Post MOD
'THANKS_FROM' => sprintf($user->lang['THANKS_FROM'], get_username_string('full', $poster_id, $row['username'], $row['user_colour'], $row['post_username'])),
//End Thank Post MOD
'RANK_TITLE' => $user_cache[$poster_id]['rank_title'],
'RANK_IMG' => $user_cache[$poster_id]['rank_image'],
'RANK_IMG_SRC' => $user_cache[$poster_id]['rank_image_src'],
'POSTER_JOINED' => $user_cache[$poster_id]['joined'],
'POSTER_POSTS' => $user_cache[$poster_id]['posts'],
//Begin Thank Post MOD
'POSTER_THANKS' => $user_cache[$poster_id]['thanks'],
'POSTER_THANKED' => ($user_cache[$poster_id]['thanked'] <= 1) ? $user_cache[$poster_id]['thanked'] . $user->lang['THANKS_TIME'] : $user_cache[$poster_id]['thanked'] . $user->lang['THANKS_TIMES'],
'POSTER_THANKS_POST' => ($user_cache[$poster_id]['thanks_post'] <= 1) ? $user_cache[$poster_id]['thanks_post'] . $user->lang['THANKS_POST'] : $user_cache[$poster_id]['thanks_post'] . $user->lang['THANKS_POSTS'],
//End Thank Post MOD
'POSTER_FROM' => $user_cache[$poster_id]['from'],
'POSTER_AVATAR' => $user_cache[$poster_id]['avatar'],
'POSTER_WARNINGS' => $user_cache[$poster_id]['warnings'],
'POSTER_AGE' => $user_cache[$poster_id]['age'],
knmt wrote:Change phpbb to your forum's prefix.Code: Select all
UPDATE `phpbb_forums` SET enable_thanks = 1