LoginSignup
0
1

More than 3 years have passed since last update.

Laravel:リダイレクトの記載

Posted at

【概要】

1.どのように記載するか

2.開発環境

1.どのように記載するか

redirect()->route( ルート名 , 配列 )
redirect()->action( アクション名 , 配列 )
redirect()->view( ビュー名 , 配列 )
redirect()->download( ファイルパス名 )
redirect()->file( ファイルパス名 )

・ルート名は、Laravelでよく使う"web.phpに記載してあるルート情報になります。
・アクション名は、"XXXXController@index","XXXXController@show"などになります。
・ビュー名は、直接"XXXX.index"などが入ります。
・ファイルパス名は、イメージファイル名やファイルパスをテキストで記載します。


2.開発環境

PHP 7.4.10
Laravel 8.9

0
1
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
0
1