newbie here, so please forgive me obvious mistakes. To the point:
I have set of 12 computers, each one is running Windows 10. My goal is to make php script which will allow to turn on/off each machine. I've already figured out part with turning via WOL, but I am stuck on turning off.
I do have shell command which works perfectly when typed to cmd.exe directly, so I tried to put it in exec() and shell_exec().
Code was:
<?php exec('shutdown /m \\computer_name /s /f'); ?>
and it did nothing.
Is there any way to make this work? What kind of solution can I use? I tried executing .bat files, but no success, I think my syntax was wrong. Can you show me the right direction?
Server is another Windows 10 machine with WAMP installed.