@php use Illuminate\Support\Facades\Auth; if (Auth::user()) { $user = Auth::user(); $userName = $user->first_name . ' ' . $user->last_name; } else { $userName = null; } // Set default values if variables are not defined $slug = $slug ?? ''; $background_image = $background_image ?? 'default-background.jpg'; // Provide a default image path $header = $header ?? 'Default Header'; // Provide a default header $title = $title ?? 'Default Title'; // Provide a default title $content = $content ?? 'Default Content'; // Provide default content $button_text = $button_text ?? 'Default Button Text'; // Provide default button text @endphp
{{ $title }}
{!! $content !!}
@else{{ $title }}
{!! $content !!}
@endif