{{-- @php $current_domain = str_replace('.'. config('app.short_url'), '', $_SERVER['HTTP_HOST']); // to get the current tenant subdomain if it exists $current_tenant = App\Models\User::where('domain', $current_domain)->first(); @endphp --}} {{-- if the tenant subdomain doesn't exist fall back to default app --}} @if(domain($_SERVER['HTTP_HOST']) == '') @yield('title') - {{config('app.name')}} @else @yield('title') - {{domain($_SERVER['HTTP_HOST'])->company_name}} @endif @if(domain($_SERVER['HTTP_HOST']) !== '') @if(tenantSetting($_SERVER['HTTP_HOST']) !== '') @else @endif @else @endif @include('elements.tenant-style')
@yield('content')
@yield('js_after') @include('layouts.flashMessage')