Check for Session timeout in Laravel

后端 未结 3 867
有刺的猬
有刺的猬 2020-12-04 16:03

I was just wondering if anyone knew how to check for session timeout in Laravel.

You can check whether the session has a specific item:

if (Session:         


        
3条回答
  •  天命终不由人
    2020-12-04 16:49

    BTW, Specifically if you need the session lifetime,

    Use this:

    {{ session('lifetime') }}
    

    When describing this,

    Use this:

    session(['User' => $user, 'lifetime' => 3600]);
    

提交回复
热议问题