[TYPO3-core] RFC: cli_dispatch.phpsh
Martin.Kutschker at n0spam-blackbox.net
Mon Dec 11 11:09:36 CET 2006
Ernesto Baschny [cron IT] schrieb:
> This is a SVN patch request
> Type: Bugfix
> Kasper added the nice "cli_dispatch.phpsh" script to TYPO3 core. I was
> trying to use it to call some CLI's, but it failed with:
> ERROR: /home/ernst/typo3cvs.cron.stgt.vpn/typo3/ was not a file. Maybe your
> environment does not support running this script with a relative path? Try
> to run the script with its absolute path and you should be fine.
> Neither $_ENV['_'] nor $_SERVER['_'] is set on my server ("standard"
> SuSE Linux with PHP 4.3.8).
> The attached patch just changes the method of finding out the current
> path to using $_SERVER['argv'], which should always be set when
> calling a PHP script from CLI.
* adds SAPI check
* uses $_SERVER['argv'] as first choice
* sets TYPO3_cliKey correctly (for the benefit of the script)
* drops unnecessary $BACK_PATH
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
More information about the TYPO3-team-core