Re: [PHP] Question about session_id() and session_start()

2013-05-21 Thread Tim Schofield
On 20/05/2013, Maciek Sokolewicz maciek.sokolew...@gmail.com wrote: On 20-5-2013 22:14, Tim Schofield wrote: Matijn There are well over half a million lines of source code in PHP. It seems a little unhelpful to tell someone to go and read half a million lines of C when you could just tell

Re: [PHP] Question about session_id() and session_start()

2013-05-21 Thread 孟远涛
thank you. I read the source code and it helps a lot, now I know the behavior of the code is consistent with the NOTE. I think the reason is that If the 'new' session_id we want to set already exists on the server, but does not exist on the client's cookie, the server must send a set-cookie header

Re: [PHP] Question about session_id() and session_start()

2013-05-20 Thread Matijn Woudt
On Mon, May 20, 2013 at 5:33 AM, 孟远涛 yuantao.m...@gmail.com wrote: I find the Note in PHP document. http://www.php.net/manual/en/function.session-id.php Note: When using session cookies, specifying an id for session_id() will always send a new cookie when session_start() is called,

Re: [PHP] Question about session_id() and session_start()

2013-05-20 Thread Tim Schofield
Matijn There are well over half a million lines of source code in PHP. It seems a little unhelpful to tell someone to go and read half a million lines of C when you could just tell them the answer? Thanks Tim Course View Towers, Plot 21 Yusuf Lule Road, Kampala T +256 (0) 312 314 418 M +256 (0)

Re: [PHP] Question about session_id() and session_start()

2013-05-20 Thread David OBrien
On Mon, May 20, 2013 at 4:14 PM, Tim Schofield t...@weberpafrica.com wrote: Matijn There are well over half a million lines of source code in PHP. It seems a little unhelpful to tell someone to go and read half a million lines of C when you could just tell them the answer? Thanks Tim

Re: [PHP] Question about session_id() and session_start()

2013-05-20 Thread Maciek Sokolewicz
On 20-5-2013 22:14, Tim Schofield wrote: Matijn There are well over half a million lines of source code in PHP. It seems a little unhelpful to tell someone to go and read half a million lines of C when you could just tell them the answer? Thanks Tim Course View Towers, Plot 21 Yusuf Lule

Re: [PHP] Question about session_id() and session_start()

2013-05-20 Thread Matijn Woudt
On Mon, May 20, 2013 at 10:46 PM, David OBrien dgobr...@gmail.com wrote: On Mon, May 20, 2013 at 4:14 PM, Tim Schofield t...@weberpafrica.com wrote: Matijn There are well over half a million lines of source code in PHP. It seems a little unhelpful to tell someone to go and read half a

Re: [PHP] Question about session_id() and session_start()

2013-05-20 Thread David OBrien
On May 20, 2013 8:45 PM, Matijn Woudt tijn...@gmail.com wrote: On Mon, May 20, 2013 at 10:46 PM, David OBrien dgobr...@gmail.com wrote: On Mon, May 20, 2013 at 4:14 PM, Tim Schofield t...@weberpafrica.com wrote: Matijn There are well over half a million lines of source code in PHP. It

Re: [PHP] Question about session_id() and session_start()

2013-05-20 Thread Matijn Woudt
Op 21 mei 2013 03:59 schreef David OBrien dgobr...@gmail.com het volgende: On May 20, 2013 8:45 PM, Matijn Woudt tijn...@gmail.com wrote: On Mon, May 20, 2013 at 10:46 PM, David OBrien dgobr...@gmail.com wrote: On Mon, May 20, 2013 at 4:14 PM, Tim Schofield t...@weberpafrica.com

[PHP] Question about session_id() and session_start()

2013-05-19 Thread 孟远涛
I find the Note in PHP document. http://www.php.net/manual/en/function.session-id.php Note: When using session cookies, specifying an id for session_id() will always send a new cookie when session_start() is called, regardless if the current session id is identical to the one being set. I feel