@php $ads = \App\Models\Advertisement::where('status','active')->latest()->with('media')->get(); @endphp
Advertisement Information {{--
--}} {{-- --}} {{-- --}} {{--
--}}
@if($ads->count()) @foreach($ads as $index => $ad)

{{ $ad->ad_name }}

{{ $ad->ad_category }}

{{ Str::limit($ad->ad_description, 100) }}

@php $media = $ad->getFirstMedia('advertisement_media'); @endphp @if($media)
@if(Str::contains($media->mime_type, 'video')) @else Ad Media @endif
@endif
@endforeach @else

No Active Advertisements

@endif