-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.php
30 lines (27 loc) · 1.15 KB
/
index.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
<?php
#Magic quotes for incoming GET/POST/Cookie data.
ini_set('magic_quotes_gpc', 0);
#Magic quotes for runtime-generated data, e.g. data from SQL, from exec(), etc.
ini_set('magic_quotes_runtime', 0);
$AppFolder = dirname(__FILE__);
$ComponentsPath = array($AppFolder.'/components');
$BaseUrl = substr($_SERVER['SCRIPT_NAME'], 0, strrpos($_SERVER['SCRIPT_NAME'], '/'));
set_include_path(implode(PATH_SEPARATOR, $ComponentsPath));
require_once 'Zend/Loader/Autoloader.php';
$autoloader = Zend_Loader_Autoloader::getInstance();
$autoloader->registerNamespace('System');
$autoloader->setFallbackAutoloader(true);
$autoloaderSystem = new System_Autoloader();
$autoloader->pushAutoloader($autoloaderSystem, 'System');
$autoloader->pushAutoloader($autoloaderSystem, 'User');
$autoloader->pushAutoloader($autoloaderSystem, 'Market');
Zend_Registry::set('AppFolder', $AppFolder);
Zend_Registry::set('ComponentsPath', $ComponentsPath);
Zend_Registry::set('baseUrl', $BaseUrl);
define('HTTPS', 0);
//Debug Mode
if (System_Application::getInstance()->getDebugMode()){
System_Profiler::enable();
}
System_Application::getInstance()->init();
System_Application::getInstance()->run();