blob: 970f2922780980384235006ec944b790ddd5c506 [file] [log] [blame]
adminb0dd10f2006-08-25 17:25:49 +00001<?php
admin1af55492006-09-22 21:43:38 +00002/*
3|---------------------------------------------------------------
4| PHP ERROR REPORTING LEVEL
5|---------------------------------------------------------------
6|
admin8f0a8f62006-10-07 01:17:25 +00007| By default CI runs with error reporting set to ALL. For security
admin1af55492006-09-22 21:43:38 +00008| reasons you are encouraged to change this when your site goes live.
admin784add72006-10-30 20:24:26 +00009| For more info visit: http://www.php.net/error_reporting
admin1af55492006-09-22 21:43:38 +000010|
11*/
admin784add72006-10-30 20:24:26 +000012 error_reporting(E_ALL);
adminb0dd10f2006-08-25 17:25:49 +000013
14/*
admin1af55492006-09-22 21:43:38 +000015|---------------------------------------------------------------
adminb0dd10f2006-08-25 17:25:49 +000016| SYSTEM FOLDER NAME
admin1af55492006-09-22 21:43:38 +000017|---------------------------------------------------------------
adminb0dd10f2006-08-25 17:25:49 +000018|
admin1af55492006-09-22 21:43:38 +000019| This variable must contain the name of your "system" folder.
admine334c472006-10-21 19:44:22 +000020| Include the path if the folder is not in the same directory
admin1af55492006-09-22 21:43:38 +000021| as this file.
22|
23| NO TRAILING SLASH!
24|
adminb0dd10f2006-08-25 17:25:49 +000025*/
adminb0dd10f2006-08-25 17:25:49 +000026 $system_folder = "system";
27
28/*
admin1af55492006-09-22 21:43:38 +000029|---------------------------------------------------------------
adminb0dd10f2006-08-25 17:25:49 +000030| APPLICATION FOLDER NAME
admin1af55492006-09-22 21:43:38 +000031|---------------------------------------------------------------
adminb0dd10f2006-08-25 17:25:49 +000032|
admine334c472006-10-21 19:44:22 +000033| If you want this front controller to use a different "application"
admin784add72006-10-30 20:24:26 +000034| folder then the default one you can set its name here. The folder
35| can also be renamed or relocated anywhere on your server.
36| For more info please see the user guide:
Derek Jones7a9193a2008-01-21 18:39:20 +000037| http://codeigniter.com/user_guide/general/managing_apps.html
admincef21062006-10-30 17:13:13 +000038|
adminb0dd10f2006-08-25 17:25:49 +000039|
admin1af55492006-09-22 21:43:38 +000040| NO TRAILING SLASH!
adminb0dd10f2006-08-25 17:25:49 +000041|
42*/
admin1af55492006-09-22 21:43:38 +000043 $application_folder = "application";
adminb0dd10f2006-08-25 17:25:49 +000044
Rick Ellis268c26c2007-07-22 18:14:41 +000045/*
admin1af55492006-09-22 21:43:38 +000046|===============================================================
admin784add72006-10-30 20:24:26 +000047| END OF USER CONFIGURABLE SETTINGS
admin1af55492006-09-22 21:43:38 +000048|===============================================================
adminb0dd10f2006-08-25 17:25:49 +000049*/
50
admin784add72006-10-30 20:24:26 +000051
52/*
53|---------------------------------------------------------------
54| SET THE SERVER PATH
55|---------------------------------------------------------------
56|
57| Let's attempt to determine the full-server path to the "system"
58| folder in order to reduce the possibility of path problems.
Rick Ellis09066a42007-06-09 01:00:06 +000059| Note: We only attempt this if the user hasn't specified a
60| full server path.
admin784add72006-10-30 20:24:26 +000061|
62*/
Rick Ellis09066a42007-06-09 01:00:06 +000063if (strpos($system_folder, '/') === FALSE)
adminb0dd10f2006-08-25 17:25:49 +000064{
Rick Ellis09066a42007-06-09 01:00:06 +000065 if (function_exists('realpath') AND @realpath(dirname(__FILE__)) !== FALSE)
66 {
67 $system_folder = realpath(dirname(__FILE__)).'/'.$system_folder;
68 }
69}
70else
71{
72 // Swap directory separators to Unix style for consistency
73 $system_folder = str_replace("\\", "/", $system_folder);
adminb0dd10f2006-08-25 17:25:49 +000074}
75
admin784add72006-10-30 20:24:26 +000076/*
77|---------------------------------------------------------------
78| DEFINE APPLICATION CONSTANTS
79|---------------------------------------------------------------
80|
81| EXT - The file extension. Typically ".php"
82| FCPATH - The full server path to THIS file
83| SELF - The name of THIS file (typically "index.php)
84| BASEPATH - The full server path to the "system" folder
85| APPPATH - The full server path to the "application" folder
86|
87*/
adminb0dd10f2006-08-25 17:25:49 +000088define('EXT', '.'.pathinfo(__FILE__, PATHINFO_EXTENSION));
admin1af55492006-09-22 21:43:38 +000089define('FCPATH', __FILE__);
adminb0dd10f2006-08-25 17:25:49 +000090define('SELF', pathinfo(__FILE__, PATHINFO_BASENAME));
91define('BASEPATH', $system_folder.'/');
admincef21062006-10-30 17:13:13 +000092
admin784add72006-10-30 20:24:26 +000093if (is_dir($application_folder))
admincef21062006-10-30 17:13:13 +000094{
admin784add72006-10-30 20:24:26 +000095 define('APPPATH', $application_folder.'/');
admincef21062006-10-30 17:13:13 +000096}
97else
98{
admin784add72006-10-30 20:24:26 +000099 if ($application_folder == '')
100 {
101 $application_folder = 'application';
102 }
103
admincef21062006-10-30 17:13:13 +0000104 define('APPPATH', BASEPATH.$application_folder.'/');
105}
adminb0dd10f2006-08-25 17:25:49 +0000106
admin784add72006-10-30 20:24:26 +0000107/*
108|---------------------------------------------------------------
admin784add72006-10-30 20:24:26 +0000109| LOAD THE FRONT CONTROLLER
110|---------------------------------------------------------------
111|
112| And away we go...
113|
114*/
adminb0dd10f2006-08-25 17:25:49 +0000115require_once BASEPATH.'codeigniter/CodeIgniter'.EXT;
Derek Jonesa3ffbbb2008-05-11 18:18:29 +0000116
117/* End of file index.php */
118/* Location: ./index.php */