Uros wrote:
Than this has to be run until I cancel it. But I also want to check
somehow, what this proces is doing right now.
If you want it to be realy nice, use shared memory. But this extension
is not enabled by default and is available only on unices.
--
PHP General Mailing List (http://
#!/usr/local/bin/php -q
Then:
chmod u+x scriptname
./scriptname &
On Mon, 2003-07-07 at 08:41, Uros wrote:
> Hello!
>
> Can somebody give me any workable example how to run some script written in
> PHP in Unix console.
>
> I wan't to write some server aplication. So it has to be run in the
>
> Can somebody give me any workable example how to run some script written in
> PHP in Unix console.
#!/usr/local/bin/php -q
> I wan't to write some server aplication. So it has to be run in the
> backgroud.
Have a look at the process control functions:
http://php.net/pcntl
--
Greg Donald
h
Uros --
...and then Uros said...
%
% Hello!
Hi!
%
% Can somebody give me any workable example how to run some script written in
% PHP in Unix console.
Sure.
php -q /path/to/script/name
(assuming you have the command-line version of php, which you may not,
and that your script doesn't nee
start your PHP files with:
#! /usr/bin/php
Replace /usr/bin/php with the path to php. You will need to make the
file executable by chmod ing it.
(try:
$ chmod +x ./yourscript.php
)
As a side note, starting any text file with #! followed by the path to a
language interpreter, and chmoding the
5 matches
Mail list logo