php定时运行任务(windows7)

1:自己写的php档,下面是我的一些php档

2:新建.bat文件

写入内容:E:\WampSever\wamp\bin\php\php5.4.12\php.exe -q E:\WampSever\task\Grab1.php

E:\WampSever\wamp\bin\php\php5.4.12\php.exe  这是我的php.exe路径

E:\WampSever\task\Grab1.php  这是我的要定时执行的php文件路径
提示:要是定时执行多个php文件时候仅仅要连起来就能够

E:\WampSever\wamp\bin\php\php5.4.12\php.exe -q E:\WampSever\task\Grab1.php
E:\WampSever\wamp\bin\php\php5.4.12\php.exe -q E:\WampSever\task\Grab2.php
E:\WampSever\wamp\bin\php\php5.4.12\php.exe -q E:\WampSever\task\Grab3.php
E:\WampSever\wamp\bin\php\php5.4.12\php.exe -q E:\WampSever\task\Grab4.php
E:\WampSever\wamp\bin\php\php5.4.12\php.exe -q E:\WampSever\task\Grab5.php
E:\WampSever\wamp\bin\php\php5.4.12\php.exe -q E:\WampSever\task\Grab6.php
E:\WampSever\wamp\bin\php\php5.4.12\php.exe -q E:\WampSever\task\Grab7.php
E:\WampSever\wamp\bin\php\php5.4.12\php.exe -q E:\WampSever\task\Grab8.php
E:\WampSever\wamp\bin\php\php5.4.12\php.exe -q E:\WampSever\task\Grab9.php
E:\WampSever\wamp\bin\php\php5.4.12\php.exe -q E:\WampSever\task\Grab10.php
E:\WampSever\wamp\bin\php\php5.4.12\php.exe -q E:\WampSever\task\Grab11.php
E:\WampSever\wamp\bin\php\php5.4.12\php.exe -q E:\WampSever\task\Grab12.php
E:\WampSever\wamp\bin\php\php5.4.12\php.exe -q E:\WampSever\task\Grab13.php
E:\WampSever\wamp\bin\php\php5.4.12\php.exe -q E:\WampSever\task\Grab14.php
E:\WampSever\wamp\bin\php\php5.4.12\php.exe -q E:\WampSever\task\Grab15.php
E:\WampSever\wamp\bin\php\php5.4.12\php.exe -q E:\WampSever\task\Grab16.php
E:\WampSever\wamp\bin\php\php5.4.12\php.exe -q E:\WampSever\task\Grab17.php
E:\WampSever\wamp\bin\php\php5.4.12\php.exe -q E:\WampSever\task\Grab18.php
E:\WampSever\wamp\bin\php\php5.4.12\php.exe -q E:\WampSever\task\Grab19.php
E:\WampSever\wamp\bin\php\php5.4.12\php.exe -q E:\WampSever\task\Grab20.php
3:bat文件建立OK后就能够建立任务计划程序

触发器里面新建设置运行时间

操作里面新建浏览刚才建立的.bat文件

这是我自己计划任务的设置选项:


条件设置依据自己的需求来设置



版权声明:本文博主原创文章,博客,未经同意不得转载。

posted @ 2015-10-18 14:38  zfyouxi  阅读(344)  评论(0编辑  收藏  举报