PTA configuration of KH

This commit is contained in:
Deon George 2011-01-14 15:19:48 +11:00
parent b6e9961846
commit a43ad2b2c5
2 changed files with 17 additions and 8 deletions

View File

@ -8,7 +8,7 @@
* @see http://kohanaframework.org/guide/using.configuration
* @see http://php.net/timezones
*/
date_default_timezone_set('America/Chicago');
date_default_timezone_set('Australia/Melbourne');
/**
* Set the default locale.
@ -58,7 +58,8 @@ if (getenv('KOHANA_ENV') !== FALSE)
* - boolean caching enable or disable internal caching FALSE
*/
Kohana::init(array(
'base_url' => '/',
'base_url' => '/pta',
'index_file' => '',
));
/**
@ -75,16 +76,16 @@ Kohana::$config->attach(new Kohana_Config_File);
* Enable modules. Modules are referenced by a relative or absolute path.
*/
Kohana::modules(array(
// 'auth' => MODPATH.'auth', // Basic authentication
'auth' => MODPATH.'auth', // Basic authentication
// 'cache' => MODPATH.'cache', // Caching with multiple backends
// 'codebench' => MODPATH.'codebench', // Benchmarking tool
// 'database' => MODPATH.'database', // Database access
'database' => MODPATH.'database', // Database access
// 'image' => MODPATH.'image', // Image manipulation
// 'orm' => MODPATH.'orm', // Object Relationship Mapping
'orm' => MODPATH.'orm', // Object Relationship Mapping
// 'oauth' => MODPATH.'oauth', // OAuth authentication
// 'pagination' => MODPATH.'pagination', // Paging of results
// 'unittest' => MODPATH.'unittest', // Unit testing
// 'userguide' => MODPATH.'userguide', // User guide and API documentation
'userguide' => MODPATH.'userguide', // User guide and API documentation
));
/**
@ -97,6 +98,14 @@ Route::set('default', '(<controller>(/<action>(/<id>)))')
'action' => 'index',
));
// Static file serving (CSS, JS, images)
Route::set('default/media', 'media(/<file>)', array('file' => '.+'))
->defaults(array(
'controller' => 'welcome',
'action' => 'media',
'file' => NULL,
));
if ( ! defined('SUPPRESS_REQUEST'))
{
/**

4
kh.php
View File

@ -13,7 +13,7 @@ $application = 'application';
*
* @see http://kohanaframework.org/guide/about.install#modules
*/
$modules = 'modules';
$modules = 'includes/kohana/modules';
/**
* The directory in which the Kohana resources are located. The system
@ -21,7 +21,7 @@ $modules = 'modules';
*
* @see http://kohanaframework.org/guide/about.install#system
*/
$system = 'system';
$system = 'includes/kohana/system';
/**
* The default extension of resource files. If you change this, all resources