Laravel 6.8 return 404 找不到页面
Laravel 6.8 return 404 not found page
我的 laravel 返回 404 页面未找到除“/”之外的所有页面。
以下是我的路线。
Route::get('/', function () {
return view('welcome');
});
Route::get('/hello', function () {
return '<h1>Hello World</h1>';
});
这是我的url
http://localhost/cultural-heritagedp/public/hello
试试这个
Route::get('/hello', function () {
return "Hello World";
});
然后
php artisan route:list
通过运行命令行中的以下命令启动开发服务器
php artisan serve
之后尝试浏览到
localhost:8000
然后
localhost:8000/hello
我的 laravel 返回 404 页面未找到除“/”之外的所有页面。 以下是我的路线。
Route::get('/', function () {
return view('welcome');
});
Route::get('/hello', function () {
return '<h1>Hello World</h1>';
});
这是我的url
http://localhost/cultural-heritagedp/public/hello
试试这个
Route::get('/hello', function () {
return "Hello World";
});
然后
php artisan route:list
通过运行命令行中的以下命令启动开发服务器
php artisan serve
之后尝试浏览到
localhost:8000
然后
localhost:8000/hello