@extends('admin.layouts.app') @section('title', 'View Content Section') @section('content')

Content Section: {{ $contentSection->title }}

Section Details
@if($contentSection->is_active) Active @else Inactive @endif
Section Key:
{{ $contentSection->section_key }}
Title:
{{ $contentSection->title }}
Content:
@if($contentSection->content)
{!! nl2br(e($contentSection->content)) !!}
@else No content provided @endif
@if($contentSection->image_path)
Image:
{{ $contentSection->title }}
{{ $contentSection->image_path }}
@endif
Sort Order:
{{ $contentSection->sort_order }}
@if($contentSection->data && count($contentSection->data) > 0)
Additional Data:
{{ json_encode($contentSection->data, JSON_PRETTY_PRINT) }}
@endif
Created:
{{ $contentSection->created_at->format('F d, Y \a\t H:i') }}
Last Updated:
{{ $contentSection->updated_at->format('F d, Y \a\t H:i') }}
@if($contentSection->content)
Content Preview (Rendered)
{!! $contentSection->content !!}
This is how the content will appear on the website
@endif
Quick Actions
Edit Section @if($contentSection->is_active)
@csrf @method('PUT') @if($contentSection->data) @endif
@else
@csrf @method('PUT') @if($contentSection->data) @endif
@endif
@csrf @method('DELETE')
Usage Information
Template Usage:

To use this content section in your Blade templates, you can retrieve it using:

$section = ContentSection::where('section_key', '{{ $contentSection->section_key }}')->first();
Display in View:
{{ '{' }}{{ '{' }} $section->title {{ '}' }}{{ '}' }}
{{ '{' }}!! $section->content !!{{ '}' }}
@endsection