MyBB Community Forums
Show Last active (last logged in) in postbit - Printable Version

+- MyBB Community Forums (https://community.mybb.com)
+-- Forum: 1.8 Support (https://community.mybb.com/forum-175.html)
+--- Forum: General Support (https://community.mybb.com/forum-176.html)
+--- Thread: Show Last active (last logged in) in postbit (/thread-185830.html)

Pages: 1 2 3 4


RE: Show Last active (last logged in) in postbit - Eldenroot - 11-01-2015

Ys, maybe thats the problem, because I use additional groups in my forum. I will check it again

When I deactivate your plugin - I see about 10 numbers in the postbin

When I activate your plugin -> no numbers, not output. Permissions are set to all


RE: Show Last active (last logged in) in postbit - SvePu - 11-01-2015

OK...could you post the content of your actual postbit/postbit_classic template please?

The used is_member function also supports additional user groups from the plugin settings.


RE: Show Last active (last logged in) in postbit - Eldenroot - 11-01-2015

{$ignore_bit}
<a name="pid{$post['pid']}" id="pid{$post['pid']}"></a>
<div class="post classic {$unapproved_shade}" style="{$post_visibility}" id="post_{$post['pid']}">
<div class="post_author scaleimages">
  <if $thread['uid'] == $post['uid'] then><center><span class="icon middle"><img src="/images/postbin_icons/meeple_gold.png" alt="Autor tématu" title="Autor tématu"></span><span class="middle">  <b>Autor tématu</b>  </span><span class="icon middle"><img src="/images/postbin_icons/meeple_gold.png" alt="Autor tématu" title="Autor tématu"></span></center><div class="author_statistics"></div></if>
	{$post['useravatar']}
	<div class="author_information">
<if $post['fid3']=="Muž" then><img src="images/postbin_icons/gender/male.png" title="{$post['fid3']}" /><elseif $post['fid3']=="Žena" then><img title="{$post['fid3']}" src="images/postbin_icons/gender/female.png" /><else /><img title="Neznámé" src="images/postbin_icons/gender/other.png" /></if></span> <strong><span class="largetext">{$post['profilelink']}</span></strong> {$post['onlinestatus']}<br />
<span class="smalltext">
				{$post['usertitle']}<br />
				{$post['userstars']}
				{$post['groupimage']}
				{$post['additional_images_html']}	
</span>
	</div>
	<div class="author_statistics">
		{$post['user_details']}
</br><span class="icon middle"><img src="/images/postbin_icons/view.png" alt="Poslední přihlášení" title="Poslední přihlášení"></span> {$post['lastactive']}{$post['thanks_count']}{$post['thanked_count']}
	</div>
</div>
<div class="post_content" id="resize">
	<div class="post_head" title="{$post['subject_title']}">
		{$post['posturl']}
		{$post['icon']}
		<span class="post_date">{$post['postdate']} <span class="post_edit" id="edited_by_{$post['pid']}">{$post['editedmsg']}</span></span>
	{$post['subject_extra']}
	</div>
	<div class="post_body scaleimages" id="pid_{$post['pid']}">
		{$post['message']}
	</div>
	
{$post['attachments']}
	{$post['signature']}
	<div class="post_meta" id="post_meta_{$post['pid']}">
			{$post['quick_quote']}
		{$post['quick_quote']}
	{$post['iplogged']}
	</div>
</div>
<div style="{$post['tyl_display']}" id="tyl_{$post['pid']}">{$post['thankyoulike_data']}</div>
<div class="post_controls">
	<div class="postbit_buttons author_buttons float_left">
		{$post['button_email']}{$post['button_pm']}{$post['button_www']}{$post['button_find']}{$post['button_rep']}
	</div>
	<div class="postbit_buttons post_management_buttons float_right">
{$post['button_tyl']}{$post['button_edit']}{$post['button_quickdelete']}{$post['button_quickrestore']}{$post['button_quote']}{$post['button_multiquote']}{$post['button_report']}{$post['button_warn']}{$post['button_purgespammer']}{$post['button_reply_pm']}{$post['button_replyall_pm']}{$post['button_forward_pm']}{$post['button_delete_pm']}
</div></div>
</div>{$post['adsaf']}



RE: Show Last active (last logged in) in postbit - SvePu - 11-01-2015

You moved {$post['lastactive']} manually to another position, thats why template modification on deactivation doesn't work.


RE: Show Last active (last logged in) in postbit - Eldenroot - 11-01-2015

Anyway, it doesnt affect functionality of the plugin itself


RE: Show Last active (last logged in) in postbit - SvePu - 11-01-2015

Please edit the main plugin file before deactivation/deinstallation.
Search for:
function postbit_lastactive_deactivate()
{
	require MYBB_ROOT."/inc/adminfunctions_templates.php";
	find_replace_templatesets("postbit", "#\n".preg_quote('{$post[\'lastactive\']}')."(\r?)#", '', 0);
	find_replace_templatesets("postbit_classic", "#\n".preg_quote('{$post[\'lastactive\']}')."(\r?)#", '', 0);
}

Replace that part with:
function postbit_lastactive_deactivate()
{
	require MYBB_ROOT."/inc/adminfunctions_templates.php";
	find_replace_templatesets("postbit", "#(\n?)".preg_quote('{$post[\'lastactive\']}')."(\r?)#", '', 0);
	find_replace_templatesets("postbit_classic", "#(\n?)".preg_quote('{$post[\'lastactive\']}')."(\r?)#", '', 0);
}
Now the lastvisit UNIX timestamp shouldn't be displayed after deactivation/deinstallation.

(11-01-2015, 04:35 PM)Eldenroot Wrote: Anyway, it doesnt affect functionality of the plugin itself
Yes, that's true...but I tried it a couple of times and I can't reproduce that issue.

Maybe another plugin blocks the functionality.


RE: Show Last active (last logged in) in postbit - Leefish - 11-01-2015

Did you remove all code I supplied Eldenroot?


RE: Show Last active (last logged in) in postbit - Eldenroot - 11-01-2015

@Leefish - Yes, I did. I provided my postbit_classic template above.

@SvePu - There must be a problem with another plugin - unfortunately I dont know whihc of them is the "bad" one Sad

EDIT: I will try to deactivate all one by one and try... I will keep your inform


RE: Show Last active (last logged in) in postbit - SvePu - 11-01-2015

OK...it must be a plugin which hooked into postbit.


RE: Show Last active (last logged in) in postbit - Leefish - 11-01-2015

Eldenroot - do you have it in the postbit or the postbit_author?