@extends('layouts.app') @section('content')

@lang('global.content-pages.title')

{{ ucfirst($content_page->title) }} {{$content_page->created_at->diffForHumans()}}
@php $cols = 8; if ( $content_page->category_id->count() ) { $otherarticles = \App\ContentPage::where('id', '!=', $content_page->id)->whereHas("category_id", function ($query) use( $content_page ) { $query->where('id', $content_page->category_id->pluck('id')->toArray()); })->limit(10)->orderBy('id', 'desc'); if ( $otherarticles->count() == 0 ) { $cols = 12; } } else { $cols = 12; } @endphp
@if($content_page->featured_image && file_exists(public_path() . '/thumb/' . $content_page->featured_image))
@endif
@if( $content_page->page_text ) {!! clean($content_page->page_text) !!} @endif
@if($content_page->category_id->count())
@lang('custom.articles.category')
@foreach ($content_page->category_id as $singleCategoryId) {{ $singleCategoryId->title }} @endforeach
@endif @if($content_page->tag_id->count())
@lang('custom.articles.tag')
@foreach ($content_page->tag_id as $singleCategoryId) {{ $singleCategoryId->title }} @endforeach
@endif
@if( $cols == 8 )

@lang('custom.articles.related-pages')


    @foreach( $otherarticles->get() as $oarticle)
  • {{$oarticle->title}}

    @if( $oarticle->page_text ) {!! clean($oarticle->page_text) !!} @endif

    {{$oarticle->created_at->diffForHumans()}}

  • @endforeach
@endif

 

@lang('global.app_back_to_list')
@stop @section('javascript') @parent @include('admin.common.standard-ckeditor') @stop