Justtechjobs.com Find a programming school near you






Online Campus Both


php3-list | 199807

RE: [PHP3] Example of du From: Brian S. Craigie (Brian.Craigie <email protected>)
Date: 07/14/98

On 15-Jul-98 David Deutsch wrote:
> Could some post a sample piece of code that uses the "du -s" command and
> ereg's the output to display the byte count only.

On Solaris 2.5 and hp-ux 10.20 :-
# du -s
3112 .

If you want to get rid of the ' .', you can use:-

du -s | awk ' { print $1 } '
3112

You could then exec() the command.

I think du is one of the commands that differs per O/S.

> --D

Cheers!
Brian

--
PHP 3 Mailing List   http://www.php.net/
To unsubscribe send an empty message to php3-unsubscribe <email protected>
To subscribe to the digest list:  php3-digest-subscribe <email protected>
For help: php3-help <email protected>  Archive: http://www.tryc.on.ca/php3.html