title: php how to preserve session state for prolonged period of time? troubles
body: <p>I'm having trouble preserving session state for a prolonged period of time. I use sessions to preserve login state. I require the below snippet of code at the top of each of my pages before any other code. First off, is there any settings I'm missing?</p>
  
  <pre><code>session_cache_expire(2880); //set session to expire in 48 hours 
  session_start();
  </code></pre>
  
  <p>Some people are logged out before the 48 hour expiration time. What types of things could cause this? I know closing the browser kills the session and this is not the case. </p>
  
  <p>As far as I can tell it happens when the user is inactive for several hours or more.</p>
  
  <p>Users are never logged off while actively browsing the site.</p>
  
  <p>What gives? </p>