Web Hosting Talk







View Full Version : How in PHP detect how much disc space user use?


Milos
02-06-2002, 10:03 AM
Hi,
we creating our own control panel but don't know how detect how much disc space a customer use. We do all in PHP4. We need to know e.g. "this customer use currently 40MB out of 200MB total".

Is it easy, or it is little bit more complicated?

Thanks a lot.
Milos

priyadi
02-06-2002, 10:45 AM
The easiest way to do that is parsing the output of 'repquota'. Capture the output to a variable by using shell_exec. Then parse it the usual way.