@include('htmlpage.frontent.layout.app') 22 Casestudies Available Now Lorem ipsum dolor sit amet consectetur adipisicing elit. Vero repellendus magni, atque delectus molestias quis? {{-- Show: 12 10 12 20 --}} Sort by: {{ request('sort', 'Newest Post') }} Newest Post Oldest Post @foreach ($casestudies as $casestudy) {{ $casestudy->title }} {{ $casestudy->industryModel->page_name }} {!! $casestudy->content !!} @php // Decode the JSON string into an array if it's a JSON string $technologyIds = json_decode($casestudy->technologies, true); // If it's a valid array, use it if (is_array($technologyIds)) { // Fetch the technology names using the decoded technology IDs $technologies = \App\Models\Technology::whereIn( 'id', $technologyIds, ) ->pluck('technology') ->toArray(); } else { // If it's not an array, treat it as a single ID (like '12') $technologies = \App\Models\Technology::whereIn('id', [ $casestudy->technologies, ]) ->pluck('technology') ->toArray(); } @endphp {{-- Display the technologies or 'No technology' --}} {{ !empty($technologies) ? implode(', ', $technologies) : 'No technology' }} Readmore @endforeach {{-- 1 2 3 4 5 6 7 --}} Advance Filter Reset Industry input('industry', [])) ? 'checked' : '' }} onchange="this.form.submit()"> All @foreach ($industries as $industry) id, request()->input('industry', [])) ? 'checked' : '' }} onchange="this.form.submit()"> {{ $industry->page_name }} @endforeach Service input('service', [])) ? 'checked' : '' }} onchange="this.form.submit()"> All @foreach ($services as $service) id, request()->input('service', [])) ? 'checked' : '' }} onchange="this.form.submit()"> {{ $service->page_name }} @endforeach @include('htmlpage.frontent.layout.footer')
{!! $casestudy->content !!}