예제 #1
0
/**
 * Team center home page (part of Team Center)
 * 
 * @package ResourceSpace
 * @subpackage Pages_Team
 */
include "../../include/db.php";
include "../../include/authenticate.php";
if (!checkperm("t")) {
    exit("Permission denied.");
}
include "../../include/general.php";
include "../../include/resource_functions.php";
if ($send_statistics) {
    send_statistics();
}
$overquota = overquota();
# Work out free space / usage for display
if (!file_exists($storagedir)) {
    mkdir($storagedir, 0777);
}
if (isset($disksize)) {
    $avail = $disksize * (1024 * 1024 * 1024);
    $used = get_total_disk_usage();
    $free = $avail - $used;
} else {
    $avail = disk_total_space($storagedir);
    $free = disk_free_space($storagedir);
    $used = $avail - $free;
}
예제 #2
0
<?php
/**
 * Team center home page (part of Team Center)
 * 
 * @package ResourceSpace
 * @subpackage Pages_Team
 */
include "../../include/db.php";
include "../../include/authenticate.php";if (!checkperm("t")) {exit ("Permission denied.");}
include "../../include/general.php";
include "../../include/resource_functions.php";

if ($send_statistics) {send_statistics();}

$overquota=overquota();


# Work out free space / usage for display
if (!file_exists($storagedir)) {mkdir($storagedir,0777);}

if (isset($disksize)) # Use disk quota rather than real disk size
	{
	$avail=$disksize*(1024*1024*1024);
	$used=get_total_disk_usage();
	$free=$avail-$used;
	}
else
	{		
	$avail=disk_total_space($storagedir);
	$free=disk_free_space($storagedir);
	$used=$avail-$free;