I have an idea, and i have a single php local web page running on localhost
and i want to use GUI for 3 buttons : shut down , sleep and restart
Is PHP allows to me for these operations? Are there ready to write classes, methods in PHP?
If your Apache/PHP configuration is setup to allow the use of
system, then you can use that.
For *nix systems:
system('shutdown -r now'); // shutdown // or system('reboot'); // reboot
system('shutdown -t -s 0'); // shutdown // or system('shutdown -r -t 0'); // reboot
As far as sleep/standby on *nix is concerned, it varies a lot.
Note: You can also use