Changeset 647 for trunk/index.php
- Timestamp:
- 10/04/2007 01:57:26 PM (14 months ago)
- Files:
-
- 1 modified
-
trunk/index.php (modified) (4 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/index.php
r644 r647 8 8 | User Guide for more information. 9 9 | ----------------------------------------------------------------------------- 10 | User Guide: http://kohanaphp.com/user_guide/kohana/installation.html 10 | User Guide: http://kohanaphp.com/user_guide/en/kohana/installation.html 11 | ----------------------------------------------------------------------------- 12 | License: http://kohanaphp.com/user_guide/en/license.html 11 13 | ----------------------------------------------------------------------------- 12 14 */ 13 15 14 // Set the error reporting level 15 @error_reporting(E_ALL); 16 /** 17 * Set the error reporting level. E_ALL is a good default. 18 * NOTE: Kohana will always ignore E_NOTICE errors 19 */ 20 error_reporting(E_ALL); 16 21 17 // Enable or disable error reporting 18 @ini_set('display_errors', TRUE); 22 /** 23 * Enable or disable error reporting. You should always disable this in production. 24 */ 25 ini_set('display_errors', TRUE); 19 26 20 // Kohana application directory 27 /** 28 * Kohana application directory. This directory must contain a config/ directory. 29 */ 21 30 $kohana_application = 'application'; 22 31 23 // Kohana system directory 32 /** 33 * Kohana system directory. This directory must contain the core/ directory. 34 */ 24 35 $kohana_system = 'system'; 36 37 /** 38 * If you have to rename all of the .php files distributed with Kohana to a 39 * different filename, you set the new extension here. Most people will never 40 * use this option. 41 */ 42 define('EXT', '.php'); 25 43 26 44 /* … … 28 46 | PLEASE DO NOT EDIT BELOW THIS LINE, unless you understand the repercussions! 29 47 | ----------------------------------------------------------------------------- 30 | User Guide: http://kohanaphp.com/user_guide/ general/bootstrapping.html48 | User Guide: http://kohanaphp.com/user_guide/en/general/bootstrapping.html 31 49 | ----------------------------------------------------------------------------- 32 50 | $Id$ 33 51 */ 34 // Absolute path names for include purposes 35 define('APPPATH', str_replace('\\', '/', realpath($kohana_application)).'/'); unset($kohana_application); 36 define(' SYSPATH', str_replace('\\', '/', realpath($kohana_system)).'/'); unset($kohana_system);37 // Information about the front controller 38 $docroot = str_replace('\\', '/', realpath(__FILE__)); 39 define(' KOHANA', pathinfo($docroot, PATHINFO_BASENAME));40 define(' DOCROOT', pathinfo($docroot, PATHINFO_DIRNAME).'/');41 define('EXT', '.'.pathinfo($docroot, PATHINFO_EXTENSION)); 42 unset($docroot );43 // Validate APPPATH 52 $docroot = pathinfo(str_replace('\\', '/', realpath(__FILE__))); 53 54 define('KOHANA', $docroot['basename']); 55 define('DOCROOT', $docroot['dirname'].'/'); 56 57 define('APPPATH', str_replace('\\', '/', realpath($kohana_application)).'/'); 58 define('SYSPATH', str_replace('\\', '/', realpath($kohana_system)).'/'); 59 60 unset($docroot, $kohana_application, $kohana_system); 61 44 62 (is_dir(APPPATH) AND is_dir(APPPATH.'/config')) or die 45 63 ( … … 47 65 'Set a valid <code>$application_path</code> in <kbd>index.php</kbd> and refresh the page.' 48 66 ); 49 // Validate SYSPATH 67 50 68 (is_dir(SYSPATH) AND file_exists(SYSPATH.'/core/'.'Bootstrap'.EXT)) or die 51 69 ( … … 53 71 'Set a valid <code>$kohana_system</code> in <kbd>index.php</kbd> and refresh the page.' 54 72 ); 55 // Buckle those bootstraps! 73 56 74 require_once SYSPATH.'core/Bootstrap'.EXT;
