PHP code example of aurorawebsoftware / asetting
1. Go to this page and download the library: Download aurorawebsoftware/asetting 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/ */
aurorawebsoftware / asetting example snippets
ASetting::group('site')->getValue('title');
ASetting::groups(['site', 'mail'])->all();
ASetting::group('site')->getValue('title');
ASetting::group('site')->getTitle('title');
ASetting::group('site')->isVisible('title');
ASetting::group('site')->get('title');
ASetting::group('site')->getValues(['title','name']);
ASetting::groups(['site','general'])->getValues(['title','name']);
ASetting::group('site')->set('title', 'New Title', 'Site Title', true);
ASetting::group('site')->delete('title');
ASetting::all(); // Get all settings
ASetting::group('site')->all(); // Get all settings under a specific group
ASetting::group('site')->destroy();
ASetting::groups(['site','general'])->destroy();
ASetting::add('site', 'new_setting', 'Value', 'Setting Title', 'string', true);
return [
'api_token' => ['YOUR_BEARER_TOKEN_HERE'],
'api_middleware' => [
// YourMiddlewareClass::class
]
];
bash
php artisan vendor:publish --tag=asetting-config
bash
php artisan migrate
plaintext
php artisan asetting myGroup myKey
plaintext
php artisan asetting myGroup
plaintext
php artisan asetting