Feralheart Feralheart -4 years ago 198
PHP Question

Laravel: Layouts.master not found

I built the demosite in Laravel, but I got the following error:

ErrorException in FileViewFinder.php line 137: View [layouts.master]
not found.(View:

The master.blade.php is next to the page.blade.php, both are in resources/views


This is the master sidebar.
<div class="container">


@yield('title', 'Page Title')
<p>This is appended to the master sidebar.</p>
<p>This is my body content.</p>

What goes wrong? I working from this tutorial.

Answer Source



They are both at the views root you said. Or create a directory called layouts and place master.blade.php inside.

Updates In your master.blade.php where you want your content to be "injected", do:

//remove @section('content') because your master does not extends any other layout

The exact same way you did with @yield('title').

Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download