Thank you/ Like system

Moneyman

Paragon
Joined
Aug 11, 2012
Messages
1,538
Reaction score
3
FP$
9,610
Just installed this plugin, and I wanna add the button to my postbit_classic.
This is what I need to put there:
Code:
	<td colspan="2" class="trow2 post_buttons {$unapproved_shade}">
		{$tyl_expcol} 
		<span id="tyl_title_{$post['pid']}" style="{$tyl_title_display}">{$lang->tyl_title}</span><span id="tyl_title_collapsed_{$post['pid']}" style="{$tyl_title_display_collapsed}">{$lang->tyl_title_collapsed}</span><br />
		<span id="tyl_data_{$post['pid']}" style="{$tyl_data_display}">{$post['thankyoulike']}</span>
	</td>

This is where I need to put it:
Code:
{$ignore_bit}
<table border="0" cellspacing="{$theme['borderwidth']}" cellpadding="{$theme['tablespace']}" class="tborder" style="{$post_extra_style} {$post_visibility}" id="post_{$post['pid']}">
	<tr>
		<td class="{$altbg}" width="15%" valign="top" style="white-space: nowrap; text-align: center;"><a name="pid{$post['pid']}" id="pid{$post['pid']}"></a>
		<strong><span class="largetext">{$post['profilelink']}</span></strong> {$post['onlinestatus']}<br />
		<span class="smalltext">
			{$post['usertitle']}<br />
			{$post['userstars']}
			{$post['groupimage']}
			{$post['useravatar']}<br />
			{$post['newpoints_postbit']}
		</span>
	</td>
	<td class="{$altbg}" valign="top">
		<table width="100%">
			<tr><td>{$post['posturl']}<span class="smalltext"><strong>{$post['icon']}{$post['subject']} {$post['subject_extra']}</strong></span>
			<br />
			<div id="pid_{$post['pid']}" class="post_body">
				{$post['message']}
			</div>
			{$post['attachments']}
			{$post['signature']}
			<div style="text-align: right; vertical-align: bottom;" id="post_meta_{$post['pid']}">
				<div id="edited_by_{$post['pid']}">{$post['editedmsg']}</div>
				{$post['iplogged']}
				</div>
		</td></tr>
	</table>
</td>
</tr>
<tr>
	<span id="tyl_data_{$post['pid']}" style="{$tyl_data_display}">{$post['thankyoulike']}</span>
	</td>
	<td class="{$altbg}" style="white-space: nowrap; text-align: center; vertical-align: middle;"><span class="smalltext">{$post['postdate']} {$post['posttime']}</span></td>
	<td class="{$altbg}" style="vertical-align: middle;">
		<table width="100%" border="0" cellpadding="0" cellspacing="0">
			<tr valign="bottom">
				<td align="left" ><span class="smalltext">{$post['button_email']}{$post['button_pm']}{$post['button_www']}{$post['button_find']}{$post['button_rep']}</span></td>
				<td align="right">{$post['postbit_l_add']}{$post['button_edit']}{$post['button_quickdelete']}{$post['button_quote']}{$post['button_multiquote']}{$post['button_report']}{$post['button_warn']}{$post['button_reply_pm']}{$post['button_replyall_pm']}{$post['button_forward_pm']}{$post['button_delete_pm']}{$post['pid']}"><a href="thankyoulike.php?action=add&amp;pid={$post['pid']}&amp;my_post_key={$mybb->post_code}" onclick="return thankyoulike.add({$post['pid']}, {$post['tid']});" title="{$lang->add_tyl}" id="tyl_a{$post['pid']}"><img src="{$imgdir}/postbit_{$pre}_add.gif" border="0" alt="{$lang->add_tyl}" id="tyl_i{$post['pid']}" /></a></td>
			</tr>   
			</table>
	</td>
</tr>
</table>

The problem is, where, to be exact? I want it to be next to the edit, delete, reply quote and report buttons.
Any help pls? Thanks!
 
The bit that you want to put is at is at the very bottom:

Code:
<td align="right">{$post['postbit_l_add']}{$post['button_edit']}{$post['button_quickdelete']}{$post['button_quote']}{$post['button_multiquote']}{$post['button_report']}{$post['button_warn']}{$post['button_reply_pm']}{$post['button_replyall_pm']}{$post['button_forward_pm']}{$post['button_delete_pm']}{$post['pid']}"><a href="thankyoulike.php?action=add&amp;pid={$post['pid']}&amp;my_post_key={$mybb->post_code}" onclick="return thankyoulike.add({$post['pid']}, {$post['tid']});" title="{$lang->add_tyl}" id="tyl_a{$post['pid']}"><img src="{$imgdir}/postbit_{$pre}_add.gif" border="0" alt="{$lang->add_tyl}" id="tyl_i{$post['pid']}" /></a></td>

If you want it before the edit button, add it after <td align="right">. If you want it after everything, add it before </td>. If you want it in the middle, find the button that you want it before or after and put the code there.

Hope that helps 🙂
 
For the button to show, all you need is:

Code:
{$post['button_tyl']}

Add that beside:

Code:
{$post['button_edit']}

Or where ever you want it to show.
 
Can you PM me some test account details so I can have a look, please.
 
Logged in, made a change, and created a test thread, please confirm it's working?
 
Back
Top Bottom