note 26468 deleted from language.variables.scope by danbrown

From: Date: Wed, 11 Nov 2009 15:52:15 +0000
Subject: note 26468 deleted from language.variables.scope by danbrown
References: 1  Groups: php.notes 
Request: Send a blank email to php-notes+get-162763@lists.php.net to get a copy of this message
Note Submitter: jez at india dot com ---- If anyone needs a permanent array / hash, similar in functionality to ASP's application object, check out the article on http://zez.org/article/articleview/46/1/ which has some working code (written by me) attached. This code implements a hash with application scope, i.e. its contents can be accessed from all php scripts running on the same computer. You could use it, for example, to globally cache configuration settings for a site. The hash is also cached in the db, i.e. it's inviolable. Its contents are buffered in memory, so there's no hit on the db when accessing the hash apart from the first time you read it, and of course when you write to it.

« previous php.notes (#162763) next »