php cli 小技巧
程序员文章站
2022-05-21 17:22:14
php代码: 复制代码 代码如下:
php代码:
<?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
复制代码 代码如下:
<?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
上一篇: 幽默恋人幽默笑话