开发者

php script on iis to copy a folder over a windows network

开发者 https://www.devze.com 2023-03-25 17:49 出处:网络
Im trying to use php to copy a folder and contents including subfolders over a windows network using windows scheduler running a php script.

Im trying to use php to copy a folder and contents including subfolders over a windows network using windows scheduler running a php script.

I want to setup a control panel so a user can access a web page that can edit the scheduler time. Is it possible to edit 开发者_如何学Gothe windows scheduler using php. Also, how can I give php access to the shared folder over the network.


PHP is a poor tool for such a job. Why not use something like xcopy? It'd be far more efficient in a single command, than using what would have to be a many-many line PHP script.

You can have PHP call Windows internally directly via COM which would presumably give you access to the scheduler. However, you'd have to play with the permissions carefully. PHP/webserver would have to have access to the scheduler, and the job would have to run with high enough privileges that it could deal with network resources - the default IIS user account does NOT have those privileges.

0

精彩评论

暂无评论...
验证码 换一张
取 消