HEX
Server: Microsoft-IIS/8.5
System: Windows NT YDAWBH120 6.3 build 9600 (Windows Server 2012 R2 Standard Edition) AMD64
User: tentjecom_web (0)
PHP: 7.4.14
Disabled: NONE
Upload Files
File: D:/HostingSpaces/SBogers10/ijzerenman.komma.pro/app/views/layouts/pages/news.blade.php
@extends('layouts.master')

@section('content')

    @include('layouts.partials.breadcrumb')

    {{-- Loop through all news items --}}
    @foreach($newsItems as $key => $newsItem)

        <div class="content-block">

            {{-- Text left and image right --}}
            @if( $key == 0 || $key % 2 == 0 )
                @include('layouts.partials.dynamicPage.contentBlockDescription',
                [
                    'title' => $newsItem->name,
                    'description' => $newsItem->description
                ])
                @include('layouts.partials.dynamicPage.contentBlockImage',
                [
                    'image' => $newsItem->large_image_url,
                    'title' => $newsItem->name,
                ])

            {{-- Image left and text right --}}
            @else
                @include('layouts.partials.dynamicPage.contentBlockDescription',
                [
                    'class' => 'right',
                    'title' => $newsItem->name,
                    'description' => $newsItem->description
                ])
                @include('layouts.partials.dynamicPage.contentBlockImage',
                [
                    'class' => 'left',
                    'image' => $newsItem->large_image_url,
                    'title' => $newsItem->name,
                ])
            @endif

        </div>
        <div class="separator"></div>

    @endforeach

    {{-- Show pagination --}}
    <div class="pagination">
         {{ $pagination }}
    </div>
@stop