Date: 01/13/02
- Next message: Mark Kronsbein: "Re: [PHP-DOC] cvs: phpdoc /en bookinfo.xml"
- Previous message: Gabor Hojtsy: "Re: [PHP-DOC] cvs: phpdoc /en bookinfo.xml"
- In reply to: Philip Olson: "[PHP-DOC] Re: [PHP-DEV] superglobals and bc"
- Next in thread: Philip Olson: "Re: [PHP-DOC] Re: [PHP-DEV] superglobals and bc"
- Reply: Philip Olson: "Re: [PHP-DOC] Re: [PHP-DEV] superglobals and bc"
- Reply: Richard Heyes: "[PHP-DOC] RE: [PHP-DEV] Re: [PHP-DOC] Re: [PHP-DEV] superglobals and bc"
- Reply: Markus Fischer: "[PHP-DOC] Re: [PHP-DEV] Re: [PHP-DOC] Re: [PHP-DEV] superglobals and bc"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
> > I mean, you could check php_version() and stick in some extract() calls
> > for older versions wherever you use the superglobals, but that seems
> > rather ugly.
>
> Some really want it, let's define the most efficient/least ugly types of
> hacks :) For example with get, checking phpversion,
I think it is better to check for the existense of these vars,
not the version!
> then appropriatly
> defining $_GET = &$HTTP_GET_VARS. And in a function, do: global $_GET.
Right :)
> Now mimicking $_SESSION functionality is another story, eww, maybe that's
> going too far.
This can be done by a register_shutdown_function() who registers
all the vars in $_SESSION, using session_register. That's all :))
If I can understand this new feature correctly (I never used it).
> Regarding the extract() idea, please clarify a little more.
I think Rasmus referred to the register_globals deprecation
question, which is another thing IMHO, that need to be documented.
There are many "user notes" coming up about using:
extract($_REQUEST);
and the like to simluate register_globals. This can
be a really bad thing sometimes...
Goba
- Next message: Mark Kronsbein: "Re: [PHP-DOC] cvs: phpdoc /en bookinfo.xml"
- Previous message: Gabor Hojtsy: "Re: [PHP-DOC] cvs: phpdoc /en bookinfo.xml"
- In reply to: Philip Olson: "[PHP-DOC] Re: [PHP-DEV] superglobals and bc"
- Next in thread: Philip Olson: "Re: [PHP-DOC] Re: [PHP-DEV] superglobals and bc"
- Reply: Philip Olson: "Re: [PHP-DOC] Re: [PHP-DEV] superglobals and bc"
- Reply: Richard Heyes: "[PHP-DOC] RE: [PHP-DEV] Re: [PHP-DOC] Re: [PHP-DEV] superglobals and bc"
- Reply: Markus Fischer: "[PHP-DOC] Re: [PHP-DEV] Re: [PHP-DOC] Re: [PHP-DEV] superglobals and bc"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]

