php cli 小技巧_php技巧
程序员文章站
2022-04-05 21:01:04
...
php代码:
var_dump($argv);
Shell/批处理代码
@echo off
:BEGIN
set /p input=any key to run or "c" exit:
if "%input%"=="c" goto END
goto RUN
:RUN
..\bin\php.exe -r "echo \"\r\n\r\n\";"
..\bin\php.exe run.php %input%
..\bin\php.exe -r "echo \"\r\n\r\n\";"
goto BEGIN
:END
exit
复制代码 代码如下:
var_dump($argv);
Shell/批处理代码
复制代码 代码如下:
@echo off
:BEGIN
set /p input=any key to run or "c" exit:
if "%input%"=="c" goto END
goto RUN
:RUN
..\bin\php.exe -r "echo \"\r\n\r\n\";"
..\bin\php.exe run.php %input%
..\bin\php.exe -r "echo \"\r\n\r\n\";"
goto BEGIN
:END
exit
上一篇: PHP集成百度Ueditor 1.4.3
下一篇: Redis源码解析1