使用PHP将任务添加到Windows调度程序

使用PHP将任务添加到Windows调度程序

问题描述:

我找不到有关使用PHP向Windows Task Scheduler添加任务的任何信息.我可以使用exec().

I'm unable to find any information on adding tasks to Windows Task Scheduler with PHP. I can use exec().

这必须在IIS上起作用.

This has to work on IIS.

Windows Schedule Task具有一个名为Schtasks的命令行实用程序,您可以使用该实用程序将任务添加到Scheduled Task List中.

Windows Schedule Task has a command line utility called Schtasks you can use this utility to add your task to Scheduled task list.

请浏览URL,以获取Schtasks的语法 http://technet.microsoft.com/zh-cn/library/cc772785%28WS.10%29.aspx#BKMK_run

Please go thru the URL for syntax of Schtasks http://technet.microsoft.com/en-us/library/cc772785%28WS.10%29.aspx#BKMK_run