30
32

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.

Laravel セッションクッキーの有効期間をブラウザを閉じるまでにする

Last updated at Posted at 2014-04-28

Laravel 4.1 では、セッションクッキーの有効期間がデフォルトでは 2 時間になっています。

これをブラウザが閉じたら、クッキーを破棄するようにします。

方法は、app/config/session.phpの設定をかえるだけ。

    'expire_on_close' => true, // デフォルト false なので、true に変更

楽ちん。

30
32
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
30
32

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?