-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.php
44 lines (32 loc) · 1.04 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
31
32
33
34
35
36
37
38
39
40
41
42
43
44
<?php
// Define path to document root
defined('DOCROOT_PATH')
|| define('DOCROOT_PATH', realpath(dirname(__FILE__)));
// Define path to application directory
defined('APPLICATION_PATH')
|| define('APPLICATION_PATH', realpath(dirname(__FILE__) . '/app'));
// Define application environment
defined('APPLICATION_ENV') || define('APPLICATION_ENV', (getenv('APPLICATION_ENV') ? getenv('APPLICATION_ENV') : 'development'));
// Ensure library/ is on include_path
set_include_path(implode(PATH_SEPARATOR, array(
realpath(APPLICATION_PATH . '/library'),
get_include_path(),
)));
error_reporting(E_ALL);
if( APPLICATION_ENV == 'staging' || APPLICATION_ENV == 'development' )
{
ini_set('display_errors', '1');
}
else
{
ini_set('display_errors', '0');
}
/** Zend_Application */
require_once 'Zend/Application.php';
// Create application, bootstrap, and run
$application = new Zend_Application(
APPLICATION_ENV,
realpath(dirname(__FILE__) . '/config/config.ini')
);
$application->bootstrap()
->run();