PHPackages                             topview-digital/laravel-lang-switcher - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Localization &amp; i18n](/categories/localization)
4. /
5. topview-digital/laravel-lang-switcher

ActiveLibrary[Localization &amp; i18n](/categories/localization)

topview-digital/laravel-lang-switcher
=====================================

Laravel Language Switcher

1.0(7y ago)04MITPHPPHP ^7.1.0

Since Mar 21Pushed 7y ago1 watchersCompare

[ Source](https://github.com/robinhoo1973/laravel-language-switcher)[ Packagist](https://packagist.org/packages/topview-digital/laravel-lang-switcher)[ RSS](/packages/topview-digital-laravel-lang-switcher/feed)WikiDiscussions master Synced today

READMEChangelog (1)Dependencies (1)Versions (2)Used By (0)

![GitHub release](https://camo.githubusercontent.com/df312629582fa4fa13f0de14230b84c7499d0f5753845eb605302ce66df8a08c/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f72656c656173652f726f62696e686f6f313937332f6c61726176656c2d6c616e67756167652d73776974636865722e737667)[![Scrutinizer Code Quality](https://camo.githubusercontent.com/0d10165e8adde70c0531ceb4a74482be447ae9a059b15d507a87a1c5235a6a61/68747470733a2f2f7363727574696e697a65722d63692e636f6d2f672f726f62696e686f6f313937332f6c61726176656c2d6c616e67756167652d73776974636865722f6261646765732f7175616c6974792d73636f72652e706e673f623d6d6173746572)](https://scrutinizer-ci.com/g/robinhoo1973/laravel-language-switcher/?branch=master)[![Build Status](https://camo.githubusercontent.com/81e509fcf6809cb179f3ab4e3739b4dbd303270361b73cd9029112f5d2599cf9/68747470733a2f2f7363727574696e697a65722d63692e636f6d2f672f726f62696e686f6f313937332f6c61726176656c2d6c616e67756167652d73776974636865722f6261646765732f6275696c642e706e673f623d6d6173746572)](https://scrutinizer-ci.com/g/robinhoo1973/laravel-language-switcher/build-status/master)[![Code Intelligence Status](https://camo.githubusercontent.com/3add1013fcd20dfeebfc66b08dbf503ed9e971ca838e347feb7b48839e8944eb/68747470733a2f2f7363727574696e697a65722d63692e636f6d2f672f726f62696e686f6f313937332f6c61726176656c2d6c616e67756167652d73776974636865722f6261646765732f636f64652d696e74656c6c6967656e63652e7376673f623d6d6173746572)](https://scrutinizer-ci.com/code-intelligence)![License](https://camo.githubusercontent.com/a00e29441e4f889da5e8f2071026334dff72e361c70a18d4d1509d2ec579b86b/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f6c2f746f70766965772d6469676974616c2f6c61726176656c2d6c616e672d73776974636865722e737667)[![Total Downloads](https://camo.githubusercontent.com/3e48d147b15a9d266a7fe038d302caa95d94be65e9bda472179df1ad6279d8a4/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f746f70766965772d6469676974616c2f6c61726176656c2d6c616e672d73776974636865722e737667)](https://packagist.org/packages/topview-digital/laravel-lang-switcher)[![HitCount](https://camo.githubusercontent.com/d93ca06c4356069f87c1937b2b886856ac149a075bdc31704bf652e996ab3402/687474703a2f2f686974732e6477796c2e696f2f726f62696e686f6f313937332f68747470733a2f2f6769746875622e636f6d2f726f62696e686f6f313937332f6c61726176656c2d6c616e67756167652d73776974636865722e737667)](http://hits.dwyl.io/robinhoo1973/https://github.com/robinhoo1973/laravel-language-switcher)

Laravel Language Switcher
=========================

[](#laravel-language-switcher)

#### Middleware for Language Switcher and Helper for Locale Switch.

[](#middleware-for-language-switcher-and-helper-for-locale-switch)

Implementations of middleware for language switch and helper for locale switch feature.

Requirements
------------

[](#requirements)

- PHP &gt;= 7.0
- MySQL &gt;= 5.7
- [Laravel](https://laravel.com/) &gt;= 5.5

Installation
------------

[](#installation)

Require the package via Composer:

```
composer require topview-digital/laravel-language-switch

```

Laravel will automatically register the [ServiceProvider](https://github.com/robinhoo1973/laravel-language-switcher/blob/master/src/LangSwitcherServiceProvider.php).

### Publish Package

[](#publish-package)

After installation, please publish the assets by below commands

```
php artisan lang-switch:publish

```

### Configure Package

[](#configure-package)

Please config your settings in config/lang-switch.php file, it should looks like below

```
