1. Go to this page and download the library: Download salehye/laravel-settings library. Choose the download type require.
2. Extract the ZIP file and open the index.php.
3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
// Using the Facade
use Salehye\LaravelSettings\Support\Facades\Settings;
$appName = Settings::get('app_name', 'Default App Name');
// Using the helper function
$contactEmail = web_setting('contact_email', '[email protected]');
// Get all settings
$allSettings = Settings::all();
// Using the Facade
Settings::set('app_name', 'My New App Name', 'string', 'general', 'Updated application name');
// Using the helper function (if you need to set, call without arguments first)
web_setting()->set('contact_email', '[email protected]', 'email', 'contact');