简体   繁体   中英

Running PHP file from command line, how do I hide the prompt?

I have a Scheduled Task that runs a PHP file every 5 minutes.

It runs

C:\\wamp\\bin\\php\\php5.5.4.12\\php.exe -f "C:\\wamp\\www\\run.php"

That works fine, but every time it runs it opens the Command Prompt window, then once it's done running it closes it.

How do I make it so the Command Prompt window never displays?

Thank you

You need to make you task run either an user is logged in or not.

there is in option for that in scheduled task

在此处输入图片说明

And with that option you wont see the cmd pop out any more

Edit for solving your question in comment.

Yes you can have the schedule task run every one min with those following option.在此处输入图片说明 7

Re-Edit

Use the following trigger if you want to run the talk every min at computer start在此处输入图片说明

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM