phpBB

Code Changes

File: includes/ucp/ucp_pm.php

  Unmodified   Added   Modified   Removed
Line 82Line 82
			$mode = 'view';
}


			$mode = 'view';
}


 
		if (!function_exists('get_folder'))
{

		include($phpbb_root_path . 'includes/functions_privmsgs.' . $phpEx);

		include($phpbb_root_path . 'includes/functions_privmsgs.' . $phpEx);

 
		}


switch ($mode)
{


switch ($mode)
{

Line 104Line 107
					break;
}


					break;
}


 
				if (!function_exists('compose_pm'))
{

				include($phpbb_root_path . 'includes/ucp/ucp_pm_compose.' . $phpEx);

				include($phpbb_root_path . 'includes/ucp/ucp_pm_compose.' . $phpEx);

 
				}

				compose_pm($id, $mode, $action, $user_folders);

$tpl_file = 'posting_body';

				compose_pm($id, $mode, $action, $user_folders);

$tpl_file = 'posting_body';

Line 114Line 120
				set_user_message_limit();
get_folder($user->data['user_id']);


				set_user_message_limit();
get_folder($user->data['user_id']);


 
				if (!function_exists('message_options'))
{

				include($phpbb_root_path . 'includes/ucp/ucp_pm_options.' . $phpEx);

				include($phpbb_root_path . 'includes/ucp/ucp_pm_options.' . $phpEx);

 
				}

				message_options($id, $mode, $global_privmsgs_rules, $global_rule_conditions);

$tpl_file = 'ucp_pm_options';

				message_options($id, $mode, $global_privmsgs_rules, $global_rule_conditions);

$tpl_file = 'ucp_pm_options';

Line 125Line 134
				get_folder($user->data['user_id']);
$this->p_name = 'pm';


				get_folder($user->data['user_id']);
$this->p_name = 'pm';


				// Call another module... please do not try this at home... Hoochie Coochie Man


				if (!class_exists('ucp_main'))
{

				include($phpbb_root_path . 'includes/ucp/ucp_main.' . $phpEx);

				include($phpbb_root_path . 'includes/ucp/ucp_main.' . $phpEx);

 
				}


$module = new ucp_main($this);
$module->u_action = $this->u_action;


$module = new ucp_main($this);
$module->u_action = $this->u_action;

Line 168Line 179
				{
send_status_line(403, 'Forbidden');
trigger_error('NO_AUTH_READ_MESSAGE');

				{
send_status_line(403, 'Forbidden');
trigger_error('NO_AUTH_READ_MESSAGE');

 
				}

if ($view == 'print' && (!$config['print_pm'] || !$auth->acl_get('u_pm_printpm')))
{
send_status_line(403, 'Forbidden');
trigger_error('NO_AUTH_PRINT_MESSAGE');

				}

// Do not allow hold messages to be seen

				}

// Do not allow hold messages to be seen

Line 175Line 192
				{
trigger_error('NO_AUTH_READ_HOLD_MESSAGE');
}

				{
trigger_error('NO_AUTH_READ_HOLD_MESSAGE');
}

 

add_form_key('ucp_pm_view');


// First Handle Mark actions and moving messages
$submit_mark = (isset($_POST['submit_mark'])) ? true : false;


// First Handle Mark actions and moving messages
$submit_mark = (isset($_POST['submit_mark'])) ? true : false;

Line 188Line 207
					$move_pm = true;
$dest_folder = (int) $mark_option;
$submit_mark = false;

					$move_pm = true;
$dest_folder = (int) $mark_option;
$submit_mark = false;

 
				}

if (($move_pm || $submit_mark) && !check_form_key('ucp_pm_view'))
{
trigger_error('FORM_INVALID');

				}

// Move PM

				}

// Move PM

Line 368Line 392
				);

if ($action == 'view_folder')

				);

if ($action == 'view_folder')

 
				{
if (!function_exists('view_folder'))

				{
include($phpbb_root_path . 'includes/ucp/ucp_pm_viewfolder.' . $phpEx);

				{
include($phpbb_root_path . 'includes/ucp/ucp_pm_viewfolder.' . $phpEx);

 
					}

					view_folder($id, $mode, $folder_id, $folder);

$tpl_file = 'ucp_pm_viewfolder';

					view_folder($id, $mode, $folder_id, $folder);

$tpl_file = 'ucp_pm_viewfolder';

Line 387Line 414
						trigger_error('NO_MESSAGE');
}


						trigger_error('NO_MESSAGE');
}


 
					if (!function_exists('view_message'))
{

					include($phpbb_root_path . 'includes/ucp/ucp_pm_viewmessage.' . $phpEx);

					include($phpbb_root_path . 'includes/ucp/ucp_pm_viewmessage.' . $phpEx);

 
					}

					view_message($id, $mode, $folder_id, $msg_id, $folder, $message_row);

$tpl_file = ($view == 'print') ? 'ucp_pm_viewmessage_print' : 'ucp_pm_viewmessage';

					view_message($id, $mode, $folder_id, $msg_id, $folder, $message_row);

$tpl_file = ($view == 'print') ? 'ucp_pm_viewmessage_print' : 'ucp_pm_viewmessage';