[EMAIL PROTECTED]>
To: "Michael Collins" <[EMAIL PROTECTED]>
Cc: <[EMAIL PROTECTED]>
Sent: Sunday, July 04, 2004 2:57 AM
Subject: Re: [PHP] user-defined superglobals
> Michael Collins wrote:
>
> > I am relatively new at PHP and wondering why there is no mechanism to
every script. For performance reasons it would be much better if certain
values or code could be cached, as is the case with the ASP global.asa
file. If the files and scope was limited to an application, or Web site,
then a certain level of security should be possible.
Well if you're looking fo
At 2:57 AM -0400 7/4/04, John W. Holmes wrote:
Michael Collins wrote:
I am relatively new at PHP and wondering why there is no mechanism
to create user-defined superglobals? For example in ASP.Net I can
setup a global.asa to define database connections or any named
value I want to be available a
Michael Collins wrote:
I am relatively new at PHP and wondering why there is no mechanism to
create user-defined superglobals? For example in ASP.Net I can setup a
global.asa to define database connections or any named value I want to
be available anywhere in an application. It would be great to
Hello,
I am not a programmer so I do not know if you can create a "superglobal
variable". I am sure there is a problem with this ... any ways I user:
"require("db_access.php");"
at the top of all my pages that require db access for a application that
way the db access gets set on a per
I am relatively new at PHP and wondering why there is no mechanism to
create user-defined superglobals? For example in ASP.Net I can setup
a global.asa to define database connections or any named value I want
to be available anywhere in an application. It would be great to have
something like t
>It would be nice to have a php-function like
>
>declare_superglobal($_MYFRAMEWORK);
>
>And then use $_MYFRAMEWORK like $_GET.
You have a few options: if you are looking to set variables that are
static and atomic, you can use environmental variables in an .htaccess
file (getenv() to access them)
Hi Jason Sheets, you wrote:
Someone wrote a php module that did this around 6 to 9 months ago. It
was easy to install but you needed access to php.ini.
Do you know where to get/download this module?
Regards,
Matthias
Try using extract with the option to use references so you don't create
a copy
Someone wrote a php module that did this around 6 to 9 months ago. It
was easy to install but you needed access to php.ini.
Try using extract with the option to use references so you don't create
a copy of the variable just a pointer to it.
Jason
Matthias Nothhaft wrote:
Sorry this all is no
* Thus wrote Matthias Nothhaft ([EMAIL PROTECTED]):
> Hi List,
>
> is there a way (mybe in php5?) to define/declare a global var as a
> superglobal, so that I can use this var like the known superglobals
> ($_GET, $_SESSION, etc.) ???
>
> If not, is there a list for "feature requests"?
You can
lt;[EMAIL PROTECTED]>
Sent: Saturday, August 23, 2003 11:44 AM
Subject: Re: [PHP] user-defined superglobals?
> Sorry this all is not what I'm looking for.
> I see it is not possible at the moment.
>
> It would be nice to have a php-function like
>
> declare_superglobal($
Sorry this all is not what I'm looking for.
I see it is not possible at the moment.
It would be nice to have a php-function like
declare_superglobal($_MYFRAMEWORK);
And then use $_MYFRAMEWORK like $_GET.
Thanks nevertheless.
Regards,
Matthias
Ray Hunter wrote:
Well, this is clear, (I'm only new
Hi,
Sunday, August 24, 2003, 3:45:33 AM, you wrote:
MN> Hi List,
MN> is there a way (mybe in php5?) to define/declare a global var as a
MN> superglobal, so that I can use this var like the known superglobals
MN> ($_GET, $_SESSION, etc.) ???
MN> If not, is there a list for "feature requests"?
Hi Ray Hunter, you wrote:
you can define your own superglobals by defining the vars first then
accessing them thru the $GLOBALS var.
example:
function test() {
echo $GLOBALS['var1'];
echo $GLOBALS['var2'];
echo "Test\n"
}
test();
?>
That should get you started with globals.
Well, this i
you can define your own superglobals by defining the vars first then
accessing them thru the $GLOBALS var.
example:
That should get you started with globals.
--
BigDog
On Sat, 2003-08-23 at 11:45, Matthias Nothhaft wrote:
> Hi List,
>
> is there a way (mybe in php5?) to define/declare a g
Hi List,
is there a way (mybe in php5?) to define/declare a global var as a
superglobal, so that I can use this var like the known superglobals
($_GET, $_SESSION, etc.) ???
If not, is there a list for "feature requests"?
Regards,
Matthias
--
PHP General Mailing List (http://www.php.net/)
To uns
16 matches
Mail list logo