velkrosmaak Posted December 4, 2006 Share Posted December 4, 2006 Hello there! I've just signed up to the forums, have been experimenting with PHP on and off for a while, but now am starting to get quite into it.Am running the xampp server on my PC, with apache, php, mysql, etc etc.I'm trying to code a little control center type web page, that's designed to fit on the screen of a pda (so I can remote control it using Wifi). I'm sure there must be a way to send commands to a command line from php, so that I can restart my pc, for example, or run launch a program remotely, that sort of thing.another thing maybe, fetching data from motherboard monitor (a program which measures CPU temperatures, that sort of thing) and displaying that on the page too.basically i'm asking how to use php to interact with other applications on my PC, in quite a basic way. Thanks in advance for any help! Link to comment https://forums.phpfreaks.com/topic/29406-running-command-line-apps-using-php/ Share on other sites More sharing options...
keeB Posted December 4, 2006 Share Posted December 4, 2006 http://php.net/exec will give you exactly what you need. Usage example:[code=php:0]$returned = exec("ps -ef", &$returned);[/code] Link to comment https://forums.phpfreaks.com/topic/29406-running-command-line-apps-using-php/#findComment-134926 Share on other sites More sharing options...
velkrosmaak Posted December 4, 2006 Author Share Posted December 4, 2006 Erm... I don't suppose you could elaborate a bit on that example? I'm not [i]that[/i] experienced unfortunately...thanks Link to comment https://forums.phpfreaks.com/topic/29406-running-command-line-apps-using-php/#findComment-134928 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.