Personal Web Space usage meter

Web hosting, FTP/database access, mirror services and hosted blogs
Post Reply
User avatar
stevebow
Posts: 192
Joined: Tue Oct 12, 2004 12:11 pm
Location: Sydney

Personal Web Space usage meter

Post by stevebow » Fri May 24, 2019 10:46 am

I have 200 MB quota allocated for my personal web space. Is there a way to tell how much of this quota has been used in MyExetel?

User avatar
KavindaS
Forum Admin
Posts: 2364
Joined: Wed Dec 23, 2009 3:59 pm
Location: Sydney

Re: Personal Web Space usage meter

Post by KavindaS » Fri May 24, 2019 4:07 pm

stevebow wrote:
Fri May 24, 2019 10:46 am
I have 200 MB quota allocated for my personal web space. Is there a way to tell how much of this quota has been used in MyExetel?
Currently there is no such option for the free web space (home.exetel.com.au ) facility in MyExetel.

However, the facility may available in future with our scheduled plan developments, and current we cannot confirm with an estimated time frame.

John Baird
Posts: 40
Joined: Fri Sep 23, 2005 10:36 am

Re: Personal Web Space usage meter

Post by John Baird » Wed Jun 05, 2019 9:55 am

Hi Steve Bow,
Place this little php routine on your index page. If you want to see how it works go to http://home.exetel.com.au/pushbike/ and to the link Space at the bottom of the page.

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html>
<head>
<title>webspace size</title>
</head>
<body background="#FFF">
<?php
// function du written by Gregor Mosheh on 17-Jul-2003 03:25
// version 1.01 written by psylogic
// just run this script and it will return the current size of your webspace in bytes
function du($location) {
if (!$location or !is_dir($location)) {
return 0;
}

$total = 0;

$all = opendir($location);
while ($file = readdir($all)) {
if (is_dir($location.'/'.$file) and $file <> ".." and $file <> ".") {
$total += du($location.'/'.$file);
unset($file);
}
elseif (!is_dir($location.'/'.$file)) {
$stats = stat($location.'/'.$file);
$total += $stats['size'];
unset($file);
}
}
closedir($all);
unset($all);
return $total;
}
?>
<div style="background-color:#ccc;">
<?php
print du(getcwd());
?>
<br />
<br />
<?php
print getcwd();
?>
<br />
</div>
</body>
</html>

Post Reply