@extends('frontEnd.layout') @section('content')
@if($Topics->total() == 0)
  {{ __('frontend.noData') }}
@else
@if($Topics->total() > 0) code; $title_var2 = "title_" . env('DEFAULT_LANGUAGE'); $details_var = "details_" . @Helper::currentLanguage()->code; $details_var2 = "details_" . env('DEFAULT_LANGUAGE'); $slug_var = "seo_url_slug_" . @Helper::currentLanguage()->code; $slug_var2 = "seo_url_slug_" . env('DEFAULT_LANGUAGE'); $i = 0; ?> @foreach($Topics as $Topic) $title_var != "") { $title = $Topic->$title_var; } else { $title = $Topic->$title_var2; } if ($Topic->$details_var != "") { $details = $details_var; } else { $details = $details_var2; } $section = ""; try { if ($Topic->section->$title_var != "") { $section = $Topic->section->$title_var; } else { $section = $Topic->section->$title_var2; } } catch (Exception $e) { $section = ""; } // set row div if (($i == 1 && count($Categories) > 0) || ($i == 2 && count($Categories) == 0)) { $i = 0; echo "
"; } $topic_link_url = Helper::topicURL($Topic->id); ?>
@if($Topic->webmasterSection->type==2 && $Topic->video_file!="") {{--video--}}

@if($Topic->icon !="")   @endif {{ $title }}

@if($Topic->video_type ==1) video_file); ?> @if($Youtube_id !="") {{-- Youtube Video --}} @endif @elseif($Topic->video_type ==2) video_file); ?> @if($Vimeo_id !="") {{-- Vimeo Video --}} @endif @elseif($Topic->video_type ==3) @if($Topic->video_file !="") {{-- Embed Video --}} {!! $Topic->video_file !!} @endif @else @endif
@elseif($Topic->webmasterSection->type==3 && $Topic->audio_file!="") {{--audio--}}

@if($Topic->icon !="")   @endif {{ $title }}

@if($Topic->photo_file !="") {{ $title }} @endif
@elseif(count($Topic->photos)>0) {{--photo slider--}}

@if($Topic->icon !="")   @endif {{ $title }}

    @if($Topic->photo_file !="")
  • {{ $title }}
  • @endif @foreach($Topic->photos as $photo)
  • {{ $photo->title  }}
  • @endforeach
@else {{--one photo--}}

@if($Topic->icon !="")   @endif {{ $title }}

@if($Topic->photo_file !="") {{ $title }} @endif
@endif {{--Additional Feilds--}} @if(count($Topic->webmasterSection->customFields->where("in_listing",true)) >0)
code; $cf_title_var2 = "title_" . env('DEFAULT_LANGUAGE'); ?> @foreach($Topic->webmasterSection->customFields->where("in_listing",true) as $customField) view_permission_groups != "") { $view_permission_groups = explode(",", $customField->view_permission_groups); } if (in_array(0, $view_permission_groups) || $customField->view_permission_groups=="") { // have permission & continue ?> @if ($customField->in_listing) $cf_title_var != "") { $cf_title = $customField->$cf_title_var; } else { $cf_title = $customField->$cf_title_var2; } $cf_saved_val = ""; $cf_saved_val_array = array(); if (count($Topic->fields) > 0) { foreach ($Topic->fields as $t_field) { if ($t_field->field_id == $customField->id) { if ($customField->type == 7) { // if multi check $cf_saved_val_array = explode(", ", $t_field->field_value); } else { $cf_saved_val = $t_field->field_value; } } } } ?> @if(($cf_saved_val!="" || count($cf_saved_val_array) > 0) && ($customField->lang_code == "all" || $customField->lang_code == @Helper::currentLanguage()->code)) @if($customField->type ==12) {{--Vimeo Video Link--}} @elseif($customField->type ==11) {{--Youtube Video Link--}} @elseif($customField->type ==10) {{--Video File--}} @elseif($customField->type ==9) {{--Attach File--}} @elseif($customField->type ==8) {{--Photo File--}} @elseif($customField->type ==7) {{--Multi Check--}}
{!! $cf_title !!} :
code; $cf_details_var2 = "details_en" . env('DEFAULT_LANGUAGE'); if ($customField->$cf_details_var != "") { $cf_details = $customField->$cf_details_var; } else { $cf_details = $customField->$cf_details_var2; } $cf_details_lines = preg_split('/\r\n|[\r\n]/', $cf_details); $line_num = 1; ?> @foreach ($cf_details_lines as $cf_details_line) @if (in_array($line_num,$cf_saved_val_array)) {!! $cf_details_line !!} @endif @endforeach
@elseif($customField->type ==6) {{--Select--}}
{!! $cf_title !!} :
code; $cf_details_var2 = "details_en" . env('DEFAULT_LANGUAGE'); if ($customField->$cf_details_var != "") { $cf_details = $customField->$cf_details_var; } else { $cf_details = $customField->$cf_details_var2; } $cf_details_lines = preg_split('/\r\n|[\r\n]/', $cf_details); $line_num = 1; ?> @foreach ($cf_details_lines as $cf_details_line) @if ($line_num == $cf_saved_val) {!! $cf_details_line !!} @endif @endforeach
@elseif($customField->type ==5) {{--Date & Time--}}
{!! $cf_title !!} :
{!! Helper::formatDate($cf_saved_val)." ".date("h:i A", strtotime($cf_saved_val)) !!}
@elseif($customField->type ==4) {{--Date--}}
{!! $cf_title !!} :
{!! Helper::formatDate($cf_saved_val) !!}
@elseif($customField->type ==3) {{--Email Address--}}
{!! $cf_title !!} :
{!! $cf_saved_val !!}
@elseif($customField->type ==2) {{--Number--}}
{!! $cf_title !!} :
{!! $cf_saved_val !!}
@elseif($customField->type ==1) {{--Text Area--}} @else {{--Text Box--}}
{!! $cf_title !!} :
{!! $cf_saved_val !!}
@endif @endif @endif @endforeach
@endif {{--End of -- Additional Feilds--}}

{!! mb_substr(strip_tags($Topic->$details),0, 300)."..." !!}

{{ __('frontend.readMore') }}
@endforeach
{!! $Topics->links() !!}

{{ $Topics->firstItem() }} - {{ $Topics->lastItem() }} {{ __('backend.of') }} ( {{ $Topics->total() }} ) {{ __('backend.records') }}
@endif @endif
@if(count($Categories)>0) @include('frontEnd.includes.side') @endif
@endsection