From d78e06a328b1f06ae0bbe77a2d96cb304e23878d Mon Sep 17 00:00:00 2001 From: Mateja Date: Tue, 20 Oct 2020 00:05:48 +0200 Subject: Database, controller and news views. --- resources/views/pages/news.blade.php | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'resources/views/pages') diff --git a/resources/views/pages/news.blade.php b/resources/views/pages/news.blade.php index b4a9f19..a8685eb 100644 --- a/resources/views/pages/news.blade.php +++ b/resources/views/pages/news.blade.php @@ -1,4 +1,14 @@ @extends('layouts.app') @section('content') + @foreach($news as $post) +
+

{{ $post->title }}

+ Written at: {{ $post->created_at }} +

{{ $post->text }}

+ @isset ($post->author) + Author: {{ $post->author }} + @endisset +
+ @endforeach @endsection() -- cgit v1.2.3