8
4

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

Laravel5.7: トップページを作る

Last updated at Posted at 2017-10-06

現状ではトップページ用のビューにはwelcome.blade.phpが使われていますが、新たに自作します。

親記事

Laravel 5.7で基本的なCRUDを作る - Qiita

トップページのビューを作る

下記の内容でファイルを新規作成します。
:page_facing_up: resources/views/top.blade.php

使用するビューを変更する

routes/web.php
  Route::get('/', function () {
-     return view('welcome');
+     return view('top');
  });

表示を確認する

ブラウザでトップページを開いて、下のように表示されれば成功です。

001.png

8
4
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
8
4

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?