Hello,

 

Looking at switching to Cherokee and I'm running into a strange issue
with some of the PHP variables.

 

Default install, 0.99.7 with php-cgi.  Document root is
/usr/local/www/cherokee/

 

I have a test.php file that just calls phpinfo(); so I can test
functionality.   If I call http://127.0.0.1/test.php   I get the
following:

_SERVER["DOCUMENT_ROOT"] = /usr/local/www/cherokee/

_SERVER["SCRIPT_NAME"]  = /test.php

_SERVER["PHP_SELF"] = /test.php

 

This is correct.   But, if I call http://127.0.0.1/test.php/more I get
the following:

_SERVER["DOCUMENT_ROOT"] = /usr/local/www/cher

_SERVER["SCRIPT_NAME"]  = rokee/test.php

_SERVER["PHP_SELF"] = rokee/test.php/more

 

It seems that the variables get shifted by the number of characters
after the script.   For instance, calling
http://127.0.0.1/test.php/a/b/c/d shows:

_SERVER["DOCUMENT_ROOT"] = /usr/local/www/c

_SERVER["SCRIPT_NAME"]  = cherokee/test.php

_SERVER["PHP_SELF"] = cherokee/test.php/a/b/c/d

 

/a/b/c/d = 8 characters, all three above variables get shifted by 8
characters.  Other variables (PATH_INFO, SCRIPT_FILENAME, etc) all seem
to be correct.   I'm currently using lighttpd with spawn_fcgi to
compare.

 

I also noticed that _ENV["DOCUMENT_ROOT"] is also /usr/local/www/c (last
example), so I think it's coming from there.

 

 

Ideas on what might be happening?

 

 

Sincerely,

 

Jaime Bozza

 

_______________________________________________
Cherokee mailing list
[email protected]
http://lists.octality.com/listinfo/cherokee

Reply via email to