Version 3.3.4
This commit is contained in:
1 parent
78706903a2
commit
fb6b5baabc
2206 files changed
+409828
-382984
No files matched your search
+120
-56
@@ -3,20 +3,28 @@
|
||||
/**
|
||||
* <pre>
|
||||
* Invision Power Services
|
||||
* IP.Board v3.2.3
|
||||
* IP.Board v3.3.4
|
||||
* INIT File - Sets up globals
|
||||
* Last Updated: $Date: 2011-09-13 21:55:41 -0400 (Tue, 13 Sep 2011) $
|
||||
* Last Updated: $Date: 2012-06-12 10:14:49 -0400 (Tue, 12 Jun 2012) $
|
||||
* </pre>
|
||||
*
|
||||
* @author $Author: bfarber $
|
||||
* @copyright (c) 2001 - 2008 Invision Power Services, Inc.
|
||||
* @license This is NULLED!
|
||||
* @license http://www.invisionpower.com/company/standards.php#license
|
||||
* @package IP.Board
|
||||
* @link http://hatynka.in
|
||||
* @version $Rev: 9487 $
|
||||
* @link http://www.invisionpower.com
|
||||
* @version $Rev: 10914 $
|
||||
*
|
||||
*/
|
||||
|
||||
// Get constants.php if it exists - this can be used to
|
||||
// override any of the constants defined in this file without
|
||||
// being overwritten when IP.Board is updated
|
||||
if ( is_file( dirname( __FILE__ ) . '/constants.php' ) )
|
||||
{
|
||||
require_once( dirname( __FILE__ ) . '/constants.php' );/*noLibHook*/
|
||||
}
|
||||
|
||||
if ( @function_exists( 'memory_get_usage' ) )
|
||||
{
|
||||
define( 'IPS_MEMORY_START', memory_get_usage() );
|
||||
@@ -32,14 +40,20 @@ if ( @function_exists( 'memory_get_usage' ) )
|
||||
* The name of the CP directory
|
||||
* @since 2.0.0.2005-01-01
|
||||
*/
|
||||
define( 'CP_DIRECTORY', 'admin' );
|
||||
if ( !defined( 'CP_DIRECTORY' ) )
|
||||
{
|
||||
define( 'CP_DIRECTORY', 'admin' );
|
||||
}
|
||||
|
||||
/**
|
||||
* PUBLIC_DIRECTORY
|
||||
*
|
||||
* The name of the public directory
|
||||
*/
|
||||
define( 'PUBLIC_DIRECTORY', 'public' );
|
||||
if ( !defined( 'PUBLIC_DIRECTORY' ) )
|
||||
{
|
||||
define( 'PUBLIC_DIRECTORY', 'public' );
|
||||
}
|
||||
|
||||
/**
|
||||
* Default app name
|
||||
@@ -65,12 +79,18 @@ if ( ! defined( 'IPS_PUBLIC_SCRIPT' ) )
|
||||
/**
|
||||
* "PUBLIC" ROOT PATH
|
||||
*/
|
||||
define( 'DOC_IPS_ROOT_PATH', str_replace( "\\", "/", dirname( __FILE__ ) ) . '/' );
|
||||
if ( !defined( 'DOC_IPS_ROOT_PATH' ) )
|
||||
{
|
||||
define( 'DOC_IPS_ROOT_PATH', str_replace( "\\", "/", dirname( __FILE__ ) ) . '/' );
|
||||
}
|
||||
|
||||
/**
|
||||
* "ADMIN" ROOT PATH
|
||||
*/
|
||||
define( 'IPS_ROOT_PATH', DOC_IPS_ROOT_PATH . CP_DIRECTORY . "/" );
|
||||
if ( !defined( 'IPS_ROOT_PATH' ) )
|
||||
{
|
||||
define( 'IPS_ROOT_PATH', DOC_IPS_ROOT_PATH . CP_DIRECTORY . "/" );
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------
|
||||
// USER CONFIGURABLE ELEMENTS: OTHER PATHS
|
||||
@@ -79,22 +99,34 @@ define( 'IPS_ROOT_PATH', DOC_IPS_ROOT_PATH . CP_DIRECTORY . "/" );
|
||||
/**
|
||||
* PUBLIC PATH
|
||||
*/
|
||||
define( 'IPS_PUBLIC_PATH', DOC_IPS_ROOT_PATH . PUBLIC_DIRECTORY . '/' );
|
||||
if ( !defined( 'IPS_PUBLIC_PATH' ) )
|
||||
{
|
||||
define( 'IPS_PUBLIC_PATH', DOC_IPS_ROOT_PATH . PUBLIC_DIRECTORY . '/' );
|
||||
}
|
||||
|
||||
/**
|
||||
* IPS KERNEL PATH
|
||||
*/
|
||||
define( 'IPS_KERNEL_PATH', DOC_IPS_ROOT_PATH . 'ips_kernel/' );
|
||||
if ( !defined( 'IPS_KERNEL_PATH' ) )
|
||||
{
|
||||
define( 'IPS_KERNEL_PATH', DOC_IPS_ROOT_PATH . 'ips_kernel/' );
|
||||
}
|
||||
|
||||
/**
|
||||
* Custom log in path
|
||||
*/
|
||||
define( 'IPS_PATH_CUSTOM_LOGIN' , IPS_ROOT_PATH.'sources/loginauth' );
|
||||
if ( !defined( 'IPS_PATH_CUSTOM_LOGIN' ) )
|
||||
{
|
||||
define( 'IPS_PATH_CUSTOM_LOGIN' , IPS_ROOT_PATH . 'sources/loginauth' );
|
||||
}
|
||||
|
||||
/**
|
||||
* HOOKS PATH
|
||||
*/
|
||||
define( 'IPS_HOOKS_PATH' , DOC_IPS_ROOT_PATH . 'hooks/' );
|
||||
if ( !defined( 'IPS_HOOKS_PATH' ) )
|
||||
{
|
||||
define( 'IPS_HOOKS_PATH' , DOC_IPS_ROOT_PATH . 'hooks/' );
|
||||
}
|
||||
|
||||
@set_include_path( @get_include_path() . PATH_SEPARATOR . IPS_KERNEL_PATH );
|
||||
|
||||
@@ -102,7 +134,7 @@ define( 'IPS_HOOKS_PATH' , DOC_IPS_ROOT_PATH . 'hooks/' );
|
||||
// USER CONFIGURABLE ELEMENTS: USER LOCATION
|
||||
//--------------------------------------------------------------------------
|
||||
|
||||
if( preg_match( "#/" . CP_DIRECTORY . "(/|$)#", $_SERVER['PHP_SELF'] ) )
|
||||
if( preg_match( "#/" . CP_DIRECTORY . "(/|$)#", $_SERVER['PHP_SELF'] ) AND defined('IPB_THIS_SCRIPT') AND IPB_THIS_SCRIPT == 'admin' )
|
||||
{
|
||||
define( 'IPS_AREA', 'admin' );
|
||||
}
|
||||
@@ -111,7 +143,10 @@ else
|
||||
define( 'IPS_AREA', 'public' );
|
||||
}
|
||||
|
||||
define( 'IN_ACP', IPS_AREA == 'public' ? 0 : 1 );
|
||||
if ( !defined( 'IN_ACP' ) )
|
||||
{
|
||||
define( 'IN_ACP', IPS_AREA == 'public' ? 0 : 1 );
|
||||
}
|
||||
|
||||
/**
|
||||
* Default Application if one is not specified in the URL / POST, etc
|
||||
@@ -133,7 +168,10 @@ if ( ! defined( 'IPS_DEFAULT_APP' ) )
|
||||
* define( 'IPS_ERROR_CAPTURE', 'classItemMarking,publicSessions' );
|
||||
* Set to 'FALSE' for off
|
||||
*/
|
||||
define( 'IPS_ERROR_CAPTURE', false );//'classItemMarking,publicSessions' );
|
||||
if ( ! defined( 'IPS_ERROR_CAPTURE' ) )
|
||||
{
|
||||
define( 'IPS_ERROR_CAPTURE', false );//'classItemMarking,publicSessions' );
|
||||
}
|
||||
|
||||
/**
|
||||
* SQL DEBUG MODE
|
||||
@@ -142,7 +180,10 @@ define( 'IPS_ERROR_CAPTURE', false );//'classItemMarking,publicSessions' );
|
||||
* as it opens your board up to potential security risks
|
||||
* @since 2.2.0.2006-11-06
|
||||
*/
|
||||
define( 'IPS_SQL_DEBUG_MODE', 0 );
|
||||
if ( ! defined( 'IPS_SQL_DEBUG_MODE' ) )
|
||||
{
|
||||
define( 'IPS_SQL_DEBUG_MODE', 0 );
|
||||
}
|
||||
|
||||
/**
|
||||
* SQL DEBUG MODE LOGGING
|
||||
@@ -151,21 +192,30 @@ define( 'IPS_SQL_DEBUG_MODE', 0 );
|
||||
* as it opens your board up to potential security risks
|
||||
* @since 2.2.0.2006-11-06
|
||||
*/
|
||||
define( 'IPS_SQL_DEBUG_LOG', 0 );
|
||||
if ( ! defined( 'IPS_SQL_DEBUG_LOG' ) )
|
||||
{
|
||||
define( 'IPS_SQL_DEBUG_LOG', 0 );
|
||||
}
|
||||
|
||||
/**
|
||||
* SQL LOG FILESORT or TEMP TABLES MODE
|
||||
*
|
||||
* Logs all queries using filesort and/or temp tables
|
||||
*/
|
||||
define( 'IPS_SQL_FIND_EVIL_MODE', false );
|
||||
if ( ! defined( 'IPS_SQL_FIND_EVIL_MODE' ) )
|
||||
{
|
||||
define( 'IPS_SQL_FIND_EVIL_MODE', false );
|
||||
}
|
||||
|
||||
/**
|
||||
* SQL FIND SLOW QUERIES MODE
|
||||
*
|
||||
* Logs all queries that take longer than X seconds (0.1), etc
|
||||
*/
|
||||
define( 'IPS_SQL_FIND_SLOW_MODE', false );
|
||||
if ( ! defined( 'IPS_SQL_FIND_SLOW_MODE' ) )
|
||||
{
|
||||
define( 'IPS_SQL_FIND_SLOW_MODE', false );
|
||||
}
|
||||
|
||||
/**
|
||||
* MEMORY DEBUG MODE
|
||||
@@ -174,16 +224,19 @@ define( 'IPS_SQL_FIND_SLOW_MODE', false );
|
||||
* as it opens your board up to potential security risks
|
||||
* @since 2.2.0.2006-11-06
|
||||
*/
|
||||
define( 'IPS_MEMORY_DEBUG_MODE', 0 );
|
||||
if ( ! defined( 'IPS_MEMORY_DEBUG_MODE' ) )
|
||||
{
|
||||
define( 'IPS_MEMORY_DEBUG_MODE', 0 );
|
||||
}
|
||||
|
||||
/*
|
||||
* Write to a general debug file?
|
||||
* IP.Board has debug messages that are sent to the log.
|
||||
* The log file will fill VERY quickly, so leave this off unless you
|
||||
* are debugging, etc
|
||||
*/
|
||||
if ( ! defined( 'IPS_LOG_ALL' ) )
|
||||
{
|
||||
/*
|
||||
* Write to a general debug file?
|
||||
* IP.Board has debug messages that are sent to the log.
|
||||
* The log file will fill VERY quickly, so leave this off unless you
|
||||
* are debugging, etc
|
||||
*/
|
||||
define( 'IPS_LOG_ALL', FALSE );
|
||||
}
|
||||
|
||||
@@ -211,13 +264,19 @@ if ( ! defined( 'IPS_XML_RPC_DEBUG_ON' ) )
|
||||
* Allow IP address matching when dealing with ACP sessions
|
||||
* @since 2.2.0.2006-06-30
|
||||
*/
|
||||
define( 'IPB_ACP_IP_MATCH', 1 );
|
||||
if ( ! defined( 'IPB_ACP_IP_MATCH' ) )
|
||||
{
|
||||
define( 'IPB_ACP_IP_MATCH', 1 );
|
||||
}
|
||||
|
||||
/**
|
||||
* Number of minutes of inactivity in ACP before you are timed out
|
||||
* @since 3.0.0
|
||||
*/
|
||||
define( 'IPB_ACP_SESSION_TIME_OUT', 60 );
|
||||
if ( ! defined( 'IPB_ACP_SESSION_TIME_OUT' ) )
|
||||
{
|
||||
define( 'IPB_ACP_SESSION_TIME_OUT', 60 );
|
||||
}
|
||||
|
||||
/**
|
||||
* Use GZIP page compression in the ACP
|
||||
@@ -236,14 +295,6 @@ else
|
||||
// ADVANCED CONFIGURATION: MISC
|
||||
//--------------------------------------------------------------------------
|
||||
|
||||
/**
|
||||
* Making FURL Transliteration for russian forums
|
||||
* @since 3.0.0.ru
|
||||
*/
|
||||
define( 'IPB_USE_SEO_TRANSLIT', FALSE );
|
||||
|
||||
define( 'IPB_USE_ONLY_ID_FURL', FALSE );
|
||||
|
||||
/**
|
||||
* USE SHUT DOWN
|
||||
*
|
||||
@@ -252,47 +303,60 @@ define( 'IPB_USE_ONLY_ID_FURL', FALSE );
|
||||
* low priority tasks until end of exec
|
||||
* @since 2.0.0.2005-01-01
|
||||
*/
|
||||
define( 'IPS_USE_SHUTDOWN', IPS_AREA == 'public' ? 1 : 0 );
|
||||
if ( ! defined( 'IPS_USE_SHUTDOWN' ) )
|
||||
{
|
||||
define( 'IPS_USE_SHUTDOWN', IPS_AREA == 'public' ? 1 : 0 );
|
||||
}
|
||||
|
||||
/**
|
||||
* Allow UNICODE
|
||||
*/
|
||||
define( 'IPS_ALLOW_UNICODE', 1 );
|
||||
if ( ! defined( 'IPS_ALLOW_UNICODE' ) )
|
||||
{
|
||||
define( 'IPS_ALLOW_UNICODE', 1 );
|
||||
}
|
||||
|
||||
/**
|
||||
* File and folder permissions
|
||||
*/
|
||||
define( 'IPS_FILE_PERMISSION', 0777 );
|
||||
define( 'IPS_FOLDER_PERMISSION', 0777 );
|
||||
if ( ! defined( 'IPS_FILE_PERMISSION' ) )
|
||||
{
|
||||
define( 'IPS_FILE_PERMISSION', 0777 );
|
||||
}
|
||||
if ( ! defined( 'IPS_FOLDER_PERMISSION' ) )
|
||||
{
|
||||
define( 'IPS_FOLDER_PERMISSION', 0777 );
|
||||
}
|
||||
|
||||
/**
|
||||
* Time now stamp
|
||||
*/
|
||||
define( 'IPS_UNIX_TIME_NOW', time() );
|
||||
if ( ! defined( 'IPS_UNIX_TIME_NOW' ) )
|
||||
{
|
||||
define( 'IPS_UNIX_TIME_NOW', time() );
|
||||
}
|
||||
|
||||
/* Min PHP version number */
|
||||
define( 'MIN_PHP_VERS', '5.1.0' );
|
||||
|
||||
if ( ! defined( 'MIN_PHP_VERS' ) )
|
||||
{
|
||||
define( 'MIN_PHP_VERS', '5.2.0' );
|
||||
}
|
||||
//--------------------------------------------------------------------------
|
||||
// ADVANCED CONFIGURATION: MAGIC QUOTES
|
||||
//--------------------------------------------------------------------------
|
||||
|
||||
@set_magic_quotes_runtime(0);
|
||||
|
||||
define( 'IPS_MAGIC_QUOTES', @get_magic_quotes_gpc() );
|
||||
if ( ! defined( 'IPS_MAGIC_QUOTES' ) )
|
||||
{
|
||||
define( 'IPS_MAGIC_QUOTES', @get_magic_quotes_gpc() );
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------
|
||||
// ADVANCED CONFIGURATION: ERROR REPORTING
|
||||
//--------------------------------------------------------------------------
|
||||
|
||||
if( version_compare( PHP_VERSION, '5.2.0', '>=' ) )
|
||||
{
|
||||
error_reporting( E_STRICT | E_ERROR | E_WARNING | E_PARSE | E_RECOVERABLE_ERROR | E_COMPILE_ERROR | E_USER_ERROR | E_USER_WARNING );
|
||||
}
|
||||
else
|
||||
{
|
||||
error_reporting( E_STRICT | E_ERROR | E_WARNING | E_PARSE | E_COMPILE_ERROR | E_USER_ERROR | E_USER_WARNING );
|
||||
}
|
||||
error_reporting( E_STRICT | E_ERROR | E_WARNING | E_PARSE | E_RECOVERABLE_ERROR | E_COMPILE_ERROR | E_USER_ERROR | E_USER_WARNING );
|
||||
|
||||
//--------------------------------------------------------------------------
|
||||
// XX NOTHING USER CONFIGURABLE XX NOTHING USER CONFIGURABLE XX
|
||||
@@ -328,6 +392,8 @@ else
|
||||
// NON-CONFIGURABLE: Attempt to sort out some defaults
|
||||
//--------------------------------------------------------------------------
|
||||
|
||||
define( 'ORIGINAL_TIME_LIMIT', @ini_get('max_execution_time') ? @ini_get('max_execution_time') : 0 );
|
||||
|
||||
if ( @function_exists("set_time_limit") == 1 and SAFE_MODE_ON == 0 )
|
||||
{
|
||||
if ( ( defined('IPS_IS_SHELL') AND IPS_IS_SHELL ) OR ( IPS_AREA != 'public' ) )
|
||||
@@ -342,7 +408,7 @@ if ( @function_exists("set_time_limit") == 1 and SAFE_MODE_ON == 0 )
|
||||
* Sets default time zone to server time zone
|
||||
* @since 2.2.0.2006-05-19
|
||||
*/
|
||||
if ( function_exists( 'date_default_timezone_set' ) )
|
||||
if ( function_exists( 'date_default_timezone_set' ) and !defined( 'DO_NOT_SET_TIMEZONE' ) ) // bug report 25566
|
||||
{
|
||||
if ( ! @date_default_timezone_get() )
|
||||
{
|
||||
@@ -442,6 +508,4 @@ function IPS_exception_error( $error )
|
||||
exit();
|
||||
}
|
||||
|
||||
mb_internal_encoding('UTF-8');
|
||||
|
||||
?>
|
||||
Reference in new issue
Block a user