@if (isset($home_sections->featured_section) && $home_sections->featured_section == 1)
@endif
@if (isset($home_sections->latest_posts) && $home_sections->latest_posts == 1)
{{ @$home_text->featured_section_title }}
{{ @$home_text->latest_item_section_title }}
@foreach ($latestPosts as $blog)
@auth('customer')
@php
$postBookmarked = 0;
foreach ($bookmarkPosts as $bookmarkPost) {
if ($bookmarkPost->post_id == $blog->id) {
$postBookmarked = 1;
break;
}
}
@endphp
@endauth
@endforeach
@endif
{{ @$home_text->causes_section_title }}
@if (count($featPostCategories) == 0)
@else
@php $langId = $userCurrentLang->id; @endphp
@foreach ($featPostCategories as $featPostCategory)
@php
$featCatPosts = DB::table('user_blogs')
->where('language_id', '=', $langId)
->where('category_id', '=', $featPostCategory->id)
->where('user_id', $user->id)
->orderBy('serial_number', 'ASC')
->limit(3)
->get();
@endphp
@if (count($featCatPosts) == 0)
@else
@endif
@endforeach
@endif