Exclude a view from master layout?

折月煮酒 提交于 2019-11-29 18:00:34

Use a different layout for login page:

File app/views/login.blade.php:

@extends('layouts.standalone')

@section('content')
   ...
@stop

And for your other pages:

File app/views/home.blade.php:

@extends('layouts.master')

@section('content')
   ...
@stop

And here your layouts:

File app/views/layouts/standalone.blade.php:

<html>
   <body>
      This is a master layout

      @yield('content')
   </body> 
</html>

File app/views/layouts/master.blade.php:

<html>
   <body>
      This is a standalone layout

      @yield('content')
   </body> 
</html>
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!