Index: send.php
===================================================================
--- send.php	(revision 3203)
+++ send.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("config.inc.php");
+require_once(dirname(__FILE__) . "/init.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
 require_once(APP_INC_PATH . "class.user.php");
Index: benchmark.php
===================================================================
--- benchmark.php	(revision 3203)
+++ benchmark.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("config.inc.php");
+require_once(dirname(__FILE__) . "/init.php");
 require_once(APP_INC_PATH . "db_access.php");
 
 error_reporting(E_ALL);
Index: self_assign.php
===================================================================
--- self_assign.php	(revision 3203)
+++ self_assign.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("config.inc.php");
+require_once(dirname(__FILE__) . "/init.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.misc.php");
 require_once(APP_INC_PATH . "class.auth.php");
Index: confirm.php
===================================================================
--- confirm.php	(revision 3203)
+++ confirm.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("config.inc.php");
+require_once(dirname(__FILE__) . "/init.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.user.php");
 require_once(APP_INC_PATH . "class.auth.php");
Index: clock_status.php
===================================================================
--- clock_status.php	(revision 3203)
+++ clock_status.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("config.inc.php");
+require_once(dirname(__FILE__) . "/init.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
 require_once(APP_INC_PATH . "class.user.php");
Index: view_note.php
===================================================================
--- view_note.php	(revision 3203)
+++ view_note.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("config.inc.php");
+require_once(dirname(__FILE__) . "/init.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
 require_once(APP_INC_PATH . "class.issue.php");
Index: adv_search.php
===================================================================
--- adv_search.php	(revision 3203)
+++ adv_search.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("config.inc.php");
+require_once(dirname(__FILE__) . "/init.php");
 require_once(APP_INC_PATH . "db_access.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
Index: scm_ping.php
===================================================================
--- scm_ping.php	(revision 3203)
+++ scm_ping.php	(working copy)
@@ -34,7 +34,7 @@
     exit;
 }
 
-require_once("config.inc.php");
+require_once(dirname(__FILE__) . "/init.php");
 require_once(APP_INC_PATH . "class.misc.php");
 require_once(APP_INC_PATH . "class.scm.php");
 require_once(APP_INC_PATH . "class.workflow.php");
Index: custom_fields.php
===================================================================
--- custom_fields.php	(revision 3203)
+++ custom_fields.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("config.inc.php");
+require_once(dirname(__FILE__) . "/init.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
 require_once(APP_INC_PATH . "class.custom_field.php");
Index: view_headers.php
===================================================================
--- view_headers.php	(revision 3203)
+++ view_headers.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("config.inc.php");
+require_once(dirname(__FILE__) . "/init.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
 require_once(APP_INC_PATH . "class.support.php");
Index: faq.php
===================================================================
--- faq.php	(revision 3203)
+++ faq.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("config.inc.php");
+require_once(dirname(__FILE__) . "/init.php");
 require_once(APP_INC_PATH . "db_access.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
Index: download.php
===================================================================
--- download.php	(revision 3203)
+++ download.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("config.inc.php");
+require_once(dirname(__FILE__) . "/init.php");
 require_once(APP_INC_PATH . "class.auth.php");
 require_once(APP_INC_PATH . "class.attachment.php");
 require_once(APP_INC_PATH . "db_access.php");
Index: view.php
===================================================================
--- view.php	(revision 3203)
+++ view.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("config.inc.php");
+require_once(dirname(__FILE__) . "/init.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
 require_once(APP_INC_PATH . "class.issue.php");
Index: list.php
===================================================================
--- list.php	(revision 3203)
+++ list.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("config.inc.php");
+require_once(dirname(__FILE__) . "/init.php");
 require_once(APP_INC_PATH . "db_access.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
Index: time_tracking.php
===================================================================
--- time_tracking.php	(revision 3203)
+++ time_tracking.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("config.inc.php");
+require_once(dirname(__FILE__) . "/init.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
 require_once(APP_INC_PATH . "class.time_tracking.php");
Index: update.php
===================================================================
--- update.php	(revision 3203)
+++ update.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("config.inc.php");
+require_once(dirname(__FILE__) . "/init.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
 require_once(APP_INC_PATH . "class.issue.php");
Index: forgot_password.php
===================================================================
--- forgot_password.php	(revision 3203)
+++ forgot_password.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("config.inc.php");
+require_once(dirname(__FILE__) . "/init.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.user.php");
 require_once(APP_INC_PATH . "class.mail.php");
Index: offline.php
===================================================================
--- offline.php	(revision 3203)
+++ offline.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("config.inc.php");
+require_once(dirname(__FILE__) . "/init.php");
 require_once(APP_INC_PATH . "class.template.php");
 
 $tpl = new Template_API();
Index: main.php
===================================================================
--- main.php	(revision 3203)
+++ main.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("config.inc.php");
+require_once(dirname(__FILE__) . "/init.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
 require_once(APP_INC_PATH . "class.user.php");
Index: post.php
===================================================================
--- post.php	(revision 3203)
+++ post.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("config.inc.php");
+require_once(dirname(__FILE__) . "/init.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.issue.php");
 require_once(APP_INC_PATH . "class.misc.php");
Index: js/dynamic_custom_field.js.php
===================================================================
--- js/dynamic_custom_field.js.php	(revision 3203)
+++ js/dynamic_custom_field.js.php	(working copy)
@@ -1,5 +1,5 @@
 <?php
-require_once("../config.inc.php");
+require_once(dirname(__FILE__) . "/../init.php");
 require_once(APP_INC_PATH . "class.custom_field.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "db_access.php");
Index: help.php
===================================================================
--- help.php	(revision 3203)
+++ help.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("config.inc.php");
+require_once(dirname(__FILE__) . "/init.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
 require_once(APP_INC_PATH . "class.help.php");
Index: new.php
===================================================================
--- new.php	(revision 3203)
+++ new.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("config.inc.php");
+require_once(dirname(__FILE__) . "/init.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
 require_once(APP_INC_PATH . "class.category.php");
Index: csv.php
===================================================================
--- csv.php	(revision 3203)
+++ csv.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("config.inc.php");
+require_once(dirname(__FILE__) . "/init.php");
 require_once(APP_INC_PATH . "class.auth.php");
 require_once(APP_INC_PATH . "db_access.php");
 
Index: removed_emails.php
===================================================================
--- removed_emails.php	(revision 3203)
+++ removed_emails.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("config.inc.php");
+require_once(dirname(__FILE__) . "/init.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
 require_once(APP_INC_PATH . "class.support.php");
Index: popup.php
===================================================================
--- popup.php	(revision 3203)
+++ popup.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("config.inc.php");
+require_once(dirname(__FILE__) . "/init.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.misc.php");
 require_once(APP_INC_PATH . "class.auth.php");
Index: misc/cli/eventum
===================================================================
--- misc/cli/eventum	(revision 3203)
+++ misc/cli/eventum	(working copy)
@@ -11,7 +11,7 @@
 //
 // @(#) $Id$
 //
-require_once("config.inc.php");
+require_once(dirname(__FILE__) . "/init.php");
 require_once(APP_INC_PATH . "class.command_line.php");
 require_once(APP_PEAR_PATH . "XML_RPC/RPC.php");
 
Index: misc/download_emails.php
===================================================================
--- misc/download_emails.php	(revision 3203)
+++ misc/download_emails.php	(working copy)
@@ -29,7 +29,7 @@
 
 ini_set("memory_limit", "256M");
 
-require_once("../config.inc.php");
+require_once(dirname(__FILE__) . "/../init.php");
 require_once(APP_INC_PATH . "class.support.php");
 require_once(APP_INC_PATH . "class.lock.php");
 require_once(APP_INC_PATH . "class.project.php");
Index: misc/process_mail_queue.php
===================================================================
--- misc/process_mail_queue.php	(revision 3203)
+++ misc/process_mail_queue.php	(working copy)
@@ -29,7 +29,7 @@
 
 ini_set("memory_limit", "256M");
 
-require_once("../config.inc.php");
+require_once(dirname(__FILE__) . "/../init.php");
 require_once(APP_INC_PATH . "db_access.php");
 require_once(APP_INC_PATH . "class.mail_queue.php");
 
Index: misc/check_reminders.php
===================================================================
--- misc/check_reminders.php	(revision 3203)
+++ misc/check_reminders.php	(working copy)
@@ -28,7 +28,7 @@
 // @(#) $Id$
 //
 
-require_once("../config.inc.php");
+require_once(dirname(__FILE__) . "/../init.php");
 require_once(APP_INC_PATH . "db_access.php");
 require_once(APP_INC_PATH . "class.lock.php");
 require_once(APP_INC_PATH . "class.reminder.php");
Index: misc/monitor.php
===================================================================
--- misc/monitor.php	(revision 3203)
+++ misc/monitor.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("../config.inc.php");
+require_once(dirname(__FILE__) . "/../init.php");
 require_once(APP_INC_PATH . "class.monitor.php");
 
 // the disk partition in which eventum is stored in
Index: index.php
===================================================================
--- index.php	(revision 3203)
+++ index.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("config.inc.php");
+require_once(dirname(__FILE__) . '/init.php');
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
 require_once(APP_INC_PATH . "db_access.php");
Index: setup/config.inc.php
===================================================================
--- setup/config.inc.php	(revision 3205)
+++ setup/config.inc.php	(working copy)
@@ -24,35 +24,7 @@
 // +----------------------------------------------------------------------+
 // | Authors: Bryan Alsdorf <bryan@mysql.com>                             |
 // +----------------------------------------------------------------------+
-//
-ini_set('allow_url_fopen', 0);
-ini_set("display_errors", 0);
-error_reporting(0);
-set_time_limit(0);
-set_magic_quotes_runtime(0);
-// prevent session from messing up the browser cache
-ini_set('session.cache_limiter', 'nocache');
 
-// definitions of path related variables
-define("APP_PATH", dirname(__FILE__) . '/');
-define("APP_INC_PATH", APP_PATH . "include/");
-define("APP_PEAR_PATH", APP_INC_PATH . "pear/");
-define("APP_TPL_PATH", APP_PATH . "templates/");
-define("APP_SMARTY_PATH", APP_INC_PATH . "Smarty/");
-define("APP_JPGRAPH_PATH", APP_INC_PATH . "jpgraph/");
-define("APP_LOG_PATH", APP_PATH . "logs/");
-define("APP_LOCKS_PATH", APP_PATH . "locks/");
-f (stristr(PHP_OS, 'darwin')) {
-    ini_set("include_path", ".:" . APP_PEAR_PATH);
-} elseif (stristr(PHP_OS, 'win')) {
-    ini_set("include_path", ".;" . APP_PEAR_PATH);
-} else {
-    ini_set("include_path", ".:" . APP_PEAR_PATH);
-}
-
-define("APP_SETUP_PATH", APP_PATH);
-define("APP_SETUP_FILE", APP_SETUP_PATH . "setup.conf.php");
-
 // definitions of SQL variables
 define("APP_SQL_DBTYPE", "mysql");
 define("APP_SQL_DBHOST", "%{APP_SQL_DBHOST}%");
@@ -64,11 +36,6 @@
 define("APP_DEFAULT_DB", APP_SQL_DBNAME);
 define("APP_TABLE_PREFIX", "%{APP_TABLE_PREFIX}%");
 
-define("APP_ERROR_LOG", APP_LOG_PATH . "errors.log");
-define("APP_CLI_LOG", APP_LOG_PATH . "cli.log");
-define("APP_IRC_LOG", APP_LOG_PATH . "irc_bot.log");
-define("APP_LOGIN_LOG", APP_LOG_PATH . "login_attempts.log");
-
 define("APP_NAME", "Eventum");
 define("APP_SHORT_NAME", APP_NAME); // used in the subject of notification emails
 define("APP_URL", "http://www.mysql.com/products/eventum/");
@@ -116,44 +83,8 @@
 // if full text searching is enabled
 define("APP_ENABLE_FULLTEXT", '%{APP_ENABLE_FULLTEXT}%');
 
-define("APP_BENCHMARK", false);
-if (APP_BENCHMARK) {
-    // always benchmark the scripts
-    require_once("Benchmark/Timer.php");
-    $bench = new Benchmark_Timer;
-    $bench->start();
-}
-
-
-// handle the language preferences now
-$avail_langs = array(
-    "en_US" =>  "English",
-//    "ru_RU" =>  "Russian",
-//    "de_DE" =>  "German",
-//    "fr_FR" =>  "French",
-    "it_IT" =>  "Italian",
-//    "fi_FI" =>  "Finish",
-//    "es_ES" =>  "Spanish",
-//    "nl_NL" =>  "Dutch",
-    "sv_SE" =>  "Swedish"
-);
 define('APP_DEFAULT_LOCALE', 'en_US');
 
 // 'native' or 'php'. Try native first, if you experience strange issues
 // such as language switching randomly, try php
 define('APP_GETTEXT_MODE', 'native');
-
-require_once(APP_INC_PATH . "class.language.php");
-require_once(APP_INC_PATH . "db_access.php");
-require_once(APP_INC_PATH . "class.auth.php");
-require_once(APP_INC_PATH . "class.misc.php");
-
-// fix magic_quote_gpc'ed values
-$_GET = Misc::dispelMagicQuotes($_GET);
-$_POST = Misc::dispelMagicQuotes($_POST);
-$_REQUEST = Misc::dispelMagicQuotes($_REQUEST);
-
-Language::setup();
-
-// set charset
-header("Content-Type: text/html; charset=" . APP_CHARSET);
Index: setup/index.php
===================================================================
--- setup/index.php	(revision 3203)
+++ setup/index.php	(working copy)
@@ -413,7 +413,7 @@
     fclose($fp);
 
     // write setup file
-    require_once("../config.inc.php");
+    require_once(dirname(__FILE__) . "/../init.php");
     require_once(APP_INC_PATH . "class.setup.php");
     $_REQUEST['setup']['update'] = 1;
     $_REQUEST['setup']['closed'] = 1;
Index: setup/check_permissions.php
===================================================================
--- setup/check_permissions.php	(revision 3203)
+++ setup/check_permissions.php	(working copy)
@@ -1,5 +1,5 @@
 <?php
-require_once("../config.inc.php");
+require_once(dirname(__FILE__) . "/../init.php");
 
 clearstatcache();
 
Index: duplicate.php
===================================================================
--- duplicate.php	(revision 3203)
+++ duplicate.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("config.inc.php");
+require_once(dirname(__FILE__) . "/init.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
 require_once(APP_INC_PATH . "class.issue.php");
Index: stats_chart.php
===================================================================
--- stats_chart.php	(revision 3203)
+++ stats_chart.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("config.inc.php");
+require_once(dirname(__FILE__) . "/init.php");
 require_once(APP_INC_PATH . "db_access.php");
 require_once(APP_INC_PATH . "class.auth.php");
 require_once(APP_INC_PATH . "class.stats.php");
Index: notification.php
===================================================================
--- notification.php	(revision 3203)
+++ notification.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("config.inc.php");
+require_once(dirname(__FILE__) . "/init.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
 require_once(APP_INC_PATH . "class.project.php");
Index: get_attachment.php
===================================================================
--- get_attachment.php	(revision 3203)
+++ get_attachment.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("config.inc.php");
+require_once(dirname(__FILE__) . "/init.php");
 require_once(APP_INC_PATH . "class.auth.php");
 require_once(APP_INC_PATH . "class.support.php");
 require_once(APP_INC_PATH . "class.mime_helper.php");
Index: rpc/xmlrpc_client.php
===================================================================
--- rpc/xmlrpc_client.php	(revision 3203)
+++ rpc/xmlrpc_client.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("../config.inc.php");
+require_once(dirname(__FILE__) . "/../init.php");
 require_once(APP_INC_PATH . "class.auth.php");
 require_once(APP_INC_PATH . "class.issue.php");
 require_once(APP_INC_PATH . "class.misc.php");
Index: rpc/xmlrpc.php
===================================================================
--- rpc/xmlrpc.php	(revision 3203)
+++ rpc/xmlrpc.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("../config.inc.php");
+require_once(dirname(__FILE__) . "/../init.php");
 require_once(APP_INC_PATH . "db_access.php");
 require_once(APP_INC_PATH . "class.auth.php");
 require_once(APP_INC_PATH . "class.issue.php");
Index: requirement.php
===================================================================
--- requirement.php	(revision 3203)
+++ requirement.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("config.inc.php");
+require_once(dirname(__FILE__) . "/init.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
 require_once(APP_INC_PATH . "class.impact_analysis.php");
Index: select_project.php
===================================================================
--- select_project.php	(revision 3203)
+++ select_project.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("config.inc.php");
+require_once(dirname(__FILE__) . "/init.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.project.php");
 require_once(APP_INC_PATH . "class.auth.php");
Index: convert_note.php
===================================================================
--- convert_note.php	(revision 3203)
+++ convert_note.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("config.inc.php");
+require_once(dirname(__FILE__) . "/init.php");
 require_once(APP_INC_PATH . "db_access.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
Index: reports/estimated_dev_time.php
===================================================================
--- reports/estimated_dev_time.php	(revision 3203)
+++ reports/estimated_dev_time.php	(working copy)
@@ -25,7 +25,7 @@
 // | Authors: Bryan Alsdorf <bryan@mysql.com>                             |
 // +----------------------------------------------------------------------+
 //
-require_once("../config.inc.php");
+require_once(dirname(__FILE__) . "/../init.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
 require_once(APP_INC_PATH . "class.report.php");
Index: reports/workload_date_range.php
===================================================================
--- reports/workload_date_range.php	(revision 3203)
+++ reports/workload_date_range.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("../config.inc.php");
+require_once(dirname(__FILE__) . "/../init.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
 require_once(APP_INC_PATH . "class.report.php");
Index: reports/open_issues.php
===================================================================
--- reports/open_issues.php	(revision 3203)
+++ reports/open_issues.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("../config.inc.php");
+require_once(dirname(__FILE__) . "/../init.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
 require_once(APP_INC_PATH . "class.report.php");
Index: reports/recent_activity.php
===================================================================
--- reports/recent_activity.php	(revision 3203)
+++ reports/recent_activity.php	(working copy)
@@ -26,7 +26,7 @@
 // +----------------------------------------------------------------------+
 //
 // This report shows a list of activity performed in recent history.
-require_once("../config.inc.php");
+require_once(dirname(__FILE__) . "/../init.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
 require_once(APP_INC_PATH . "db_access.php");
Index: reports/tree.php
===================================================================
--- reports/tree.php	(revision 3203)
+++ reports/tree.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("../config.inc.php");
+require_once(dirname(__FILE__) . "/../init.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
 require_once(APP_INC_PATH . "db_access.php");
Index: reports/custom_fields.php
===================================================================
--- reports/custom_fields.php	(revision 3203)
+++ reports/custom_fields.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("../config.inc.php");
+require_once(dirname(__FILE__) . "/../init.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
 require_once(APP_INC_PATH . "class.report.php");
Index: reports/customer_stats_graph.php
===================================================================
--- reports/customer_stats_graph.php	(revision 3203)
+++ reports/customer_stats_graph.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("../config.inc.php");
+require_once(dirname(__FILE__) . "/../init.php");
 require_once(APP_INC_PATH . "class.auth.php");
 require_once(APP_INC_PATH . "class.customer_stats_report.php");
 require_once(APP_INC_PATH . "class.prefs.php");
Index: reports/weekly.php
===================================================================
--- reports/weekly.php	(revision 3203)
+++ reports/weekly.php	(working copy)
@@ -25,7 +25,7 @@
 // | Authors: Bryan Alsdorf <bryan@mysql.com>                             |
 // +----------------------------------------------------------------------+
 //
-require_once("../config.inc.php");
+require_once(dirname(__FILE__) . "/../init.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
 require_once(APP_INC_PATH . "class.report.php");
Index: reports/top.php
===================================================================
--- reports/top.php	(revision 3203)
+++ reports/top.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("../config.inc.php");
+require_once(dirname(__FILE__) . "/../init.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
 require_once(APP_INC_PATH . "db_access.php");
Index: reports/workload_time_period.php
===================================================================
--- reports/workload_time_period.php	(revision 3203)
+++ reports/workload_time_period.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("../config.inc.php");
+require_once(dirname(__FILE__) . "/../init.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
 require_once(APP_INC_PATH . "class.report.php");
Index: reports/index.php
===================================================================
--- reports/index.php	(revision 3203)
+++ reports/index.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("../config.inc.php");
+require_once(dirname(__FILE__) . "/../init.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "db_access.php");
 
Index: reports/workload_date_range_graph.php
===================================================================
--- reports/workload_date_range_graph.php	(revision 3203)
+++ reports/workload_date_range_graph.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("../config.inc.php");
+require_once(dirname(__FILE__) . "/../init.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
 require_once(APP_INC_PATH . "class.report.php");
Index: reports/customer_stats.php
===================================================================
--- reports/customer_stats.php	(revision 3203)
+++ reports/customer_stats.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("../config.inc.php");
+require_once(dirname(__FILE__) . "/../init.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
 require_once(APP_INC_PATH . "class.report.php");
Index: reports/custom_fields_graph.php
===================================================================
--- reports/custom_fields_graph.php	(revision 3203)
+++ reports/custom_fields_graph.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("../config.inc.php");
+require_once(dirname(__FILE__) . "/../init.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
 require_once(APP_INC_PATH . "class.report.php");
Index: reports/stalled_issues.php
===================================================================
--- reports/stalled_issues.php	(revision 3203)
+++ reports/stalled_issues.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("../config.inc.php");
+require_once(dirname(__FILE__) . "/../init.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
 require_once(APP_INC_PATH . "class.report.php");
Index: reports/workload_time_period_graph.php
===================================================================
--- reports/workload_time_period_graph.php	(revision 3203)
+++ reports/workload_time_period_graph.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("../config.inc.php");
+require_once(dirname(__FILE__) . "/../init.php");
 require_once(APP_INC_PATH . "class.auth.php");
 require_once(APP_INC_PATH . "class.report.php");
 require_once(APP_INC_PATH . "class.prefs.php");
Index: reports/issue.php
===================================================================
--- reports/issue.php	(revision 3203)
+++ reports/issue.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("../config.inc.php");
+require_once(dirname(__FILE__) . "/../init.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
 require_once(APP_INC_PATH . "class.report.php");
Index: login.php
===================================================================
--- login.php	(revision 3203)
+++ login.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("config.inc.php");
+require_once(dirname(__FILE__) . "/init.php");
 require_once(APP_INC_PATH . "db_access.php");
 require_once(APP_INC_PATH . "class.auth.php");
 require_once(APP_INC_PATH . "class.user.php");
Index: logout.php
===================================================================
--- logout.php	(revision 3203)
+++ logout.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("config.inc.php");
+require_once(dirname(__FILE__) . "/init.php");
 require_once(APP_INC_PATH . "class.auth.php");
 
 Auth::removeCookie(APP_COOKIE);
Index: associate.php
===================================================================
--- associate.php	(revision 3203)
+++ associate.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("config.inc.php");
+require_once(dirname(__FILE__) . "/init.php");
 require_once(APP_INC_PATH . "db_access.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
Index: news.php
===================================================================
--- news.php	(revision 3203)
+++ news.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("config.inc.php");
+require_once(dirname(__FILE__) . "/init.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
 require_once(APP_INC_PATH . "class.news.php");
Index: view_email.php
===================================================================
--- view_email.php	(revision 3203)
+++ view_email.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("config.inc.php");
+require_once(dirname(__FILE__) . "/init.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
 require_once(APP_INC_PATH . "class.issue.php");
Index: searchbar.php
===================================================================
--- searchbar.php	(revision 3203)
+++ searchbar.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("config.inc.php");
+require_once(dirname(__FILE__) . "/init.php");
 require_once(APP_INC_PATH . "db_access.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
Index: authorized_replier.php
===================================================================
--- authorized_replier.php	(revision 3203)
+++ authorized_replier.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("config.inc.php");
+require_once(dirname(__FILE__) . "/init.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
 require_once(APP_INC_PATH . "class.project.php");
Index: switch.php
===================================================================
--- switch.php	(revision 3203)
+++ switch.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("config.inc.php");
+require_once(dirname(__FILE__) . "/init.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
 require_once(APP_INC_PATH . "db_access.php");
Index: history.php
===================================================================
--- history.php	(revision 3203)
+++ history.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("config.inc.php");
+require_once(dirname(__FILE__) . "/init.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
 require_once(APP_INC_PATH . "class.history.php");
Index: preferences.php
===================================================================
--- preferences.php	(revision 3203)
+++ preferences.php	(working copy)
@@ -32,7 +32,7 @@
 if (@$_POST['language']) {
     define('SKIP_LANGUAGE_INIT', true);
 }
-require_once("config.inc.php");
+require_once(dirname(__FILE__) . "/init.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
 require_once(APP_INC_PATH . "class.prefs.php");
Index: manage/priorities.php
===================================================================
--- manage/priorities.php	(revision 3203)
+++ manage/priorities.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("../config.inc.php");
+require_once(dirname(__FILE__) . "/../init.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
 require_once(APP_INC_PATH . "class.user.php");
Index: manage/reminder_conditions.php
===================================================================
--- manage/reminder_conditions.php	(revision 3203)
+++ manage/reminder_conditions.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("../config.inc.php");
+require_once(dirname(__FILE__) . "/../init.php");
 require_once(APP_INC_PATH . "db_access.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
Index: manage/custom_fields.php
===================================================================
--- manage/custom_fields.php	(revision 3203)
+++ manage/custom_fields.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("../config.inc.php");
+require_once(dirname(__FILE__) . "/../init.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
 require_once(APP_INC_PATH . "class.custom_field.php");
Index: manage/users.php
===================================================================
--- manage/users.php	(revision 3203)
+++ manage/users.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("../config.inc.php");
+require_once(dirname(__FILE__) . "/../init.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
 require_once(APP_INC_PATH . "class.user.php");
Index: manage/releases.php
===================================================================
--- manage/releases.php	(revision 3203)
+++ manage/releases.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("../config.inc.php");
+require_once(dirname(__FILE__) . "/../init.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
 require_once(APP_INC_PATH . "class.user.php");
Index: manage/resolution.php
===================================================================
--- manage/resolution.php	(revision 3203)
+++ manage/resolution.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("../config.inc.php");
+require_once(dirname(__FILE__) . "/../init.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
 require_once(APP_INC_PATH . "class.user.php");
Index: manage/faq.php
===================================================================
--- manage/faq.php	(revision 3203)
+++ manage/faq.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("../config.inc.php");
+require_once(dirname(__FILE__) . "/../init.php");
 require_once(APP_INC_PATH . "db_access.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
Index: manage/field_display.php
===================================================================
--- manage/field_display.php	(revision 3203)
+++ manage/field_display.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("../config.inc.php");
+require_once(dirname(__FILE__) . "/../init.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
 require_once(APP_INC_PATH . "class.project.php");
Index: manage/customer_notes.php
===================================================================
--- manage/customer_notes.php	(revision 3203)
+++ manage/customer_notes.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("../config.inc.php");
+require_once(dirname(__FILE__) . "/../init.php");
 require_once(APP_INC_PATH . "db_access.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
Index: manage/news.php
===================================================================
--- manage/news.php	(revision 3203)
+++ manage/news.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("../config.inc.php");
+require_once(dirname(__FILE__) . "/../init.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
 require_once(APP_INC_PATH . "class.project.php");
Index: manage/groups.php
===================================================================
--- manage/groups.php	(revision 3203)
+++ manage/groups.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("../config.inc.php");
+require_once(dirname(__FILE__) . "/../init.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
 require_once(APP_INC_PATH . "class.user.php");
Index: manage/time_tracking.php
===================================================================
--- manage/time_tracking.php	(revision 3203)
+++ manage/time_tracking.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("../config.inc.php");
+require_once(dirname(__FILE__) . "/../init.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
 require_once(APP_INC_PATH . "class.user.php");
Index: manage/round_robin.php
===================================================================
--- manage/round_robin.php	(revision 3203)
+++ manage/round_robin.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("../config.inc.php");
+require_once(dirname(__FILE__) . "/../init.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
 require_once(APP_INC_PATH . "class.project.php");
Index: manage/reminder_review.php
===================================================================
--- manage/reminder_review.php	(revision 3203)
+++ manage/reminder_review.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("../config.inc.php");
+require_once(dirname(__FILE__) . "/../init.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
 require_once(APP_INC_PATH . "class.reminder.php");
Index: manage/email_accounts.php
===================================================================
--- manage/email_accounts.php	(revision 3203)
+++ manage/email_accounts.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("../config.inc.php");
+require_once(dirname(__FILE__) . "/../init.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
 require_once(APP_INC_PATH . "class.user.php");
Index: manage/anonymous.php
===================================================================
--- manage/anonymous.php	(revision 3203)
+++ manage/anonymous.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("../config.inc.php");
+require_once(dirname(__FILE__) . "/../init.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
 require_once(APP_INC_PATH . "class.user.php");
Index: manage/email_responses.php
===================================================================
--- manage/email_responses.php	(revision 3203)
+++ manage/email_responses.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("../config.inc.php");
+require_once(dirname(__FILE__) . "/../init.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
 require_once(APP_INC_PATH . "class.user.php");
Index: manage/projects.php
===================================================================
--- manage/projects.php	(revision 3203)
+++ manage/projects.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("../config.inc.php");
+require_once(dirname(__FILE__) . "/../init.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
 require_once(APP_INC_PATH . "class.project.php");
Index: manage/issue_auto_creation.php
===================================================================
--- manage/issue_auto_creation.php	(revision 3203)
+++ manage/issue_auto_creation.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("../config.inc.php");
+require_once(dirname(__FILE__) . "/../init.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
 require_once(APP_INC_PATH . "class.user.php");
Index: manage/check_email_settings.php
===================================================================
--- manage/check_email_settings.php	(revision 3203)
+++ manage/check_email_settings.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("../config.inc.php");
+require_once(dirname(__FILE__) . "/../init.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
 require_once(APP_INC_PATH . "class.support.php");
Index: manage/account_managers.php
===================================================================
--- manage/account_managers.php	(revision 3203)
+++ manage/account_managers.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("../config.inc.php");
+require_once(dirname(__FILE__) . "/../init.php");
 require_once(APP_INC_PATH . "db_access.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
Index: manage/statuses.php
===================================================================
--- manage/statuses.php	(revision 3203)
+++ manage/statuses.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("../config.inc.php");
+require_once(dirname(__FILE__) . "/../init.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
 require_once(APP_INC_PATH . "class.project.php");
Index: manage/customize_listing.php
===================================================================
--- manage/customize_listing.php	(revision 3203)
+++ manage/customize_listing.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("../config.inc.php");
+require_once(dirname(__FILE__) . "/../init.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
 require_once(APP_INC_PATH . "class.user.php");
Index: manage/general.php
===================================================================
--- manage/general.php	(revision 3203)
+++ manage/general.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("../config.inc.php");
+require_once(dirname(__FILE__) . "/../init.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
 require_once(APP_INC_PATH . "class.project.php");
Index: manage/phone_categories.php
===================================================================
--- manage/phone_categories.php	(revision 3203)
+++ manage/phone_categories.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("../config.inc.php");
+require_once(dirname(__FILE__) . "/../init.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
 require_once(APP_INC_PATH . "class.user.php");
Index: manage/column_display.php
===================================================================
--- manage/column_display.php	(revision 3203)
+++ manage/column_display.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("../config.inc.php");
+require_once(dirname(__FILE__) . "/../init.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
 require_once(APP_INC_PATH . "class.user.php");
Index: manage/reminder_actions.php
===================================================================
--- manage/reminder_actions.php	(revision 3203)
+++ manage/reminder_actions.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("../config.inc.php");
+require_once(dirname(__FILE__) . "/../init.php");
 require_once(APP_INC_PATH . "db_access.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
Index: manage/link_filters.php
===================================================================
--- manage/link_filters.php	(revision 3203)
+++ manage/link_filters.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("../config.inc.php");
+require_once(dirname(__FILE__) . "/../init.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
 require_once(APP_INC_PATH . "class.user.php");
Index: manage/categories.php
===================================================================
--- manage/categories.php	(revision 3203)
+++ manage/categories.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("../config.inc.php");
+require_once(dirname(__FILE__) . "/../init.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
 require_once(APP_INC_PATH . "class.user.php");
Index: manage/reminders.php
===================================================================
--- manage/reminders.php	(revision 3203)
+++ manage/reminders.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("../config.inc.php");
+require_once(dirname(__FILE__) . "/../init.php");
 require_once(APP_INC_PATH . "db_access.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
Index: init.php
===================================================================
--- init.php	(revision 0)
+++ init.php	(revision 0)
@@ -0,0 +1,149 @@
+<?php
+/* vim: set expandtab tabstop=4 shiftwidth=4 encoding=utf-8: */
+// +----------------------------------------------------------------------+
+// | Eventum - Issue Tracking System                                      |
+// +----------------------------------------------------------------------+
+// | Copyright (c) 2003, 2004, 2005, 2006, 2007 MySQL AB                              |
+// |                                                                      |
+// | This program is free software; you can redistribute it and/or modify |
+// | it under the terms of the GNU General Public License as published by |
+// | the Free Software Foundation; either version 2 of the License, or    |
+// | (at your option) any later version.                                  |
+// |                                                                      |
+// | This program is distributed in the hope that it will be useful,      |
+// | but WITHOUT ANY WARRANTY; without even the implied warranty of       |
+// | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the        |
+// | GNU General Public License for more details.                         |
+// |                                                                      |
+// | You should have received a copy of the GNU General Public License    |
+// | along with this program; if not, write to:                           |
+// |                                                                      |
+// | Free Software Foundation, Inc.                                       |
+// | 59 Temple Place - Suite 330                                          |
+// | Boston, MA 02111-1307, USA.                                          |
+// +----------------------------------------------------------------------+
+// | Authors: Bryan Alsdorf <bryan@mysql.com>                             |
+// | Authors: Elan Ruusamäe <glen@delfi.ee>                               |
+// +----------------------------------------------------------------------+
+
+if (!file_exists('config/config.inc.php')) {
+    Header('Location: setup/');
+    exit;
+}
+
+ini_set('allow_url_fopen', 0);
+ini_set("display_errors", 0);
+error_reporting(0);
+set_time_limit(0);
+set_magic_quotes_runtime(0);
+// prevent session from messing up the browser cache
+ini_set('session.cache_limiter', 'nocache');
+
+// definitions of path related variables
+define('APP_PATH', dirname(__FILE__) . '/');
+define('APP_INC_PATH', APP_PATH . 'include/');
+define('APP_PEAR_PATH', '/usr/share/pear/');
+define('APP_PEAR_PATH', APP_INC_PATH . 'pear/');
+define('APP_TPL_PATH', APP_PATH . 'templates/');
+define('APP_SMARTY_PATH', APP_INC_PATH . 'Smarty/');
+define('APP_JPGRAPH_PATH', APP_INC_PATH . 'jpgraph/');
+define('APP_LOG_PATH', APP_PATH . 'logs/');
+define('APP_LOCKS_PATH', APP_PATH . 'locks/');
+
+define('APP_SETUP_PATH', APP_PATH . 'config/');
+define('APP_SETUP_FILE', APP_SETUP_PATH . 'setup.conf.php');
+
+define('APP_ERROR_LOG', APP_LOG_PATH . 'errors.log');
+define('APP_CLI_LOG', APP_LOG_PATH . 'cli.log');
+define('APP_IRC_LOG', APP_LOG_PATH . 'irc_bot.log');
+define('APP_LOGIN_LOG', APP_LOG_PATH . 'login_attempts.log');
+
+f (stristr(PHP_OS, 'darwin')) {
+    ini_set('include_path', '.:' . APP_PEAR_PATH);
+} elseif (stristr(PHP_OS, 'win')) {
+    ini_set('include_path', '.;' . APP_PEAR_PATH);
+} else {
+    ini_set('include_path', '.:' . APP_PEAR_PATH);
+}
+
+# include site config
+require_once 'config/config.php';
+
+// define the user_id of system user
+if (!defined('APP_SYSTEM_USER_ID')) {
+    define('APP_SYSTEM_USER_ID', 1);
+}
+
+// if full text searching is enabled
+if (!defined('APP_ENABLE_FULLTEXT')) {
+    define('APP_ENABLE_FULLTEXT', false);
+}
+
+if (!defined('APP_BENCHMARK')) {
+    define('APP_BENCHMARK', false);
+}
+
+if (!defined('APP_DEFAULT_ASSIGNED_EMAILS')) {
+    define('APP_DEFAULT_ASSIGNED_EMAILS', 1);
+}
+if (!defined('APP_DEFAULT_NEW_EMAILS')) {
+    define('APP_DEFAULT_NEW_EMAILS', 0);
+}
+if (!defined('APP_COOKIE_URL')) {
+    define('APP_COOKIE_URL', APP_RELATIVE_URL);
+}
+if (!defined('APP_COOKIE_DOMAIN')) {
+    define('APP_COOKIE_DOMAIN', APP_HOSTNAME);
+}
+if (!defined('APP_HASH_TYPE')) {
+    define('APP_HASH_TYPE', 'MD5');
+}
+if (!defined('APP_DEFAULT_LOCALE')) {
+    define('APP_DEFAULT_LOCALE', 'en_US');
+}
+if (!defined('APP_EMAIL_ENCODING')) {
+    if (APP_CHARSET == 'UTF-8') {
+        define('APP_EMAIL_ENCODING', '8bit');
+    } else {
+        define('APP_EMAIL_ENCODING', '7bit');
+    }
+}
+
+if (APP_BENCHMARK) {
+    // always benchmark the scripts
+    require_once 'Benchmark/Timer.php';
+    $bench = new Benchmark_Timer;
+    $bench->start();
+}
+
+// handle the language preferences now
+$avail_langs = array(
+    'en_US' =>  'English',
+#    'ru_RU' =>  'Russian',
+#    'de_DE' =>  'German',
+#    'fr_FR' =>  'French',
+    'it_IT' =>  'Italian',
+#    'fi_FI' =>  'Finish',
+#    'es_ES' =>  'Spanish',
+#    'nl_NL' =>  'Dutch',
+    'sv_SE' =>  'Swedish',
+);
+
+include_once(APP_INC_PATH . 'class.language.php');
+include_once(APP_INC_PATH . 'db_access.php');
+include_once(APP_INC_PATH . 'class.auth.php');
+include_once(APP_INC_PATH . 'class.misc.php');
+
+// fix magic_quote_gpc'ed values
+if (get_magic_quotes_gpc()) {
+    $_GET = Misc::dispelMagicQuotes($_GET);
+    $_POST = Misc::dispelMagicQuotes($_POST);
+    $_REQUEST = Misc::dispelMagicQuotes($_REQUEST);
+}
+
+Language::setup();
+
+// set charset
+Header('Content-Type: text/html; charset=' . APP_CHARSET);
+
+/* vim: set expandtab tabstop=4 shiftwidth=4 encoding=utf-8: */
Index: close.php
===================================================================
--- close.php	(revision 3203)
+++ close.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("config.inc.php");
+require_once(dirname(__FILE__) . "/init.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
 require_once(APP_INC_PATH . "class.issue.php");
Index: signup.php
===================================================================
--- signup.php	(revision 3203)
+++ signup.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("config.inc.php");
+require_once(dirname(__FILE__) . "/init.php");
 require_once(APP_INC_PATH . "class.setup.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "db_access.php");
Index: rss.php
===================================================================
--- rss.php	(revision 3203)
+++ rss.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("config.inc.php");
+require_once(dirname(__FILE__) . "/init.php");
 require_once(APP_INC_PATH . "db_access.php");
 require_once(APP_INC_PATH . "class.setup.php");
 require_once(APP_INC_PATH . "class.filter.php");
Index: post_note.php
===================================================================
--- post_note.php	(revision 3203)
+++ post_note.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("config.inc.php");
+require_once(dirname(__FILE__) . "/init.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
 require_once(APP_INC_PATH . "class.user.php");
Index: emails.php
===================================================================
--- emails.php	(revision 3203)
+++ emails.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("config.inc.php");
+require_once(dirname(__FILE__) . "/init.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
 require_once(APP_INC_PATH . "class.issue.php");
Index: spell_check.php
===================================================================
--- spell_check.php	(revision 3203)
+++ spell_check.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("config.inc.php");
+require_once(dirname(__FILE__) . "/init.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.misc.php");
 require_once(APP_INC_PATH . "db_access.php");
Index: redeem_incident.php
===================================================================
--- redeem_incident.php	(revision 3203)
+++ redeem_incident.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // This page handles marking an issue as 'redeeming' an incident.
 
-require_once("config.inc.php");
+require_once(dirname(__FILE__) . "/init.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.customer.php");
 require_once(APP_INC_PATH . "db_access.php");
Index: file_upload.php
===================================================================
--- file_upload.php	(revision 3203)
+++ file_upload.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("config.inc.php");
+require_once(dirname(__FILE__) . "/init.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
 require_once(APP_INC_PATH . "class.attachment.php");
Index: get_remote_data.php
===================================================================
--- get_remote_data.php	(revision 3203)
+++ get_remote_data.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("config.inc.php");
+require_once(dirname(__FILE__) . "/init.php");
 require_once(APP_INC_PATH . "db_access.php");
 require_once(APP_INC_PATH . "class.auth.php");
 require_once(APP_INC_PATH . "class.note.php");
Index: mail_queue.php
===================================================================
--- mail_queue.php	(revision 3203)
+++ mail_queue.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("config.inc.php");
+require_once(dirname(__FILE__) . "/init.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
 require_once(APP_INC_PATH . "class.mail_queue.php");
Index: phone_calls.php
===================================================================
--- phone_calls.php	(revision 3203)
+++ phone_calls.php	(working copy)
@@ -27,7 +27,7 @@
 //
 // @(#) $Id$
 //
-require_once("config.inc.php");
+require_once(dirname(__FILE__) . "/init.php");
 require_once(APP_INC_PATH . "class.template.php");
 require_once(APP_INC_PATH . "class.auth.php");
 require_once(APP_INC_PATH . "class.phone_support.php");
