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

« Back to your topics

{{ $topic->title }}

{{ Carbon\Carbon::createFromTimeStamp(strtotime($topic->created_at))->diffForHumans() }} by {{ '@' . App\User::findOrFail($topic->user_id)->name }}
@can ('delete', $topic)
{{ method_field('DELETE') }} {{ csrf_field() }}
@endcan @if (Auth::check()) @endif
{{ count($posts) }}
@if (count($posts)) @foreach ($posts as $post)
{{ $topic->title }} image {{ Carbon\Carbon::createFromTimeStamp(strtotime($post->created_at))->diffForHumans() }} by {{ '@' . $user = App\User::findOrFail($post->user_id)->name }}


{!! GrahamCampbell\Markdown\Facades\Markdown::convertToHtml( $post->body ) !!}

@can ('edit', $post) Edit @endcan @can ('delete', $post)
{{ method_field('DELETE') }} {{ csrf_field() }}
@endcan
@endforeach @else

The are currently no posts for this topic.

@endif
@if (Auth::check())
@if ($errors->has('post'))
{{ $errors->first('post') }}
@endif
Feel free to use Markdown. Use @username to mention another user.
{{ csrf_field() }}
@else

Please register and login to join the conversation.

@endif
@endsection