Пример #1
0
}
require_once GP_PATH . GP_INC . 'gp.php';
/*
 * In most cases the default internal encoding is latin1, which is of no use,
 * since we want to use the mb_ functions for UTF-8 strings
 */
if (function_exists('mb_internal_encoding')) {
    mb_internal_encoding('UTF-8');
}
require_once BACKPRESS_PATH . 'class.bp-log.php';
$gp_log = new BP_Log();
if (defined('GP_LOG_LEVEL')) {
    $gp_log->set_level(GP_LOG_LEVEL);
}
if (defined('GP_LOG_TYPE')) {
    $gp_log->set_type(GP_LOG_TYPE);
}
if (defined('GP_LOG_FILENAME')) {
    $gp_log->set_filename(GP_LOG_FILENAME);
}
$gp_log->notice('Logging started');
// Load core BackPress functions
require_once BACKPRESS_PATH . 'functions.core.php';
require_once BACKPRESS_PATH . 'functions.compat.php';
require_once BACKPRESS_PATH . 'functions.formatting.php';
// alleviate the magic_quotes_gpc effects
if (get_magic_quotes_gpc()) {
    $_GET = stripslashes_deep($_GET);
    $_POST = stripslashes_deep($_POST);
    $_COOKIE = stripslashes_deep($_COOKIE);
}
Пример #2
0
 * Define include paths and load core BackPress libraries
 */
/**
 * The full path to the BackPress libraries
 */
if (!defined('BACKPRESS_PATH')) {
    define('BACKPRESS_PATH', BB_PATH . BB_INC . 'backpress/');
}
// Load logging class
require_once BACKPRESS_PATH . 'class.bp-log.php';
$bb_log = new BP_Log();
if (defined('BB_LOG_LEVEL')) {
    $bb_log->set_level(BB_LOG_LEVEL);
}
if (defined('BB_LOG_TYPE')) {
    $bb_log->set_type(BB_LOG_TYPE);
}
if (defined('BB_LOG_FILENAME')) {
    $bb_log->set_filename(BB_LOG_FILENAME);
}
$bb_log->notice('Logging started');
// Load core BackPress functions
require_once BACKPRESS_PATH . 'functions.core.php';
require_once BACKPRESS_PATH . 'functions.compat.php';
require_once BACKPRESS_PATH . 'functions.formatting.php';
// nxt_Error
if (!class_exists('nxt_Error')) {
    require_once BACKPRESS_PATH . 'class.nxt-error.php';
}
/**
 * Set up database parameters based on config and initialise