-1

I'm having a difficult time making sense of sessions.

I am working on a project and the first part will be a login form including username, email, and password. Neither of them has set parameters so whatever the user enters, they will be able to see a table with data in it.

After they enter the credentials, how do I start the session and include a time period to lock the user after 30 mins of inactivity?

Also, for this table that will appear after login, is there anyone I can include that on the same page or should it be redirected to another file?

Any help would be greatly appreciated!

Funk Forty Niner
  • 74,450
  • 15
  • 68
  • 141
Stackhouse
  • 73
  • 6

1 Answers1

0

You can start a PHP session via session_start(). Once the session is started you can store values in the $_SESSION array; in your case this could be the username, e-mail and password. Later on you can retrieve the values from $_SESSION.

Tom
  • 122
  • 2
  • 9
  • You should read their question again. They also state: *"After they enter the credentials, how do I start the session and include a time period to lock the user after 30 mins of inactivity?"*. – Funk Forty Niner Nov 14 '18 at 18:35
  • @FunkFortyNiner would you be able to explain that to me? – Stackhouse Nov 14 '18 at 21:01