Package Data | |
---|---|
Maintainer Username: | ikerasLT |
Package Create Date: | 2017-09-11 |
Package Last Update: | 2018-10-15 |
Language: | PHP |
License: | MIT |
Last Refreshed: | 2025-02-06 03:08:42 |
Package Statistics | |
---|---|
Total Downloads: | 89 |
Monthly Downloads: | 0 |
Daily Downloads: | 0 |
Total Stars: | 1 |
Total Watchers: | 3 |
Total Forks: | 0 |
Total Open Issues: | 0 |
Provides accessibility to key - value based settings model
Require this package with composer
composer require ikeraslt/laravel-settings
Add the ServiceProvider to the providers array in config/app.php
Ikeraslt\LaravelSettings\ServiceProvider::class,
If you want to use the facade, add this to your facades in config/app.php:
'Settings' => Ikeraslt\LaravelSettings\Facade::class,
Run the migrations. This will add the settings table to your database
php artisan migrate
Get setting:
$value = settings('key');
Set value:
settings('key', 'value');
Get all:
settings()
Get setting:
$value = Settings::get('key');
Set value:
Settings::set('key', 'value');
Get all:
Settings::getAll()