How to Increase Session Time in Laravel?

Hi Dev,

This article goes in definite on the most proficient method to increment meeting break in laravel. you will figure out how to set meeting lifetime in laravel. I might want to tell you the best way to set meeting break in laravel 7. we will assist you with giving illustration of laravel increment meeting break.

You can undoubtedly increment meeting lifetime in laravel 5, laravel 6, laravel 7, laravel 8 and laravel 9 rendition.

To build your meeting life time then you can undoubtedly do it from setup record in laravel. laravel give session.php there is a ‘lifetime’ key choice for setting time in minutes. in meeting design record there is a likewise a few choice for set driver, break, expire_on_close and encode and so on.

Fundamentally, you can not set lifetime meeting everlastingly yet you can set in minutes for meeting lapse time. so I will set 1 year time for meeting lapse.

Here i will show how to increase Time from env file and configuration file. so let’s see both example as bellow:

Solution 1: Using .env File

you can simple define value in minutes in your env file as bellow:

.env

SESSION_LIFETIME=86400

Solution 2: Using Config File

config/session.php

<?php
  
use Illuminate\Support\Str;
  
return [
  
    .....
  
    'lifetime' => env('SESSION_LIFETIME', 86400),
  
    .....
  
] 

I hope it can help you….

0 0 votes
Article Rating
Subscribe
Notify of
guest

This site uses Akismet to reduce spam. Learn how your comment data is processed.

0 Comments
Inline Feedbacks
View all comments
0
Would love your thoughts, please comment.x
()
x