PHPackages                             rhincodon/laravel-db-language - 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. rhincodon/laravel-db-language

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

rhincodon/laravel-db-language
=============================

Laravel 5.1 Database Language

1.0.4(10y ago)1211MITPHPPHP &gt;=5.5.9

Since Feb 8Pushed 10y ago1 watchersCompare

[ Source](https://github.com/Rhincodon/laravel-db-language)[ Packagist](https://packagist.org/packages/rhincodon/laravel-db-language)[ Docs](https://github.com/rhincodon/laravel-db-language)[ RSS](/packages/rhincodon-laravel-db-language/feed)WikiDiscussions master Synced 1mo ago

READMEChangelogDependencies (5)Versions (7)Used By (0)

Laravel DB Language
===================

[](#laravel-db-language)

[![Latest Version](https://camo.githubusercontent.com/82f04d91fdd44aa65ee2e7820ca176e037bed55d73ad045d8e69e452695a97ae/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f72656c656173652f5268696e636f646f6e2f6c61726176656c2d64622d6c616e67756167652e7376673f7374796c653d666c61742d737175617265)](https://github.com/Rhincodon/laravel-db-language/releases)[![Software License](https://camo.githubusercontent.com/55c0218c8f8009f06ad4ddae837ddd05301481fcf0dff8e0ed9dadda8780713e/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f6c6963656e73652d4d49542d627269676874677265656e2e7376673f7374796c653d666c61742d737175617265)](LICENSE.md)[![Build Status](https://camo.githubusercontent.com/63b91e568c2e102909d3a88d16db4f2f4df8bf30166ab06c6ce4fc6dcc349a12/68747470733a2f2f696d672e736869656c64732e696f2f7472617669732f5268696e636f646f6e2f6c61726176656c2d64622d6c616e67756167652f6d61737465722e7376673f7374796c653d666c61742d737175617265)](https://travis-ci.org/Rhincodon/laravel-db-language)[![Total Downloads](https://camo.githubusercontent.com/105b5ebf3bdd28f961b21b26de756640e400aa08a9829439a0d5132921b71e2d/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f5268696e636f646f6e2f6c61726176656c2d64622d6c616e67756167652e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/Rhincodon/laravel-db-language)

Install
-------

[](#install)

Via Composer

```
$ composer require rhincodon/laravel-db-language
```

Usage
-----

[](#usage)

Register Service Provider in `config/app.php`:

```
Rhinodontypicus\DBLanguage\DbLanguageServiceProvider::class,
```

Publish config and migration and migrate:

```
php artisan vendor:publish
php artisan migrate
```

Package have 3 models — Language, Value, Constant. You can extend them and use in your app to create language/value/constant.

For usage you need to create one Language in your database. Then you can load all constants/values in your middleware for language and use them like so:

```
$language = \Rhinodontypicus\DBLanguage\Language::create(['name' => 'English']); // Create language

// Somewhere in your middleware you can load all constants
db_language()->load($language->id); // Load all constants for language
db_language()->load($language->id, 'site'); // Load all constants for language from 'site' group

// Somewhere in view/controller, group::value syntax
db_language('site::some_constant'); // Get language constant for loaded language
db_language('site::some_constant', 'Default Value'); // Get language constant with default value. If constant does not exists, value will be created in database for the first time

db_language()->language(); // Get current loaded language
db_language()->language('name'); // Current loaded language field
```

Credits
-------

[](#credits)

- [rhinodontypicus](https://github.com/rhincodon)

License
-------

[](#license)

The MIT License (MIT). Please see [License File](LICENSE.md) for more information.

###  Health Score

29

—

LowBetter than 59% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity13

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity62

Established project with proven stability

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~10 days

Total

5

Last Release

3712d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/c0bffa0284dbcdc91f949e5e3986677201953bbf259fcee322eafccfb3e1ac20?d=identicon)[Rhincodon](/maintainers/Rhincodon)

---

Top Contributors

[![Rhincodon](https://avatars.githubusercontent.com/u/6630959?v=4)](https://github.com/Rhincodon "Rhincodon (50 commits)")

---

Tags

laravellocalizationlanguage

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/rhincodon-laravel-db-language/health.svg)

```
[![Health](https://phpackages.com/badges/rhincodon-laravel-db-language/health.svg)](https://phpackages.com/packages/rhincodon-laravel-db-language)
```

###  Alternatives

[codezero/laravel-localized-routes

A convenient way to set up, manage and use localized routes in a Laravel app.

543638.1k4](/packages/codezero-laravel-localized-routes)[codezero/laravel-localizer

Automatically detect and set an app locale that matches your visitor's preference.

50394.3k4](/packages/codezero-laravel-localizer)[opgginc/codezero-laravel-localized-routes

A convenient way to set up, manage and use localized routes in a Laravel app.

2770.1k1](/packages/opgginc-codezero-laravel-localized-routes)[longman/laravel-multilang

Package to integrate multi language (multi locale) functionality in Laravel 5.x

5514.4k1](/packages/longman-laravel-multilang)[awes-io/localization-helper

Package for convenient work with Laravel's localization features

3527.1k4](/packages/awes-io-localization-helper)[zachleigh/laravel-lang-bundler

Create Laravel translations bundles.

2512.5k](/packages/zachleigh-laravel-lang-bundler)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
