Difference between #3 and #9 of
Using the configuration file, explain what can be configured.

Changes

Title unchanged

Using the configuration file, explain what can be configured.

Category unchanged

Tutorials

Yii version unchanged

Tags unchanged

Content changed

[...]
// name of application
// access it using Yii::app()->name
'name'=>'My website',

//
aliases to specify shortcuts for paths in your app or
 
      // perhaps to external resources for your app
 
      'aliases'=>array(
 
            'myExternalFramework'=>dirname(__FILE__).DIRECTORY_SEPARATOR.'..'
 
            .DIRECTORY_SEPARATOR.'..'.DIRECTORY_SEPARATOR.'myexternalframework'
 
        ),
 
 
        //building on above for a controller in the external 
 
        //framework you can use the controller map to map the 
 
        //controller path
 
        'controllerMap'=>array('myController'=>'myExternalFramework.controllers.MyController'),
 
 
        //
default controller that will be executed when running the application 'defaultController'=>'site', // source language of the application
 
'l
user language (for Locale)
 
'language'=>'es',
 
 
        //language for messages and views
 
        'sourceL
anguage'=>'es',

// charset to use
[...]
// using sqlite
// 'connectionString'=>'sqlite:'.dirname(__FILE__).'/../data/blog.db',
//'),
// url
'urlManager'=>array(
[...]
),
),
                // you can use the scriptMap to configure where your scripts come from. 
 
                //If you use the split configurations for development and production you can 
 
                // have different maps in each and then just load the file and it'll
 
                // load the appropriate file depending on the configuration your running.
 
                // for a production configuration you can have this
 
                'clientScript'=>array(
 
                      'scriptMap'=>array(
 
                          'register.js'=>'site.min.js',
 
                          'login.js'=>'site.min.js',
 
                      ),
 
                ),
 
                // for a development configuration you can have this
 
                'clientScript'=>array(
 
                      'scriptMap'=>array(
 
                          'register.js'=>'register.js',
 
                          'login.js'=>'login.js',
 
                      ),
 
                ),
 
), ); ?> ```
 
17 0
14 followers
Viewed: 92 298 times
Version: 1.1
Category: Tutorials
Tags:
Written by: atrandafir
Last updated by: Yang He
Created on: Jan 10, 2010
Last updated: 12 years ago
Update Article

Revisions

View all history