NYCPHP Meetup

NYPHP.org

Wow, I feel so stupid Re: [nycphp-talk] $_POST

Webapprentice webapprentice at onemain.com
Sat May 24 22:57:53 EDT 2003


>>Unless you know what host environment you are going to be in, one may 
>>opt to use $HTTP_POST_VARS['foo'].  I've run into several hosts who have 
>>not upgraded the engine, so $_POST doesn't work.
> 
> 
> Unfortunately, this can be an issue.  However, I also try to make the code as
> "forward thinking" as possible.
> 
> $_POST = &$HTTP_POST_VARS;
> 
> at some top level include, or under a conditional that checks for a php
> version, can make migrations easier.  There are still of course global scope
> issues, but it's better than nothing.  But, I feel it's important to use the
> newer superglobals (which aren't even that new anymore).  And of course not
> register_globals!  :)

Holy smokes, I didn't realize that was possible.  Then again, I have not 
used references yet.

@_@




More information about the talk mailing list