Re: Overriding session length in existing session?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



At 5:00 PM -0800 3/3/11, Scott Baker wrote:
On 03/03/2011 04:31 PM, tedd wrote:

 > Simple answer -- put session_start() at the start of your code -- first
 line.

Of index.php or header.php? You lost me.

--
Scott Baker - Canby Telcom

Scott:

The statement should be at the start of every php file that has php code in it.

For example, if you have three web pages (index.php, services.php, and contact.php) AND you have php code in each that share session data, then the first statement in every page should be:

<?php  session_start;

Here's a working example:

http://www.webbytedd.com/b/sessions/index.php

The code is there.

Cheers,

tedd

--
-------
http://sperling.com/

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux