<commit_before><?php
// Start session for login and redirects
session_start();
//*******************
if (!is_dir("logs"))
{
	mkdir("logs", 0755);
}
//******************************************/
// DOMAIN SPECIFIC SETTINGS
@include "priv.php";
if (!defined("PRIV"))
{
	define("PRIV", "priv");
}
require_once PRIV."/config.domain.php";
require_once PRIV."/dbdata.php";
require_once "sys.php";
require_once PRIV."/social.php";
require_once 'lib/phpass-0.3/PasswordHash.php';

require_once 'process_input.php';
require_once 'graphs.php';
require_once 'vga_functions.php';
include_once 'lib/php_lib.php';
require_once 'lib/htmlpurifier-4.0.0-live/HTMLPurifier.standalone.php';
require_once "lib/feedcreator-1.7.2-ppt/include/feedcreator.class.php";
require_once "vga_bubble_functions.php";

// Set error logs if log directory is defined (in config.domain.php)
if (defined('LOG_DIRECTORY'))
{
	ini_set('log_errors', 'On');
	ini_set('error_log', LOG_DIRECTORY.'vga_runtime_errors.log');

	define("ERROR_FILE", LOG_DIRECTORY."vga_error.log");
	define("LOG_FILE", LOG_DIRECTORY."vga.log");
}

define("MAX_LEN_EMAIL", 60);
define("MAX_LEN_USERNAME", 50);
define("MAX_LEN_PASSWORD", 60);
define("MIN_LEN_PASSWORD", 6);
define("MAX_LEN_ROOM", 20);<commit_msg>Will look in the current directory, then one above site root, for priv.php file. If not found will default to files located in the default priv directory.<commit_after><?php
// Start session for login and redirects
session_start();
//*******************
if (!is_dir("logs"))
{
	mkdir("logs", 0755);
}
//******************************************/
// DOMAIN SPECIFIC SETTINGS

// Look in current directory then above root for priv.php
if (realpath($_SERVER["DOCUMENT_ROOT"] . "priv.php"))
{
	include "priv.php";
}
elseif ($privfile = realpath($_SERVER["DOCUMENT_ROOT"] . "/../priv.php"))
{
	include $privfile;
}

//@include "priv.php";
if (!defined("PRIV"))
{
	define("PRIV", "priv");
}
require_once PRIV."/config.domain.php";
require_once PRIV."/dbdata.php";
require_once "sys.php";
require_once PRIV."/social.php";
require_once 'lib/phpass-0.3/PasswordHash.php';

require_once 'process_input.php';
require_once 'graphs.php';
require_once 'vga_functions.php';
include_once 'lib/php_lib.php';
require_once 'lib/htmlpurifier-4.0.0-live/HTMLPurifier.standalone.php';
require_once "lib/feedcreator-1.7.2-ppt/include/feedcreator.class.php";
require_once "vga_bubble_functions.php";

// Set error logs if log directory is defined (in config.domain.php)
if (defined('LOG_DIRECTORY'))
{
	ini_set('log_errors', 'On');
	ini_set('error_log', LOG_DIRECTORY.'vga_runtime_errors.log');

	define("ERROR_FILE", LOG_DIRECTORY."vga_error.log");
	define("LOG_FILE", LOG_DIRECTORY."vga.log");
	define("BAD_INPUT_LOG", LOG_DIRECTORY."bad_input.log");
}

define("MAX_LEN_EMAIL", 60);
define("MAX_LEN_USERNAME", 50);
define("MAX_LEN_PASSWORD", 60);
define("MIN_LEN_PASSWORD", 6);
define("MAX_LEN_ROOM", 20);
{'fraction_non_alphanumeric': 0.2067553735926305, 'fraction_numerical': 0.014329580348004094, 'mean_word_length': 6.5372750642673525, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2075334', 'n_tokens_mistral': 1066, 'n_tokens_neox': 1036, 'n_words': 197}