Difference between #6 and #7 of
Yii v2 snippet guide III

Revision #7 has been created by rackycz on Jan 21, 2021, 2:32:59 PM with the memo:

Translations
« previous (#6) next (#8) »

Changes

Title unchanged

Yii v2 snippet guide III

Category unchanged

Tutorials

Yii version unchanged

2.0

Tags unchanged

Content changed

# My other articles
 
 
* [Yii for beginners](https://www.yiiframework.com/wiki/250/yii-for-beginners)
 
  * [Yii for beginners 2](https://www.yiiframework.com/wiki/462/yii-for-beginners-2)
 
  * [Yii v2 snippet guide I](https://www.yiiframework.com/wiki/2552/yii-v2-snippet-guide)
 
  * [Yii v2 snippet guide II](https://www.yiiframework.com/wiki/2558/yii-v2-snippet-guide-ii)
 
 
# Switching languages and Language in URL
I already [wrote](https://www.yiiframework.com/wiki/2552/yii-v2-snippet-guide#i18n-translations) how translations work. Here I will show how language can be switched and saved into the URL.
So let's add the language switcher into the main menu:

```php
echo Nav::widget([
[...]
8 0
4 followers
Viewed: 164 801 times
Version: 2.0
Category: Tutorials
Written by: rackycz
Last updated by: rackycz
Created on: Jan 21, 2021
Last updated: 9 months ago
Update Article

Revisions

View all history