我想显示具有以下代码视图:PHPLaravel:我如何显示搜索
{!! Stored in /resources/views/about.blade.php !!}
@extends('layouts.app')
@section('title')
Conway's Game Of Life - About
@endsection
@section('content')
<h2>Conway's Game Of Life - About</h2>
<p>The Game of Life, also known simply as Life, is a cellular automaton devised by the British mathematician John Horton Conway in 1970.</p>
@endsection
然后将下面的主刀页:
<!-- Stored in /resources/views/layouts/app.blade.php --> <title>@yield('title')</title>
@yield('content')
在这之后的路线。 PHP有:
Route::get('/', function() {
return view('index');
});
Route::get('/about/', function() {
return view('about');
});
Route::get('/about/', '[email protected]');
我收到以下错误:
`FileViewFinder.php中的InvalidArgumentException行137:
View [index.blade] not found。
FileViewFinder.php 137行中的ErrorException:
未找到[index.blade]。 (View:C:\ Bitnami \ wampstack-5.5.30-0 \ apache2 \ htdocs \ GameOfLife \ resources \ views \ layouts \ app.blade.php)
FileViewFinder.php中的ErrorException 137行:
View [index .blade]找不到。 (查看:C:\ Bitnami \ wampstack-5.5.30-0 \ apache2 \ htdocs \ GameOfLife \ resources \ views \ layouts \ app.blade.php)(查看:C:\ Bitnami \ wampstack-5.5.30-0 \ apache2 \ htdocs \ GameOfLife \ resources \ views \ layouts \ app.blade.php)`
我该做些什么才能避免出错?
感谢您帮助我摆脱困境!
PS,建议:下面
无论答案找到一个解决问题的办法。这可以是我使用PHP7,而不是任何较小的版本?它可能影响Laravel程序代码的执行。
它是'@ extends'。 – lagbox