Revision #68 has been created by rackycz on Sep 20, 2019, 2:30:08 PM with the memo:
edit
« previous (#67) next (#69) »
Changes
Title
unchanged
Yii v2 for beginners
Category
unchanged
Tutorials
Yii version
unchanged
2.0
Tags
unchanged
tutorial,beginner,yii2
Content
changed
[...]
Now you can open the page for adding a new user and you will see than so far nothing changed :-)
- [http://localhost/basic-/web/index.php?r=user%2Fcreate](http://localhost/basic-/web/index.php?r=user%2Fcreate)
We must change the language ... For now let's do it in a primitive way. Open the userController, find actionCreate() and paste this code:
```php
Yii::$app->language = "cs-CZ"; // use your languageand permanent way again in file config/web.php
```php
$config = [
// use your language
// also accessible via Yii::$app->language
'language' => 'cs-CZ',
'sourceLanguage' => 'en-US', // en-US is default value, try not to change it.
```
Note: This language-setting will be forgotten as soon as you click somewhere. In next chapter we will enhance this ..
Switching languages + session + dropdown in the top menu
---[...]