Version 3.1.4
This commit is contained in:
1 parent
1d4720f3e2
commit
ae5c01cc78
2563 files changed
+283048
-240689
No files matched your search
@@ -1,19 +1,21 @@
|
||||
<?php
|
||||
|
||||
/**
|
||||
* <pre>
|
||||
* Invision Power Services
|
||||
* IP.Board v3.0.5
|
||||
* IP.Board v3.1.4
|
||||
* Online list
|
||||
* Last Updated: $Date: 2009-08-31 20:32:10 -0400 (Mon, 31 Aug 2009) $
|
||||
* Last Updated: $Date: 2010-09-14 05:48:02 -0400 (Tue, 14 Sep 2010) $
|
||||
* </pre>
|
||||
*
|
||||
* @author $Author: bfarber $
|
||||
* @author $Author: terabyte $
|
||||
* @copyright (c) 2001 - 2009 Invision Power Services, Inc.
|
||||
* @license http://www.iinvisionpower.com/community/board/license.html
|
||||
* @package Invision Power Board
|
||||
* @license http://www.invisionpower.com/community/board/license.html
|
||||
* @package IP.Board
|
||||
* @subpackage Members
|
||||
* @link http://www.iinvisionpower.com
|
||||
* @link http://www.invisionpower.com
|
||||
* @since 12th March 2002
|
||||
* @version $Revision: 5066 $
|
||||
* @version $Revision: 6865 $
|
||||
*
|
||||
*/
|
||||
|
||||
@@ -89,22 +91,22 @@ class public_members_messaging_view extends ipsCommand
|
||||
|
||||
if ( ! $this->memberData['g_use_pm'] )
|
||||
{
|
||||
$this->registry->getClass('output')->showError( 'messenger_disabled', 10226 );
|
||||
$this->registry->getClass('output')->showError( 'messenger_disabled', 10226, null, null, 403 );
|
||||
}
|
||||
|
||||
if ( $this->memberData['members_disable_pm'] )
|
||||
{
|
||||
$this->registry->getClass('output')->showError( 'messenger_disabled', 10227 );
|
||||
$this->registry->getClass('output')->showError( 'messenger_disabled', 10227, null, null, 403 );
|
||||
}
|
||||
|
||||
if ( ! $this->memberData['member_id'] )
|
||||
{
|
||||
$this->registry->getClass('output')->showError( 'messenger_no_guests', 10228 );
|
||||
$this->registry->getClass('output')->showError( 'messenger_no_guests', 10228, null, null, 403 );
|
||||
}
|
||||
|
||||
if( ! IPSLib::moduleIsEnabled( 'messaging', 'members' ) )
|
||||
{
|
||||
$this->registry->getClass('output')->showError( 'messenger_disabled', 10227 );
|
||||
$this->registry->getClass('output')->showError( 'messenger_disabled', 10227, null, null, 404 );
|
||||
}
|
||||
|
||||
//-----------------------------------------
|
||||
@@ -119,8 +121,8 @@ class public_members_messaging_view extends ipsCommand
|
||||
// Grab class
|
||||
//-----------------------------------------
|
||||
|
||||
require_once( IPSLib::getAppDir( 'members' ) . '/sources/classes/messaging/messengerFunctions.php' );
|
||||
$this->messengerFunctions = new messengerFunctions( $registry );
|
||||
$classToLoad = IPSLib::loadLibrary( IPSLib::getAppDir( 'members' ) . '/sources/classes/messaging/messengerFunctions.php', 'messengerFunctions', 'members' );
|
||||
$this->messengerFunctions = new $classToLoad( $registry );
|
||||
|
||||
/* Messenger Totals */
|
||||
$this->_totals = $this->messengerFunctions->buildMessageTotals();
|
||||
@@ -180,7 +182,7 @@ class public_members_messaging_view extends ipsCommand
|
||||
//-----------------------------------------
|
||||
|
||||
$this->registry->output->addContent( $this->registry->getClass('output')->getTemplate('messaging')->messengerTemplate( $html, $this->messengerFunctions->_jumpMenu, $this->messengerFunctions->_dirData, $this->_totals, $this->_topicParticipants, $this->_errorString, $this->_deletedTopic ) );
|
||||
$this->registry->output->setTitle( $this->_title );
|
||||
$this->registry->output->setTitle( $this->_title . ' - ' . ipsRegistry::$settings['board_name']);
|
||||
|
||||
$this->registry->output->addNavigation( $this->lang->words['messenger__nav'], 'app=members&module=messaging' );
|
||||
|
||||
@@ -217,7 +219,7 @@ class public_members_messaging_view extends ipsCommand
|
||||
|
||||
if ( $this->request['authKey'] != $this->member->form_hash )
|
||||
{
|
||||
$this->registry->getClass('output')->showError( 'messenger_bad_key', 2024 );
|
||||
$this->registry->getClass('output')->showError( 'messenger_bad_key', 2024, null, null, 403 );
|
||||
}
|
||||
|
||||
//-----------------------------------------
|
||||
@@ -261,7 +263,7 @@ class public_members_messaging_view extends ipsCommand
|
||||
|
||||
if ( $this->request['authKey'] != $this->member->form_hash )
|
||||
{
|
||||
$this->registry->getClass('output')->showError( 'messenger_bad_key', 2024 );
|
||||
$this->registry->getClass('output')->showError( 'messenger_bad_key', 2024, null, null, 403 );
|
||||
}
|
||||
|
||||
//-----------------------------------------
|
||||
@@ -305,7 +307,7 @@ class public_members_messaging_view extends ipsCommand
|
||||
|
||||
if ( $this->request['authKey'] != $this->member->form_hash )
|
||||
{
|
||||
$this->registry->getClass('output')->showError( 'messenger_bad_key', 2024 );
|
||||
$this->registry->getClass('output')->showError( 'messenger_bad_key', 2024, null, null, 403 );
|
||||
}
|
||||
|
||||
//-----------------------------------------
|
||||
@@ -348,7 +350,7 @@ class public_members_messaging_view extends ipsCommand
|
||||
|
||||
if ( $this->request['authKey'] != $this->member->form_hash )
|
||||
{
|
||||
$this->registry->getClass('output')->showError( 'messenger_bad_key', 2024 );
|
||||
$this->registry->getClass('output')->showError( 'messenger_bad_key', 2024, null, null, 403 );
|
||||
}
|
||||
|
||||
//-----------------------------------------
|
||||
@@ -394,7 +396,7 @@ class public_members_messaging_view extends ipsCommand
|
||||
|
||||
if ( $this->request['authKey'] != $this->member->form_hash )
|
||||
{
|
||||
$this->registry->getClass('output')->showError( 'messenger_bad_key', 2024 );
|
||||
$this->registry->getClass('output')->showError( 'messenger_bad_key', 2024, null, null, 403 );
|
||||
}
|
||||
|
||||
//-----------------------------------------
|
||||
@@ -435,7 +437,7 @@ class public_members_messaging_view extends ipsCommand
|
||||
{
|
||||
$_msgString = $this->lang->words[ 'err_' . $msg ];
|
||||
$_msgString = str_replace( '#NAMES#' , implode( ",", $this->messengerFunctions->exceptionData ), $_msgString );
|
||||
$_msgString = str_replace( '#TONAME#' , $toMember['members_display_name'] , $_msgString );
|
||||
$_msgString = str_replace( '#TONAME#' , implode( ",", $inviteUsers), $_msgString );
|
||||
$_msgString = str_replace( '#FROMNAME#', $this->memberData['members_display_name'], $_msgString );
|
||||
}
|
||||
else
|
||||
@@ -452,10 +454,10 @@ class public_members_messaging_view extends ipsCommand
|
||||
/**
|
||||
* Redirects the user to the correct page in a conversation based on the incoming msg ID
|
||||
*
|
||||
* @access private
|
||||
* @access protected
|
||||
* @return string returns HTML
|
||||
*/
|
||||
private function _findMessage()
|
||||
protected function _findMessage()
|
||||
{
|
||||
$msgID = ( $this->request['msgID'] == '__firstUnread__' ) ? '__firstUnread__' : intval( $this->request['msgID'] );
|
||||
$topicID = intval( $this->request['topicID'] );
|
||||
@@ -558,10 +560,16 @@ class public_members_messaging_view extends ipsCommand
|
||||
if ( $method == 'delete' )
|
||||
{
|
||||
$this->messengerFunctions->deleteTopics( $this->memberData['member_id'], $ids );
|
||||
|
||||
$p_end = $this->settings['show_max_msg_list'] > 0 ? $this->settings['show_max_msg_list'] : 50;
|
||||
$start = ( count( $ids ) >= $p_end ) ? $start-$p_end : $start;
|
||||
}
|
||||
else if ( $method == 'move' )
|
||||
{
|
||||
$this->messengerFunctions->moveTopics( $this->memberData['member_id'], $ids, $folderID );
|
||||
|
||||
$p_end = $this->settings['show_max_msg_list'] > 0 ? $this->settings['show_max_msg_list'] : 50;
|
||||
$start = ( count( $ids ) >= $p_end ) ? $start-$p_end : $start;
|
||||
}
|
||||
else if ( $method == 'markread' OR $method == 'markunread' )
|
||||
{
|
||||
@@ -631,7 +639,7 @@ class public_members_messaging_view extends ipsCommand
|
||||
|
||||
if ( ! $topicID )
|
||||
{
|
||||
$this->registry->getClass('output')->showError( 'messenger_no_msgid', 10225 );
|
||||
$this->registry->getClass('output')->showError( 'messenger_no_msgid', 10225, null, null, 404 );
|
||||
}
|
||||
|
||||
//-----------------------------------------
|
||||
@@ -648,11 +656,11 @@ class public_members_messaging_view extends ipsCommand
|
||||
|
||||
if ( $_msg == 'NO_READ_PERMISSION' )
|
||||
{
|
||||
$this->registry->getClass('output')->showError( 'messenger_no_msgid', 10229 );
|
||||
$this->registry->getClass('output')->showError( 'messenger_no_msgid', 10229, null, null, 403 );
|
||||
}
|
||||
else if ( $_msg == 'YOU_ARE_BANNED' )
|
||||
{
|
||||
$this->registry->getClass('output')->showError( 'messenger_you_be_banned_yo', 99910229 );
|
||||
$this->registry->getClass('output')->showError( 'messenger_you_be_banned_yo', 10275, null, null, 403 );
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user