Download the PHP package palgoals/locale-package without Composer
On this page you can find all versions of the php package palgoals/locale-package. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download palgoals/locale-package
More information about palgoals/locale-package
Files in palgoals/locale-package
Package locale-package
Short Description A Laravel package for database-driven multilingual support with language switcher, translation management, and RTL/LTR auto-detection.
License MIT
Informations about the package locale-package
PalGoals Locale Package
A Laravel package for database-driven multilingual support with language management, translation CRUD, RTL/LTR auto-detection, and ready-to-use Blade components.
Features
- ✅ Database-driven translations with
t('key')helper - ✅ Auto-create missing translation keys in the DB
- ✅ Cache per key/locale pair (configurable TTL)
- ✅ Fallback locale chain
- ✅ RTL / LTR auto-detection via
current_dir() - ✅ Language switcher Blade components (frontend + dashboard)
- ✅ Full CRUD admin panel for languages and translations
- ✅ Supports Laravel 10, 11, 12
Requirements
- PHP 8.1+
- Laravel 10 / 11 / 12
Installation
Step 1 — Install via Composer
Step 2 — Run the installer
This single command will:
- ✅ Publish all files (Models, Controllers, Middleware, Views, Routes, Config)
- ✅ Run migrations (creates
languagesandtranslation_valuestables)
Optional: Add
--seedto seed default languages automatically:
Step 3 — Register the Helper
In your project's composer.json, add the helper to autoload:
Then run:
Step 4 — Register the Middleware
Laravel 11+ — in bootstrap/app.php:
Laravel 10 and below — in app/Http/Kernel.php:
Step 5 — Add Routes
In routes/web.php:
In your dashboard routes file (inside auth/admin group):
Step 6 — Share Variables with All Views
In app/Providers/AppServiceProvider.php inside boot():
Usage
Translate text
Page direction (RTL / LTR)
Language Switcher (Frontend)
Language Switcher (Dashboard)
CMS Page Slug (optional — requires App\Models\Page)
Configuration
After installation, edit config/palgoals-locale.php:
.env options
Views Note
The dashboard views (resources/views/dashboard/lang/) depend on your project's layout components:
<x-dashboard-layout>— your project's dashboard layout<x-form.input>— your project's input component
Edit these views after installation to match your project's component names.
License
MIT — © PalGoals
All versions of locale-package with dependencies
illuminate/support Version ^10.0|^11.0|^12.0
illuminate/database Version ^10.0|^11.0|^12.0
illuminate/http Version ^10.0|^11.0|^12.0