RE: [PHP-WIN] Uptime script
| From: | Ben Bleything | Date: | Sat, 14 Jul 2001 16:31:55 +0000 |
| Subject: | RE: [PHP-WIN] Uptime script | ||
| References: | 1 | Groups: | php.windows |
| Request: | Send a blank email to php-windows+get-8322@lists.php.net to get a copy of this message | ||
Have you tried backticks? 'echo
uptime';? That has worked for me in
the past... it seems, from other postings, that people have nothing but
trouble with exec() and system().
Good luck,
Ben
-----Original Message-----
From: Dave Milford [mailto:davemilford@home.com]
Sent: Friday, July 13, 2001 6:50 AM
To: php-windows@lists.php.net
Subject: [PHP-WIN] Uptime script
Hi,
I'm trying to create a little script to show the system uptime (and
hopefully system resource usage) on my Windows 2000 Professional SP2
box.
I'm currently running Apache 1.3.20 and PHP 4.0.6 on it... It should be
noted that I have MS' "uptime" program installed.
So far, I've tried using: system(uptime);
That didn't work. I get the following printed: "Warning: Unable to fork
[uptime] in d:\www\inc_top.html on line 58".
So I hit the PHP website, found out some other methods of doing this,
like:
PRINT exec("cmd \\c uptime");
This time it displays: d:\www>
(that's my HTTPd root dir)
How could I get this displaying my uptime, and maybe even resource
usage?
Any help would be appreciated.
Thanks
---------------------------
Dave Milford
ICQ : 8516328
Email: davemilford@shaw.ca
--
PHP Windows Mailing List (http://www.php.net/)
To unsubscribe, e-mail: php-windows-unsubscribe@lists.php.net
For additional commands, e-mail: php-windows-help@lists.php.net
To contact the list administrators, e-mail: php-list-admin@lists.php.net