Browse Source

Fixes #1134: doc fix.

tags/2.0.0-beta
Qiang Xue 11 years ago
parent
commit
2509748fda
  1. 8
      framework/yii/BaseYii.php

8
framework/yii/BaseYii.php

@ -321,18 +321,12 @@ class BaseYii
* the rest of the name-value pairs in the array will be used to initialize * the rest of the name-value pairs in the array will be used to initialize
* the corresponding object properties. * the corresponding object properties.
* *
* The object type can be either a class name or the [[getAlias()|alias]] of
* the class. For example,
*
* - `app\components\GoogleMap`: fully-qualified namespaced class.
* - `@app/components/GoogleMap`: an alias, used for non-namespaced class.
*
* Below are some usage examples: * Below are some usage examples:
* *
* ~~~ * ~~~
* $object = \Yii::createObject('@app/components/GoogleMap'); * $object = \Yii::createObject('@app/components/GoogleMap');
* $object = \Yii::createObject([ * $object = \Yii::createObject([
* 'class' => '\app\components\GoogleMap', * 'class' => 'app\components\GoogleMap',
* 'apiKey' => 'xyz', * 'apiKey' => 'xyz',
* ]); * ]);
* ~~~ * ~~~

Loading…
Cancel
Save