Re: Alternative session control system
| From: | Bastien | Date: | Mon, 26 Dec 2011 14:33:51 +0000 |
| Subject: | Re: Alternative session control system | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-316100@lists.php.net to get a copy of this message | ||
On 2011-12-26, at 7:04 AM, "Francisco M. Marzoa Alonso" <francisco@marzoa.com>
wrote:
> Hello,
>
> I need an alternative session control system different from the PHP
> standard one, that does not need to use the headers, because it's for a
> series of scripts that will be accessed through AJAX javascript code
> inserted in different places of a web page which headers I do not
> control, so I cannot do an start_session before headers sent or
> setcookies neither.
>
> I have an idea on how to solve this, based on client IP, but if there is
> something done yet, I do not want to reinvent the wheel from scratch.
>
> Thanks a lot in advance,
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>
The initial page load will contain some HTML and the js code needed for the app to work. This is the
perfect place to launch the session and set the session cookie and the standard HTML headers. Ajax
will only start after that initial page load and won't affect the first time the app is
accessed
Bastien Koert