Do you have a question? Post it now! No Registration Necessary. Now with pictures!
- Posted on
- Help with Passthru and wmic...
July 29, 2005, 8:38 pm
rate this thread
echo passthru('wmic cpu get loadpercentage');
and just output to the browser... It looks like cmd.exe hangs when it
tries to execute the command. The IUSR_ account has access to both the
cmd.exe and wmic files. I have also tried copying the wmic files to
the C:\php dir, and to the directory the web app is running from. Any
Re: Help with Passthru and wmic...
You will have to use proc_open to start a process in read/write mode;
$descriptorspec = array(
$process = proc_open("wmic", $descriptorspec, $pipes);
fwrite($pipes, 'cpu get loadpercentage');