Solved

Session Variable in php

Posted on 2006-11-15
4
205 Views
Last Modified: 2007-01-02
I have web pages on a local intranet which are used by different users in the office.  

Some forms require the user to do research then input the data.  If the user waits to long between requests the session variable expires.  I think.  I takes them back to a login.

When would I tell php not time time out the session variable?

In the php.ini file?
0
Comment
Question by:jmsloan
4 Comments
 
LVL 19

Accepted Solution

by:
VoteyDisciple earned 50 total points
ID: 17950834
You can do it in the php.ini file, or you can call ini_set('session.gc_maxlifetime', 3600);

3600 being 60 seconds * 60 minutes.  You can use any value you want.
0
 
LVL 18

Expert Comment

by:ingwa
ID: 17954915
Additionally, you can change the session paremeter in your php.ini file.  That would then ensure that it's system wide, and not script specific.
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article will explain how to display the first page of your Microsoft Word documents (e.g. .doc, .docx, etc...) as images in a web page programatically. I have scoured the web on a way to do this unsuccessfully. The goal is to produce something …
Foreword (July, 2015) Since I first wrote this article, years ago, a great many more people have begun using the internet.  They are coming online from every part of the globe, learning, reading, shopping and spending money at an ever-increasing ra…
The viewer will learn how to look for a specific file type in a local or remote server directory using PHP.
The viewer will learn how to create and use a small PHP class to apply a watermark to an image. This video shows the viewer the setup for the PHP watermark as well as important coding language. Continue to Part 2 to learn the core code used in creat…

867 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

22 Experts available now in Live!

Get 1:1 Help Now