blade模版之页面的嵌套

blade模版

相关关键词:@section @yield @extends @extends @show @parent(追加内容而不是覆盖)

父页面viewlayoutf.blade.php

子页面views.blade.php

父页面:

     在子页面的相应位置写上@yield('content');

子页面:

     @extends('layout.f')

     @section('content')

         子页面

     @endsection

原文地址:https://www.cnblogs.com/li-mei/p/4738977.html