You are here: Re: Persistent global variable? « PHP Programming Language « IT news, forums, messages
Re: Persistent global variable?

Posted by Oli Filth on 12/16/36 11:59

David Gillen said the following on 27/09/2006 17:22:
> An noise sounding like Oli Filth said:
>> howachen@gmail.com said the following on 27/09/2006 16:49:
>>> Hi,
>>>
>>> Are there something like a `Persistent global variable` in PHP?
>>>
>>> It is something like `Application` in the classic ASP, all the request
>>> share the same variable, and the die after a timeout.
>>>
>> Sessions.
>> http://php.net/manual/features.sessions.php
>>
>> Be aware that sessions are not cross-user though. Each user has their
>> own set of independent persistent variables.
>>
> Pass the same session id to session_id() after you start the session should
> give you the same session for all users. A bit hacky though. If it even works.
> Can't see why it wouldn't though.
>

Of course, that then presents the users from having any "personal"
variables at all...


--
Oli

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация