Re: [cgiwrap-users] New php support and PATH_INFO / $PHP_SELF
Brought to you by:
nneul
From: Piotr K. <ma...@ma...> - 2002-09-20 07:25:45
|
On Thu, Sep 19, 2002 at 08:13:08PM -0400, Cedric Veilleux wrote: > I have noticed a problem with the new PHP support. When running wrapped PHP > scripts, the PATH_INFO env var is NULL. PHP uses this variable to generate > $PHP_SELF, which is used by a lot of scripts... The resulting $PHP_SELF is > also null.. > > I am using a 3 days old cgiwrap-cvs with the AddHandler / Action in apache > technique and it works great except for this problem. IMHO PHP is inconsistent in this case, and should be fixed ... In the meantime, you can use SCRIPT_URL variable (if you use Apache): $PHP_SELF = $_SERVER['SCRIPT_URL']; SCRIPT_URL variable contains the self-referencing script URL (including PATH_INFO part) then it is equal to PHP_SELF in php's apache-mod api. -- Piotr Klaban |