########################################################
# 	Mantis Bugtracker Add-On
# 	PM Version 0.91
#	Sending Private Mesages 
#	2010 plugin by Cas Nuy www.NUY.info
########################################################

This plugin allows to send a Private Message to other members of the system
Private Messages Inbound & Outbound are visible through a Mein menu option called My PM's
From that screen, one can delete or reply to a PM.
Sending a PM is enabled through the View_User_page.
In order to achieve this, a new event has been defined to be used within "view_user_page.php".
The event is called "EVENT_VIEW_USER"

********************************************************************************************
* Installation                                                                             *
********************************************************************************************
Like any other plugin. 
After copying to your webserver :
- Start mantis ad administrator
- Select manage
- Select manage Plugins
- Select Install behind PM 0.91
- Once installed, click on the plugin-name for further configuration.

For version 1.2.1 and above make sure to have this statement in confg_inc.php:
$g_path          = 'http://path to your mantis installation/';


Adding the event to the view_user_page.php script:
Open the script and search for (towards the bottom):
<?php if ( $t_can_manage ) { ?>
<tr>
<td colspan="2" class="center">
<?php print_bracket_link( 'manage_user_edit_page.php?user_id=' . $f_user_id, lang_get( 'manage_user' ) ); ?>
</td>
</tr>
<?php } 
?>
</table>
</div>
<br />
<?php
html_page_bottom();
and change this to look like:
<?php if ( $t_can_manage ) { ?>
<tr>
<td colspan="2" class="center">
<?php print_bracket_link( 'manage_user_edit_page.php?user_id=' . $f_user_id, lang_get( 'manage_user' ) ); ?>
</td>
</tr>
<?php } 
event_signal( 'EVENT_VIEW_USER', array( $tpl_bug_id ) );
?>
</table>
</div>
<br />
<?php
html_page_bottom();

********************************************************************************************
Configuration options                                                                      *
********************************************************************************************
// Who is allowed to add messages
pm_add_treshold		= 	VIEWER

// Do we send an email when adding PM?
pm_mail				=	OFF

// Do we show realname or userid?
pm_show_realname	=	OFF

********************************************************************************************
License                                                                                    *
********************************************************************************************
This plugin is distributed under the same conditions as Mantis itself.

********************************************************************************************
Mantis Issue                                                                               *
********************************************************************************************
http://www.mantisbt.org/bugs/view.php?id=12505

********************************************************************************************
Greetings                                                                                  *
********************************************************************************************
Cas Nuy 
cas@nuy.info
http://www.nuy.info