[Xitami] $PHP_SELF variable
Paul Reid
xitami@lists.xitami.org
Tue, 13 Nov 2001 21:17:34 -0500
> describe this a little more in detail to me? Not on the list but in private?
I'm not being secretive--- I just don't have my notes handy. It
is a fairly common issue here so (now that I am at the machine
with my hacks) I will reply here.
In Defaults.cfg:
[Filter]
.php=C:/php/patchphp.bat
patchphp.bat is:
@set path_translated=%1
@C:\php\php.exe
Notes:
When Xitami sees a ".php" file, it calls the BAT file which sets
the environment variable and then calls PHP.exe.
I found this was needed for PHP 4, was not needed for PHP 3.
If you use other extensions for PHP scripts, you will need more
entries in Defaults.cfg.
The "@" prevents DOS from writing to output. (I hate to do that,
but DOS's gibberish confuses things.)
Forward/slash in Xitami config files; back\slash in DOS. (Both
places *may* work the other way... but this is the preferred
syntax for unix-think Xitami and DOS-think Windows.)
I assume "C:" drive and the customary installation directories.
Adapt to your situation.
-PRR