<?xml version="1.0" encoding="UTF-8"?><!-- generator="bbPress" -->

<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
>

<channel>
<title>bbPress support forums Topic: Duplicate Messages Tab in Private Message Plugin</title>
<link>http://bbpress.org/forums/</link>
<description>bbPress support forums Topic: Duplicate Messages Tab in Private Message Plugin</description>
<language>en</language>
<pubDate>Thu, 20 Nov 2008 13:13:35 +0000</pubDate>

<item>
<title>_ck_ on "Duplicate Messages Tab in Private Message Plugin"</title>
<link>http://bbpress.org/forums/topic/duplicate-messages-tab-in-private-message-plugin#post-15476</link>
<pubDate>Thu, 17 Apr 2008 09:31:00 +0000</pubDate>
<dc:creator>_ck_</dc:creator>
<guid isPermaLink="false">15476@http://bbpress.org/forums/</guid>
<description>&#60;p&#62;I had the same problem with my plugins with the avatar tab too. It makes tabs duplicate.&#60;/p&#62;
&#60;p&#62;I'll have to lookup the workaround I did...&#60;/p&#62;
&#60;p&#62;Okay the bug fix I had to use was to wrap the function that adds a tab and check if $self was set.&#60;/p&#62;
&#60;p&#62;ie.&#60;br /&#62;
&#60;pre&#62;&#60;code&#62;function add_tab(blah) {
global $self;
   if (!self) {
     // code that adds tab goes here
   }
}&#60;/code&#62;&#60;/pre&#62;
&#60;p&#62;So what you probably need to do is change this line like so:&#60;br /&#62;
&#60;code&#62;if (!$self &#38;#38;&#38;#38; bb_get_current_user_info( &#38;#39;id&#38;#39; ) == $user_id) {&#60;/code&#62;
&#60;/p&#62;</description>
</item>
<item>
<title>djquinn on "Duplicate Messages Tab in Private Message Plugin"</title>
<link>http://bbpress.org/forums/topic/duplicate-messages-tab-in-private-message-plugin#post-15405</link>
<pubDate>Tue, 15 Apr 2008 17:55:59 +0000</pubDate>
<dc:creator>djquinn</dc:creator>
<guid isPermaLink="false">15405@http://bbpress.org/forums/</guid>
<description>&#60;p&#62;I have the Private Messages plugin and the Avatar plugin both installed, and whenever I click on the Avatar tab in user profiles, I get two Messages tabs. I added the function suggested in the PM plugin forum:&#60;/p&#62;
&#60;p&#62;function add_pm_tab()&#60;br /&#62;
{&#60;br /&#62;
        global $user_id;&#60;br /&#62;
		global $self;&#60;/p&#62;
&#60;p&#62;        if (bb_get_current_user_info( 'id' ) == $user_id) {&#60;br /&#62;
                add_profile_tab(__('Messages'), 'edit_profile', '', 'pm.php');&#60;br /&#62;
        }&#60;br /&#62;
}&#60;br /&#62;
add_action( 'bb_profile_menu', 'add_pm_tab' );&#60;br /&#62;
bb_add_filter('get_bb_location', 'get_mess_bb_location');&#60;br /&#62;
bb_add_filter('get_bb_location', 'get_pm_bb_location');&#60;/p&#62;
&#60;p&#62;To display the PM message tab on the users' profiles. Any idea what's causing the tab to duplicate? It only happens when users click on the Avatar tab in their profile.
&#60;/p&#62;</description>
</item>

</channel>
</rss>
